[PATCH] D95708: [GlobalISel] Make sure G_ASSERT_ZEXT's src ends up with the same rc as dst
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 29 17:47:07 PST 2021
arsenm added inline comments.
================
Comment at: llvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp:146
+ const TargetRegisterClass *DstRC = MRI.getRegClassOrNull(DstReg);
+ if (DstRC && !MRI.getRegClassOrNull(SrcReg))
+ MRI.setRegClass(SrcReg, DstRC);
----------------
!MRI.getRegClassOrNull(SrcReg) should be redundant since this would have been invalid if it weren't the same class anyway
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95708/new/
https://reviews.llvm.org/D95708
More information about the llvm-commits
mailing list