[llvm] [SPIRV] Support for the extension SPV_EXT_image_raw10_raw12 (PR #160032)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Sep 21 22:26:29 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp -- llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp llvm/lib/Target/SPIRV/SPIRVCommandLine.cpp llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp b/llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp
index b00e7c34c..ce95506a6 100644
--- a/llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp
+++ b/llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp
@@ -2357,12 +2357,11 @@ generateTernaryBitwiseFunctionINTELInst(const SPIRV::IncomingCall *Call,
}
static bool generateImageChannelDataTypeInst(const SPIRV::IncomingCall *Call,
- MachineIRBuilder &MIRBuilder,
- SPIRVGlobalRegistry *GR) {
+ MachineIRBuilder &MIRBuilder,
+ SPIRVGlobalRegistry *GR) {
const SPIRV::DemangledBuiltin *Builtin = Call->Builtin;
unsigned Opcode =
SPIRV::lookupNativeBuiltin(Builtin->Name, Builtin->Set)->Opcode;
-
return buildImageChannelDataTypeInst(Call, Opcode, MIRBuilder, GR);
}
diff --git a/llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp b/llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp
index 0dfb0310d..cbd3f5322 100644
--- a/llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp
+++ b/llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp
@@ -1459,8 +1459,7 @@ void addInstrRequirements(const MachineInstr &MI,
for (const MachineOperand &Op : UseInst.operands())
if (Op.isImm())
CheckAndAddExtension(Op.getImm());
- }
- else if (llvm::is_contained(CompareOps, Opc)) {
+ } else if (llvm::is_contained(CompareOps, Opc)) {
for (unsigned i = 1; i < UseInst.getNumOperands(); ++i) {
Register UseReg = UseInst.getOperand(i).getReg();
MachineInstr *ConstInst = MRI.getVRegDef(UseReg);
``````````
</details>
https://github.com/llvm/llvm-project/pull/160032
More information about the llvm-commits
mailing list