Handle an addrspacecast case in memcpyopt

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@199836 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Matt Arsenault
2014-01-22 21:53:19 +00:00
parent 1214e71d77
commit 88a9f0476c
2 changed files with 18 additions and 1 deletions

View File

@ -662,7 +662,7 @@ bool MemCpyOpt::performCallSlotOptzn(Instruction *cpy,
while (!srcUseList.empty()) {
User *UI = srcUseList.pop_back_val();
if (isa<BitCastInst>(UI)) {
if (isa<BitCastInst>(UI) || isa<AddrSpaceCastInst>(UI)) {
for (User::use_iterator I = UI->use_begin(), E = UI->use_end();
I != E; ++I)
srcUseList.push_back(*I);