summaryrefslogtreecommitdiffstats
path: root/tests/codegen/abi-x86_64_sysv.rs
blob: 84e06023e9c3f48f6311760b5bc43b919883f904 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// only-x86_64

// compile-flags: -C no-prepopulate-passes

#![crate_type = "lib"]

pub struct S24 {
  a: i8,
  b: i8,
  c: i8,
}

pub struct S48 {
  a: i16,
  b: i16,
  c: i8,
}

// CHECK: i24 @struct_24_bits(i24
#[no_mangle]
pub extern "sysv64" fn struct_24_bits(a: S24) -> S24 {
  a
}

// CHECK: i48 @struct_48_bits(i48
#[no_mangle]
pub extern "sysv64" fn struct_48_bits(a: S48) -> S48 {
  a
}