[PATCH] D86709: [GlobalISel] Extend not_cmp_fold to work on conditional expressions
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 27 09:00:01 PDT 2020
arsenm added inline comments.
================
Comment at: llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp:2162
return false;
+ MachineInstr *Def = MRI.getVRegDef(Reg);
+ switch (Def->getOpcode()) {
----------------
paquette wrote:
> Usually people assert that the result of `MRI.getVRegDef(...)` isn't null.
>
> I'm not sure if that's actually necessary in this case though; I *think* that it can only be null when you have a physreg, but I'm not entirely sure.
getVRegDef should never fail for gMIR.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D86709/new/
https://reviews.llvm.org/D86709
More information about the llvm-commits
mailing list