summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/IPO/FunctionAttrs.cpp
diff options
context:
space:
mode:
authorMatt Arsenault <Matthew.Arsenault@amd.com>2014-01-14 19:11:52 +0000
committerMatt Arsenault <Matthew.Arsenault@amd.com>2014-01-14 19:11:52 +0000
commite55a2c2e6bda2cdd2350c478cb08df440f263db8 (patch)
tree622d3bb5fc2226de7d6303cd91cd015cba3c7224 /llvm/lib/Transforms/IPO/FunctionAttrs.cpp
parent6633d57ae427515801ca24478add077c5049e7de (diff)
downloadbcm5719-llvm-e55a2c2e6bda2cdd2350c478cb08df440f263db8.tar.gz
bcm5719-llvm-e55a2c2e6bda2cdd2350c478cb08df440f263db8.zip
Make nocapture analysis work with addrspacecast
llvm-svn: 199246
Diffstat (limited to 'llvm/lib/Transforms/IPO/FunctionAttrs.cpp')
-rw-r--r--llvm/lib/Transforms/IPO/FunctionAttrs.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/IPO/FunctionAttrs.cpp b/llvm/lib/Transforms/IPO/FunctionAttrs.cpp
index 6e41f262fa6..ea664506da2 100644
--- a/llvm/lib/Transforms/IPO/FunctionAttrs.cpp
+++ b/llvm/lib/Transforms/IPO/FunctionAttrs.cpp
@@ -437,6 +437,7 @@ determinePointerReadAttrs(Argument *A,
case Instruction::GetElementPtr:
case Instruction::PHI:
case Instruction::Select:
+ case Instruction::AddrSpaceCast:
// The original value is not read/written via this if the new value isn't.
for (Instruction::use_iterator UI = I->use_begin(), UE = I->use_end();
UI != UE; ++UI) {
@@ -723,6 +724,7 @@ bool FunctionAttrs::IsFunctionMallocLike(Function *F,
// Extend the analysis by looking upwards.
case Instruction::BitCast:
case Instruction::GetElementPtr:
+ case Instruction::AddrSpaceCast:
FlowsToReturn.insert(RVI->getOperand(0));
continue;
case Instruction::Select: {
OpenPOWER on IntegriCloud