Author: zoltan
Date: 2005-03-06 14:15:51 -0500 (Sun, 06 Mar 2005)
New Revision: 41488

Modified:
   trunk/mono/mono/mini/ChangeLog
   trunk/mono/mono/mini/basic-float.cs
Log:
2005-03-06  Zoltan Varga  <[EMAIL PROTECTED]>

        * basic-float.cs: Add rounding regression test.


Modified: trunk/mono/mono/mini/ChangeLog
===================================================================
--- trunk/mono/mono/mini/ChangeLog      2005-03-06 19:15:16 UTC (rev 41487)
+++ trunk/mono/mono/mini/ChangeLog      2005-03-06 19:15:51 UTC (rev 41488)
@@ -1,5 +1,7 @@
 2005-03-06  Zoltan Varga  <[EMAIL PROTECTED]>
 
+       * basic-float.cs: Add rounding regression test.
+
        * mini-amd64.c (INST_IGNORES_CFLAGS): Add more instructions.
 
 2005-03-04  Neale Ferguson <[EMAIL PROTECTED]>

Modified: trunk/mono/mono/mini/basic-float.cs
===================================================================
--- trunk/mono/mono/mini/basic-float.cs 2005-03-06 19:15:16 UTC (rev 41487)
+++ trunk/mono/mono/mini/basic-float.cs 2005-03-06 19:15:51 UTC (rev 41488)
@@ -184,6 +184,18 @@
                return 4;
        }
 
+       public static int test_0_rounding () {
+               long ticks = 631502475130080000L;
+               long ticksperday = 864000000000L;
+
+               double days = (double) ticks / ticksperday;
+
+               if ((int)days != 730905)
+                       return 1;
+
+               return 0;
+       }
+
        /* FIXME: This only works on little-endian machines */
        /*
        static unsafe int test_2_negative_zero () {

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to