diff options
| author | bors <bors@rust-lang.org> | 2024-07-16 13:38:39 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-07-16 13:38:39 +0000 |
| commit | 216bef36bccb67bcc4c0a4d7940f6dc84c4fac7b (patch) | |
| tree | 11e65227b6348995609411f581e100f97e9475b6 /tests/codegen/float | |
| parent | e5b1a2b3cd1e3a53b939e81a3eef1f4da924eb0f (diff) | |
| parent | 137c736d667dd500ddac47450df21ae9be345ba0 (diff) | |
| download | rust-216bef36bccb67bcc4c0a4d7940f6dc84c4fac7b.tar.gz rust-216bef36bccb67bcc4c0a4d7940f6dc84c4fac7b.zip | |
Auto merge of #17609 - lnicola:sync-from-rust, r=lnicola
minor: Sync from downstream
Diffstat (limited to 'tests/codegen/float')
| -rw-r--r-- | tests/codegen/float/f128.rs | 11 | ||||
| -rw-r--r-- | tests/codegen/float/f16.rs | 11 |
2 files changed, 18 insertions, 4 deletions
diff --git a/tests/codegen/float/f128.rs b/tests/codegen/float/f128.rs index 32c5be1ec65..80b572fbbc9 100644 --- a/tests/codegen/float/f128.rs +++ b/tests/codegen/float/f128.rs @@ -1,3 +1,8 @@ +// 32-bit x86 returns `f32` and `f64` differently to avoid the x87 stack. +//@ revisions: x86 other +//@[x86] only-x86 +//@[other] ignore-x86 + // Verify that our intrinsics generate the correct LLVM calls for f128 #![crate_type = "lib"] @@ -138,14 +143,16 @@ pub fn f128_as_f16(a: f128) -> f16 { a as f16 } -// CHECK-LABEL: float @f128_as_f32( +// other-LABEL: float @f128_as_f32( +// x86-LABEL: i32 @f128_as_f32( #[no_mangle] pub fn f128_as_f32(a: f128) -> f32 { // CHECK: fptrunc fp128 %{{.+}} to float a as f32 } -// CHECK-LABEL: double @f128_as_f64( +// other-LABEL: double @f128_as_f64( +// x86-LABEL: void @f128_as_f64( #[no_mangle] pub fn f128_as_f64(a: f128) -> f64 { // CHECK: fptrunc fp128 %{{.+}} to double diff --git a/tests/codegen/float/f16.rs b/tests/codegen/float/f16.rs index 96daac869c2..2910d7d3e92 100644 --- a/tests/codegen/float/f16.rs +++ b/tests/codegen/float/f16.rs @@ -1,3 +1,8 @@ +// 32-bit x86 returns `f32` and `f64` differently to avoid the x87 stack. +//@ revisions: x86 other +//@[x86] only-x86 +//@[other] ignore-x86 + // Verify that our intrinsics generate the correct LLVM calls for f16 #![crate_type = "lib"] @@ -140,14 +145,16 @@ pub fn f16_as_self(a: f16) -> f16 { a as f16 } -// CHECK-LABEL: float @f16_as_f32( +// other-LABEL: float @f16_as_f32( +// x86-LABEL: i32 @f16_as_f32( #[no_mangle] pub fn f16_as_f32(a: f16) -> f32 { // CHECK: fpext half %{{.+}} to float a as f32 } -// CHECK-LABEL: double @f16_as_f64( +// other-LABEL: double @f16_as_f64( +// x86-LABEL: void @f16_as_f64( #[no_mangle] pub fn f16_as_f64(a: f16) -> f64 { // CHECK: fpext half %{{.+}} to double |
