summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/Collector.cpp4
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp4
-rw-r--r--llvm/lib/CodeGen/ShadowStackCollector.cpp2
3 files changed, 5 insertions, 5 deletions
diff --git a/llvm/lib/CodeGen/Collector.cpp b/llvm/lib/CodeGen/Collector.cpp
index 07869a0ff55..6c5263d73e3 100644
--- a/llvm/lib/CodeGen/Collector.cpp
+++ b/llvm/lib/CodeGen/Collector.cpp
@@ -179,7 +179,7 @@ bool LowerIntrinsics::InsertRootInitializers(Function &F, AllocaInst **Roots,
for (; !CouldBecomeSafePoint(IP); ++IP)
if (StoreInst *SI = dyn_cast<StoreInst>(IP))
if (AllocaInst *AI =
- dyn_cast<AllocaInst>(StripPointerCasts(SI->getOperand(1))))
+ dyn_cast<AllocaInst>(SI->getOperand(1)->stripPointerCasts()))
InitedRoots.insert(AI);
// Add root initializers.
@@ -294,7 +294,7 @@ bool LowerIntrinsics::PerformDefaultLowering(Function &F, Collector &Coll) {
// Initialize the GC root, but do not delete the intrinsic. The
// backend needs the intrinsic to flag the stack slot.
Roots.push_back(cast<AllocaInst>(
- StripPointerCasts(CI->getOperand(1))));
+ CI->getOperand(1)->stripPointerCasts()));
}
break;
default:
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
index ea047e683f5..7ac5218ecfd 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
@@ -2712,7 +2712,7 @@ void SelectionDAGLowering::visitTargetIntrinsic(CallInst &I,
/// ExtractTypeInfo - Returns the type info, possibly bitcast, encoded in V.
static GlobalVariable *ExtractTypeInfo (Value *V) {
- V = StripPointerCasts(V);
+ V = V->stripPointerCasts();
GlobalVariable *GV = dyn_cast<GlobalVariable>(V);
assert ((GV || isa<ConstantPointerNull>(V)) &&
"TypeInfo must be a global variable or NULL");
@@ -3150,7 +3150,7 @@ SelectionDAGLowering::visitIntrinsicCall(CallInst &I, unsigned Intrinsic) {
return 0;
case Intrinsic::init_trampoline: {
- const Function *F = cast<Function>(StripPointerCasts(I.getOperand(2)));
+ const Function *F = cast<Function>(I.getOperand(2)->stripPointerCasts());
SDOperand Ops[6];
Ops[0] = getRoot();
diff --git a/llvm/lib/CodeGen/ShadowStackCollector.cpp b/llvm/lib/CodeGen/ShadowStackCollector.cpp
index 121dfc24077..092671ce562 100644
--- a/llvm/lib/CodeGen/ShadowStackCollector.cpp
+++ b/llvm/lib/CodeGen/ShadowStackCollector.cpp
@@ -325,7 +325,7 @@ void ShadowStackCollector::CollectRoots(Function &F) {
if (Function *F = CI->getCalledFunction())
if (F->getIntrinsicID() == Intrinsic::gcroot) {
std::pair<CallInst*,AllocaInst*> Pair = std::make_pair(
- CI, cast<AllocaInst>(StripPointerCasts(CI->getOperand(1))));
+ CI, cast<AllocaInst>(CI->getOperand(1)->stripPointerCasts()));
if (IsNullValue(CI->getOperand(2)))
Roots.push_back(Pair);
else
OpenPOWER on IntegriCloud