[PATCH] D61754: [PowerPC] Custom lower known CR bit spills
Lei Huang via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 13 13:11:16 PDT 2019
lei marked an inline comment as done.
lei added a comment.
address spacing issues.
================
Comment at: llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp:725
+ MachineBasicBlock::reverse_iterator Ins;
+ for (Ins=MI; Ins!=MBB.rend(); Ins++) {
+ if (Ins->modifiesRegister(SrcReg, TRI))
----------------
hfinkel wrote:
> lei wrote:
> > hfinkel wrote:
> > > lei wrote:
> > > > hfinkel wrote:
> > > > > I think that this makes sense, but I'm a bit concerned that, without a cutoff, this makes the spilling process quadratic. Can you please add a cl::opt search cutoff for this?
> > > > How about `--ppc-max-crbit-spill-dist` with an initial value of 20?
> > > Sounds good. Make the initial value a bit larger, however. It's easy to have blocks with more than 20 instructions. I'd start with 100. Also, remember to skip the debug instructions when counting, so you don't end up with differences between the debugging-enabled and debugging-disabled cases.
> > I didn't even think about debug instructions... how do I identify if an instruction is a debug instruction?
> You can, I believe, call `Ins->isDebugInstr()`
thx!
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61754/new/
https://reviews.llvm.org/D61754
More information about the llvm-commits
mailing list