[PATCH] D30369: Allow None as a MemoryLocation to getModRefInfo, use it to start cleaning up interfaces and uses

Davide Italiano via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 14 08:35:27 PDT 2017


davide accepted this revision.
davide added a comment.
This revision is now accepted and ready to land.

Some nits inline.



================
Comment at: include/llvm/Analysis/AliasAnalysis.h:530-544
+      return getModRefInfo((const VAArgInst *)I, Loc);
+    case Instruction::Load:
+      return getModRefInfo((const LoadInst *)I, Loc);
+    case Instruction::Store:
+      return getModRefInfo((const StoreInst *)I, Loc);
+    case Instruction::Fence:
+      return getModRefInfo((const FenceInst *)I, Loc);
----------------
can you use `static_cast<>` here instead (and if you feel motivated change the surrounding statements to do the same)? 


================
Comment at: include/llvm/Analysis/MemoryLocation.h:19-20
 
+#include "llvm/ADT/Optional.h"
 #include "llvm/ADT/DenseMapInfo.h"
 #include "llvm/IR/CallSite.h"
----------------
Unsorted.


https://reviews.llvm.org/D30369





More information about the llvm-commits mailing list