Make CodeGen TBAA-aware.
[oota-llvm.git] / lib / CodeGen / MachineLICM.cpp
index 1f0412498b66ebc021488c3e572123af73ea4b93..8d0e1358863ce144bdb678db105b79e0e4ccb4b3 100644 (file)
@@ -777,7 +777,9 @@ bool MachineLICM::isLoadFromConstantMemory(MachineInstr *MI) {
     MachineFunction &MF = *MI->getParent()->getParent();
     return PSV->isConstant(MF.getFrameInfo());
   } else {
-    return AA->pointsToConstantMemory(MMO->getValue());
+    return AA->pointsToConstantMemory(AliasAnalysis::Location(MMO->getValue(),
+                                                              MMO->getSize(),
+                                                              MMO->getTBAAInfo()));
   }
 }