[SYCL][ABI] Subgroup Extension spec update#1600
Conversation
sycl/plugins/opencl/pi_opencl.cpp
Outdated
There was a problem hiding this comment.
the OpenCL returns "size_t", why are you truncating this to 32-bit? If really needed (I don't think it is) we should document this for piKernelGetSubGroupInfo
There was a problem hiding this comment.
The return type of the get_sub_group_info APIs have been changed to return uint32_t data instead of size_t, which is why this change was done. How should this be documented?
There was a problem hiding this comment.
Add a comment in the pi.h for piKernelGetSubGroupInfo to indicated now supported parameters with their sizes.
There was a problem hiding this comment.
But I suggest that we continue to use "size_t" in PI, and truncate at SYCL level.
There was a problem hiding this comment.
I have made the call to PI_API check the returned size of the result value and truncate the value appropriately. Does this look better?
I'm essentially hesitant to make it size_t based on OpenCL spec, because if any new backend is developed based on the SYCL extension spec, it will have to change the Plugin to cast the uint32_t to size_t first, and then in the library will be casting the size_t to uint32_t. It will be weird that the PI APIs are not SYCL extension spec compliant.
There was a problem hiding this comment.
I'm essentially hesitant to make it size_t based on OpenCL spec
I'd be fine making it uint32_t in PI, document this in the pi.h, and truncate in OpenCL plugin.
But we should stick to just one size that fits SYCL well.
There was a problem hiding this comment.
@smaslov-intel : Do you mean the initial solution was ok with the document change?
There was a problem hiding this comment.
Yes, I'd be fine with it.
There was a problem hiding this comment.
Thanks. I have updated the review. Let me know if it looks good.
102c7eb to
11bcbd9
Compare
|
@smaslov-intel Ping. |
eac4935 to
ac04c3f
Compare
alexbatashev
left a comment
There was a problem hiding this comment.
ac04c3f to
602c90f
Compare
https://github.com/intel/llvm/blob/sycl/sycl/doc/ABIPolicyGuide.md |
e083664 to
b4c6d7b
Compare
Thank you for the link @alexbatashev . Let me know if I have missed something. I have updated the Major version, the ABI version and the PR commit message. |
sycl/CMakeLists.txt
Outdated
There was a problem hiding this comment.
@garimagu the major version is updated once per release. You only need to update DEV_ABI version.
| set(SYCL_MAJOR_VERSION 1) | |
| set(SYCL_MAJOR_VERSION 0) |
There was a problem hiding this comment.
uploaded the change. please review and approve. smaslov-intel has approved the changes other than the ABI version update.
There was a problem hiding this comment.
I think we should (semi-)automate SYCL version update.
It's hard to manage multiple commits requiring version update.
@alexbatashev, could you create a post-commit job, which will create a PR with the version update if it's required, please?
Implements the change as per the spec update at https://github.com/intel/llvm/blob/sycl/sycl/doc/extensions/SubGroup/SYCL_INTEL_sub_group.asciidoc and update from : intel#1565 ABI update: Functions corresponding to the deleted APIs have been deleted. Edit info.cpp test to expect max sub-group size based on the spec update. Changed pi.h document and changed the plugin to always return a 32 bit value. ABI version update. Signed-off-by: Garima Gupta <garima.gupta@intel.com>
cee31e8 to
21c9f6f
Compare
Signed-off-by: Garima Gupta <garima.gupta@intel.com>
|
@bader Please approve and merge. |
|
Waiting on code owner review from smaslov-intel and/or intel/llvm-reviewers-runtime. |
bader
left a comment
There was a problem hiding this comment.
LGTM. A few minor suggestions.
| static uint32_t get(RT::PiKernel Kernel, RT::PiDevice Device, | ||
| const plugin &Plugin) { | ||
| uint32_t Result; | ||
| // TODO catch an exception and put it to list of asynchronous exceptions |
There was a problem hiding this comment.
| // TODO catch an exception and put it to list of asynchronous exceptions |
There was a problem hiding this comment.
Should this comment be removed?
There was a problem hiding this comment.
AFAIK, this comment is not valid anymore. Most of the errors now reported through synchronous exceptions.
Although, I'm not the owner of the runtime and let @intel/llvm-reviewers-runtime to decide.
Signed-off-by: Garima Gupta <garima.gupta@intel.com>
|
@bader uploaded the changes. smaslov has also approved the changes just before the suggested changes were merged. |
|
@bader ping |
[L0] Refactoring of boolean event parameters
Implements the change as per the spec update at
https://github.com/intel/llvm/blob/sycl/sycl/doc/extensions/SubGroup/SYCL_INTEL_sub_group.asciidoc
and update from : #1565
ABI update: Symbols corresponding to the deleted APIs have been deleted.
Signed-off-by: Garima Gupta garima.gupta@intel.com