public inbox for java@gcc.gnu.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: java@gcc.gnu.org
Subject: Mauve - the remainder
Date: Wed, 17 Apr 2002 15:54:00 -0000	[thread overview]
Message-ID: <1019080941.7866.133.camel@elsschot> (raw)

[-- Attachment #1: Type: text/plain, Size: 3699 bytes --]

Hi,

It seems that the slippage of GCC 3.1 was a positive thing for Mauve
regression test fixing. On i686-pc-linux-gnu there are only 6 unanalyzed
failures left. (And Andrew is chasing the extra failures on powerpc).

Since I don't know how much time I will have till the actual release I
will list the remaining issues. Maybe someone can help analyze and/or
fix them.

FAIL: gnu.testlet.java.lang.Double.DoubleTest: Error: test_intValue
returned wrong results CYGNUS: Float to int conversions - 1 (number 1)

When compiling to byte-code the following prints zero:

public class DT
{
	public static void main(String[] args)
	{
		System.out.println((int) 3.4e+32);
	}
}

The actual buyte-code produced contains the zero. It should print
2147483647 (maxint), which it does when compiling from source.

FAIL: gnu.testlet.java.lang.Double.DoubleTest: Error: test_longValue
returned wrong results CYGNUS: Float to int conversions - 1 (number 1)

Same kind of failure, but now for (long) 3.4e+32. The byte-code contains
-4294967296 but the result should be 9223372036854775807 (maxlong).
Compiling from source gives the correct result.

FAIL: gnu.testlet.java.lang.Float.FloatTest: Error: test_intValue
returned wrong results - 1 (number 1)

Same for (int) 3.4e+32f.

Simple testcase for above failures attached. It succeeds when compiling
from source, it fails when compiling to byte-code.

FAIL: Compile gnu/testlet/java/lang/Math/min.o for
gnu.testlet.java.lang.Math.min

The verifier doesn't like the byte-code generated by gcj -C:
gnu/testlet/java/lang/Math/min.java: In class
`gnu.testlet.java.lang.Math.min':
gnu/testlet/java/lang/Math/min.java: In method
`gnu.testlet.java.lang.Math.min.test(gnu.testlet.TestHarness)':
gnu/testlet/java/lang/Math/min.java:30: verification error at PC=542
gnu/testlet/java/lang/Math/min.java:30: invalid argument type
gnu/testlet/java/lang/Math/min.java:30: Invalid multi-word value on type
stack

Running from bytecode doesn't work either since the libgcj verifier
finds the same error:
java.lang.VerifyError: verification failed at PC 542 in
gnu.testlet.java.lang.Math.min:test((Lgnu.testlet.TestHarness;)V):
incompatible type on stack

Compiling from source gives the following failures:

FAIL: gnu.testlet.java.lang.Math.min: Float NaNs (number 1)
got 0.0 but expected NaN
FAIL: gnu.testlet.java.lang.Math.min: Float NaNs (number 2)
got 0.0 but expected NaN
2 of 41 tests failed

Interestingly compiling from source with -O2 gives:
gnu/testlet/java/lang/Math/min.java:87: Internal compiler error in
emit_move_insn, at expr.c:2768

But I cannot produce a simple testcase for this even though it seems
that it is triggered by Math.min(2.0f, Float.NaN).

FAIL: gnu.testlet.java.lang.StringBuffer.plus (number 1)

The following program returns false, but should return true:

public class SN
{
        public static void main(String[] args)
        {
                System.out.println("null".equals(n(0) + ""));
        }

        static String n(int i)
        {
                if (i==0) return null; else return "x";
        }
}

The problem is that the String concatenation gets optimized away and
since n(0) returns null it does not generate the string "null" but it
generates the value null. The problem disappears when the return type of
n() is changed to Object.

FAIL: gnu.testlet.java.lang.ref.PhantomReference.phantom: unreachable
(number 1)

Haven't looked at the PhantomReference documentation enough to know what
should happen.

The other thing that should still be done is cleanup the mauve testing
script. At the moment it only works after a make install. And it only
tests source->byte-code->native compilation, not source->native.

Cheers,

Mark

[-- Attachment #2: DFT.java --]
[-- Type: text/x-java, Size: 231 bytes --]

public class DFT
{
	public static void main(String[] args)
	{
		System.out.println((int) 3.4e+32);
		System.out.println((long) 3.4e+32);

		System.out.println((int) 3.4e+32f);
		System.out.println((long) 3.4e+32f);
	}
}

[-- Attachment #3: DFT.out --]
[-- Type: text/plain, Size: 66 bytes --]

2147483647
9223372036854775807
2147483647
9223372036854775807

             reply	other threads:[~2002-04-17 22:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-17 15:54 Mark Wielaard [this message]
2002-04-17 16:24 ` Mark Wielaard
2002-04-18  8:31 ` Andrew Haley
2002-04-19 17:02 ` Mauve - the remainder (ieee_real_to_integer) Mark Wielaard
2002-04-19 18:05 ` Mauve - the remainder Tom Tromey

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=1019080941.7866.133.camel@elsschot \
    --to=mark@klomp.org \
    --cc=java@gcc.gnu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).