[LICM] Add an assert to ensure all instruction types needing aliasing are handled...
authorPhilip Reames <listmail@philipreames.com>
Thu, 9 Aug 2018 03:44:28 +0000 (03:44 +0000)
committerPhilip Reames <listmail@philipreames.com>
Thu, 9 Aug 2018 03:44:28 +0000 (03:44 +0000)
llvm-svn: 339308

llvm/lib/Transforms/Scalar/LICM.cpp

index 1cbe3ef..d4ef9ad 100644 (file)
@@ -686,6 +686,8 @@ bool llvm::canSinkOrHoistInst(Instruction &I, AAResults *AA, DominatorTree *DT,
     return false;
   }
 
+  assert(!I.mayReadOrWriteMemory() && "unhandled aliasing");
+
   // We've established mechanical ability and aliasing, it's up to the caller
   // to check fault safety
   return true;