[SYCL][Driver][libdevice] Link libspirv in -fsycl-device-only
mode
#19136
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Based on PR #19135
Chain of upstream PRs as of 2025-06-25
PR [SYCL][Driver] Improve SYCL libspirv linking test coverage (NFC) #19130
PR [SYCL][Driver] Deduplicate libspirv logic #19131
PR [SYCL][Driver] Base libspirv path on sycl install candidates #19134
PR [SYCL][Driver] Emit unused argument warning for -fno-libspirv #19135
-fsycl-device-only
mode #19136 (THIS ONE)Previously, the
-fsycl-device-only
mode disabled linking libspirv.-fsycl-device-only
should produce the same LLVM-IR as-fsycl
would,but without any host actions.
Libdevice is the likely reason why this was done as is, but it should
not be the default. This patch changes libdevice options to disable
libspirv linking there, and enables linking by default in
-fsycl-device-only
mode.