diff options
author | David Blaikie <dblaikie@gmail.com> | 2018-03-28 22:28:50 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2018-03-28 22:28:50 +0000 |
commit | 8ad9a97310239d4c2922f3583dcce7af40645c75 (patch) | |
tree | 911e4f4fc3d137b86ba53023a4a0be24f9ce0b67 /llvm/lib/CodeGen/CodeGenPrepare.cpp | |
parent | 2ce74015052d29700d5d4675c97a850c87bdb495 (diff) | |
download | llvm-8ad9a97310239d4c2922f3583dcce7af40645c75.zip llvm-8ad9a97310239d4c2922f3583dcce7af40645c75.tar.gz llvm-8ad9a97310239d4c2922f3583dcce7af40645c75.tar.bz2 |
Plumb useAA through TargetTransformInfo to remove Transforms->CodeGen header dependency
Thanks to echristo for the pointers on direction.
llvm-svn: 328737
Diffstat (limited to 'llvm/lib/CodeGen/CodeGenPrepare.cpp')
-rw-r--r-- | llvm/lib/CodeGen/CodeGenPrepare.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/CodeGenPrepare.cpp b/llvm/lib/CodeGen/CodeGenPrepare.cpp index c04cff9..4854a26 100644 --- a/llvm/lib/CodeGen/CodeGenPrepare.cpp +++ b/llvm/lib/CodeGen/CodeGenPrepare.cpp @@ -4314,8 +4314,7 @@ bool CodeGenPrepare::optimizeMemoryInst(Instruction *MemoryInst, Value *Addr, if (SunkAddr->getType() != Addr->getType()) SunkAddr = Builder.CreatePointerCast(SunkAddr, Addr->getType()); } else if (AddrSinkUsingGEPs || - (!AddrSinkUsingGEPs.getNumOccurrences() && TM && - SubtargetInfo->useAA())) { + (!AddrSinkUsingGEPs.getNumOccurrences() && TM && TTI->useAA())) { // By default, we use the GEP-based method when AA is used later. This // prevents new inttoptr/ptrtoint pairs from degrading AA capabilities. DEBUG(dbgs() << "CGP: SINKING nonlocal addrmode: " << AddrMode << " for " |