Missing these could potentially screw up post-ra scheduling.
Issue found by inspection, so I don't have a real testcase. Included test just verifies the expected operands after expansion.
Paths
| Differential D35156
[ARM] Make ARMExpandPseudo add implicit uses for predicated instructions ClosedPublic Authored by efriedma on Jul 7 2017, 3:28 PM.
Details Summary Missing these could potentially screw up post-ra scheduling. Issue found by inspection, so I don't have a real testcase. Included test just verifies the expected operands after expansion.
Diff Detail
Event TimelineHerald added subscribers: kristof.beyls, javed.absar, aemerson. · View Herald TranscriptJul 7 2017, 3:28 PM Comment Actions Hi Eli, I couldn't find an awful lot of tests for ARM pseudo expansion in particular, so I think it would be nice to add one. A MIR test checking each of the transformations that you touched in this patch would work fine. I've been looking into this area myself recently and found it all a bit confusing. I have a few questions inline, sorry if they're a bit basic. Thanks.
Comment Actions OK, I'll add a testcase.
Comment Actions Added testcases (didn't add a testcase for every single opcode, since there's a lot of them, but this should be enough to illustrate what's happening). Comment Actions Thanks for the test-case and the explanations.
Comment Actions This LGTM, but could you please commit the pass registration changes as a separate commit, as they are not really related to this change. This revision is now accepted and ready to land.Sep 1 2017, 5:55 AM Closed by commit rL312589: [ARM] Make ARMExpandPseudo add implicit uses for predicated instructions (authored by efriedma). · Explain WhySep 5 2017, 3:55 PM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 106109 lib/Target/ARM/ARM.h
lib/Target/ARM/ARMExpandPseudoInsts.cpp
lib/Target/ARM/ARMTargetMachine.cpp
test/CodeGen/ARM/expand-pseudos.mir
|
How exactly does this work? You're already passing the register from MI.getOperand(1) to BuildMI, which IIUC will mark it as a define. Why do you also need to make it implicit?