|
1 |
| -// |
2 |
| -//@ compile-flags: -C no-prepopulate-passes |
3 |
| -//@ only-riscv64 |
4 |
| -//@ only-linux |
| 1 | +//@ compile-flags: -O -C no-prepopulate-passes --target riscv64gc-unknown-linux-gnu |
| 2 | +//@ needs-llvm-components: riscv |
| 3 | + |
| 4 | +#![feature(no_core, lang_items)] |
5 | 5 | #![crate_type = "lib"]
|
| 6 | +#![no_std] |
| 7 | +#![no_core] |
| 8 | + |
| 9 | +#[lang = "sized"] |
| 10 | +trait Sized {} |
| 11 | +#[lang = "freeze"] |
| 12 | +trait Freeze {} |
| 13 | +#[lang = "copy"] |
| 14 | +trait Copy {} |
6 | 15 |
|
7 |
| -// CHECK: define void @f_fpr_tracking(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, i8 zeroext %i) |
| 16 | +// CHECK: define void @f_fpr_tracking(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, i8 noundef zeroext %i) |
8 | 17 | #[no_mangle]
|
9 | 18 | pub extern "C" fn f_fpr_tracking(
|
10 | 19 | a: f64,
|
@@ -144,7 +153,7 @@ pub extern "C" fn f_ret_double_int64_s() -> DoubleInt64 {
|
144 | 153 | DoubleInt64 { f: 1., i: 2 }
|
145 | 154 | }
|
146 | 155 |
|
147 |
| -// CHECK: define void @f_double_int8_s_arg_insufficient_gprs(i32 signext %a, i32 signext %b, i32 signext %c, i32 signext %d, i32 signext %e, i32 signext %f, i32 signext %g, i32 signext %h, [2 x i64] %0) |
| 156 | +// CHECK: define void @f_double_int8_s_arg_insufficient_gprs(i32 noundef signext %a, i32 noundef signext %b, i32 noundef signext %c, i32 noundef signext %d, i32 noundef signext %e, i32 noundef signext %f, i32 noundef signext %g, i32 noundef signext %h, [2 x i64] %0) |
148 | 157 | #[no_mangle]
|
149 | 158 | pub extern "C" fn f_double_int8_s_arg_insufficient_gprs(
|
150 | 159 | a: i32,
|
@@ -250,11 +259,11 @@ pub struct IntDoubleInt {
|
250 | 259 | c: i32,
|
251 | 260 | }
|
252 | 261 |
|
253 |
| -// CHECK: define void @f_int_double_int_s_arg(%IntDoubleInt* {{.*}}%a) |
| 262 | +// CHECK: define void @f_int_double_int_s_arg(ptr {{.*}} %a) |
254 | 263 | #[no_mangle]
|
255 | 264 | pub extern "C" fn f_int_double_int_s_arg(a: IntDoubleInt) {}
|
256 | 265 |
|
257 |
| -// CHECK: define void @f_ret_int_double_int_s(%IntDoubleInt* {{.*}}sret |
| 266 | +// CHECK: define void @f_ret_int_double_int_s(ptr {{.*}} sret([24 x i8]) align 8 dereferenceable(24) %_0) |
258 | 267 | #[no_mangle]
|
259 | 268 | pub extern "C" fn f_ret_int_double_int_s() -> IntDoubleInt {
|
260 | 269 | IntDoubleInt { a: 1, b: 2., c: 3 }
|
|
0 commit comments