diff options
author | Renato Golin <renato.golin@linaro.org> | 2013-08-15 20:45:13 +0000 |
---|---|---|
committer | Renato Golin <renato.golin@linaro.org> | 2013-08-15 20:45:13 +0000 |
commit | 24adc8f60f0a39e45363eef5392fe1a7e27bd12f (patch) | |
tree | ebe12fbf3f22dc41de0d1fee5f3bfa2fe65fc2c6 /lib/Target/ARM/ARMSubtarget.cpp | |
parent | 873e392ffd6701f6724e4c2a7accd0a4e1f1e0a1 (diff) | |
download | llvm-24adc8f60f0a39e45363eef5392fe1a7e27bd12f.tar.gz llvm-24adc8f60f0a39e45363eef5392fe1a7e27bd12f.tar.bz2 llvm-24adc8f60f0a39e45363eef5392fe1a7e27bd12f.tar.xz |
make arm-reserve-r9 available for all ARM
r9 is defined as a platform-specific register in the ARM EABI.
It can be reserved for a special purpose or be used as a general
purpose register. Add support for reserving r9 for all ARM, while
leaving the IOS usage unchanged.
Patch by Jeroen Hofstee.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188485 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMSubtarget.cpp')
-rw-r--r-- | lib/Target/ARM/ARMSubtarget.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Target/ARM/ARMSubtarget.cpp b/lib/Target/ARM/ARMSubtarget.cpp index c592421d9a..a94c9425fb 100644 --- a/lib/Target/ARM/ARMSubtarget.cpp +++ b/lib/Target/ARM/ARMSubtarget.cpp @@ -169,9 +169,10 @@ void ARMSubtarget::resetSubtargetFeatures(StringRef CPU, StringRef FS) { if (isAAPCS_ABI()) stackAlignment = 8; - if (!isTargetIOS()) + if (!isTargetIOS()) { UseMovt = hasV6T2Ops(); - else { + IsR9Reserved = ReserveR9; + } else { IsR9Reserved = ReserveR9 | !HasV6Ops; UseMovt = DarwinUseMOVT && hasV6T2Ops(); SupportsTailCall = !getTargetTriple().isOSVersionLT(5, 0); |