Remove unused parameter Penalty from the BoundsChecking pass.
authorJoey Gouly <joey.gouly@arm.com>
Fri, 23 Nov 2012 10:47:35 +0000 (10:47 +0000)
committerJoey Gouly <joey.gouly@arm.com>
Fri, 23 Nov 2012 10:47:35 +0000 (10:47 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168511 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Transforms/Instrumentation.h
lib/Transforms/Instrumentation/BoundsChecking.cpp

index 8e63aaa4e87369abca29ecf798aa3838366d442b..3558251a4339785144b4f9851160913984c2f9c6 100644 (file)
@@ -41,9 +41,7 @@ FunctionPass *createThreadSanitizerPass();
 
 // BoundsChecking - This pass instruments the code to perform run-time bounds
 // checking on loads, stores, and other memory intrinsics.
-// Penalty is the maximum run-time that is acceptable for the user.
-//
-FunctionPass *createBoundsCheckingPass(unsigned Penalty = 5);
+FunctionPass *createBoundsCheckingPass();
 
 } // End llvm namespace
 
index 7810b1b8a3efbe067bad049bd672ec7a627d9461..2d5d5603c09da93a27c5decfac2d4dd68622ee22 100644 (file)
@@ -41,7 +41,7 @@ namespace {
   struct BoundsChecking : public FunctionPass {
     static char ID;
 
-    BoundsChecking(unsigned _Penalty = 5) : FunctionPass(ID), Penalty(_Penalty){
+    BoundsChecking() : FunctionPass(ID) {
       initializeBoundsCheckingPass(*PassRegistry::getPassRegistry());
     }
 
@@ -59,7 +59,6 @@ namespace {
     BuilderTy *Builder;
     Instruction *Inst;
     BasicBlock *TrapBB;
-    unsigned Penalty;
 
     BasicBlock *getTrapBB();
     void emitBranchToTrap(Value *Cmp = 0);
@@ -208,6 +207,6 @@ bool BoundsChecking::runOnFunction(Function &F) {
   return MadeChange;
 }
 
-FunctionPass *llvm::createBoundsCheckingPass(unsigned Penalty) {
-  return new BoundsChecking(Penalty);
+FunctionPass *llvm::createBoundsCheckingPass() {
+  return new BoundsChecking();
 }