llvm-project/llvm/unittests
Amara Emerson 8bde5e58c0 Delay outgoing register assignments to last.
The delayed stack protector feature which is currently used for SDAG (and thus
allows for more commonly generating tail calls) depends on being able to extract
the tail call into a separate return block. To do this it also has to extract
the vreg->physreg copies that set up the call's arguments, since if it doesn't
then the call inst ends up using undefined physregs in it's new spliced block.

SelectionDAG implementations can do this because they delay emitting register
copies until  *after* the stack arguments are set up. GISel however just
processes and emits the arguments in IR order, so stack arguments always end up
last, and thus this breaks the code that looks for any register arg copies that
precede the call instruction.

This patch adds a thunk argument to the assignValueToReg() and custom assignment
hooks. For outgoing arguments, register assignments use this return param to
return a thunk that does the actual generating of the copies. We collect these
until all the outgoing stack assignments have been done and then execute them,
so that the copies (and perhaps some artifacts like G_SEXTs) are placed after
any stores.

Differential Revision: https://reviews.llvm.org/D110610
2021-10-04 12:33:20 -07:00
..
ADT [llvm] [ADT] Add a range/iterator-based Split() 2021-09-27 10:43:09 +02:00
Analysis Fix incorrect GEP bitwidth in areNonOverlapSameBaseLoadAndStore() 2021-09-28 17:57:36 +01:00
AsmParser [SVE] Remove calls to VectorType::getNumElements from AsmParserTest 2020-07-07 14:55:42 -07:00
BinaryFormat [llvm][clang][NFC] updates inline licence info 2021-08-11 02:48:53 +00:00
Bitcode [AMDGPU] Set the default globals address space to 1 2020-11-20 15:46:53 +00:00
Bitstream PR51018: Remove explicit conversions from SmallString to StringRef to future-proof against C++23 2021-07-08 13:37:57 -07:00
CodeGen Delay outgoing register assignments to last. 2021-10-04 12:33:20 -07:00
DebugInfo [DWARF][NFC] add ParentIdx and SiblingIdx to DWARFDebugInfoEntry for faster navigation. 2021-10-02 08:11:06 +03:00
Demangle [demangle] Add a unittest for _Float16 demangling. NFC 2021-10-04 22:05:08 +08:00
ExecutionEngine [ORC] Remove ORC RPC. 2021-10-01 11:17:33 -07:00
FileCheck Bump googletest to 1.10.0 2021-05-14 19:16:31 +02:00
Frontend [OpenMP][OpenMPIRBuilder] Implement loop unrolling. 2021-09-04 19:18:58 -05:00
FuzzMutate [FuzzMutate] Add mutator to modify instruction flags. 2021-01-23 19:05:20 +00:00
IR [APInt] Stop using soft-deprecated constructors and methods in llvm. NFC. 2021-10-04 08:57:44 +01:00
InterfaceStub [ifs][elfabi] Merge llvm-ifs/elfabi tools 2021-07-19 11:23:19 -07:00
LineEditor
Linker [RGT] Recode more unreachable assertions and tautologies 2021-03-19 09:17:22 -07:00
MC [SystemZ][z/OS] Introduce initial support for GOFF asm parser 2021-10-01 10:29:14 -04:00
MI [AMDGPU] Rename amdgcn_wwm to amdgcn_strict_wwm 2021-03-03 09:33:57 +01:00
MIR CodeGen: Print/parse LLTs in MachineMemOperands 2021-06-30 16:54:13 -04:00
Object [AIX][XCOFF] emit vector info of traceback table. 2021-06-14 11:15:22 -04:00
ObjectYAML Add -Wno-error=unknown flag to clang-format. 2020-09-19 10:17:57 +02:00
Option [OptTable] Reapply Improve error message output for grouped short options 2021-09-03 11:13:52 +01:00
Passes unittests: Fix library dependency name 2021-07-07 06:56:15 -07:00
ProfileData [CSSPGO] Split context string to deduplicate function name used in the context. 2021-08-30 20:09:29 -07:00
Remarks
Support [APInt] Stop using soft-deprecated constructors and methods in llvm. NFC. 2021-10-04 08:57:44 +01:00
TableGen Make TableGenGlobalISel an object library 2021-06-05 15:04:33 +02:00
Target [ARM] Allow smaller VMOVL in tail predicated loops 2021-09-22 12:07:52 +01:00
TextAPI [llvm][TextAPI] add mapping from OS string to Platform 2021-05-06 16:25:56 -07:00
Transforms [CodeMoverUtils] Enhance isSafeToMoveBefore() when control flow equivalence is satisfied 2021-09-27 18:37:36 -04:00
XRay Put back the trailing commas on TYPED_TEST_SUITE 2021-05-17 14:14:13 +02:00
tools [exegesis][X86] ParallelSnippetGenerator: don't accidentally create serialized instructions 2021-09-07 12:39:23 +03:00
CMakeLists.txt [MIRPrinter] Add machine metadata support. 2021-06-19 12:48:08 -04:00
unittest.cfg.in