[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 7/7] target-s390: Use float128_to_uint[64/32] where
From: |
Bharata B Rao |
Subject: |
[Qemu-devel] [PATCH 7/7] target-s390: Use float128_to_uint[64/32] where required |
Date: |
Fri, 10 Feb 2017 12:53:11 +0530 |
Use float126_to_uint[64/32] instead of using int versions of the same.
Signed-off-by: Bharata B Rao <address@hidden>
CC: Christian Borntraeger <address@hidden>
CC: Cornelia Huck <address@hidden>
---
target/s390x/fpu_helper.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/target/s390x/fpu_helper.c b/target/s390x/fpu_helper.c
index e604e9f..9aa94d9 100644
--- a/target/s390x/fpu_helper.c
+++ b/target/s390x/fpu_helper.c
@@ -515,8 +515,7 @@ uint64_t HELPER(clgxb)(CPUS390XState *env, uint64_t h,
uint64_t l, uint32_t m3)
{
int hold = swap_round_mode(env, m3);
float128 v2 = make_float128(h, l);
- /* ??? Not 100% correct. */
- uint64_t ret = float128_to_int64(v2, &env->fpu_status);
+ uint64_t ret = float128_to_uint64(v2, &env->fpu_status);
set_float_rounding_mode(hold, &env->fpu_status);
handle_exceptions(env, GETPC());
return ret;
@@ -547,8 +546,7 @@ uint64_t HELPER(clfxb)(CPUS390XState *env, uint64_t h,
uint64_t l, uint32_t m3)
{
int hold = swap_round_mode(env, m3);
float128 v2 = make_float128(h, l);
- /* Not 100% correct. */
- uint32_t ret = float128_to_int64(v2, &env->fpu_status);
+ uint32_t ret = float128_to_uint32(v2, &env->fpu_status);
set_float_rounding_mode(hold, &env->fpu_status);
handle_exceptions(env, GETPC());
return ret;
--
2.7.4
- [Qemu-devel] [PATCH 0/7] POWER9 TCG and softfloat enablements - part16 + s390 float fixes, Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 1/7] softfloat: Add round-to-odd rounding mode, Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 2/7] softfloat: Add float128_to_uint64_round_to_zero(), Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 3/7] softfloat: Add float128_to_uint32_round_to_zero(), Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 4/7] target-ppc: Implement round to odd variants of quad FP instructions, Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 5/7] target-ppc: Add xscvqpudz and xscvqpuwz instructions, Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 6/7] softfloat: Add float128_to_uint32(), Bharata B Rao, 2017/02/10
- [Qemu-devel] [PATCH 7/7] target-s390: Use float128_to_uint[64/32] where required,
Bharata B Rao <=
- Re: [Qemu-devel] [PATCH 0/7] POWER9 TCG and softfloat enablements - part16 + s390 float fixes, David Gibson, 2017/02/12
- Re: [Qemu-devel] [PATCH 0/7] POWER9 TCG and softfloat enablements - part16 + s390 float fixes, David Gibson, 2017/02/12