FIX: Floating Point Exception Incorrect Under Win32sLast reviewed: October 29, 1997Article ID: Q150405 |
1.30
WINDOWS
kbprg kbbuglist kbfixlist
The information in this article applies to:
SYMPTOMSThere are some inconsistencies in floating point exception handling under Win32s and Windows NT platforms. For example, the following code causes a underflow on both platforms as expected and the exception is masked:
d1 = pow(1000000, -53);However, the following code:
d2 = 1/d1;causes this behavior:
Windows NT 3.51 - Floating point Overflow. Windows 3.1/Win32s - Denormal operand errorThe overflow exception under Windows NT is correct, but the result under Win32s is not.
RESOLUTIONIf you examine the exception record, you can see that the denormal operand status bit is set but the exception is masked in the control word. On the other hand, the overflow exception status bit is also set and the exception is unmasked. Even though the exception indication is incorrect, you can get the correct exception by examining the status and control words appropriately.
STATUSMicrosoft has confirmed this to be a bug in Win32s version 1.30. Win32s incorrectly sets the floating point exception in the above case to a Denormal operand error instead of an Overflow exception. This problem has been corrected in Win32s version 1.30c.
|
Additional reference words: 1.30 win32s fp error
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |