[clang] [llvm] [Offload][Driver] Split frontend CUDA/HIP language assumptions from backend device (PR #212373)
via cfe-commits
cfe-commits at lists.llvm.org
Mon Jul 27 17:46:08 PDT 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results
* 139046 tests passed
* 3590 tests skipped
* 4 tests failed
## Failed Tests
(click on a test name to see its output)
### Clang
<details>
<summary>Clang.CodeGenCUDA/offload_via_llvm.cu</summary>
```
Exit Code: 2
Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\24\include -nostdsysteminc C:\_work\llvm-project\llvm-project\clang\test\CodeGenCUDA\offload_via_llvm.cu -triple nvptx-unknown-unknown -foffload-via-llvm -emit-llvm -o - | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CodeGenCUDA\offload_via_llvm.cu --check-prefix=HST
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\24\include' -nostdsysteminc 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenCUDA\offload_via_llvm.cu' -triple nvptx-unknown-unknown -foffload-via-llvm -emit-llvm -o -
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\clang\test\CodeGenCUDA\offload_via_llvm.cu:73:17: error: Can't find declaration for __llvmLaunchKernel
# | 73 | __global__ void foo(int, short, void *, void *) {}
# | | ^
# | 1 error generated when compiling for host.
# `-----------------------------
# error: command failed with exit status: 1
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenCUDA\offload_via_llvm.cu' --check-prefix=HST
# .---command stderr------------
# | FileCheck error: '<stdin>' is empty.
# | FileCheck command line: c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CodeGenCUDA\offload_via_llvm.cu --check-prefix=HST
# `-----------------------------
# error: command failed with exit status: 2
--
```
</details>
<details>
<summary>Clang.CodeGenHIP/offload-pgo-sections.hip</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 12
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\24\include -nostdsysteminc -triple amdgpu-amd-amdhsa -fcuda-is-device -cuid=abc -fprofile-instrument=clang -emit-llvm -o - -x hip C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip | c:\_work\llvm-project\llvm-project\build\bin\opt.exe -passes=instrprof -S | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe -check-prefix=DEV C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\24\include' -nostdsysteminc -triple amdgpu-amd-amdhsa -fcuda-is-device -cuid=abc -fprofile-instrument=clang -emit-llvm -o - -x hip 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip'
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\opt.exe' -passes=instrprof -S
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' -check-prefix=DEV 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip'
# note: command had no output on stdout or stderr
# RUN: at line 17
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\24\include -nostdsysteminc -triple x86_64-linux-gnu -cuid=abc -fprofile-instrument=clang -emit-llvm -o - -x hip C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe -check-prefix=HOST C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\24\include' -nostdsysteminc -triple x86_64-linux-gnu -cuid=abc -fprofile-instrument=clang -emit-llvm -o - -x hip 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip'
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' -check-prefix=HOST 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip:71:14: error: HOST-DAG: expected string not found in input
# | // HOST-DAG: @__llvm_profile_shadow_ucnts_[[CUID]]_{{[0-9]+}} = global ptr null
# | ^
# | <stdin>:7:60: note: scanning from here
# | @__llvm_profile_sections_b04fd23c98500190 = global ptr null
# | ^
# | <stdin>:7:60: note: with "CUID" equal to "b04fd23c98500190"
# | @__llvm_profile_sections_b04fd23c98500190 = global ptr null
# | ^
# | <stdin>:21:154: note: possible intended match here
# | @llvm.compiler.used = appending global [5 x ptr] [ptr @__llvm_profile_sections_b04fd23c98500190, ptr @__llvm_profile_shadow_data_b04fd23c98500190_0, ptr @__llvm_profile_shadow_cnts_b04fd23c98500190_1, ptr @__llvm_profile_shadow_names_b04fd23c98500190_2, ptr @__hip_cuid_b04fd23c98500190], section "llvm.metadata"
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | 1: ; ModuleID = 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenHIP\offload-pgo-sections.hip'
# | 2: source_filename = "C:\\_work\\llvm-project\\llvm-project\\clang\\test\\CodeGenHIP\\offload-pgo-sections.hip"
# | 3: target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
# | 4: target triple = "x86_64-unknown-linux-gnu"
# | 5:
# | 6: @_Z6kernelPi = constant ptr @_Z21__device_stub__kernelPi, align 8
# | 7: @__llvm_profile_sections_b04fd23c98500190 = global ptr null
# | dag:71'0 { search range start (exclusive)
# | dag:71'1 error: no match found in search range
# | dag:71'2 with "CUID" equal to "b04fd23c98500190"
# | 8: @__llvm_profile_shadow_data_b04fd23c98500190_0 = global ptr null
# | 9: @__llvm_profile_shadow_cnts_b04fd23c98500190_1 = global ptr null
# | 10: @__llvm_profile_shadow_names_b04fd23c98500190_2 = global ptr null
# | 11: @0 = private unnamed_addr constant [12 x i8] c"_Z6kernelPi\00", align 1
# | 12: @1 = private unnamed_addr constant [41 x i8] c"__llvm_profile_sections_b04fd23c98500190\00", align 1
# | 13: @2 = private unnamed_addr constant [20 x i8] c"__profd__Z6kernelPi\00", align 1
# | 14: @3 = private unnamed_addr constant [20 x i8] c"__profc__Z6kernelPi\00", align 1
# | 15: @4 = private unnamed_addr constant [31 x i8] c"__llvm_prf_nm_b04fd23c98500190\00", align 1
# | 16: @__hip_fatbin_b04fd23c98500190 = external constant i8, section ".hip_fatbin"
# | 17: @__hip_fatbin_wrapper = internal constant { i32, i32, ptr, ptr } { i32 1212764230, i32 1, ptr @__hip_fatbin_b04fd23c98500190, ptr null }, section ".hipFatBinSegment", align 8
# | 18: @__hip_gpubin_handle_b04fd23c98500190 = internal global ptr null, align 8
# | 19: @llvm.global_ctors = appending global [1 x { i32, ptr, ptr }] [{ i32, ptr, ptr } { i32 65535, ptr @__hip_module_ctor, ptr null }]
# | 20: @__hip_cuid_b04fd23c98500190 = global i8 0
# | 21: @llvm.compiler.used = appending global [5 x ptr] [ptr @__llvm_profile_sections_b04fd23c98500190, ptr @__llvm_profile_shadow_data_b04fd23c98500190_0, ptr @__llvm_profile_shadow_cnts_b04fd23c98500190_1, ptr @__llvm_profile_shadow_names_b04fd23c98500190_2, ptr @__hip_cuid_b04fd23c98500190], section "llvm.metadata"
# | dag:71'3 ? possible intended match
# | 22:
# | 23: ; Function Attrs: mustprogress noinline norecurse nounwind optnone
# | 24: define dso_local void @_Z21__device_stub__kernelPi(ptr noundef %p) #0 {
# | 25: entry:
# | 26: %p.addr = alloca ptr, align 8
# | .
# | .
# | .
# | 112:
# | 113: !llvm.module.flags = !{!0}
# | 114: !llvm.ident = !{!1}
# | 115:
# | 116: !0 = !{i32 2, !"EnableValueProfiling", i32 0}
# | 117: !1 = !{!"clang version 24.0.0git (https://github.com/llvm/llvm-project fe164d14ea02d941c33ccdd7a47097c335969086)"}
# | dag:71'4 } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1
--
```
</details>
<details>
<summary>Clang.Driver/cuda-via-liboffload.cu</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -### -target x86_64-linux-gnu -foffload-via-llvm -ccc-print-bindings --offload-arch=sm_35 --offload-arch=sm_70 C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe -check-prefix BINDINGS C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' '-###' -target x86_64-linux-gnu -foffload-via-llvm -ccc-print-bindings --offload-arch=sm_35 --offload-arch=sm_70 'C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu'
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' -check-prefix BINDINGS 'C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu:6:19: error: BINDINGS-NEXT: expected string not found in input
# | // BINDINGS-NEXT: "nvptx64-nvidia-cuda" - "clang", inputs: ["[[INPUT]]", "[[HOST_BC]]"], output: "[[PTX_SM_35:.+]]"
# | ^
# | <stdin>:11:338: note: scanning from here
# | # "x86_64-unknown-linux-gnu" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu", "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-7b563f.out"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | ^
# | <stdin>:11:338: note: with "INPUT" equal to "C:\\_work\\llvm-project\\llvm-project\\clang\\test\\Driver\\cuda-via-liboffload.cu\", \"C:\\Users\\ContainerAdministrator\\AppData\\Local\\Temp\\lit-tmp-f1iehomj\\cuda-via-liboffload-7b563f.out" (escaped value)
# | # "x86_64-unknown-linux-gnu" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu", "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-7b563f.out"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | ^
# | <stdin>:11:338: note: with "HOST_BC" equal to "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | # "x86_64-unknown-linux-gnu" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu", "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-7b563f.out"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | ^
# | <stdin>:11:338: note: pattern attempts to capture variables: "PTX_SM_35"
# | # "x86_64-unknown-linux-gnu" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu", "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-7b563f.out"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | ^
# | <stdin>:12:112: note: possible intended match here
# | # "x86_64-unknown-linux-gnu" - "Offload::Linker", inputs: ["C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"], output: "a.out"
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 6: # "nvptx64-nvidia-cuda-llvm" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_35-bac122.s"
# | 7: # "nvptx64-nvidia-cuda-llvm" - "NVPTX::Assembler", inputs: ["C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_35-bac122.s"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_35-5cfaad.o"
# | 8: # "nvptx64-nvidia-cuda-llvm" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_70-3d67ae.s"
# | 9: # "nvptx64-nvidia-cuda-llvm" - "NVPTX::Assembler", inputs: ["C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_70-3d67ae.s"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_70-7eec01.o"
# | 10: # "x86_64-unknown-linux-gnu" - "Offload::Packager", inputs: ["C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_35-5cfaad.o", "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-sm_70-7eec01.o"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-7b563f.out"
# | 11: # "x86_64-unknown-linux-gnu" - "clang", inputs: ["C:\_work\llvm-project\llvm-project\clang\test\Driver\cuda-via-liboffload.cu", "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-7b563f.out"], output: "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | next:6'0 { search range start (exclusive)
# | next:6'1 error: no match found in search range
# | next:6'2 with "INPUT" equal to "C:\\_work\\llvm-project\\llvm-project\\clang\\test\\Driver\\cuda-via-liboffload.cu\", \"C:\\Users\\ContainerAdministrator\\AppData\\Local\\Temp\\lit-tmp-f1iehomj\\cuda-via-liboffload-7b563f.out" (escaped value)
# | next:6'3 with "HOST_BC" equal to "C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"
# | next:6'4 pattern attempts to capture variables: "PTX_SM_35"
# | 12: # "x86_64-unknown-linux-gnu" - "Offload::Linker", inputs: ["C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\cuda-via-liboffload-41edf7.o"], output: "a.out"
# | next:6'5 ? possible intended match
# | next:6'6 } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1
--
```
</details>
<details>
<summary>Clang.OffloadTools/clang-linker-wrapper/linker-wrapper-image.c</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 6
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c -triple x86_64-unknown-linux-gnu -emit-obj -o C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.elf.o
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' -triple x86_64-unknown-linux-gnu -emit-obj -o 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.elf.o'
# note: command had no output on stdout or stderr
# RUN: at line 8
c:\_work\llvm-project\llvm-project\build\bin\llvm-offload-binary.exe -o C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out --image=file=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.elf.o,kind=openmp,triple=nvptx64-nvidia-cuda,arch=sm_70
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llvm-offload-binary.exe' -o 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out' '--image=file=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.elf.o,kind=openmp,triple=nvptx64-nvidia-cuda,arch=sm_70'
# note: command had no output on stdout or stderr
# RUN: at line 9
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c -triple x86_64-unknown-linux-gnu -emit-obj -o C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -fembed-offload-object=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' -triple x86_64-unknown-linux-gnu -emit-obj -o 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o' '-fembed-offload-object=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out'
# note: command had no output on stdout or stderr
# RUN: at line 11
c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe --print-wrapped-module --dry-run --host-triple=x86_64-unknown-linux-gnu --linker-path=/usr/bin/ld C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -o a.out 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c --check-prefixes=OPENMP,OPENMP-ELF
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe' --print-wrapped-module --dry-run --host-triple=x86_64-unknown-linux-gnu --linker-path=/usr/bin/ld 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o' -o a.out
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' --check-prefixes=OPENMP,OPENMP-ELF
# note: command had no output on stdout or stderr
# RUN: at line 13
c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe --print-wrapped-module --dry-run -r --host-triple=x86_64-unknown-linux-gnu --linker-path=/usr/bin/ld C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -o a.out 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c --check-prefixes=OPENMP-ELF,OPENMP-REL
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe' --print-wrapped-module --dry-run -r --host-triple=x86_64-unknown-linux-gnu --linker-path=/usr/bin/ld 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o' -o a.out
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' --check-prefixes=OPENMP-ELF,OPENMP-REL
# note: command had no output on stdout or stderr
# RUN: at line 15
c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe --print-wrapped-module --dry-run --host-triple=x86_64-unknown-windows-gnu --linker-path=/usr/bin/ld C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -o a.out 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c --check-prefixes=OPENMP,OPENMP-COFF
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe' --print-wrapped-module --dry-run --host-triple=x86_64-unknown-windows-gnu --linker-path=/usr/bin/ld 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o' -o a.out
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' --check-prefixes=OPENMP,OPENMP-COFF
# note: command had no output on stdout or stderr
# RUN: at line 45
c:\_work\llvm-project\llvm-project\build\bin\llvm-offload-binary.exe -o C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out --image=file=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.elf.o,kind=cuda,triple=nvptx64-nvidia-cuda,arch=sm_70
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llvm-offload-binary.exe' -o 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out' '--image=file=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.elf.o,kind=cuda,triple=nvptx64-nvidia-cuda,arch=sm_70'
# note: command had no output on stdout or stderr
# RUN: at line 46
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c -triple x86_64-unknown-linux-gnu -emit-obj -o C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -fembed-offload-object=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' -triple x86_64-unknown-linux-gnu -emit-obj -o 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o' '-fembed-offload-object=C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.out'
# note: command had no output on stdout or stderr
# RUN: at line 48
c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe --print-wrapped-module --dry-run --host-triple=x86_64-unknown-linux-gnu --linker-path=/usr/bin/ld C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -o a.out 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c --check-prefixes=CUDA,CUDA-ELF
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang-linker-wrapper.exe' --print-wrapped-module --dry-run --host-triple=x86_64-unknown-linux-gnu --linker-path=/usr/bin/ld 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o' -o a.out
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c' --check-prefixes=CUDA,CUDA-ELF
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c:97:15: error: CUDA-NEXT: expected string not found in input
# | // CUDA-NEXT: %entry1 = phi ptr [ @__start_llvm_offload_entries, %entry ], [ %16, %if.end ]
# | ^
# | <stdin>:59:13: note: scanning from here
# | while.entry: ; preds = %if.end, %entry
# | ^
# | <stdin>:60:2: note: possible intended match here
# | %entry1 = phi ptr [ @__start_llvm_offload_entries, %entry ], [ %17, %if.end ]
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\clang\test\OffloadTools\clang-linker-wrapper\linker-wrapper-image.c
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 54: define internal void @.cuda.globals_reg(ptr %0) section ".text.startup" {
# | 55: entry:
# | 56: %1 = icmp ne ptr @__start_llvm_offload_entries, @__stop_llvm_offload_entries
# | 57: br i1 %1, label %while.entry, label %while.end
# | 58:
# | 59: while.entry: ; preds = %if.end, %entry
# | next:97'0 { search range start (exclusive)
# | next:97'1 error: no match found in search range
# | 60: %entry1 = phi ptr [ @__start_llvm_offload_entries, %entry ], [ %17, %if.end ]
# | next:97'2 ? possible intended match
# | 61: %2 = getelementptr inbounds %struct.__tgt_offload_entry, ptr %entry1, i32 0, i32 4
# | 62: %addr = load ptr, ptr %2, align 8
# | 63: %3 = getelementptr inbounds %struct.__tgt_offload_entry, ptr %entry1, i32 0, i32 8
# | 64: %aux_addr = load ptr, ptr %3, align 8
# | 65: %4 = getelementptr inbounds %struct.__tgt_offload_entry, ptr %entry1, i32 0, i32 2
# | .
# | .
# | .
# | 120: br i1 %18, label %while.end, label %while.entry
# | 121:
# | 122: while.end: ; preds = %if.end, %entry
# | 123: ret void
# | 124: }
# | 125: "/usr/bin/ld" C:\_work\llvm-project\llvm-project\build\tools\clang\test\OffloadTools\clang-linker-wrapper\Output\linker-wrapper-image.c.tmp.o -o a.out C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-f1iehomj\a.out.cuda.image.wrapper-39fd89.o
# | next:97'3 } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1
--
```
</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/212373
More information about the cfe-commits
mailing list