summaryrefslogtreecommitdiffstats
path: root/target-alpha/fpu_helper.c
Commit message (Collapse)AuthorAgeFilesLines
* target-alpha: Raise IOV from CVTQLRichard Henderson2015-05-181-2/+6
| | | | | | | | | Even if an exception isn't taken, the status flags need updating and the result should be written to the destination. Move the body of cvtql out of line, since we now always need a call. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Suppress underflow from CVTTQ if DNZRichard Henderson2015-05-181-1/+1
| | | | | | | I.e. respect flush_inputs_to_zero. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Raise EXC_M_INV properly for fp inputsRichard Henderson2015-05-181-10/+22
| | | | | | | | Ignore DNZ if software completion isn't used. Raise INV for denormals in system mode so the OS completion handler sees them. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Fix cvttq vs infRichard Henderson2015-05-181-1/+1
| | | | | | | We should raise INV for infinities as well, not OVR+INE. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Fix cvttq vs large integersRichard Henderson2015-05-181-5/+5
| | | | | | | | The range +- 2**63 - 2**64 was returning the wrong truncated result. We also incorrectly signaled overflow for -2**63. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Raise IOV from CVTTQRichard Henderson2015-05-181-16/+9
| | | | | | | Floating-point overflow is a different bit from integer overflow. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Set EXC_M_SWC for exceptions from /S insnsRichard Henderson2015-05-181-5/+3
| | | | | | | | Previously forgotten, the kernel needs the software completion bit to know that it needs to emulate software completion qualified insns. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Set fpcr_exc_status even for disabled exceptionsRichard Henderson2015-05-181-14/+21
| | | | | | | | The qualifiers can suppress the raising of exceptions, but real hardware still records that the exceptions occurred. Reported-by: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Tidy FPCR representationRichard Henderson2015-05-181-47/+83
| | | | | | | Store the fpcr as the hardware represents it. Convert the softfpu representation of exceptions into the fpcr representation. Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Rename floating-point subroutinesRichard Henderson2015-05-181-1/+1
| | | | | | ... to match the instructions, which have no leading "f". Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Move VAX helpers to a new fileRichard Henderson2015-05-181-328/+0
| | | | | | Keep the IEEE and VAX floating point emulation separate. Signed-off-by: Richard Henderson <rth@twiddle.net>
* tcg: Invert the inclusion of helper.hRichard Henderson2014-05-281-1/+1
| | | | | | | | | | Rather than include helper.h with N values of GEN_HELPER, include a secondary file that sets up the macros to include helper.h. This minimizes the files that must be rebuilt when changing the macros for file N. Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Richard Henderson <rth@twiddle.net>
* target-alpha: Convert gen_fcvtlq/ql to source/sinkRichard Henderson2014-04-171-0/+7
| | | | Signed-off-by: Richard Henderson <rth@twiddle.net>
* fpu: move public header file to include/fpuPaolo Bonzini2012-12-191-1/+1
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* Use uintptr_t for various op related functionsBlue Swirl2012-04-141-3/+3
| | | | | | | | | Use uintptr_t instead of void * or unsigned long in several op related functions, env->mem_io_pc and GETPC() macro. Reviewed-by: Stefan Weil <sw@weilnetz.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* target-alpha: Make use of fp_status.flush_inputs_to_zero.Richard Henderson2012-03-241-34/+10
| | | | | | | | | This softfp feature post-dates the last major update to the Alpha fpu translation. We can make use of this to eliminate at least one helper function that was performing this operation by hand. Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* target-alpha: Move floating-point helpers to fpu_helper.c.Richard Henderson2012-03-241-0/+846
Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
OpenPOWER on IntegriCloud