[llvm] r245549 - Make helper functions static. NFC.

Benjamin Kramer via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 20 02:57:22 PDT 2015


Author: d0k
Date: Thu Aug 20 04:57:22 2015
New Revision: 245549

URL: http://llvm.org/viewvc/llvm-project?rev=245549&view=rev
Log:
Make helper functions static. NFC.

Modified:
    llvm/trunk/lib/CodeGen/PeepholeOptimizer.cpp
    llvm/trunk/lib/Transforms/Scalar/LoopUnrollPass.cpp

Modified: llvm/trunk/lib/CodeGen/PeepholeOptimizer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/PeepholeOptimizer.cpp?rev=245549&r1=245548&r2=245549&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/PeepholeOptimizer.cpp (original)
+++ llvm/trunk/lib/CodeGen/PeepholeOptimizer.cpp Thu Aug 20 04:57:22 2015
@@ -721,7 +721,7 @@ bool PeepholeOptimizer::findNextSource(u
 /// successfully traverse a PHI instruction and find suitable sources coming
 /// from its edges. By inserting a new PHI, we provide a rewritten PHI def
 /// suitable to be used in a new COPY instruction.
-MachineInstr *
+static MachineInstr *
 insertPHI(MachineRegisterInfo *MRI, const TargetInstrInfo *TII,
           const SmallVectorImpl<TargetInstrInfo::RegSubRegPair> &SrcRegs,
           MachineInstr *OrigPHI) {

Modified: llvm/trunk/lib/Transforms/Scalar/LoopUnrollPass.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoopUnrollPass.cpp?rev=245549&r1=245548&r2=245549&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LoopUnrollPass.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LoopUnrollPass.cpp Thu Aug 20 04:57:22 2015
@@ -518,7 +518,7 @@ struct EstimatedUnrollCost {
 /// \returns Optional value, holding the RolledDynamicCost and UnrolledCost. If
 /// the analysis failed (no benefits expected from the unrolling, or the loop is
 /// too big to analyze), the returned value is None.
-Optional<EstimatedUnrollCost>
+static Optional<EstimatedUnrollCost>
 analyzeLoopUnrollCost(const Loop *L, unsigned TripCount, DominatorTree &DT,
                       ScalarEvolution &SE, const TargetTransformInfo &TTI,
                       int MaxUnrolledLoopSize) {




More information about the llvm-commits mailing list