[clang] [CIR][NVPTX] Support WMMA fragment loads (PR #234812)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 13 13:46:17 PST 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results
* 59483 tests passed
* 561 tests skipped
* 1 test failed
## Failed Tests
(click on a test name to see its output)
### Clang
<details>
<summary>Clang.CIR/CodeGenCUDA/builtins-nvptx-wmma.cu</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 1
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 nvptx64-nvidia-cuda -target-cpu sm_70 -target-feature +ptx60 -x cuda -fcuda-is-device -fclangir -emit-cir C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu -o - | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu --check-prefix=CIR --enable-var-scope
# 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 nvptx64-nvidia-cuda -target-cpu sm_70 -target-feature +ptx60 -x cuda -fcuda-is-device -fclangir -emit-cir 'C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu' -o -
# 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\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu' --check-prefix=CIR --enable-var-scope
# note: command had no output on stdout or stderr
# RUN: at line 4
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 nvptx64-nvidia-cuda -target-cpu sm_70 -target-feature +ptx60 -x cuda -fcuda-is-device -fclangir -emit-llvm C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu -o - | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu --check-prefix=LLVM --enable-var-scope
# 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 nvptx64-nvidia-cuda -target-cpu sm_70 -target-feature +ptx60 -x cuda -fcuda-is-device -fclangir -emit-llvm 'C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu' -o -
# 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\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu' --check-prefix=LLVM --enable-var-scope
# note: command had no output on stdout or stderr
# RUN: at line 7
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 nvptx64-nvidia-cuda -target-cpu sm_70 -target-feature +ptx60 -x cuda -fcuda-is-device -emit-llvm C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu -o - | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu --check-prefix=LLVM --enable-var-scope
# 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 nvptx64-nvidia-cuda -target-cpu sm_70 -target-feature +ptx60 -x cuda -fcuda-is-device -emit-llvm 'C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu' -o -
# 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\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu' --check-prefix=LLVM --enable-var-scope
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu:32:10: error: LLVM: expected string not found in input
# | // LLVM: %[[P1:.*]] = getelementptr{{.*}} i32, ptr %[[DST]], i{{32|64}} 1
# | ^
# | <stdin>:25:35: note: scanning from here
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:25:35: note: with "DST" equal to "0"
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:25:35: note: pattern attempts to capture variables: "P1"
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:27:2: note: possible intended match here
# | %10 = getelementptr i32, ptr %0, i32 2
# | ^
# | C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu:86:10: error: LLVM: expected string not found in input
# | // LLVM: %[[P1:.*]] = getelementptr{{.*}} i32, ptr %[[DST]], i{{32|64}} 1
# | ^
# | <stdin>:127:35: note: scanning from here
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:127:35: note: with "DST" equal to "0"
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:127:35: note: pattern attempts to capture variables: "P1"
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:129:2: note: possible intended match here
# | %10 = getelementptr i32, ptr %0, i32 2
# | ^
# | C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu:140:10: error: LLVM: expected string not found in input
# | // LLVM: %[[P1:.*]] = getelementptr{{.*}} i32, ptr %[[DST]], i{{32|64}} 1
# | ^
# | <stdin>:229:35: note: scanning from here
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:229:35: note: with "DST" equal to "0"
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:229:35: note: pattern attempts to capture variables: "P1"
# | %9 = bitcast <2 x half> %8 to i32
# | ^
# | <stdin>:231:2: note: possible intended match here
# | %10 = getelementptr i32, ptr %0, i32 2
# | ^
# | C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu:175:10: error: LLVM: expected string not found in input
# | // LLVM: %[[P1:.*]] = getelementptr{{.*}} float, ptr %[[DST]], i{{32|64}} 1
# | ^
# | <stdin>:297:84: note: scanning from here
# | %7 = extractvalue { float, float, float, float, float, float, float, float } %3, 1
# | ^
# | <stdin>:297:84: note: with "DST" equal to "0"
# | %7 = extractvalue { float, float, float, float, float, float, float, float } %3, 1
# | ^
# | <stdin>:297:84: note: pattern attempts to capture variables: "P1"
# | %7 = extractvalue { float, float, float, float, float, float, float, float } %3, 1
# | ^
# | <stdin>:299:2: note: possible intended match here
# | %8 = getelementptr float, ptr %0, i32 2
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\clang\test\CIR\CodeGenCUDA\builtins-nvptx-wmma.cu
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 20: %5 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 0
# | 21: %6 = bitcast <2 x half> %5 to i32
# | 22: store i32 %6, ptr %4, align 4
# | 23: %7 = getelementptr i32, ptr %0, i32 1
# | 24: %8 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 1
# | 25: %9 = bitcast <2 x half> %8 to i32
# | check:32'0 { search range start (exclusive)
# | check:32'1 error: no match found in search range
# | check:32'2 with "DST" equal to "0"
# | check:32'3 pattern attempts to capture variables: "P1"
# | 26: store i32 %9, ptr %7, align 4
# | 27: %10 = getelementptr i32, ptr %0, i32 2
# | check:32'4 ? possible intended match
# | 28: %11 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 2
# | 29: %12 = bitcast <2 x half> %11 to i32
# | 30: store i32 %12, ptr %10, align 4
# | 31: %13 = getelementptr i32, ptr %0, i32 3
# | 32: %14 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 3
# | .
# | .
# | .
# | 53:
# | 54: ; Function Attrs: nocallback nounwind willreturn memory(argmem: read)
# | 55: declare { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } @llvm.nvvm.wmma.m16n16k16.load.a.row.stride.f16.p0(ptr readonly captures(none), i32) #1
# | 56:
# | 57: ; Function Attrs: convergent mustprogress noinline nounwind optnone
# | 58: define dso_local void @load_a_f16_col(ptr noundef %dst, ptr noundef %src, i32 noundef %stride) #0 {
# | check:32'5 } search range end (exclusive)
# | 59: entry:
# | 60: %dst.addr = alloca ptr, align 8
# | 61: %src.addr = alloca ptr, align 8
# | 62: %stride.addr = alloca i32, align 4
# | 63: store ptr %dst, ptr %dst.addr, align 8
# | .
# | .
# | .
# | 122: %5 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 0
# | 123: %6 = bitcast <2 x half> %5 to i32
# | 124: store i32 %6, ptr %4, align 4
# | 125: %7 = getelementptr i32, ptr %0, i32 1
# | 126: %8 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 1
# | 127: %9 = bitcast <2 x half> %8 to i32
# | check:86'0 { search range start (exclusive)
# | check:86'1 error: no match found in search range
# | check:86'2 with "DST" equal to "0"
# | check:86'3 pattern attempts to capture variables: "P1"
# | 128: store i32 %9, ptr %7, align 4
# | 129: %10 = getelementptr i32, ptr %0, i32 2
# | check:86'4 ? possible intended match
# | 130: %11 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 2
# | 131: %12 = bitcast <2 x half> %11 to i32
# | 132: store i32 %12, ptr %10, align 4
# | 133: %13 = getelementptr i32, ptr %0, i32 3
# | 134: %14 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 3
# | .
# | .
# | .
# | 155:
# | 156: ; Function Attrs: nocallback nounwind willreturn memory(argmem: read)
# | 157: declare { <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half>, <2 x half> } @llvm.nvvm.wmma.m16n16k16.load.b.row.stride.f16.p0(ptr readonly captures(none), i32) #1
# | 158:
# | 159: ; Function Attrs: convergent mustprogress noinline nounwind optnone
# | 160: define dso_local void @load_b_f16_col(ptr noundef %dst, ptr noundef %src, i32 noundef %stride) #0 {
# | check:86'5 } search range end (exclusive)
# | 161: entry:
# | 162: %dst.addr = alloca ptr, align 8
# | 163: %src.addr = alloca ptr, align 8
# | 164: %stride.addr = alloca i32, align 4
# | 165: store ptr %dst, ptr %dst.addr, align 8
# | .
# | .
# | .
# | 224: %5 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 0
# | 225: %6 = bitcast <2 x half> %5 to i32
# | 226: store i32 %6, ptr %4, align 4
# | 227: %7 = getelementptr i32, ptr %0, i32 1
# | 228: %8 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 1
# | 229: %9 = bitcast <2 x half> %8 to i32
# | check:140'0 { search range start (exclusive)
# | check:140'1 error: no match found in search range
# | check:140'2 with "DST" equal to "0"
# | check:140'3 pattern attempts to capture variables: "P1"
# | 230: store i32 %9, ptr %7, align 4
# | 231: %10 = getelementptr i32, ptr %0, i32 2
# | check:140'4 ? possible intended match
# | 232: %11 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 2
# | 233: %12 = bitcast <2 x half> %11 to i32
# | 234: store i32 %12, ptr %10, align 4
# | 235: %13 = getelementptr i32, ptr %0, i32 3
# | 236: %14 = extractvalue { <2 x half>, <2 x half>, <2 x half>, <2 x half> } %3, 3
# | .
# | .
# | .
# | 241:
# | 242: ; Function Attrs: nocallback nounwind willreturn memory(argmem: read)
# | 243: declare { <2 x half>, <2 x half>, <2 x half>, <2 x half> } @llvm.nvvm.wmma.m16n16k16.load.c.row.stride.f16.p0(ptr readonly captures(none), i32) #1
# | 244:
# | 245: ; Function Attrs: convergent mustprogress noinline nounwind optnone
# | 246: define dso_local void @load_c_f16_col(ptr noundef %dst, ptr noundef %src, i32 noundef %stride) #0 {
# | check:140'5 } search range end (exclusive)
# | 247: entry:
# | 248: %dst.addr = all
# | ...
# `---data was truncated (10240/13069) (change limit with -D output_limit=N)
# 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/234812
More information about the cfe-commits
mailing list