[llvm] [SPIRV] Addition of @llvm.lround.* and @llvm.llround.* intrinsic (PR #129240)
Dmitry Sidorov via llvm-commits
llvm-commits at lists.llvm.org
Thu May 15 10:33:08 PDT 2025
================
@@ -1017,6 +1042,42 @@ bool SPIRVInstructionSelector::selectExtInst(Register ResVReg,
}
return false;
}
+bool SPIRVInstructionSelector::selectExtInstForLRound(
+ Register ResVReg, const SPIRVType *ResType, MachineInstr &I,
+ CL::OpenCLExtInst CLInst, GL::GLSLExtInst GLInst) const {
+ ExtInstList ExtInsts = {{SPIRV::InstructionSet::OpenCL_std, CLInst},
+ {SPIRV::InstructionSet::GLSL_std_450, GLInst}};
+ return selectExtInstForLRound(ResVReg, ResType, I, ExtInsts);
+}
+
+bool SPIRVInstructionSelector::selectExtInstForLRound(
+ Register ResVReg, const SPIRVType *ResType, MachineInstr &I,
+ const ExtInstList &Insts) const {
+
----------------
MrSidims wrote:
lets remove an empty line
```suggestion
const ExtInstList &Insts) const {
```
https://github.com/llvm/llvm-project/pull/129240
More information about the llvm-commits
mailing list