-
Notifications
You must be signed in to change notification settings - Fork 788
[SYCL] Add template parameter support for max_global_work_dim attribute #2816
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
This patch adds support for template parameter on [[intel::max_global_work_dim)]] attribute splits test/SemaSYCL/intel-max-global-work-dim.cpp to separate files for host compilation (test/SemaSYCL/intel-max-global-work-dim.cpp-host.cpp) and device compilation (test/SemaSYCL/intel-max-global-work-dim.cpp-device.cpp) updates sema/codegen tests with mock headers on device. uses existing function "addIntelSYCLSingleArgFunctionAttr" of other single argument function attributes such as num_simd_work_items and intel_reqd_sub_group_size source codes to avoid duplication and reuse for the template parameter support. Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
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.
LGTM, just two nits.
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
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.
One suggestion.
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
17bb689
to
f11d097
Compare
Sorry for the force push (not able to publish commit by git push) |
Please, remove Yes, it is removed now. |
Signed-off-by: Soumi Manna <[email protected]>
Template parameter support was added for 1. [[intel::max_global_work_dim)]] attribute on intel#2816 2. [[intel::num_simd_work_items()]] attribute on intel#2510 3. [[intel::reqd_sub_group_size()]] attribute on intel#1807 This patch adds the following new test cases that were not there before to improve the support: 1. Test that checks wrong function template instantiation and ensures that the type is checked properly when instantiating from the template definition. 2. Test that checks expression is not a constant expression. 3. Test that checks expression is a constant expression. 4. Test that checks template parameter support on function. NOTE: No change in compiler. All new test cases have already been supported. Signed-off-by: Soumi Manna <[email protected]>
…3089) Template parameter support was added for 1. [[intel::max_global_work_dim)]] attribute on #2816 2. [[intel::num_simd_work_items()]] attribute on #2510 3. [[intel::reqd_sub_group_size()]] attribute on #1807 This patch adds the following new test cases that were not there before to improve the support: 1. Test that checks wrong function template instantiation and ensures that the type is checked properly when instantiating from the template definition. 2. Test that checks expression is not a constant expression. 3. Test that checks expression is a constant expression. 4. Test that checks template parameter support on function. NOTE: No change in compiler. All new test cases have already been supported. Signed-off-by: Soumi Manna <[email protected]>
This patch
adds support for template parameter on [[intel::max_global_work_dim)]] attribute
splits test/SemaSYCL/intel-max-global-work-dim.cpp to separate files for
host compilation (test/SemaSYCL/intel-max-global-work-dim.cpp-host.cpp) and
device compilation (test/SemaSYCL/intel-max-global-work-dim.cpp-device.cpp)
updates sema/codegen tests with mock headers on device.
uses existing function "sema::addIntelSYCLSingleArgFunctionAttr" from
other single argument function attributes such as num_simd_work_items
and intel_reqd_sub_group_size to avoid source codes duplication and
reuse for the template parameter support.
addresses special diagnostics in case the value of ‘max_global_work_dim’
attribute equals to 0, we shall ensure that if max_work_group_size and
reqd_work_group_size attributes exist, they hold equal values (1, 1, 1).
additionally updates sema/codegen tests for "reqd-sub-group-size" and
"num-simd-work-items" attributes with mock headers.
Signed-off-by: Soumi Manna [email protected]