[Mono-bugs] [Bug 54467][Wis] Changed - Incorrect values when subtracting doubles

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 19 May 2004 09:08:51 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by massi@ximian.com.

http://bugzilla.ximian.com/show_bug.cgi?id=54467

--- shadow/54467	2004-05-19 08:51:20.000000000 -0400
+++ shadow/54467.tmp.6000	2004-05-19 09:08:51.000000000 -0400
@@ -87,6 +87,29 @@
 affects with NaNs etc.
 
 ------- Additional Comments From massi@ximian.com  2004-05-19 08:51 -------
 Created an attachment (id=7761)
 More test cases that fail (in the form of regression tests)
 
+
+------- Additional Comments From massi@ximian.com  2004-05-19 09:08 -------
+After the comment from Paolo, I investigated a bit, and created more
+tests that fail (see previous attachment, at the bottom).
+I have verified that adding 0.0 works, and the fastes way to do it
+seems to be with a fldz and a faddp in sequence.
+They take four bytes in code, but do not touch the memory otherwise,
+and with that correction all the "easy" tests pass.
+
+On the other hand, they could cause some more spilling (they use a fp
+register). An alternative would be to push a fp 0.0 on the stack (I
+mean the regular stack in memory), and have the faddp use it instead
+of using a fp register.
+This is probably slower, but would avoid any added spill, and would
+therefore be easier to "inline" in the relevant places in mini-x86.c.
+
+However, I am puzzled by the last test that fails (it seems that fsqrt
+does honor the precision bit, but things get strange with that complex
+expression at the end of the file).
+
+Moreover, I am going to investigate what will happen with NaNs (I'll
+create more test cases).
+