diff options
author | Aurelien Jarno <aurelien@aurel32.net> | 2015-05-25 01:47:26 +0200 |
---|---|---|
committer | Alexander Graf <agraf@suse.de> | 2015-06-05 01:37:58 +0200 |
commit | 4a33565f9f46145d8cc701ab623b18bf423c469e (patch) | |
tree | 81be77e7fd25e24d8cef47fa6d060efea24c3864 /target-s390x | |
parent | f821135cdd4df09b1362666ddfbdfd162b905b1f (diff) | |
download | qemu-4a33565f9f46145d8cc701ab623b18bf423c469e.zip qemu-4a33565f9f46145d8cc701ab623b18bf423c469e.tar.gz qemu-4a33565f9f46145d8cc701ab623b18bf423c469e.tar.bz2 |
target-s390x: detect tininess before rounding for FP operations
The s390x floating point unit detects tininess before rounding, so set
the softfloat fp_status up appropriately.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'target-s390x')
-rw-r--r-- | target-s390x/cpu.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/target-s390x/cpu.c b/target-s390x/cpu.c index d2f9836..7f17823 100644 --- a/target-s390x/cpu.c +++ b/target-s390x/cpu.c @@ -118,6 +118,10 @@ static void s390_cpu_initial_reset(CPUState *s) env->pfault_token = -1UL; + /* tininess for underflow is detected before rounding */ + set_float_detect_tininess(float_tininess_before_rounding, + &env->fpu_status); + /* Reset state inside the kernel that we cannot access yet from QEMU. */ if (kvm_enabled()) { kvm_s390_reset_vcpu(cpu); @@ -143,6 +147,10 @@ static void s390_cpu_full_reset(CPUState *s) env->pfault_token = -1UL; + /* tininess for underflow is detected before rounding */ + set_float_detect_tininess(float_tininess_before_rounding, + &env->fpu_status); + /* Reset state inside the kernel that we cannot access yet from QEMU. */ if (kvm_enabled()) { kvm_s390_reset_vcpu(cpu); |