[llvm] b0fb982 - [Coverity] Big parameter passed by value.

via llvm-commits llvm-commits at lists.llvm.org
Thu May 4 18:15:30 PDT 2023


Author: Luo, Yuanke
Date: 2023-05-05T09:15:22+08:00
New Revision: b0fb98227c90adf2536c9ad644a74d5e92961111

URL: https://github.com/llvm/llvm-project/commit/b0fb98227c90adf2536c9ad644a74d5e92961111
DIFF: https://github.com/llvm/llvm-project/commit/b0fb98227c90adf2536c9ad644a74d5e92961111.diff

LOG: [Coverity] Big parameter passed by value.

Added: 
    

Modified: 
    llvm/lib/CodeGen/MachineCombiner.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/CodeGen/MachineCombiner.cpp b/llvm/lib/CodeGen/MachineCombiner.cpp
index 4ae95bfa7266..ec5eb71205cf 100644
--- a/llvm/lib/CodeGen/MachineCombiner.cpp
+++ b/llvm/lib/CodeGen/MachineCombiner.cpp
@@ -502,8 +502,8 @@ bool MachineCombiner::preservesResourceLen(
 ///                          otherwise invalidate the trace
 static void insertDeleteInstructions(
     MachineBasicBlock *MBB, MachineInstr &MI,
-    SmallVector<MachineInstr *, 16> InsInstrs,
-    SmallVector<MachineInstr *, 16> DelInstrs,
+    SmallVectorImpl<MachineInstr *> &InsInstrs,
+    SmallVectorImpl<MachineInstr *> &DelInstrs,
     MachineTraceMetrics::Ensemble *TraceEnsemble,
     SparseSet<LiveRegUnit> &RegUnits, const TargetInstrInfo *TII,
     MachineCombinerPattern Pattern, bool IncrementalUpdate) {


        


More information about the llvm-commits mailing list