[PATCH] D75098: Add TCOPY, a terminator form of the COPY instr

Nick Desaulniers via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 27 15:08:59 PST 2020


nickdesaulniers added inline comments.


================
Comment at: llvm/lib/CodeGen/MachineSink.cpp:845
                         MachineBasicBlock::iterator InsertPos,
+                        const TargetInstrInfo *TII,
                         SmallVectorImpl<MachineInstr *> &DbgValuesToSink) {
----------------
void wrote:
> nickdesaulniers wrote:
> > pass as `const&`, or make `performSink` a private method.
> Two different passes use this function so it can't be made a private method. I"m not sure why passing it as "const&" is better than a "const*"...
Generally, passing by const reference indicates that a parameter is strictly an input, as opposed to both input AND output, which is why you don't see a mix of pointers and references in this function signature.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75098/new/

https://reviews.llvm.org/D75098





More information about the llvm-commits mailing list