1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 02:52:53 +02:00
llvm-mirror/unittests/IR
Chandler Carruth 4fc787e70d [PM] Support invalidation of inner analysis managers from a pass over the outer IR unit.
Summary:
This never really got implemented, and was very hard to test before
a lot of the refactoring changes to make things more robust. But now we
can test it thoroughly and cleanly, especially at the CGSCC level.

The core idea is that when an inner analysis manager proxy receives the
invalidation event for the outer IR unit, it needs to walk the inner IR
units and propagate it to the inner analysis manager for each of those
units. For example, each function in the SCC needs to get an
invalidation event when the SCC gets one.

The function / module interaction is somewhat boring here. This really
becomes interesting in the face of analysis-backed IR units. This patch
effectively handles all of the CGSCC layer's needs -- both invalidating
SCC analysis and invalidating function analysis when an SCC gets
invalidated.

However, this second aspect doesn't really handle the
LoopAnalysisManager well at this point. That one will need some change
of design in order to fully integrate, because unlike the call graph,
the entire function behind a LoopAnalysis's results can vanish out from
under us, and we won't even have a cached API to access. I'd like to try
to separate solving the loop problems into a subsequent patch though in
order to keep this more focused so I've adapted them to the API and
updated the tests that immediately fail, but I've not added the level of
testing and validation at that layer that I have at the CGSCC layer.

An important aspect of this change is that the proxy for the
FunctionAnalysisManager at the SCC pass layer doesn't work like the
other proxies for an inner IR unit as it doesn't directly manage the
FunctionAnalysisManager and invalidation or clearing of it. This would
create an ever worsening problem of dual ownership of this
responsibility, split between the module-level FAM proxy and this
SCC-level FAM proxy. Instead, this patch changes the SCC-level FAM proxy
to work in terms of the module-level proxy and defer to it to handle
much of the updates. It only does SCC-specific invalidation. This will
become more important in subsequent patches that support more complex
invalidaiton scenarios.

Reviewers: jlebar

Subscribers: mehdi_amini, mcrosier, mzolotukhin, llvm-commits

Differential Revision: https://reviews.llvm.org/D27197

llvm-svn: 289317
2016-12-10 06:34:44 +00:00
..
AsmWriterTest.cpp Fix crash when printing instructions that have a metadata attached but no parent. 2016-01-07 20:14:30 +00:00
AttributesTest.cpp Fix non-determinism in order of LLVM attributes 2016-04-04 23:06:05 +00:00
CMakeLists.txt ADT: Split out simple_ilist, a simple intrusive list 2016-08-30 16:23:55 +00:00
ConstantRangeTest.cpp Introduce ConstantRange.addWithNoSignedWrap 2016-10-19 14:44:23 +00:00
ConstantsTest.cpp Fix constant folding of addrspacecast of null 2016-05-21 00:14:04 +00:00
DebugInfoTest.cpp Formatting with clang-format patch r280700 2016-09-06 17:03:02 +00:00
DebugTypeODRUniquingTest.cpp Formatting with clang-format patch r280700 2016-09-06 17:03:02 +00:00
DominatorTreeTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
FunctionTest.cpp Fix warnings in FunctionTest.cpp. 2016-07-13 18:17:46 +00:00
InstructionsTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
IntrinsicsTest.cpp Handle more edge cases in intrinsic name binary search 2016-01-26 22:33:19 +00:00
IRBuilderTest.cpp Formatting with clang-format patch r280700 2016-09-06 17:03:02 +00:00
LegacyPassManagerTest.cpp [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
MDBuilderTest.cpp IR: Split Metadata from Value 2014-12-09 18:38:53 +00:00
MetadataTest.cpp [DIExpression] Introduce a dedicated DW_OP_LLVM_fragment operation 2016-12-05 18:04:47 +00:00
ModuleTest.cpp Avoid unnecessary constexpr to appease MSVC 2013 2016-10-11 18:35:13 +00:00
PassManagerTest.cpp [PM] Support invalidation of inner analysis managers from a pass over the outer IR unit. 2016-12-10 06:34:44 +00:00
PatternMatch.cpp Add support to paternmatch for simple const Value cases. 2016-08-12 22:16:05 +00:00
TypeBuilderTest.cpp [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
TypesTest.cpp Fix several accidental DOS line endings in source files 2016-01-03 17:22:03 +00:00
UserTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
UseTest.cpp Format: Modernize using variadic templates. 2015-02-15 22:15:41 +00:00
ValueHandleTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
ValueMapTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
ValueTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
VerifierTest.cpp [unittests] Remove an MSVC 2013 workaround, NFCI. 2016-10-25 17:58:25 +00:00
WaymarkTest.cpp Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00