llvm-project/llvm/lib/Transforms
Andrew Litteken e6ae623314 [IROutliner] Adding support for consolidating functions with different output arguments.
Certain regions can have values introduced inside the region that are
used outside of the region. These may not be the same for each similar
region, so we must create one over arching set of arguments for the
consolidated function.

We do this by iterating over the outputs for each extracted function,
and creating as many different arguments to encapsulate the different
outputs sets. For each output set, we create a different block with the
necessary stores from the value to the output register. There is then
one switch statement, controlled by an argument to the function, to
differentiate which block to use.

Changed Tests for consistency:
llvm/test/Transforms/IROutliner/extraction.ll
llvm/test/Transforms/IROutliner/illegal-assumes.ll
llvm/test/Transforms/IROutliner/illegal-memcpy.ll
llvm/test/Transforms/IROutliner/illegal-memmove.ll
llvm/test/Transforms/IROutliner/illegal-vaarg.ll

Tests to test new functionality:
llvm/test/Transforms/IROutliner/outlining-different-output-blocks.ll
llvm/test/Transforms/IROutliner/outlining-remapped-outputs.ll
llvm/test/Transforms/IROutliner/outlining-same-output-blocks.ll

Reviewers: jroelofs, paquette

Differential Revision: https://reviews.llvm.org/D87296
2020-12-28 16:17:07 -06:00
..
AggressiveInstCombine [AggressiveInstCombine] Generalize foldGuardedRotateToFunnelShift to generic funnel shifts (REAPPLIED) 2020-12-21 15:22:27 +00:00
CFGuard llvmbuildectomy - replace llvm-build by plain cmake 2020-11-13 10:35:24 +01:00
Coroutines Add a llvm.coro.end.async intrinsic 2020-12-22 10:52:28 -08:00
Hello
HelloNew llvmbuildectomy - replace llvm-build by plain cmake 2020-11-13 10:35:24 +01:00
IPO [IROutliner] Adding support for consolidating functions with different output arguments. 2020-12-28 16:17:07 -06:00
InstCombine [InstCombine] Disable unsafe select transform behind a flag 2020-12-28 22:43:52 +01:00
Instrumentation [Transforms] Use llvm::append_range (NFC) 2020-12-27 09:57:29 -08:00
ObjCARC [ObjC][ARC] Fix a bug where the inline-asm retain/claim RV marker wasn't 2020-12-18 16:59:06 -08:00
Scalar [RS4GC] Lazily set changed flag when folding single entry phis 2020-12-28 10:54:21 +07:00
Utils [SimplifyCFG] FoldBranchToCommonDest: gracefully handle unreachable code () 2020-12-28 23:31:19 +03:00
Vectorize Reapply "[LV] Vectorize (some) early and multiple exit loops"" w/fix for builder 2020-12-28 10:13:28 -08:00
CMakeLists.txt Reland [docs][NewPM] Add docs for writing NPM passes 2020-09-14 16:06:19 -07:00