[SYCL] Switch to using integration footer by default#3777
Conversation
…e header This patch moves functions which use `__builtin_unique_stable_name` to a separate header which should only be included to integration footer. This was made to get rid of UB when the compiler sees defenition of the template specialization before seeing a declaration.
This description is not accurate |
Right, it is not directly related to |
…_stable_name-to-separate-header
…_stable_name-to-separate-header
…bled by default for any app
|
I don't think we should be putting the last patch into the repo, we are about a week and a half away from getting the actual implementation, and this will delay it. |
…e_name-to-separate-header
…e_name-to-separate-header
erichkeane
left a comment
There was a problem hiding this comment.
Just 2 CFE test nits.
…din_unique_stable_name-to-separate-header
3ef8887
…din_unique_stable_name-to-separate-header
…din_unique_stable_name-to-separate-header
The primary function/wrapper which is used by DPC++ RT is left as-is, i.e. `get_spec_constant_symbolic_ID`. The internal function and its specialziations which are generated by the compiler renamed to `get_spec_constant_symbolic_ID_impl`.
|
@AGindinson, @mdtoguchi, could you please take a look at the driver part? Basically, we have enabled integration footer by default and turned existing @AaronBallman, @elizabethandrews, @premanandrao, could you please take a look at FE part? The changes are quite simple: we have added a few more includes to emitted integration footer + did renaming |
elizabethandrews
left a comment
There was a problem hiding this comment.
FE changes LGTM. Thanks!
…din_unique_stable_name-to-separate-header
…eparate-header' of github.com:dm-vodopyanov/llvm into private/dvodopya/move-__buildin_unique_stable_name-to-separate-header
elizabethandrews
left a comment
There was a problem hiding this comment.
FE changes LGTM
* upstream/sycl: (649 commits) [SYCL][Driver][NFC] Update integration footer test for 32-bit host (intel#4039) [SYCL][L0] Initialize descriptor .stype and .pNext (intel#4032) [SYCL] Add sycl::kernel::get_kernel_bundle method (intel#3855) [SYCL] Add support for device UUID as a SYCL extension. (intel#3696) [SYCL][Matrix] Add spec document for the matrix extension interface and its first implementation for AMX (intel#3551) Fix debug build mangler test after PR#3992 (8f38045). (intel#4033) [Driver][SYCL] Restrict user -include file in final integration footer step (intel#4036) [SYCL] [Tests] Do not copy device binary image mocks (intel#4023) [SYCL][Doc] Update docs to reflect new compiler features (intel#4030) [SYCL][CUDA] cl_khr_fp16 extension connected to cuda PI. (intel#4029) [SYCL][NFC] Refactor RT unit tests (intel#4021) [SYCL] Switch to using integration footer by default (intel#3777) [SYCL][CUDA] Add the Use Default Stream property (intel#4004) Uplift GPU RT version for Linux to 21.24.20098 (intel#4003) [SYCL][CUDA] atomic_ref.fetch_add used for fp64 reduction if device.has(atomic64) (intel#3950) [Driver][SYCL] Differentiate host dependency link from regular host link (intel#4002) [SYCL][ESIMD] Support device half type in intrinsics. (intel#4024) [SYCL] Allow fpga_reg only for PODs and Trivially-copyable structs (intel#3643) [SYCL][FPGA] Restore legacy debug info version for the hardware (intel#3991) [SYCL][PI][L0] Force reset of memcpy command-list. (intel#4001) ...
For a vector type, add `SPV_EXT_long_vector` extension and prioritize it over `SPV_INTEL_vector_compute` whenever the vector type doesn't have a standard component size (2, 3, 4, 8, or 16). Original commit: KhronosGroup/SPIRV-LLVM-Translator@7d4b128df7e6ff3
#3829) #3777 added `SPV_EXT_long_vector` and gave it priority over `SPV_INTEL_vector_compute`: when both extensions are enabled and a vector has a non-standard component count, the translator now emits `CapabilityLongVectorEXT` instead of `CapabilityVectorAnyINTEL`. This regresses `VectorCompute` modules. The offloading flow (producing both `VectorCompute` and non-`VectorCompute` modules) applies a single, fixed extension list uniformly to every device image, so a `VectorCompute` module is translated with both `SPV_INTEL_vector_compute` and `SPV_EXT_long_vector` enabled. Before #3777 such a module emitted `VectorAnyINTEL` for its non-standard vectors; after #3777 it emits `LongVectorEXT`. `VectorCompute` consumers require `VectorAnyINTEL`, so this is a functional regression. Hence, the enabled extension list does not identify a module as `VectorCompute` - the `VectorCompute` metadata (`VCFunction` /`VCGlobalVariable`) does. `IsVectorComputeModule` records the presence of that metadata before type translation. `VectorCompute` modules keep using `VectorAnyINTEL`, restoring the pre-#3777 behavior; all other modules still prefer the multi-vendor `LongVectorEXT` when its extension is enabled. --------- Co-authored-by: Ye, Qi <qi.ye@intel.com> Original commit: KhronosGroup/SPIRV-LLVM-Translator@3238c2903cd177e
Added
spec_constant_integration.hppheader file, which is included fromintegration footer.
Added
get_spec_constant_symbolic_ID_wrapperwhich in combinationwith
spec_constant_integration.hppallows us to avoid exploiting a UBrelated to instantiating a template before we have seen all its
specializations.
Replaced
-fsycl-use-footercompiler flag with-fno-sycl-use-footerflag with the opposite semantics.