[clang] [Driver][SYCL] Add compile-time device library linking for SPIR-V targets (PR #196656)

via cfe-commits cfe-commits at lists.llvm.org
Fri May 8 15:51:07 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Linux-->
# :penguin: Linux x64 Test Results

* 87900 tests passed
* 1551 tests skipped
* 6 tests failed

## Failed Tests
(click on a test name to see its output)

### lldb-api
<details>
<summary>lldb-api.python_api/run_locker/TestRunLocker.py</summary>

```
Script:
--
/usr/bin/python3 /home/gha/actions-runner/_work/llvm-project/llvm-project/lldb/test/API/dotest.py -u CXXFLAGS -u CFLAGS --env LLVM_LIBS_DIR=/home/gha/actions-runner/_work/llvm-project/llvm-project/build/./lib --env LLVM_INCLUDE_DIR=/home/gha/actions-runner/_work/llvm-project/llvm-project/build/include --env LLVM_TOOLS_DIR=/home/gha/actions-runner/_work/llvm-project/llvm-project/build/./bin --libcxx-include-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/include/c++/v1 --libcxx-include-target-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/include/x86_64-unknown-linux-gnu/c++/v1 --libcxx-library-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/./lib/x86_64-unknown-linux-gnu --triple x86_64-unknown-linux-gnu --build-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/lldb-test-build.noindex --lldb-module-cache-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/lldb-test-build.noindex/module-cache-lldb/lldb-api --clang-module-cache-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/lldb-test-build.noindex/module-cache-clang/lldb-api --executable /home/gha/actions-runner/_work/llvm-project/llvm-project/build/./bin/lldb --compiler /home/gha/actions-runner/_work/llvm-project/llvm-project/build/./bin/clang --dsymutil /home/gha/actions-runner/_work/llvm-project/llvm-project/build/./bin/dsymutil --make /usr/bin/gmake --llvm-tools-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/./bin --lldb-obj-root /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/lldb --lldb-libs-dir /home/gha/actions-runner/_work/llvm-project/llvm-project/build/./lib --cmake-build-type Release /home/gha/actions-runner/_work/llvm-project/llvm-project/lldb/test/API/python_api/run_locker -p TestRunLocker.py
--
Exit Code: 1

Command Output (stdout):
--
lldb version 23.0.0git (https://github.com/llvm/llvm-project revision 86024b1ebe098c6d60a1f3f653742f2b88d1000a)
  clang revision 86024b1ebe098c6d60a1f3f653742f2b88d1000a
  llvm revision 86024b1ebe098c6d60a1f3f653742f2b88d1000a
"can't evaluate expressions when the process is running."
Skipping the following test categories: msvcstl, dsym, pdb, gmodules, debugserver, objc

--
Command Output (stderr):
--
Traceback (most recent call last):
  File "<input>", line 1, in <module>
AttributeError: 'NoneType' object has no attribute 'EvaluateExpression'
FAIL: LLDB (/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang-x86_64) :: test_run_locker (TestRunLocker.TestRunLocker.test_run_locker)
Log Files:
 - /home/gha/actions-runner/_work/llvm-project/llvm-project/build/lldb-test-build.noindex/python_api/run_locker/TestRunLocker/Failure_test_run_locker.log
PASS: LLDB (/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang-x86_64) :: test_run_locker_stop_at_entry (TestRunLocker.TestRunLocker.test_run_locker_stop_at_entry)
======================================================================
FAIL: test_run_locker (TestRunLocker.TestRunLocker.test_run_locker)
   Test that the run locker is set correctly when we launch
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/gha/actions-runner/_work/llvm-project/llvm-project/lldb/packages/Python/lldbsuite/test/decorators.py", line 160, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/gha/actions-runner/_work/llvm-project/llvm-project/lldb/test/API/python_api/run_locker/TestRunLocker.py", line 23, in test_run_locker
    self.runlocker_test(False)
  File "/home/gha/actions-runner/_work/llvm-project/llvm-project/lldb/test/API/python_api/run_locker/TestRunLocker.py", line 110, in runlocker_test
    self.assertIn(
AssertionError: "can't evaluate expressions when the process is running" not found in ''
Config=x86_64-/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang
----------------------------------------------------------------------
Ran 2 tests in 0.552s

FAILED (failures=1)

--

```
</details>

### Clang
<details>
<summary>Clang.Driver/sycl-offload-jit-unix.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 10
rm -rf /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp && mkdir -p /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/bin /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/lib/x86_64-unknown-linux-gnu
# executed command: rm -rf /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp
# note: command had no output on stdout or stderr
# executed command: mkdir -p /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/bin /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/lib/x86_64-unknown-linux-gnu
# note: command had no output on stdout or stderr
# RUN: at line 11
touch /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/lib/x86_64-unknown-linux-gnu/libLLVMSYCL.so
# executed command: touch /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/lib/x86_64-unknown-linux-gnu/libLLVMSYCL.so
# note: command had no output on stdout or stderr
# RUN: at line 12
ln -s /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/bin/clang
# executed command: ln -s /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/bin/clang
# note: command had no output on stdout or stderr
# RUN: at line 13
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/bin/clang -### -no-canonical-prefixes --target=x86_64-unknown-linux-gnu -fsycl /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-unix.cpp 2>&1    | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefixes=CHECK-LSYCL,CHECK-SYCL-HEADERS-HOST,CHECK-SYCL-HEADERS-DEVICE /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-unix.cpp
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/clang/test/Driver/Output/sycl-offload-jit-unix.cpp.tmp/bin/clang '-###' -no-canonical-prefixes --target=x86_64-unknown-linux-gnu -fsycl /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-unix.cpp
# note: command had no output on stdout or stderr
# error: command failed with exit status: 1
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefixes=CHECK-LSYCL,CHECK-SYCL-HEADERS-HOST,CHECK-SYCL-HEADERS-DEVICE /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-unix.cpp
# note: command had no output on stdout or stderr

--

```
</details>
<details>
<summary>Clang.Driver/sycl-offload-jit-xarch.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 5
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -fsycl --offload-targets=spirv64-unknown-unknown -Xarch_spirv64 -O3 -### /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-xarch.cpp 2>&1  | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefix=SYCL-DEVICE-O3 /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-xarch.cpp
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -fsycl --offload-targets=spirv64-unknown-unknown -Xarch_spirv64 -O3 '-###' /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-xarch.cpp
# note: command had no output on stdout or stderr
# error: command failed with exit status: 1
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefix=SYCL-DEVICE-O3 /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit-xarch.cpp
# note: command had no output on stdout or stderr

--

```
</details>
<details>
<summary>Clang.Driver/sycl-offload-jit.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 4
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -ccc-print-phases --target=x86_64-unknown-linux-gnu -fsycl /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp 2>&1    | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefixes=CHK-PHASES /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -ccc-print-phases --target=x86_64-unknown-linux-gnu -fsycl /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# note: command had no output on stdout or stderr
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefixes=CHK-PHASES /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# note: command had no output on stdout or stderr
# RUN: at line 6
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang --driver-mode=cl -ccc-print-phases --target=x86_64-pc-windows-msvc -fsycl -- /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp 2>&1    | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefixes=CHK-PHASES /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang --driver-mode=cl -ccc-print-phases --target=x86_64-pc-windows-msvc -fsycl -- /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# note: command had no output on stdout or stderr
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefixes=CHK-PHASES /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# note: command had no output on stdout or stderr
# RUN: at line 24
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -### -fsycl -c --target=x86_64-unknown-linux-gnu /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp 2>&1    | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefix=CHK-DEVICE-TRIPLE /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang '-###' -fsycl -c --target=x86_64-unknown-linux-gnu /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# note: command had no output on stdout or stderr
# error: command failed with exit status: 1
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -check-prefix=CHK-DEVICE-TRIPLE /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-offload-jit.cpp
# note: command had no output on stdout or stderr

--

```
</details>
<details>
<summary>Clang.Driver/sycl-std-default.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 3
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang --driver-mode=g++ -### -fsycl -c /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-std-default.cpp 2>&1 | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-std-default.cpp --check-prefixes=CHECK-DEVICE,CHECK-HOST
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang --driver-mode=g++ '-###' -fsycl -c /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-std-default.cpp
# note: command had no output on stdout or stderr
# error: command failed with exit status: 1
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl-std-default.cpp --check-prefixes=CHECK-DEVICE,CHECK-HOST
# note: command had no output on stdout or stderr

--

```
</details>
<details>
<summary>Clang.Driver/sycl.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 1
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -### -fsycl -c /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl.cpp 2>&1 | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl.cpp --check-prefix=ENABLED
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang '-###' -fsycl -c /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl.cpp
# note: command had no output on stdout or stderr
# error: command failed with exit status: 1
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/Driver/sycl.cpp --check-prefix=ENABLED
# note: command had no output on stdout or stderr

--

```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

https://github.com/llvm/llvm-project/pull/196656


More information about the cfe-commits mailing list