[PATCH] D40146: [JumpThreading] Deferred preservation of DT and LVI across the pass.

Jakub Kuderski via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 12 07:11:22 PST 2017


kuhar added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/JumpThreading.cpp:289
   auto AA = &getAnalysis<AAResultsWrapperPass>().getAAResults();
+  DeferredDominance *DDT = new DeferredDominance(*DT);
   std::unique_ptr<BlockFrequencyInfo> BFI;
----------------
kuhar wrote:
> One remark: why new here instead of just putting it on the stack? If you need to pass the ownership around, who deallocates it? 
Nit: `DeferredDominance DDT = DeferredDominance(*DT)` can be just `DeferredDominance DDT(*DT);`


https://reviews.llvm.org/D40146





More information about the llvm-commits mailing list