[PATCH] D43086: [PowerPC] Infrastructure work. Implement getting the opcode for a spill in one place.
Stefan Pintilie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 26 10:13:32 PDT 2018
stefanp added inline comments.
================
Comment at: lib/Target/PowerPC/PPCInstrInfo.cpp:1180
+
+ if (get(Opcode).TSFlags & PPCII::XFormMemOp)
+ FuncInfo->setHasNonRISpills();
----------------
nemanjai wrote:
> Just another minor suggestion, since this is probably going to be useful in other places, can you just provide something like `static bool isXFormMemOp(unsigned Opcode);` in `PPCInstrInfo`? Then we can query it wherever we need it. I don't imagine there's anything about that query that would require an actual instance of the class, but I haven't checked so it may not be possible to make it `static`.
I've created the function `bool isXFormMemOp(unsigned Opcode) const;`. I was not able to make it static because I have to call `MCInstrInfo::get`.
https://reviews.llvm.org/D43086
More information about the llvm-commits
mailing list