llvm-project/llvm/unittests
Chandler Carruth 2e0fe3e65b [PM/LCG] Remove the lazy RefSCC formation from the LazyCallGraph during
iteration.

The lazy formation of RefSCCs isn't really the most important part of
the laziness here -- that has to do with walking the functions
themselves -- and isn't essential to maintain. Originally, there were
incremental update algorithms that relied on updates happening
predominantly near the most recent RefSCC formed, but those have been
replaced with ones that have much tighter general case bounds at this
point. We do still perform asserts that only scale well due to this
incrementality, but those are easy to place behind EXPENSIVE_CHECKS.

Removing this simplifies the entire analysis by having a single up-front
step that builds all of the RefSCCs in a direct Tarjan walk. We can even
easily replace this with other or better algorithms at will and with
much less confusion now that there is no iterator-based incremental
logic involved. This removes a lot of complexity from LCG.

Another advantage of moving in this direction is that it simplifies
testing the system substantially as we no longer have to worry about
observing and mutating the graph half-way through the RefSCC formation.

We still need a somewhat special iterator for RefSCCs because we want
the iterator to remain stable in the face of graph updates. However,
this now merely involves relative indexing to the current RefSCC's
position in the sequence which isn't too hard.

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

llvm-svn: 294227
2017-02-06 19:38:06 +00:00
..
ADT TripleTest.FileFormat: check non-default value 2017-02-04 22:49:22 +00:00
Analysis [PM/LCG] Remove the lazy RefSCC formation from the LazyCallGraph during 2017-02-06 19:38:06 +00:00
AsmParser Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
Bitcode Reapply "Make BitCodeAbbrev ownership explicit using shared_ptr rather than IntrusiveRefCntPtr"" 2017-01-04 22:36:33 +00:00
CodeGen GlobalISel: rename legalizer components to match others. 2016-10-14 22:18:18 +00:00
DebugInfo Fix for r293104, which renamed a directory. 2017-01-25 22:48:57 +00:00
ExecutionEngine [Orc][RPC] Refactor ParallelCallGroup to decouple it from RPCEndpoint. 2017-01-24 06:13:47 +00:00
IR Change debug-info-for-profiling from a TargetOption to a function attribute. 2017-02-01 22:45:09 +00:00
LineEditor Remove autoconf support 2016-01-26 21:29:08 +00:00
Linker Remangle intrinsics names when types are renamed 2016-06-24 15:10:29 +00:00
MC Fix static initialization order fiasco in MCTests 2016-11-11 22:18:42 +00:00
MI CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses 2016-08-24 01:52:46 +00:00
Object Fix llvm-symbolizer to correctly sort a symbol array and calculate symbol sizes 2016-11-15 21:07:03 +00:00
ObjectYAML Move ObjectYAML code to a new library. 2016-03-01 19:15:06 +00:00
Option Option parser: class for consuming a joined arg in addition to all remaining args 2016-04-15 00:23:30 +00:00
ProfileData Fix spelling mistakes in Tools/Tests comments. NFC. 2016-11-20 13:31:13 +00:00
Support [Support] Simplify triple check in Host CPU test. NFC. 2017-02-04 00:46:59 +00:00
Target Remove a FIXME that I forgot about. NFC. 2016-10-13 05:28:55 +00:00
Transforms Revert "[MemorySSA] Revert r293361 and r293363, as the tests fail under asan." 2017-01-30 11:35:39 +00:00
CMakeLists.txt [gtest] Fix the way we disable a warning for unittests. 2017-01-04 23:40:06 +00:00