[SeparateConstOffsetFromGEP] set PreservesCFG flag
authorJingyue Wu <jingyue@google.com>
Sun, 1 Feb 2015 02:33:02 +0000 (02:33 +0000)
committerJingyue Wu <jingyue@google.com>
Sun, 1 Feb 2015 02:33:02 +0000 (02:33 +0000)
SeparateConstOffsetFromGEP does not change the shape of the control flow graph.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@227704 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Scalar/SeparateConstOffsetFromGEP.cpp

index 34994d2f3774fad6b0d56401adf44efc558e43cd..47ffd23fa430c1d3e645b556ae1f07d6366ddac0 100644 (file)
@@ -314,6 +314,7 @@ class SeparateConstOffsetFromGEP : public FunctionPass {
   void getAnalysisUsage(AnalysisUsage &AU) const override {
     AU.addRequired<DataLayoutPass>();
     AU.addRequired<TargetTransformInfoWrapperPass>();
+    AU.setPreservesCFG();
   }
 
   bool doInitialization(Module &M) override {