diff options
author | Juergen Ributzka <juergen@apple.com> | 2013-11-09 01:51:33 +0000 |
---|---|---|
committer | Juergen Ributzka <juergen@apple.com> | 2013-11-09 01:51:33 +0000 |
commit | d4f5a615674aaabeee4e444e708d1fa00a41495e (patch) | |
tree | 37ab0cacf3e60a5d6660d7f4b65e64609d29046c /lib/Target/X86/X86ISelLowering.cpp | |
parent | 999ffb6085a6e24261680b41d4f43ad4ba8fd250 (diff) | |
download | external_llvm-d4f5a615674aaabeee4e444e708d1fa00a41495e.tar.gz external_llvm-d4f5a615674aaabeee4e444e708d1fa00a41495e.tar.bz2 external_llvm-d4f5a615674aaabeee4e444e708d1fa00a41495e.zip |
[Stackmap] Materialize the jump address within the patchpoint noop slide.
This patch moves the jump address materialization inside the noop slide. This
enables patching of the materialization itself or its complete removal. This
patch also adds the ability to define scratch registers that can be used safely
by the code called from the patchpoint intrinsic. At least one scratch register
is required, because that one is used for the materialization of the jump
address. This patch depends on D2009.
Differential Revision: http://llvm-reviews.chandlerc.com/D2074
Reviewed by Andy
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194306 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86/X86ISelLowering.cpp')
-rw-r--r-- | lib/Target/X86/X86ISelLowering.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 55bfab449a..a8743afce9 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -1773,6 +1773,11 @@ X86TargetLowering::CanLowerReturn(CallingConv::ID CallConv, return CCInfo.CheckReturn(Outs, RetCC_X86); } +const uint16_t *X86TargetLowering::getScratchRegisters(CallingConv::ID) const { + static const uint16_t ScratchRegs[] = { X86::R11, 0 }; + return ScratchRegs; +} + SDValue X86TargetLowering::LowerReturn(SDValue Chain, CallingConv::ID CallConv, bool isVarArg, |