]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - opencl/llvm.git/commit
Revert "r225811 - Revert "r225808 - [PowerPC] Add StackMap/PatchPoint support""
authorHal Finkel <hfinkel@anl.gov>
Wed, 14 Jan 2015 01:07:51 +0000 (01:07 +0000)
committerHal Finkel <hfinkel@anl.gov>
Wed, 14 Jan 2015 01:07:51 +0000 (01:07 +0000)
commitade705c6e5efec4deabd07e1455c3bcb7b3ad5d6
tree7878144d3680820c3024099d81341021fc32a05a
parent21befa7761c9e0983a85603ec0ec35e58441fadf
Revert "r225811 - Revert "r225808 - [PowerPC] Add StackMap/PatchPoint support""

This re-applies r225808, fixed to avoid problems with SDAG dependencies along
with the preceding fix to ScheduleDAGSDNodes::RegDefIter::InitNodeNumDefs.
These problems caused the original regression tests to assert/segfault on many
(but not all) systems.

Original commit message:

This commit does two things:

 1. Refactors PPCFastISel to use more of the common infrastructure for call
    lowering (this lets us take advantage of this common code for lowering some
    common intrinsics, stackmap/patchpoint among them).

 2. Adds support for stackmap/patchpoint lowering. For the most part, this is
    very similar to the support in the AArch64 target, with the obvious differences
    (different registers, NOP instructions, etc.). The test cases are adapted
    from the AArch64 test cases.

One difference of note is that the patchpoint call sequence takes 24 bytes, so
you can't use less than that (on AArch64 you can go down to 16). Also, as noted
in the docs, we take the patchpoint address to be the actual code address
(assuming the call is local in the TOC-sharing sense), which should yield
higher performance than generating the full cross-DSO indirect-call sequence
and is likely just as useful for JITed code (if not, we'll change it).

StackMaps and Patchpoints are still marked as experimental, and so this support
is doubly experimental. So go ahead and experiment!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225909 91177308-0d34-0410-b5e6-96231b3b80d8
17 files changed:
docs/StackMaps.rst
lib/Target/PowerPC/PPCAsmPrinter.cpp
lib/Target/PowerPC/PPCCallingConv.h [new file with mode: 0644]
lib/Target/PowerPC/PPCCallingConv.td
lib/Target/PowerPC/PPCFastISel.cpp
lib/Target/PowerPC/PPCFrameLowering.cpp
lib/Target/PowerPC/PPCISelLowering.cpp
lib/Target/PowerPC/PPCISelLowering.h
lib/Target/PowerPC/PPCInstrInfo.cpp
lib/Target/PowerPC/PPCRegisterInfo.cpp
lib/Target/PowerPC/PPCRegisterInfo.h
lib/Target/PowerPC/PPCTargetTransformInfo.cpp
test/CodeGen/PowerPC/ppc64-anyregcc-crash.ll [new file with mode: 0644]
test/CodeGen/PowerPC/ppc64-anyregcc.ll [new file with mode: 0644]
test/CodeGen/PowerPC/ppc64-patchpoint.ll [new file with mode: 0644]
test/CodeGen/PowerPC/ppc64-stackmap-nops.ll [new file with mode: 0644]
test/CodeGen/PowerPC/ppc64-stackmap.ll [new file with mode: 0644]