aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/ModuleDependencyCollector.cpp
diff options
context:
space:
mode:
authorAlexandros Lamprineas <alexandros.lamprineas@arm.com>2023-06-01 15:09:08 +0100
committerAlexandros Lamprineas <alexandros.lamprineas@arm.com>2023-06-01 16:38:04 +0100
commitb1f41685a60e5416af8f636393bffd03ac4c13f5 (patch)
treed474f6696a4be72153f5a66695c0624e956b5de6 /clang/lib/Frontend/ModuleDependencyCollector.cpp
parentb7052fa3295e49bbd6b90cf9c874392721603df2 (diff)
downloadllvm-b1f41685a60e5416af8f636393bffd03ac4c13f5.zip
llvm-b1f41685a60e5416af8f636393bffd03ac4c13f5.tar.gz
llvm-b1f41685a60e5416af8f636393bffd03ac4c13f5.tar.bz2
[IPSCCP] Decouple queries for function analysis results.
The SCCPSolver is using a structure (AnalysisResultsForFn) where it keeps pointers to various analyses needed by the IPSCCP pass. These analyses are requested all at the same time, which can become problematic in some cases. For example one could be retrieved via getCachedAnalysis() prior to the actual execution of the analysis. In more detail: The IPSCCP pass uses a DomTreeUpdater to preserve the PostDominatorTree in case the PostDominatorTreeAnalysis had run before IPSCCP. Starting with commit 1b1232047e83b the IPSCCP pass may use BlockFrequencyAnalysis for some functions in the module. As a result, the PostDominatorTreeAnalysis may not run until the BlockFrequencyAnalysis has run, since the latter analysis depends on the former. Currently, we setup the DomTreeUpdater using getCachedAnalysis to retrieve a PostDominatorTree. This happens before BlockFrequencyAnalysis has run, therefore the cached analysis can become invalid by the time we use it. Differential Revision: https://reviews.llvm.org/D151666
Diffstat (limited to 'clang/lib/Frontend/ModuleDependencyCollector.cpp')
0 files changed, 0 insertions, 0 deletions