From 7f8c11d5715dad01dffd26de3b5f6d028417373a Mon Sep 17 00:00:00 2001 From: Scott Bambrough Date: Thu, 11 May 2000 18:16:37 +0000 Subject: [PATCH] sysv.S (ffi_call_SYSV): Doubles are not saved to memory correctly. 2000-05-11 Scott Bambrough * libffi/src/arm/sysv.S (ffi_call_SYSV): Doubles are not saved to memory correctly. Use conditional instructions, not branches where possible. From-SVN: r33852 --- libffi/ChangeLog | 6 ++++++ libffi/src/arm/sysv.S | 16 +++++----------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/libffi/ChangeLog b/libffi/ChangeLog index 9d08899e6d33..89ea007c11db 100644 --- a/libffi/ChangeLog +++ b/libffi/ChangeLog @@ -1,3 +1,9 @@ +2000-05-11 Scott Bambrough + + * libffi/src/arm/sysv.S (ffi_call_SYSV): Doubles are not saved to + memory correctly. Use conditional instructions, not branches where + possible. + 2000-05-04 Tom Tromey * configure: Rebuilt. diff --git a/libffi/src/arm/sysv.S b/libffi/src/arm/sysv.S index 14230c4b25fe..874b80a24ae3 100644 --- a/libffi/src/arm/sysv.S +++ b/libffi/src/arm/sysv.S @@ -97,19 +97,13 @@ ENTRY(ffi_call_SYSV) beq epilogue # return FLOAT - cmp a4, #FFI_TYPE_FLOAT - bne retdouble - stfs f0, [a3] - b epilogue + cmp a4, #FFI_TYPE_FLOAT + stfeqs f0, [a3] + beq epilogue # return DOUBLE or LONGDOUBLE -retdouble: - cmp a4, #FFI_TYPE_DOUBLE - bne epilogue - - stfs f0, [a3, #0] - stfs f1, [a3, #4] - b epilogue + cmp a4, #FFI_TYPE_DOUBLE + stfeqd f0, [a3] epilogue: ldmfd sp!, {a1-a4, fp, pc}