[PATCH] D31726: AliasAnalysis: Be less conservative about volatile than atomic.

Hal Finkel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 6 09:00:43 PDT 2017


hfinkel added inline comments.


================
Comment at: lib/Analysis/AliasAnalysis.cpp:336
+  // Be conservative in the face of atomic.
+  if (isStrongerThan(L->getOrdering(), AtomicOrdering::Unordered))
     return MRI_ModRef;
----------------
Can you please make sure this part of the AA interface contract is now documented in the header file.


================
Comment at: lib/Transforms/Utils/MemorySSA.cpp:1468
+  }
+  return false;
+}
----------------
Can you add a comment somewhere that we don't need to check atomicrmw or cmpxchg because they're not allowed to have an ordering less than relaxed. The LangRef says so, but I think it is worth noting why these are the only two things you need to check here because the others should always get a ModRef return from AA.


https://reviews.llvm.org/D31726





More information about the llvm-commits mailing list