[llvm] 163aeca - [CodeGenPrepare] Remove unused TypePromotionTransaction::moveBefore to fix gcc Wunused-function warning. NFC.

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 15 06:45:38 PST 2023


Author: Simon Pilgrim
Date: 2023-12-15T14:45:17Z
New Revision: 163aeca33d4adb97e8599584409457ca14b1419b

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

LOG: [CodeGenPrepare] Remove unused TypePromotionTransaction::moveBefore to fix gcc Wunused-function warning. NFC.

Added: 
    

Modified: 
    llvm/lib/CodeGen/CodeGenPrepare.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/CodeGen/CodeGenPrepare.cpp b/llvm/lib/CodeGen/CodeGenPrepare.cpp
index f9e791c7334838..e06b430b3d287f 100644
--- a/llvm/lib/CodeGen/CodeGenPrepare.cpp
+++ b/llvm/lib/CodeGen/CodeGenPrepare.cpp
@@ -3218,10 +3218,6 @@ class TypePromotionTransaction {
   /// Same as IRBuilder::createZExt.
   Value *createZExt(Instruction *Inst, Value *Opnd, Type *Ty);
 
-  /// Same as Instruction::moveBefore.
-  void moveBefore(Instruction *Inst, Instruction *Before);
-  /// @}
-
 private:
   /// The ordered list of actions made so far.
   SmallVector<std::unique_ptr<TypePromotionAction>, 16> Actions;
@@ -3281,13 +3277,6 @@ Value *TypePromotionTransaction::createZExt(Instruction *Inst, Value *Opnd,
   return Val;
 }
 
-void TypePromotionTransaction::moveBefore(Instruction *Inst,
-                                          Instruction *Before) {
-  Actions.push_back(
-      std::make_unique<TypePromotionTransaction::InstructionMoveBefore>(
-          Inst, Before));
-}
-
 TypePromotionTransaction::ConstRestorationPt
 TypePromotionTransaction::getRestorationPoint() const {
   return !Actions.empty() ? Actions.back().get() : nullptr;


        


More information about the llvm-commits mailing list