llvm-6502/include/llvm
Philip Reames d021bb8003 [Statepoints 3/4] Statepoint infrastructure for garbage collection: SelectionDAGBuilder
This is the third patch in a small series.  It contains the CodeGen support for lowering the gc.statepoint intrinsic sequences (223078) to the STATEPOINT pseudo machine instruction (223085).  The change also includes the set of helper routines and classes for working with gc.statepoints, gc.relocates, and gc.results since the lowering code uses them.  

With this change, gc.statepoints should be functionally complete.  The documentation will follow in the fourth change, and there will likely be some cleanup changes, but interested parties can start experimenting now.

I'm not particularly happy with the amount of code or complexity involved with the lowering step, but at least it's fairly well isolated.  The statepoint lowering code is split into it's own files and anyone not working on the statepoint support itself should be able to ignore it.  

During the lowering process, we currently spill aggressively to stack. This is not entirely ideal (and we have plans to do better), but it's functional, relatively straight forward, and matches closely the implementations of the patchpoint intrinsics.  Most of the complexity comes from trying to keep relocated copies of values in the same stack slots across statepoints.  Doing so avoids the insertion of pointless load and store instructions to reshuffle the stack.  The current implementation isn't as effective as I'd like, but it is functional and 'good enough' for many common use cases.  

In the long term, I'd like to figure out how to integrate the statepoint lowering with the register allocator.  In principal, we shouldn't need to eagerly spill at all.  The register allocator should do any spilling required and the statepoint should simply record that fact.  Depending on how challenging that turns out to be, we may invest in a smarter global stack slot assignment mechanism as a stop gap measure.  

Reviewed by: atrick, ributzka





git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223137 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-02 18:50:36 +00:00
..
ADT Triple: Add AMDHSA operating system type 2014-12-02 16:45:47 +00:00
Analysis [stack protector] Set edge weights for newly created basic blocks. 2014-12-01 04:27:03 +00:00
AsmParser
Bitcode Revert commits r222146 and r222137. 2014-11-17 19:26:40 +00:00
CodeGen [Statepoints 3/4] Statepoint infrastructure for garbage collection: SelectionDAGBuilder 2014-12-02 18:50:36 +00:00
Config Expose LLVM version string via macro in llvm-config.h, and modify Go bindings 2014-11-19 03:34:17 +00:00
DebugInfo Reapply "[dwarfdump] Add support for dumping accelerator tables." 2014-11-14 16:15:53 +00:00
ExecutionEngine [MCJIT] Replace JITEventListener::anchor (temporarily removed in r222861), and 2014-11-27 01:41:16 +00:00
IR [Statepoints 3/4] Statepoint infrastructure for garbage collection: SelectionDAGBuilder 2014-12-02 18:50:36 +00:00
IRReader
LineEditor
Linker Partial revert of r222986. 2014-12-01 16:32:20 +00:00
LTO Remove StringMap::GetOrCreateValue in favor of StringMap::insert 2014-11-19 05:49:42 +00:00
MC [NVPTX] Do not emit .weak symbols for NVPTX 2014-12-01 21:16:17 +00:00
Object Widen ELFYAML relocation type to 32 bits 2014-11-27 17:20:48 +00:00
Option
ProfileData llvm-cov: Sink some reporting logic into CoverageMapping 2014-11-14 01:50:32 +00:00
Support Emit Tag_ABI_FP_denormal correctly in fast-math mode. 2014-12-02 08:22:29 +00:00
TableGen Revert r222965 "Make MultiClass::DefPrototypes own their Records to fix memory leaks." 2014-11-30 00:43:50 +00:00
Target [Statepoints 2/4] Statepoint infrastructure for garbage collection: MI & x86-64 Backend 2014-12-01 22:52:56 +00:00
Transforms DebugIR: Delete -debug-ir 2014-11-29 03:15:47 +00:00
CMakeLists.txt
InitializePasses.h DebugIR: Delete -debug-ir 2014-11-29 03:15:47 +00:00
LinkAllIR.h
LinkAllPasses.h Remove the unused FindUsedTypes pass. 2014-11-24 20:53:26 +00:00
module.modulemap Try to make the modules buildbot happy again. 2014-11-26 03:44:47 +00:00
module.modulemap.build
Pass.h
PassAnalysisSupport.h
PassInfo.h
PassManager.h
PassRegistry.h
PassSupport.h