From: Jessica Paquette Date: Wed, 5 Dec 2018 18:17:40 +0000 (+0000) Subject: [MachineOutliner][NFC] Use getOccurrenceCount() in getNotOutlinedCost() X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4532b1f1e8b0922afd1d63096bf66adc8c50e739;p=platform%2Fupstream%2Fllvm.git [MachineOutliner][NFC] Use getOccurrenceCount() in getNotOutlinedCost() Some more gardening. llvm-svn: 348392 --- diff --git a/llvm/include/llvm/CodeGen/MachineOutliner.h b/llvm/include/llvm/CodeGen/MachineOutliner.h index 19abeba..93c61c6 100644 --- a/llvm/include/llvm/CodeGen/MachineOutliner.h +++ b/llvm/include/llvm/CodeGen/MachineOutliner.h @@ -190,7 +190,7 @@ public: unsigned FrameConstructionID; /// Return the number of candidates for this \p OutlinedFunction. - unsigned getOccurrenceCount() { return OccurrenceCount; } + unsigned getOccurrenceCount() const { return OccurrenceCount; } /// Decrement the occurrence count of this OutlinedFunction and return the /// new count. @@ -210,7 +210,9 @@ public: } /// Return the size in bytes of the unoutlined sequences. - unsigned getNotOutlinedCost() const { return OccurrenceCount * SequenceSize; } + unsigned getNotOutlinedCost() const { + return getOccurrenceCount() * SequenceSize; + } /// Return the number of instructions that would be saved by outlining /// this function.