[llvm] [SPIR-V] Add support for SPV_INTEL_masked_gather_scatter extension (PR #185418)

via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 10 03:54:27 PDT 2026


github-actions[bot] wrote:

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

* 170986 tests passed
* 3020 tests skipped
* 2 tests failed

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

### LLVM
<details>
<summary>LLVM.CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 1
not /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -O0 -mtriple=spirv64-unknown-unknown /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll -o - 2>&1 | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll
# executed command: not /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -O0 -mtriple=spirv64-unknown-unknown /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll -o -
# 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/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll
# .---command stderr------------
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll:3:10: error: CHECK: expected string not found in input
# | ; CHECK: error:{{.*}}: llvm.masked.gather requires SPV_INTEL_masked_gather_scatter
# |          ^
# | <stdin>:1:1: note: scanning from here
# | llc: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp:327: SPIRVTypeInst llvm::SPIRVGlobalRegistry::getOpTypeVector(uint32_t, SPIRVTypeInst, MachineIRBuilder &): Assertion `cast<SPIRVSubtarget>(MIRBuilder.getMF().getSubtarget()) .canUseExtension( SPIRV::Extension::SPV_INTEL_masked_gather_scatter) && "Vector of pointers requires SPV_INTEL_masked_gather_scatter " "extension"' failed.
# | ^
# | <stdin>:1:345: note: possible intended match here
# | llc: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp:327: SPIRVTypeInst llvm::SPIRVGlobalRegistry::getOpTypeVector(uint32_t, SPIRVTypeInst, MachineIRBuilder &): Assertion `cast<SPIRVSubtarget>(MIRBuilder.getMF().getSubtarget()) .canUseExtension( SPIRV::Extension::SPV_INTEL_masked_gather_scatter) && "Vector of pointers requires SPV_INTEL_masked_gather_scatter " "extension"' failed.
# |                                                                                                                                                                                                                                                                                                                                                         ^
# | 
# | Input file: <stdin>
# | Check file: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |            1: llc: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp:327: SPIRVTypeInst llvm::SPIRVGlobalRegistry::getOpTypeVector(uint32_t, SPIRVTypeInst, MachineIRBuilder &): Assertion `cast<SPIRVSubtarget>(MIRBuilder.getMF().getSubtarget()) .canUseExtension( SPIRV::Extension::SPV_INTEL_masked_gather_scatter) && "Vector of pointers requires SPV_INTEL_masked_gather_scatter " "extension"' failed. 
# | check:3'0     X~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ error: no match found
# | check:3'1                                                                                                                                                                                                                                                                                                                                                             ?                                                                                               possible intended match
# |            2: PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace and instructions to reproduce the bug. 
# | check:3'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            3: Stack dump: 
# | check:3'0     ~~~~~~~~~~~~
# |            4: 0. Program arguments: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -O0 -mtriple=spirv64-unknown-unknown /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll -o - 
# | check:3'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            5: 1. Running pass 'Function Pass Manager' on module '/home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/extensions/SPV_INTEL_masked_gather_scatter/masked-gather-scatter-no-extension.ll'. 
# | check:3'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            6: 2. Running pass 'SPIRV pre legalizer' on function '@test_gather_no_ext' 
# | check:3'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            .
# |            .
# |            .
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>
<details>
<summary>LLVM.CodeGen/SPIRV/llc-pipeline.ll</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -O0 -mtriple=spirv-- -disable-verify -debug-pass=Structure < /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/llc-pipeline.ll 2>&1    | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -match-full-lines -strict-whitespace -check-prefix=SPIRV-O0 /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/llc-pipeline.ll
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -O0 -mtriple=spirv-- -disable-verify -debug-pass=Structure
# note: command had no output on stdout or stderr
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck -match-full-lines -strict-whitespace -check-prefix=SPIRV-O0 /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/llc-pipeline.ll
# .---command stderr------------
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/llc-pipeline.ll:28:17: error: SPIRV-O0-NEXT: expected string not found in input
# | ; SPIRV-O0-NEXT:      SPIRV convert masked memory intrinsics
# |                 ^
# | <stdin>:16:33: note: scanning from here
# |       Expand Atomic instructions
# |                                 ^
# | <stdin>:17:5: note: possible intended match here
# |     SPIRV convert masked memory intrinsics
# |     ^
# | 
# | Input file: <stdin>
# | Check file: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/SPIRV/llc-pipeline.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |            .
# |            .
# |            .
# |           11: Machine Branch Probability Analysis 
# |           12:   ModulePass Manager 
# |           13:     Pre-ISel Intrinsic Lowering 
# |           14:     FunctionPass Manager 
# |           15:       Expand IR instructions 
# |           16:       Expand Atomic instructions 
# | next:28'0                                     X error: no match found
# |           17:     SPIRV convert masked memory intrinsics 
# | next:28'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | next:28'1         ?                                       possible intended match
# |           18:     FunctionPass Manager 
# | next:28'0     ~~~~~~~~~~~~~~~~~~~~~~~~~
# |           19:       Lower Garbage Collection Instructions 
# | next:28'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           20:       Shadow Stack GC Lowering 
# | next:28'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           21:       Remove unreachable blocks from the CFG 
# | next:28'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           22:       Instrument function entry/exit with calls to e.g. mcount() (post inlining) 
# | next:28'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            .
# |            .
# |            .
# | >>>>>>
# `-----------------------------
# 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/185418


More information about the llvm-commits mailing list