diff options
author | Chris Lattner <sabre@nondot.org> | 2008-03-17 06:58:37 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-03-17 06:58:37 +0000 |
commit | 7d4152bda6ee55be2699f7f7072b2f4ab3c66ac3 (patch) | |
tree | 7e114bf71cb09c776a3e21544300496703fa96bc /llvm/lib/Target/Sparc/SparcCallingConv.td | |
parent | 52f16deb6574c30b2a4d2b22de57c75e06804bfe (diff) | |
download | bcm5719-llvm-7d4152bda6ee55be2699f7f7072b2f4ab3c66ac3.tar.gz bcm5719-llvm-7d4152bda6ee55be2699f7f7072b2f4ab3c66ac3.zip |
Check in some #ifdef'd out code switching call argument
lowering over to SparcCallingConv.td. We can't make the switch
yet because we can't say to pass f64 registers in 2 x i32 registers
with the td file yet.
llvm-svn: 48449
Diffstat (limited to 'llvm/lib/Target/Sparc/SparcCallingConv.td')
-rw-r--r-- | llvm/lib/Target/Sparc/SparcCallingConv.td | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/lib/Target/Sparc/SparcCallingConv.td b/llvm/lib/Target/Sparc/SparcCallingConv.td index 02d24397e6d..dc0bf8e3122 100644 --- a/llvm/lib/Target/Sparc/SparcCallingConv.td +++ b/llvm/lib/Target/Sparc/SparcCallingConv.td @@ -21,3 +21,12 @@ def RetCC_Sparc32 : CallingConv<[ CCIfType<[f32], CCAssignToReg<[F0]>>, CCIfType<[f64], CCAssignToReg<[D0]>> ]>; + +// Sparc 32-bit C Calling convention. +def CC_Sparc32 : CallingConv<[ + // All arguments get passed in integer registers if there is space. + CCIfType<[i32, f32, f64], CCAssignToReg<[I0, I1, I2, I3, I4, I5]>>, + + // Alternatively, they are assigned to the stack in 4-byte aligned units. + CCAssignToStack<4, 4> +]>; |