aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Transforms/Utils
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-11-03 05:33:46 +0000
committerChris Lattner <sabre@nondot.org>2009-11-03 05:33:46 +0000
commita856e3625f4d2486c2968afbbbc1192ae191b88f (patch)
tree4cead040b0b7dd68a53789da6cf294358a693013 /lib/Transforms/Utils
parent53716298997391af4aa6547150f9162a942312ff (diff)
downloadexternal_llvm-a856e3625f4d2486c2968afbbbc1192ae191b88f.zip
external_llvm-a856e3625f4d2486c2968afbbbc1192ae191b88f.tar.gz
external_llvm-a856e3625f4d2486c2968afbbbc1192ae191b88f.tar.bz2
remove a isFreeCall check: it is a callinst that can write to memory already.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85863 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils')
-rw-r--r--lib/Transforms/Utils/Local.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/Transforms/Utils/Local.cpp b/lib/Transforms/Utils/Local.cpp
index fcaf69e..543ddf1 100644
--- a/lib/Transforms/Utils/Local.cpp
+++ b/lib/Transforms/Utils/Local.cpp
@@ -24,7 +24,6 @@
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/Analysis/ConstantFolding.h"
#include "llvm/Analysis/DebugInfo.h"
-#include "llvm/Analysis/MemoryBuiltins.h"
#include "llvm/Analysis/ProfileInfo.h"
#include "llvm/Target/TargetData.h"
#include "llvm/Support/GetElementPtrTypeIterator.h"
@@ -60,8 +59,8 @@ bool llvm::isSafeToLoadUnconditionally(Value *V, Instruction *ScanFrom) {
// If we see a free or a call which may write to memory (i.e. which might do
// a free) the pointer could be marked invalid.
- if (isFreeCall(BBI) || (isa<CallInst>(BBI) && BBI->mayWriteToMemory() &&
- !isa<DbgInfoIntrinsic>(BBI)))
+ if (isa<CallInst>(BBI) && BBI->mayWriteToMemory() &&
+ !isa<DbgInfoIntrinsic>(BBI))
return false;
if (LoadInst *LI = dyn_cast<LoadInst>(BBI)) {