[llvm] llvm.lround: Update verifier to validate support of vector types. (PR #98950)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 25 09:36:34 PDT 2024
================
@@ -2032,7 +2032,20 @@ void MachineVerifier::verifyPreISelGenericInstruction(const MachineInstr *MI) {
}
case TargetOpcode::G_LLROUND:
case TargetOpcode::G_LROUND: {
- verifyAllRegOpsScalar(*MI, *MRI);
+ LLT DstTy = MRI->getType(MI->getOperand(0).getReg());
+ LLT SrcTy = MRI->getType(MI->getOperand(1).getReg());
+ if (!DstTy.isValid() || !SrcTy.isValid())
+ break;
+ if (SrcTy.isPointer() || DstTy.isPointer()) {
+ std::string Op = SrcTy.isPointer() ? "Source" : "Destination";
----------------
arsenm wrote:
This can be a StringRef
https://github.com/llvm/llvm-project/pull/98950
More information about the llvm-commits
mailing list