-
Notifications
You must be signed in to change notification settings - Fork 772
[SYCL] Throw exception if range/offset of kernel execution exceeds INT_MAX #1713
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
[SYCL] Throw exception if range/offset of kernel execution exceeds INT_MAX #1713
Conversation
…T_MAX Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
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.
Since this is C++ you should use https://en.cppreference.com/w/cpp/header/limits instead of old INT_MAX
C macro
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
@s-kanaev, are you going to address this? |
I believe not as the contract was about |
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.
are you going to address this?
I believe not as the contract was about
INT_MAX
.
I don't follow. What "contract" are you talking about?
Sorry, a little misunderstanding here.
The comment is addressed. |
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com>
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.
This looks better. Thanks.
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.
Please fix that issue with std::max + windows.h by adding parentheses around max.
This is pretty common issue that, I believe, must have worked-around in SYCL headers.
Signed-off-by: Sergey Kanaev <sergey.kanaev@intel.com> Co-authored-by: Vyacheslav Klochkov <34946562+v-klochkov@users.noreply.github.com>
* upstream/sycl: [SYCL] Handle KernelName templated using type with enum template argument (intel#1780) [SYCL] Fix KernelNameInfo generated for empty template parameter pack (intel#1775) [SYCL] Do not export utility methods from SYCLMemObjT (intel#1768) [Driver][SYCL] Fix processing when using -fsycl-link (intel#1765) [SYCL][NFC] Remove outdated confusing comment (intel#1779) [SYCL][NFC] Wrap classes in .cpp into a namespace to disable external linkage. (intel#1776) [SYCL][CUDA] Fixes CUDA unit tests that uses SYCL directly (intel#1763) [SYCL][Doc] Fix default device selection rules doc (intel#1769) [SYCL][CUDA] Remove pi Event Callback implementation (intel#1735) [SYCL] Throw exception if range/offset of kernel execution exceeds INT_MAX (intel#1713) [SYCL-PTX] Add intermediate layer to libclc to ease type management (intel#1712)
The exception will only be thrown if
__SYCL_ID_QUERIES_FIT_IN_INT
macro is defined.