[PATCH] D133193: [GlobalOpt] Fix debug variance problem in hasOnlyColdCalls

Mikael Holmén via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 2 03:03:03 PDT 2022


uabelho added a comment.

In D133193#3766538 <https://reviews.llvm.org/D133193#3766538>, @nikic wrote:

> LGTM
>
>> However, without debuginfo, GlobalOpt went further and ran
>
> BlockFrequencyAnalysis and (more importanly) LoopAnalysis, and later on in
> the pipeline, instcombine behaved in different ways when LoopInfo was
> present.
>
> We should really stop doing that, and instead pass in an argument whether InstCombine in a given pipeline position should use LoopInfo or not. Especially with the NewPM "if available" dependencies are a really bad idea, because whether a given analysis is available or not can be quite unpredictable.

Yes this really had me confused for a while when I tried to track down where the debug variance occured.
Thanks for the super quick review!


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D133193/new/

https://reviews.llvm.org/D133193



More information about the llvm-commits mailing list