Rename CallConv::Native to CallConv::SystemV. (#291)
To keep cross-compiling straightforward, Cretonne shouldn't have any behavior that depends on the host. This renames the "Native" calling convention to "SystemV", which has a defined meaning for each target, so that it's clear that the calling convention doesn't change depending on what host Cretonne is running on.
This commit is contained in:
@@ -2,7 +2,7 @@ test compile
|
||||
set is_64bit=1
|
||||
isa intel haswell
|
||||
|
||||
function %foo(i64, i64, i64, i32) -> b1 native {
|
||||
function %foo(i64, i64, i64, i32) -> b1 system_v {
|
||||
ebb3(v0: i64, v1: i64, v2: i64, v3: i32):
|
||||
v5 = icmp ne v2, v2
|
||||
v8 = iconst.i64 0
|
||||
|
||||
@@ -5,14 +5,14 @@ isa intel
|
||||
; regex: V=v\d+
|
||||
|
||||
function %f() {
|
||||
sig0 = (i32) -> i32 native
|
||||
; check: sig0 = (i32 [0]) -> i32 [%rax] native
|
||||
sig0 = (i32) -> i32 system_v
|
||||
; check: sig0 = (i32 [0]) -> i32 [%rax] system_v
|
||||
|
||||
sig1 = (i64) -> b1 native
|
||||
; check: sig1 = (i32 [0], i32 [4]) -> b1 [%rax] native
|
||||
sig1 = (i64) -> b1 system_v
|
||||
; check: sig1 = (i32 [0], i32 [4]) -> b1 [%rax] system_v
|
||||
|
||||
sig2 = (f32, i64) -> f64 native
|
||||
; check: sig2 = (f32 [0], i32 [4], i32 [8]) -> f64 [%xmm0] native
|
||||
sig2 = (f32, i64) -> f64 system_v
|
||||
; check: sig2 = (f32 [0], i32 [4], i32 [8]) -> f64 [%xmm0] system_v
|
||||
|
||||
ebb0:
|
||||
return
|
||||
|
||||
@@ -6,14 +6,14 @@ isa intel
|
||||
; regex: V=v\d+
|
||||
|
||||
function %f() {
|
||||
sig0 = (i32) -> i32 native
|
||||
; check: sig0 = (i32 [%rdi]) -> i32 [%rax] native
|
||||
sig0 = (i32) -> i32 system_v
|
||||
; check: sig0 = (i32 [%rdi]) -> i32 [%rax] system_v
|
||||
|
||||
sig1 = (i64) -> b1 native
|
||||
; check: sig1 = (i64 [%rdi]) -> b1 [%rax] native
|
||||
sig1 = (i64) -> b1 system_v
|
||||
; check: sig1 = (i64 [%rdi]) -> b1 [%rax] system_v
|
||||
|
||||
sig2 = (f32, i64) -> f64 native
|
||||
; check: sig2 = (f32 [%xmm0], i64 [%rdi]) -> f64 [%xmm0] native
|
||||
sig2 = (f32, i64) -> f64 system_v
|
||||
; check: sig2 = (f32 [%xmm0], i64 [%rdi]) -> f64 [%xmm0] system_v
|
||||
|
||||
ebb0:
|
||||
return
|
||||
|
||||
@@ -9,7 +9,7 @@ ebb0(v0: f32):
|
||||
v1 = floor v0
|
||||
return v1
|
||||
}
|
||||
; check: function %floor(f32 [%xmm0]) -> f32 [%xmm0] native {
|
||||
; check: sig0 = (f32) -> f32 native
|
||||
; check: function %floor(f32 [%xmm0]) -> f32 [%xmm0] system_v {
|
||||
; check: sig0 = (f32) -> f32 system_v
|
||||
; check: fn0 = sig0 %FloorF32
|
||||
; check: v1 = call fn0(v0)
|
||||
|
||||
@@ -9,7 +9,7 @@ ebb0:
|
||||
return
|
||||
}
|
||||
|
||||
; check: function %foo(i64 fp [%rbp], i64 csr [%rbx], i64 csr [%r12], i64 csr [%r13], i64 csr [%r14], i64 csr [%r15]) -> i64 fp [%rbp], i64 csr [%rbx], i64 csr [%r12], i64 csr [%r13], i64 csr [%r14], i64 csr [%r15] native {
|
||||
; check: function %foo(i64 fp [%rbp], i64 csr [%rbx], i64 csr [%r12], i64 csr [%r13], i64 csr [%r14], i64 csr [%r15]) -> i64 fp [%rbp], i64 csr [%rbx], i64 csr [%r12], i64 csr [%r13], i64 csr [%r14], i64 csr [%r15] system_v {
|
||||
; nextln: ss0 = explicit_slot 168, offset -224
|
||||
; nextln: ss1 = incoming_arg 56, offset -56
|
||||
; check: ebb0(v0: i64 [%rbp], v1: i64 [%rbx], v2: i64 [%r12], v3: i64 [%r13], v4: i64 [%r14], v5: i64 [%r15]):
|
||||
|
||||
Reference in New Issue
Block a user