summaryrefslogtreecommitdiff
path: root/lib/Target/X86/X86RegisterInfo.td
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2012-01-26 22:59:28 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2012-01-26 22:59:28 +0000
commit53fa56e8dc60c8b594f22b888b4fb3c3b0567d82 (patch)
tree952e37054fb68acdc1139a842e316a015bbf35c9 /lib/Target/X86/X86RegisterInfo.td
parentf26475af976389839c4affdcd2b5ef07ba548a81 (diff)
downloadllvm-53fa56e8dc60c8b594f22b888b4fb3c3b0567d82.tar.gz
llvm-53fa56e8dc60c8b594f22b888b4fb3c3b0567d82.tar.bz2
llvm-53fa56e8dc60c8b594f22b888b4fb3c3b0567d82.tar.xz
Handle call-clobbered ymm registers on Win64.
The Win64 calling convention has xmm6-15 as callee-saved while still clobbering all ymm registers. Add a YMM_HI_6_15 pseudo-register that aliases the clobbered part of the ymm registers, and mark that as call-clobbered. This allows live xmm registers across calls. This hack wouldn't be necessary with RegisterMask operands representing the call clobbers, but they are not quite operational yet. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149088 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86/X86RegisterInfo.td')
-rw-r--r--lib/Target/X86/X86RegisterInfo.td7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/Target/X86/X86RegisterInfo.td b/lib/Target/X86/X86RegisterInfo.td
index 5263a4934c..d98eea3e37 100644
--- a/lib/Target/X86/X86RegisterInfo.td
+++ b/lib/Target/X86/X86RegisterInfo.td
@@ -206,6 +206,13 @@ let Namespace = "X86" in {
def YMM15: RegisterWithSubRegs<"ymm15", [XMM15]>, DwarfRegAlias<XMM15>;
}
+ // Pseudo-register that aliases the high part of ymm6-ymm15 that is clobbered
+ // by win64 calls. Doesn't alias the callee-saved xmm6-xmm15.
+ def YMM_HI_6_15 : Register<"ymmhi-6-15"> {
+ let Aliases = [YMM6, YMM7, YMM8, YMM9, YMM10, YMM11, YMM12, YMM13, YMM14,
+ YMM15];
+ }
+
class STRegister<string Name, list<Register> A> : Register<Name> {
let Aliases = A;
}