Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove confusing wording about errors #471

Merged

Conversation

gmlueck
Copy link
Contributor

@gmlueck gmlueck commented Oct 11, 2023

I noticed this while reviewing work on the SYCL reference guide.

The specification for the member functions queue::get_context and queue::get_device implied that they could throw an exception for an error scenario. I cannot think of any reason these functions could fail because a queue always has a context and a device. Therefore, I think we should remove these sentences. For example, notice that there is no similar wording for queue::is_in_order, which also has no obvious reason to fail.

I noticed this while reviewing work on the SYCL reference guide.

The specification for the member functions `queue::get_context` and
`queue::get_device` implied that they could throw an exception for an
error scenario.  I cannot think of any reason these functions could
fail because a queue always has a context and a device.  Therefore,
I think we should remove these sentences.  For example, notice that
there is no similar wording for `queue::is_in_order`, which also has
no obvious reason to fail.
@keryell
Copy link
Member

keryell commented Oct 11, 2023

I guess there is always the possibility that the device is no longer available for some reason.

@gmlueck
Copy link
Contributor Author

gmlueck commented Oct 11, 2023

I guess there is always the possibility that the device is no longer available for some reason.

But we have already decided that SYCL 2020 does not support hot-swapped devices:

The execution environment for a SYCL application has a fixed number of root devices which does not vary as the application executes.

(https://registry.khronos.org/SYCL/specs/sycl-2020/html/sycl-2020.html#sec:device-class)

@TApplencourt
Copy link
Contributor

I agree with Greg that for SYCL 2020, I don't see how they can fail. (for SYCL SC Next this is another topic :) )

@gmlueck gmlueck merged commit bd17f78 into KhronosGroup:SYCL-2020/master Nov 9, 2023
2 checks passed
@gmlueck gmlueck deleted the gmlueck/queue-get-errors branch December 1, 2023 19:29
keryell pushed a commit that referenced this pull request Sep 10, 2024
Remove confusing wording about errors
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants