From: David Miller <davem@davemloft.net>
To: galak@kernel.crashing.org
Cc: linux-kernel@vger.kernel.org
Subject: minor bug in invalid exception patch
Date: Tue, 21 Oct 2008 23:24:21 -0700 (PDT) [thread overview]
Message-ID: <20081021.232421.212159699.davem@davemloft.net> (raw)
While looking over some recent changes to op-common.h I found
a minor error in:
commit 48d6c64311ddb6417b901639530ccbc47bdc7635
Author: Kumar Gala <galak@kernel.crashing.org>
Date: Fri Jun 27 09:39:00 2008 -0500
math-emu: Add support for reporting exact invalid exception
that I didn't catch in my initial review :) Sorry.
Specifically:
@@ -490,11 +490,15 @@ do { \
break; \
\
case _FP_CLS_COMBINE(FP_CLS_INF,FP_CLS_INF): \
+ R##_s = _FP_NANSIGN_##fs; \
+ R##_c = FP_CLS_NAN; \
+ _FP_FRAC_SET_##wc(R, _FP_NANFRAC_##fs); \
+ FP_SET_EXCEPTION(FP_EX_INVALID | FP_EX_INVALID_IDI);\
case _FP_CLS_COMBINE(FP_CLS_ZERO,FP_CLS_ZERO): \
R##_s = _FP_NANSIGN_##fs; \
R##_c = FP_CLS_NAN; \
_FP_FRAC_SET_##wc(R, _FP_NANFRAC_##fs); \
- FP_SET_EXCEPTION(FP_EX_INVALID); \
+ FP_SET_EXCEPTION(FP_EX_INVALID | FP_EX_INVALID_ZDZ);\
break; \
\
default: \
That first case statement code block falls through to
the next one, which is probably not as you intended.
Seems there is a missing break there.
next reply other threads:[~2008-10-22 6:24 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-22 6:24 David Miller [this message]
2008-10-23 5:10 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20081021.232421.212159699.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=galak@kernel.crashing.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®