This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: [PATCH/RFC] Enable java on sh64-linux (Take 2)
- From: Andrew Haley <aph at redhat dot com>
- To: Kaz Kojima <kkojima at rr dot iij4u dot or dot jp>
- Cc: tromey at redhat dot com, java-patches at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org, andreast at gcc dot gnu dot org, joern dot rennecke at superh dot com, aoliva at redhat dot com
- Date: Mon, 4 Oct 2004 14:32:07 +0100
- Subject: Re: [PATCH/RFC] Enable java on sh64-linux (Take 2)
- References: <16732.7381.219841.977197@cuddles.cambridge.redhat.com><20041001.073612.35673489.kkojima@rr.iij4u.or.jp><m3zn36gxh0.fsf@localhost.localdomain><20041002.092711.15255785.kkojima@rr.iij4u.or.jp>
Kaz Kojima writes:
> Tom Tromey <tromey@redhat.com> wrote:
> > Kaz> I'd like to see the divide overflow handler.
> >
> > The usual solution to this problem is to turn on
> > -fuse-divide-subroutine in configure.host for your platform. See,
> > e.g., libjava/prims.cc:_Jv_divI() for what is supposed to happen.
> > Divide_1 just tests all these cases.
>
> I've noticed that -fuse-divide-subroutine is used already for this
> target and found that a libffi problem of this target causes
> the Divide_1 failure with gij. SH-5 has 64-bit integer registers
> and I've forgot to extend 32-bit signed integers to 64-bit signed
> integers when storing them to 64-bit width memory in ffi_prep_args.
...
> BTW, it's surprising that no testcase could detect the above problem,
> isn't it? How about the testcase below? It caught this mistake.
That's good. The libffi testsuite is far from complete.
I'm betting on libffi mistakes for the rest of the gij failures, too.
Andrew.