[llvm] [SPIR-V] Fix inconsistency between previously deduced element type of a pointer and function's return type (PR #109660)
Nathan Gauër via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 25 02:57:33 PDT 2024
================
@@ -341,6 +341,17 @@ createNewIdReg(SPIRVType *SpvType, Register SrcReg, MachineRegisterInfo &MRI,
return {Reg, GetIdOp};
}
+static void setInsertPtAfterDef(MachineIRBuilder &MIB, MachineInstr *Def) {
+ MachineBasicBlock &MBB = *Def->getParent();
+ MachineBasicBlock::iterator DefIt =
+ Def->getNextNode() ? Def->getNextNode()->getIterator() : MBB.end();
+ // Skip all the PHI and debug instructions.
+ while (DefIt != MBB.end() &&
+ (DefIt->isPHI() || DefIt->isDebugOrPseudoInstr()))
----------------
Keenuts wrote:
Doesn't this break with OpPhi instructions?
(on my tasks is to make OpPhi a "phi" instruction for the verifier)
https://github.com/llvm/llvm-project/pull/109660
More information about the llvm-commits
mailing list