diff options
author | Joseph Tremoulet <jotrem@microsoft.com> | 2015-11-07 01:11:31 +0000 |
---|---|---|
committer | Joseph Tremoulet <jotrem@microsoft.com> | 2015-11-07 01:11:31 +0000 |
commit | f748c8937e71b70386833829a65436cdff15d286 (patch) | |
tree | 834d20fd23c5580659dfb8a881f7f3cc6f12f9c2 /llvm/lib/Target/Sparc/SparcISelLowering.h | |
parent | c22811bbcc02e833a315274f2158add4217f8ca1 (diff) | |
download | bcm5719-llvm-f748c8937e71b70386833829a65436cdff15d286.tar.gz bcm5719-llvm-f748c8937e71b70386833829a65436cdff15d286.zip |
[WinEH] Update exception pointer registers
Summary:
The CLR's personality routine passes these in rdx/edx, not rax/eax.
Make getExceptionPointerRegister a virtual method parameterized by
personality function to allow making this distinction.
Similarly make getExceptionSelectorRegister a virtual method parameterized
by personality function, for symmetry.
Reviewers: pgavlin, majnemer, rnk
Subscribers: jyknight, dsanders, llvm-commits
Differential Revision: http://reviews.llvm.org/D14344
llvm-svn: 252383
Diffstat (limited to 'llvm/lib/Target/Sparc/SparcISelLowering.h')
-rw-r--r-- | llvm/lib/Target/Sparc/SparcISelLowering.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/lib/Target/Sparc/SparcISelLowering.h b/llvm/lib/Target/Sparc/SparcISelLowering.h index 6786b9e3cd3..4e46709cfc0 100644 --- a/llvm/lib/Target/Sparc/SparcISelLowering.h +++ b/llvm/lib/Target/Sparc/SparcISelLowering.h @@ -89,6 +89,20 @@ namespace llvm { return MVT::i32; } + /// If a physical register, this returns the register that receives the + /// exception address on entry to an EH pad. + unsigned + getExceptionPointerRegister(const Constant *PersonalityFn) const override { + return SP::I0; + } + + /// If a physical register, this returns the register that receives the + /// exception typeid on entry to a landing pad. + unsigned + getExceptionSelectorRegister(const Constant *PersonalityFn) const override { + return SP::I1; + } + /// getSetCCResultType - Return the ISD::SETCC ValueType EVT getSetCCResultType(const DataLayout &DL, LLVMContext &Context, EVT VT) const override; |