about summary refs log tree commit diff
diff options
context:
space:
mode:
authorJieyou Xu <jieyouxu@outlook.com>2025-04-23 17:04:14 +0800
committerJieyou Xu <jieyouxu@outlook.com>2025-04-23 17:11:49 +0800
commitc79f15687a7eb01bf9eab041fe0401770268cec9 (patch)
treec8169ffd1f78ddcd30ee064f63d4dcbb9bce050f
parente3296cdcab7f0ee21cbc958985005b835cd605c6 (diff)
downloadrust-c79f15687a7eb01bf9eab041fe0401770268cec9.tar.gz
rust-c79f15687a7eb01bf9eab041fe0401770268cec9.zip
tests: account for CFI directives in `tests/assembly/x86-return-float.rs`
-rw-r--r--tests/assembly/x86-return-float.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/assembly/x86-return-float.rs b/tests/assembly/x86-return-float.rs
index 2c39c830684..165c11d2280 100644
--- a/tests/assembly/x86-return-float.rs
+++ b/tests/assembly/x86-return-float.rs
@@ -35,6 +35,7 @@ use minicore::*;
 pub fn return_f32(x: f32) -> f32 {
     // CHECK: movss {{.*}}(%ebp), %xmm0
     // CHECK-NEXT: popl %ebp
+    // linux-NEXT: .cfi_def_cfa
     // CHECK-NEXT: retl
     x
 }
@@ -44,6 +45,7 @@ pub fn return_f32(x: f32) -> f32 {
 pub fn return_f64(x: f64) -> f64 {
     // CHECK: movsd {{.*}}(%ebp), %xmm0
     // CHECK-NEXT: popl %ebp
+    // linux-NEXT: .cfi_def_cfa
     // CHECK-NEXT: retl
     x
 }
@@ -313,9 +315,13 @@ pub unsafe fn call_other_f64(x: &mut (usize, f64)) {
 #[no_mangle]
 pub fn return_f16(x: f16) -> f16 {
     // CHECK: pushl %ebp
+    // linux-NEXT: .cfi_def_cfa_offset
+    // linux-NEXT: .cfi_offset
     // CHECK-NEXT: movl %esp, %ebp
+    // linux-NEXT: .cfi_def_cfa_register
     // CHECK-NEXT: pinsrw $0, 8(%ebp), %xmm0
     // CHECK-NEXT: popl %ebp
+    // linux-NEXT: .cfi_def_cfa
     // CHECK-NEXT: retl
     x
 }
@@ -324,10 +330,14 @@ pub fn return_f16(x: f16) -> f16 {
 #[no_mangle]
 pub fn return_f128(x: f128) -> f128 {
     // CHECK: pushl %ebp
+    // linux-NEXT: .cfi_def_cfa_offset
+    // linux-NEXT: .cfi_offset
     // CHECK-NEXT: movl %esp, %ebp
+    // linux-NEXT: .cfi_def_cfa_register
     // linux-NEXT: movaps 8(%ebp), %xmm0
     // win-NEXT: movups 8(%ebp), %xmm0
     // CHECK-NEXT: popl %ebp
+    // linux-NEXT: .cfi_def_cfa
     // CHECK-NEXT: retl
     x
 }