qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] target/i386: fxtract, fscale fixes
@ 2020-05-07  0:42 Joseph Myers
  2020-05-07  0:43 ` [PATCH 1/5] target/i386: implement special cases for fxtract Joseph Myers
                   ` (8 more replies)
  0 siblings, 9 replies; 17+ messages in thread
From: Joseph Myers @ 2020-05-07  0:42 UTC (permalink / raw)
  To: qemu-devel, pbonzini, rth, ehabkost

Among the various bugs in the x87 floating-point emulation that show
up through a combination of glibc testing and code inspection, there
are several in the implementations of the fxtract and fscale
instructions.  This series fixes those bugs.

Bugs in other instructions, and bugs relating to floating-point
exceptions and flag setting, will be addressed separately.  In
particular, while some of these patches add code that sets exception
flags in the softfloat state, it's generally the case that the x87
emulation ignores exceptions in that state rather than propagating
them to the status word (and to generating traps where appropriate).
I intend to address that missing propagation of exceptions in a
subsequent patch series; until it's addressed, the code setting
exceptions won't actually do anything useful.  (There is also code in
the x87 emulation, including that of fscale, that would result in
spurious exceptions being set from a naive propagation of exceptions
from the softfloat state, and thus will need updating to avoid
propagating inappropriate exceptions when such propagation is
implemented.)

Joseph Myers (5):
  target/i386: implement special cases for fxtract
  target/i386: fix fscale handling of signaling NaN
  target/i386: fix fscale handling of invalid exponent encodings
  target/i386: fix fscale handling of infinite exponents
  target/i386: fix fscale handling of rounding precision

 target/i386/fpu_helper.c           |  59 +++++++++++++-
 tests/tcg/i386/test-i386-fscale.c  | 108 ++++++++++++++++++++++++++
 tests/tcg/i386/test-i386-fxtract.c | 120 +++++++++++++++++++++++++++++
 3 files changed, 285 insertions(+), 2 deletions(-)
 create mode 100644 tests/tcg/i386/test-i386-fscale.c
 create mode 100644 tests/tcg/i386/test-i386-fxtract.c

-- 
2.17.1


-- 
Joseph S. Myers
joseph@codesourcery.com


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2020-06-25  9:44 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-05-07  0:42 [PATCH 0/5] target/i386: fxtract, fscale fixes Joseph Myers
2020-05-07  0:43 ` [PATCH 1/5] target/i386: implement special cases for fxtract Joseph Myers
2020-05-15  8:59   ` Alex Bennée
2020-06-23 21:42   ` Eduardo Habkost
2020-06-23 22:00     ` Joseph Myers
2020-06-25  9:43       ` Peter Maydell
2020-05-07  0:44 ` [PATCH 2/5] target/i386: fix fscale handling of signaling NaN Joseph Myers
2020-05-07  0:44 ` [PATCH 3/5] target/i386: fix fscale handling of invalid exponent encodings Joseph Myers
2020-05-07  0:45 ` [PATCH 4/5] target/i386: fix fscale handling of infinite exponents Joseph Myers
2020-05-07  0:46 ` [PATCH 5/5] target/i386: fix fscale handling of rounding precision Joseph Myers
2020-05-07  2:13 ` [PATCH 0/5] target/i386: fxtract, fscale fixes no-reply
2020-05-07 14:57   ` Joseph Myers
2020-05-08  3:42     ` Richard Henderson
2020-05-14 18:25 ` Ping " Joseph Myers
2020-05-14 23:02   ` Paolo Bonzini
2020-05-15  7:03 ` Philippe Mathieu-Daudé
2020-05-21 15:36 ` Paolo Bonzini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).