aboutsummaryrefslogtreecommitdiff
path: root/fpu/softfloat.c
AgeCommit message (Collapse)Author
2014-11-24softfloat: Clarify license statussf-relicensingPeter Maydell
The code in the softfloat source files is under a mixture of licenses: the original code and many changes from QEMU contributors are under the base SoftFloat-2a license; changes from Stefan Weil and RedHat employees are GPLv2-or-later; changes from Fabrice Bellard are under the BSD license. Clarify this in the comments at the top of each affected source file, including a statement about the assumed licensing for future contributions, so we don't need to remember to ask patch submitters explicitly to pick a license. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-11-24softfloat: Implement uint64_to_float64() and uint64_to_float32()Peter Maydell
Reimplement from scratch the uint64_to_float64() and uint64_to_float32() conversion functions. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-11-24softfloat: Revert remaining portions of commits 75d62a5856 and 3430b0be36fPeter Maydell
Revert the remaining portions of commits 75d62a5856 and 3430b0be36f which are under a SoftFloat-2b license, ie the functions uint64_to_float32() and uint64_to_float64(). (The float64_to_uint64() and float64_to_uint64_round_to_zero() functions were completely rewritten in commits fb3ea83aa and 0a87a3107d so can stay.) Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-11-21softfloat: Apply patch corresponding to rebasing to softfloat-2aPeter Maydell
This commit applies the changes to master which correspond to replacing commit 158142c2c2df with a set of changes made by: * taking the SoftFloat-2a release * mechanically transforming the block comment style * reapplying Fabrice's original changes from 158142c2c2df This commit was created by: diff -u 158142c2c2df import-sf-2a patch -p1 --fuzz 10 <../relicense-patch.txt (where import-sf-2a is the branch resulting from the changes above). Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-10-14softfloat: add functions corresponding to IEEE-2008 min/maxNumMagLeon Alrae
Add abs argument to the existing softfloat minmax() function and define new float{32,64}_{min,max}nummag functions. minnummag(x,y) returns x if |x| < |y|, returns y if |y| < |x|, otherwise minnum(x,y) maxnummag(x,y) returns x if |x| > |y|, returns y if |y| > |x|, otherwise maxnum(x,y) Signed-off-by: Leon Alrae <leon.alrae@imgtec.com> Reviewed-by: Aurelien Jarno <aurelien@aurel32.net>
2014-06-23fpu: softfloat: drop INLINE macroLuiz Capitulino
This commit expands all uses of the INLINE macro and drop it. The reason for this is to avoid clashes with external libraries with bad name conventions and also because renaming keywords is not a good practice. PS: I'm fine with this change to be licensed under softfloat-2a or softfloat-2b. Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2014-04-08softfloat: Introduce float32_to_uint64_round_to_zeroTom Musta
This change adds the float32_to_uint64_round_to_zero function to the softfloat library. This function fills out the complement of float32 to INT round-to-zero conversion rountines, where INT is {int32_t, uint32_t, int64_t, uint64_t}. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta <tommusta@gmail.com> Tested-by: Tom Musta <tommusta@gmail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Alexander Graf <agraf@suse.de>
2014-03-17softfloat: export squash_input_denormal functionsAlex Bennée
I need these available outside of softfloat for some of the reciprocal processing in aarch64 helper functions. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net> Message-id: 1394822294-14837-20-git-send-email-peter.maydell@linaro.org
2014-02-20softfloat: Support halving the result of muladd operationPeter Maydell
The ARMv8 instruction set includes a fused floating point reciprocal square root step instruction which demands an "(x * y + z) / 2" fused operation. Support this by adding a flag to the softfloat muladd operations which requests that the result is halved before rounding. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Add support for ties-away roundingPeter Maydell
IEEE754-2008 specifies a new rounding mode: "roundTiesToAway: the floating-point number nearest to the infinitely precise result shall be delivered; if the two nearest floating-point numbers bracketing an unrepresentable infinitely precise result are equally near, the one with larger magnitude shall be delivered." Implement this new mode (it is needed for ARM). The general principle is that the required code is exactly like the ties-to-even code, except that we do not need to do the "in case of exact tie clear LSB to round-to-even", because the rounding operation naturally causes the exact tie to round up in magnitude. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Refactor code handling various rounding modesPeter Maydell
Refactor the code in various functions which calculates rounding increments given the current rounding mode, so that instead of a set of nested if statements we have a simple switch statement. This will give us a clean place to add the case for the new tiesAway rounding mode. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Add float16 <=> float64 conversion functionsPeter Maydell
Add the conversion functions float16_to_float64() and float64_to_float16(), which will be needed for the ARM A64 instruction set. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Factor out RoundAndPackFloat16 and NormalizeFloat16SubnormalPeter Maydell
In preparation for adding conversions between float16 and float64, factor out code currently done inline in the float16<=>float32 conversion functions into functions RoundAndPackFloat16 and NormalizeFloat16Subnormal along the lines of the existing versions for the other float types. Note that we change the handling of zExp from the inline code to match the API of the other RoundAndPackFloat functions; however we leave the positioning of the binary point between bits 22 and 23 rather than shifting it up to the high end of the word. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Provide complete set of accessors for fp statePeter Maydell
Tidy up the get/set accessors for the fp state to add missing ones and make them all inline in softfloat.h rather than some inline and some not. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Fix float64_to_uint32_round_to_zeroTom Musta
The float64_to_uint32_round_to_zero routine is incorrect. For example, the following test pattern: 425F81378DC0CD1F / 0x1.f81378dc0cd1fp+38 will erroneously set the inexact flag. This patch re-implements the routine to use the float64_to_uint64_round_to_zero routine. If saturation occurs we ignore any flags set by the conversion function and raise only Invalid. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta <tommusta@gmail.com> Message-id: 1387397961-4894-6-git-send-email-tommusta@gmail.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Fix float64_to_uint32Tom Musta
The float64_to_uint32 has several flaws: - for numbers between 2**32 and 2**64, the inexact exception flag may get incorrectly set. In this case, only the invalid flag should be set. test pattern: 425F81378DC0CD1F / 0x1.f81378dc0cd1fp+38 - for numbers between 2**63 and 2**64, incorrect results may be produced: test pattern: 43EAAF73F1F0B8BD / 0x1.aaf73f1f0b8bdp+63 This patch re-implements float64_to_uint32 to re-use the float64_to_uint64 routine (instead of float64_to_int64). For the saturation case, we ignore any flags which the conversion routine has set and raise only the invalid flag. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta <tommusta@gmail.com> Message-id: 1387397961-4894-5-git-send-email-tommusta@gmail.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Fix float64_to_uint64_round_to_zeroTom Musta
The float64_to_uint64_round_to_zero routine is incorrect. For example, the following test pattern: 46697351FF4AEC29 / 0x1.97351ff4aec29p+103 currently produces 8000000000000000 instead of FFFFFFFFFFFFFFFF. This patch re-implements the routine to temporarily force the rounding mode and use the float64_to_uint64 routine. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta <tommusta@gmail.com> Message-id: 1387397961-4894-4-git-send-email-tommusta@gmail.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Add float32_to_uint64()Tom Musta
This patch adds the float32_to_uint64() routine, which converts a 32-bit floating point number to an unsigned 64 bit number. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta <tommusta@gmail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> [PMM: removed harmless but silly int64_t casts] Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Fix factor 2 error for scalbn on denormal inputsPeter Maydell
If the input to float*_scalbn() is denormal then it represents a number 0.[mantissabits] * 2^(1-exponentbias) (and the actual exponent field is all zeroes). This means that when we convert it to our unpacked encoding the unpacked exponent must be one greater than for a normal number, which represents 1.[mantissabits] * 2^(e-exponentbias) for an exponent field e. This meant we were giving answers too small by a factor of 2 for all denormal inputs. Note that the float-to-int routines also have this behaviour of not adjusting the exponent for denormals; however there it is harmless because denormals will all convert to integer zero anyway. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Aurelien Jarno <aurelien@aurel32.net> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Only raise Invalid when conversions to int are out of rangePeter Maydell
We implement a number of float-to-integer conversions using conversion to an integer type with a wider range and then a check against the narrower range we are actually converting to. If we find the result to be out of range we correctly raise the Invalid exception, but we must also suppress other exceptions which might have been raised by the conversion function we called. This won't throw away exceptions we should have preserved, because for the 'core' exception flags the IEEE spec mandates that the only valid combinations of exception that can be raised by a single operation are Inexact + Overflow and Inexact + Underflow. For the non-IEEE softfloat flag for input denormals, we can guarantee that that flag won't have been set for out of range float-to-int conversions because a squashed denormal by definition goes to plus or minus zero, which is always in range after conversion to integer zero. This bug has been fixed for some of the float-to-int conversion routines by previous patches; fix it for the remaining functions as well, so that they all restore the pre-conversion status flags prior to raising Invalid. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Aurelien Jarno <aurelien@aurel32.net> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Fix float64_to_uint64Tom Musta
The comment preceding the float64_to_uint64 routine suggests that the implementation is broken. And this is, indeed, the case. This patch properly implements the conversion of a 64-bit floating point number to an unsigned, 64 bit integer. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta <tommusta@gmail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Make the int-to-float functions take exact-width typesPeter Maydell
Currently the int-to-float functions take types which are specified as "at least X bits wide", rather than "exactly X bits wide". This is confusing and unhelpful since it means that the callers have to include an explicit cast to [u]intXX_t to ensure the correct behaviour. Fix them all to take the exactly-X-bits-wide types instead. Note that this doesn't change behaviour at all since at the moment we happen to define the 'int32' and 'uint32' types as exactly 32 bits wide, and the 'int64' and 'uint64' types as exactly 64 bits wide. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Add float to 16bit integer conversions.Will Newton
ARMv8 requires support for converting 32 and 64bit floating point values to signed and unsigned 16bit integers. Signed-off-by: Will Newton <will.newton@linaro.org> [PMM: updated not to incorrectly set Inexact for Invalid inputs] Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2014-01-08softfloat: Fix exception flag handling for float32_to_float16()Peter Maydell
Our float32 to float16 conversion routine was generating the correct numerical answers, but not always setting the right set of exception flags. Fix this, mostly by rearranging the code to more closely resemble RoundAndPackFloat*, and in particular: * non-IEEE halfprec always raises Invalid for input NaNs * we need to check for the overflow case before underflow * we weren't getting the tininess-detected-after-rounding case correct (somewhat academic since only ARM uses halfprec and it is always tininess-detected-before-rounding) * non-IEEE halfprec overflow raises only Invalid, not Invalid + Inexact * we weren't setting Inexact when we should Also add some clarifying comments about what the code is doing. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net>
2013-12-10softfloat: Add minNum() and maxNum() functions to softfloat.Will Newton
Add floatnn_minnum() and floatnn_maxnum() functions which are equivalent to the minNum() and maxNum() functions from IEEE 754-2008. They are similar to min() and max() but differ in the handling of QNaN arguments. Signed-off-by: Will Newton <will.newton@linaro.org> Message-id: 1386158099-9239-5-git-send-email-will.newton@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2013-12-10softfloat: Remove unused argument from MINMAX macro.Will Newton
The nan_exp argument is not used, so remove it. Signed-off-by: Will Newton <will.newton@linaro.org> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1386158099-9239-4-git-send-email-will.newton@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2013-04-15fpu: Correct edgecase in float64_muladdPeter Maydell
In handling float64_muladd, if we end up doing a subtraction of the product and c, and the 128 bit result of this subtraction happens to have its most significant bit in bit 63, we weren't handling this correctly when attempting to normalize to put the most significant bit into bit 126. We would end up doing a right shift by a negative number (undefined behaviour in C) so at best we would return an incorrect result to the guest. MSB in bit 63 has to be handled as a special case separately from MSB in 0..62 and MSB in 63..126. (MSB in 127 is not possible.) Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Aurelien Jarno <aurelien@aurel32.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2013-01-26softfloat: Handle float_muladd_negate_c when product is zeroRichard Sandiford
Honour float_muladd_negate_c in the case where the product is zero and c is nonzero. Previously we would fail to negate c. Seen in (and tested against) the gfortran testsuite on MIPS. Signed-off-by: Richard Sandiford <rdsandiford@googlemail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2013-01-05softfloat: Implement uint64_to_float128Richard Henderson
Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2013-01-05softfloat: Fix uint64_to_float64Richard Henderson
The interface to normalizeRoundAndPackFloat64 requires that the high bit be clear. Perform one shift-right-and-jam if needed. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2012-12-19fpu: move public header file to include/fpuPaolo Bonzini
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2012-10-01fpu/softfloat.c: Return correctly signed values from uint64_to_float32Peter Maydell
The uint64_to_float32() conversion function was incorrectly always returning numbers with the sign bit set (ie negative numbers). Correct this so we return positive numbers instead. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2012-10-01fpu/softfloat.c: Remove pointless shift of always-zero valuePeter Maydell
In float16_to_float32, when returning an infinity, just pass zero as the mantissa argument to packFloat32(), rather than shifting a value which we know must be zero. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2012-04-28softfloat: Replace int16 type with int_fast16_tAndreas Färber
Based on the following Coccinelle patch: @@ typedef int16, int_fast16_t; @@ -int16 +int_fast16_t Avoids a workaround for AIX. Add typedef for pre-10 Solaris. Signed-off-by: Andreas Färber <afaerber@suse.de> Cc: malc <av1474@comtv.ru> Cc: Ben Taylor <bentaylor.solx86@gmail.com> Tested-by: Bernhard Walle <bernhard@bwalle.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2012-04-28softfloat: Replace uint16 type with uint_fast16_tAndreas Färber
Based on the following Coccinelle patch: @@ typedef uint16, uint_fast16_t; @@ -uint16 +uint_fast16_t Fixes the build of the Cocoa frontend on Mac OS X and avoids a workaround for AIX. For pre-10 Solaris include osdep.h. Reported-by: Pavel Borzenkov <pavel.borzenkov@gmail.com> Reported-by: Rui Carmo <rui.carmo@gmail.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Cc: Juan Pineda <juan@logician.com> Cc: malc <av1474@comtv.ru> Cc: Ben Taylor <bentaylor.solx86@gmail.com> Tested-by: Bernhard Walle <bernhard@bwalle.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2012-04-28softfloat: Fix mixups of int and int16Andreas Färber
normalizeFloat{32,64}Subnormal() expect the exponent as int16, not int. This went unnoticed since int16 and uint16 were both typedef'ed to int. Signed-off-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Bernhard Walle <bernhard@bwalle.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2012-04-21softfloat: make USE_SOFTFLOAT_STRUCT_TYPES compileJuan Quintela
This change makes it compile and return the same value than the #undef one. Signed-off-by: Juan Quintela <quintela@redhat.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Acked-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2012-04-07softfloat: roundAndPackInt{32, 64}: Don't assume int32 is 32 bitsPeter Maydell
Fix code in roundAndPackInt32 that assumed that int32 was only 32 bits, by simply using int32_t instead. Fix the parallel bug in roundAndPackInt64 as well, although that one is only theoretical since it's unlikely that int64 will ever be more than 64 bits. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2012-04-07softfloat: float*_to_int32_round_to_zero: don't assume int32 is 32 bitsPeter Maydell
Code in the float64_to_int32_round_to_zero() function was assuming that int32 would not be wider than 32 bits; this meant it might not correctly detect the overflow case. We take the simple approach of using int32_t. Also fix equivalent issues in the functions for other float sizes. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2011-10-19softfloat: Implement fused multiply-addPeter Maydell
Implement fused multiply-add as a softfloat primitive. This implements "a+b*c" as a single step without any intermediate rounding; it is specified in IEEE 754-2008 and implemented in a number of CPUs. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2011-10-01softfloat: Reinstate accidentally disabled target-specific NaN handlingPeter Maydell
Include config.h in softfloat.c, so that the target specific ifdefs in softfloat-specialize.h are evaluated correctly. This was accidentally broken in commit 789ec7ce2 when config-target.h was removed from softfloat.h, and means that most targets will have been returning the wrong results for calculations involving NaNs. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2011-09-03softfloat: Use uint32 consistentlyAndreas Färber
Prepares for uint32 replacement. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2011-09-03softfloat: Use uint16 consistentlyAndreas Färber
Prepares for uint16 replacement. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2011-06-03softfloat: always enable floatx80 and float128 supportAurelien Jarno
Now that softfloat-native is gone, there is no real point on not always enabling floatx80 and float128 support. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2011-05-23softfloat: Add new flag for when denormal result is flushed to zeroPeter Maydell
Add a new float_flag_output_denormal which is set when the result of a floating point operation would be denormal but is flushed to zero because we are in flush_to_zero mode. This is necessary because some architectures signal this condition as an underflow and others signal it as an inexact result. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2011-04-25softfloat: fix float*_scalnb() corner casesAurelien Jarno
float*_scalnb() were not taking into account all cases. This patch fixes some corner cases: - NaN values in input were not properly propagated and the invalid flag not correctly raised. Use propagateFloat*NaN() for that. - NaN or infinite values in input of floatx80_scalnb() were not correctly detected due to a typo. - The sum of exponent and n could overflow, leading to strange results. Additionally having int16 defined to int make that happening for a very small range of values. Fix that by saturating n to the maximum exponent range, and using an explicit wider type if needed. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2011-04-25softfloat: add floatx80_compare*() functionsAurelien Jarno
Add floatx80_compare() and floatx80_compare_quiet() functions to match the softfloat-native ones. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2011-04-17softfloat: improve description of comparison functionsAurelien Jarno
Make clear for all comparison functions which ones trigger an exception for all NaNs, and which one only for sNaNs. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2011-04-17softfloat: move float*_eq and float*_eq_quietAurelien Jarno
I am not a big fan of code moving, but having the signaling version in the middle of quiet versions and vice versa doesn't make the code easy to read. This patch is a simple code move, basically swapping locations of float*_eq and float*_eq_quiet. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2011-04-17softfloat: rename float*_eq_signaling() into float*_eq()Aurelien Jarno
float*_eq_signaling functions have a different semantics than other comparison functions. Fix that by renaming float*_quiet_signaling() into float*_eq(). Note that it is purely mechanical, and the behaviour should be unchanged. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>