[SPIR-V] Correct/improve declaration of some SPIR-V builtins#1519
Conversation
|
Some of the changes are also in PR (some rounding modes) #1463, will remove the WIP once it is merged |
There was a problem hiding this comment.
Why do you need it?
BTW, I think we should use OpenCL address spaces "as is" instead of doing some stuff with SYCL address spaces.
There was a problem hiding this comment.
Yeah, there was a significant effort as I recall to remove this, @bader ?
There was a problem hiding this comment.
Yeah, here it is #1039 . The only problem is failing C++ for OpenCL test but it is because of bug in C++ for OpenCL (I debugged it and described it in comments for PR 1039).
There was a problem hiding this comment.
BTW, I think we should use OpenCL address spaces "as is" instead of doing some stuff with SYCL address spaces.
I totally agree with you, I don't see any rational to have this distinction.
The problem is that this patch is not merge, so for the moment opencl_global != sycl_global. This means a pointer to opencl_global is different to a pointer sycl_global.
e3e97b8 to
e5d0def
Compare
e5d0def to
a934aab
Compare
a934aab to
ca75e50
Compare
Fznamznon
left a comment
There was a problem hiding this comment.
To be honest I'm not an expert in SPIRV built-ins and this tablegen solution yet. @AlexeySachkov @fadeeval , I see that you have been working on it, could you please help with review?
BTW, can we commit it after the change re-using OpenCL address space attributes? #1581 . I guess, then we won't need conversions between sycl and opencl address spaces.
I was sure I commented somewhere about this... I agree, this would avoid pushing a workaround. |
Make the address space overloads more flexible by supporting OpenCL and SYCL. Correct the signature of __spirv_ocl_native_* and __spirv_ocl_half_* builtins. Correct the naming of overloads of __spirv_ocl_vload* and __spirv_ocl_vstore* builtins. Add missing overloads for conversion with specific rounding modes and saturation. Remove inexistent __spirv_All(bool) and __spirv_Any(bool) overloads. Signed-off-by: Victor Lomuller <victor@codeplay.com>
ca75e50 to
ad01615
Compare
|
@Fznamznon I rebased to tip, the address space work around is now gone 🎉 |
|
I don't understand the purpose of the changes enough to review, so @bader s review will have to be enough (or we wait for @Fznamznon to return). |
…_docs * origin/sycl: (6482 commits) [SYCL][NFC] Clean formatting in Markdown documents (intel#1635) [SYCL][Doc] Remove obsolete parens from README (intel#1637) [SYCL] Fix failing ABI tests when LLVM_LIBDIR_SUFFIX is set (intel#1605) [SYCL] Fix warnings in libdevice (intel#1630) [SYCL][CUDA] Triage and clean LIT (intel#1620) [SYCL][NFC] Fix GCC 8 compilation warnings (intel#1631) [SYCL] Minor fixes in LowerWGScope [SYCL] PI: correct default interoperability plugin selection [SYCL] Add faster reduction implementations using atomic or/and intel::reduce() (intel#1615) [SYCL] Add sycl-ls utility for listing devices discovered/selected by SYCL RT (intel#1575) [SYCL] Fix getDeviceFromHandler declarations (intel#1626) [SPIR-V] Correct/improve declaration of SPIR-V builtins (intel#1519) [SYCL][USM] Improve USM allocator test and fix improper behavior. (intel#1538) [SYCL] Fix failing ABI LITs (intel#1622) [SYCL] Add support for MSVC internal math functions in device library (intel#1441) [SYCL] Add runtime library versioning (intel#1604) [SYCL] Check weak symbols in ABI dumps (intel#1609) [NFC][SYCL] Improve kernel metadata test (intel#1610) Revert "[SYCL] XFAIL LIT test due to duplicate diagnostic" (intel#1460) [SYCL] Move the reduction command group funcs out of handler.hpp (intel#1602) ...
Make the address space overloads more flexible by supporting OpenCL and SYCL.
Correct the signature of _spirv_ocl_native* and _spirv_ocl_half* builtins.
Correct the naming of overloads of __spirv_ocl_vload* and __spirv_ocl_vstore* builtins.
Add missing overloads for conversion with specific rounding modes and saturation.
Remove inexistent __spirv_All(bool) and __spirv_Any(bool) overloads.
Signed-off-by: Victor Lomuller victor@codeplay.com