[llvm] r291710 - [NewGVN] Parenthesise assertion condition (-Wparenthesis).

Davide Italiano via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 11 13:58:42 PST 2017


Author: davide
Date: Wed Jan 11 15:58:42 2017
New Revision: 291710

URL: http://llvm.org/viewvc/llvm-project?rev=291710&view=rev
Log:
[NewGVN] Parenthesise assertion condition (-Wparenthesis).

Format an assertion message while I'm here.

Modified:
    llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp

Modified: llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp?rev=291710&r1=291709&r2=291710&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp Wed Jan 11 15:58:42 2017
@@ -1536,13 +1536,12 @@ void NewGVN::verifyMemoryCongruency() co
     if (auto *FirstMUD = dyn_cast<MemoryUseOrDef>(KV.first)) {
       auto *SecondMUD = dyn_cast<MemoryUseOrDef>(KV.second);
       if (FirstMUD && SecondMUD)
-        assert(singleReachablePHIPath(FirstMUD, SecondMUD) ||
+        assert((singleReachablePHIPath(FirstMUD, SecondMUD) ||
                ValueToClass.lookup(FirstMUD->getMemoryInst()) ==
-                       ValueToClass.lookup(SecondMUD->getMemoryInst()) &&
+                       ValueToClass.lookup(SecondMUD->getMemoryInst())) &&
                    "The instructions for these memory operations should have "
-                   "been in "
-                   "the same congruence class or reachable through a single "
-                   "argument phi");
+                   "been in the same congruence class or reachable through"
+                   "a single argument phi");
     } else if (auto *FirstMP = dyn_cast<MemoryPhi>(KV.first)) {
 
       // We can only sanely verify that MemoryDefs in the operand list all have




More information about the llvm-commits mailing list