[SYCL] Fix compilation warnings in libdevice#1630
Conversation
|
Fixes compilation warnings like repeated for lines 17, 18, 20, 21, 22. |
|
Passes |
|
On the other hand, this breaks building with |
I guess this is because spirv_vars.hpp is included before DEVICE_EXTERNAL is defined in device.h :-) |
Apply the `DEVICE_EXERNAL` attribute also to the function definitions, not only to the function declarations. Signed-off-by: Andrea Bocci <andrea.bocci@cern.ch>
e65de2f to
e830bc7
Compare
Indeed, including it at the end seems to fix the compilation. |
|
I am, however, a bit confused about
Is |
Yes, it is pretty much WIP, especially after we moved it to toplevel. I am moving I will try deploy-sycl-toolchain, but from what I see here https://github.com/intel/llvm/blob/sycl/sycl/CMakeLists.txt#L292 and here https://github.com/intel/llvm/blob/sycl/libdevice/cmake/modules/SYCLLibdevice.cmake#L163 it has to be deployed. |
What files should I look for in the installation directory ? |
Files like these: |
Thanks, then yes, they are installed by |
…_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) ...
While running OpenCL-CTS SPIR-V subtests, i found that launching llvm-spirv with arguments: -r --spec-const=101:i64:4609589727908835759 results in error message: Error: Invalid value for '-spec-const' option! In "101:i64:4609589727908835759": can't convert "4609589727908835759" to 64-bit integer number However, 4609589727908835759 fits into 64bits (0x3ff88d6f544bb1af). The problem seems to be that getNumWords() returns 2 so i changed it to use getActiveBits(). Original commit: KhronosGroup/SPIRV-LLVM-Translator@1103477
Apply the
DEVICE_EXERNALattribute also to the function definitions,not only to the function declarations.
Signed-off-by: Andrea Bocci andrea.bocci@cern.ch