-
Notifications
You must be signed in to change notification settings - Fork 769
[SYCL][DOC] Add documentation for the filter selector #2460
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
Conversation
Signed-off-by: James Brodman <[email protected]>
|
||
=== DSL for Specifying Filters | ||
|
||
A string passed to the selector defines one or more filters. Filters have a certain syntax that must be followed. A filter is specified as a triple of the form: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we define what happens if that syntax is not followed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Throws an error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Throws an error.
Just to expand, syntax being incorrect throws and error, but what about requesting a GPU when there isn't one or requesting gpu:1 when only gpu:0 exists?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should get a runtime error (some sorta device not found one) similar to using gpu_selector when there's no gpu.
|
||
== Filter Selector | ||
|
||
The filter selector is a new device selector class that accepts a string of one or more filters that refine the set of devices that may be returned when the selector's `select_device` method is invoked. Devices that match the specified filter(s) are ranked by the default_selector to determine which device is ultimately selected. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand how default_selector fits in here. Should it be filter_selector?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The default selector is used to score devices that match the filter, in case more than one device does.
Signed-off-by: James Brodman <[email protected]>
…arget (#2470) This change addresses p.4 of #2460. No changes for OpCopyMemory as we currently don't use it in translation. Original commit: KhronosGroup/SPIRV-LLVM-Translator@a384e036501551e
Do nothing for now, as it's not used in translator. Addresses p.6 of #2460 Original commit: KhronosGroup/SPIRV-LLVM-Translator@2c3b505879dcaf1
There is no mapping to LLVM instructions, so it can be used only via SPIR-V friendly translation. This addresses p1. of #2460 Original commit: KhronosGroup/SPIRV-LLVM-Translator@8518a6f72fd586c
…2482) This addresses p.2 and p.3 of #2460 Original commit: KhronosGroup/SPIRV-LLVM-Translator@4b4508438a6dfe5
There is no mapping to LLVM instructions, so it can be used only via SPIR-V friendly translation. This addresses p1. of #2460 Original commit: KhronosGroup/SPIRV-LLVM-Translator@8518a6f72fd586c
…2482) This addresses p.2 and p.3 of #2460 Original commit: KhronosGroup/SPIRV-LLVM-Translator@4b4508438a6dfe5
…ng (#2677) This PR adds "reverse translation" (from SPIR-V to LLVM IR) support for OpDecorateString and OpMemberDecorateString, see #2460 and #2670. These instructions are currently treated as synonyms for OpDecorate and OpMemberDecorate. We'll want to tidy this up at some point, but at least for now we won't crash if we see these instructions. I'll still need to add proper support for decorating variables in the input storage class for #2670, but I'll do that in a separate PR. Original commit: KhronosGroup/SPIRV-LLVM-Translator@f7057b44e20fd06
…ng (#2677) This PR adds "reverse translation" (from SPIR-V to LLVM IR) support for OpDecorateString and OpMemberDecorateString, see #2460 and #2670. These instructions are currently treated as synonyms for OpDecorate and OpMemberDecorate. We'll want to tidy this up at some point, but at least for now we won't crash if we see these instructions. I'll still need to add proper support for decorating variables in the input storage class for #2670, but I'll do that in a separate PR. Original commit: KhronosGroup/SPIRV-LLVM-Translator@f7057b44e20fd06
[Benchmarks] fix running benchmarks when umf dir is not specified
Document the design and function of ONEAPI::filter_selector.
Signed-off-by: James Brodman [email protected]