While LazyBlockFrequencyInfo itself is lazy, the dominator tree and loop info analyses it requires are not. Drop the dependency on this pass in SelectionDAGIsel at O0. This makes for a ~0.6% O0 compile-time improvement.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | ||
---|---|---|
447 ↗ | (On Diff #265532) | Can we have this explicitly query OptLevel like above to be in sync, as in if (PSI && PSI->hasProfileSummary() && OptLevel != CodeGenOpt::None) { BFI = &getAnalysis<LazyBlockFrequencyInfoPass>().getBFI(); } I think that would be safer against accidental cases where the above and this code get out of sync for some reason and BFI silently gets dropped. Also, this is in line with the code that uses 'UseMBPI' below (line 465). |
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | ||
---|---|---|
447 ↗ | (On Diff #265532) | Good point, done! |