* Re: GCC 3.1 Prerelease
[not found] ` <3CC5909E.7070704@bothner.com>
@ 2002-04-23 14:36 ` Tom Tromey
2002-04-23 16:05 ` Per Bothner
0 siblings, 1 reply; 6+ messages in thread
From: Tom Tromey @ 2002-04-23 14:36 UTC (permalink / raw)
To: Per Bothner; +Cc: gcc, Alexandre Petit-Bianco, Java Discuss List
>>>>> "Per" == Per Bothner <per@bothner.com> writes:
Per> I just created pr java/6425. I'm biased, but I think this needs
Per> to be fixed before the release.
I looked at this.
First, the problem occurs on this line:
sbuf.append(RealNum.toScaledInt(number, 10).toString());
Breaking this into two lines, like so, makes the code compile:
IntNum x = RealNum.toScaledInt(number, 10);
sbuf.append(x.toString());
That's interesting information. It helped me track down the
difference between what happens when things go ok and when they don't.
However I don't fully understand what it means.
The class-loading code seems pretty fragile. If it is going to
compare file names it seems like it ought to compare the results of
realpath(). Otherwise there might be ways to fool it. However, while
this code isn't ideal (as far as I can see anyway), I think the
problem lies elsewhere.
The appended patch fixes the problem for me. What happened was we got
to this code with an EXPR_WITH_FILE_LOCATION like this:
arg 0 <expr_with_file_location 0x4012a420
arg 0 <identifier_node 0x4012a480 RealNum.toScaledInt tree_2> arg 1 <identifier_node 0x40126340 FixedRealFormat.java>
arg 2 <tree_list 0x4012917c
purpose <expr_with_file_location 0x4012a4a0
arg 0 <identifier_node 0x4012a400 RealNum> arg 1 <identifier_node 0x40126340 FixedRealFormat.java>
FixedRealFormat.java:9:16>
chain <tree_list 0x40129190
purpose <expr_with_file_location 0x4012a4c0 arg 0 <identifier_node 0x4012a440 toScaledInt> arg 1 <identifier_node 0x40126340 FixedRealFormat.java>
FixedRealFormat.java:9:23>>>
FixedRealFormat.java:9:16>
If we strip the outer EXPR_WITH_FILE_LOCATION, as the patch does, we
end up with qual_wfl as:
<identifier_node 0x4012a400 RealNum>
Anyway, I don't really understand what is going on here. I assume
there is some reason for the existing `if', but I don't know what it
is. I'm going to try rebuilding libgcj with this patch and see how
that goes.
Alex, can you look at this quickly? As far as I know you're the only
one who really understands this code.
Tom
Index: ChangeLog
from Tom Tromey <tromey@redhat.com>
* parse.y (qualify_ambiguous_name) [case CALL_EXPR]: Always choose
EXPR_WFL_QUALIFICATION of qual_wfl.
Index: parse.y
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/parse.y,v
retrieving revision 1.353.2.17
diff -u -r1.353.2.17 parse.y
--- parse.y 15 Apr 2002 09:28:53 -0000 1.353.2.17
+++ parse.y 23 Apr 2002 21:01:01 -0000
@@ -11219,11 +11219,8 @@
{
case CALL_EXPR:
qual_wfl = TREE_OPERAND (qual_wfl, 0);
- if (TREE_CODE (qual_wfl) != EXPR_WITH_FILE_LOCATION)
- {
- qual = EXPR_WFL_QUALIFICATION (qual_wfl);
- qual_wfl = QUAL_WFL (qual);
- }
+ qual = EXPR_WFL_QUALIFICATION (qual_wfl);
+ qual_wfl = QUAL_WFL (qual);
break;
case NEW_ARRAY_EXPR:
case NEW_ANONYMOUS_ARRAY_EXPR:
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: GCC 3.1 Prerelease
2002-04-23 14:36 ` GCC 3.1 Prerelease Tom Tromey
@ 2002-04-23 16:05 ` Per Bothner
2002-04-23 16:55 ` Tom Tromey
0 siblings, 1 reply; 6+ messages in thread
From: Per Bothner @ 2002-04-23 16:05 UTC (permalink / raw)
To: tromey; +Cc: gcc, Alexandre Petit-Bianco, Java Discuss List
Tom Tromey wrote:
> Index: ChangeLog
> from Tom Tromey <tromey@redhat.com>
>
> * parse.y (qualify_ambiguous_name) [case CALL_EXPR]: Always choose
> EXPR_WFL_QUALIFICATION of qual_wfl.
>
> Index: parse.y
> ===================================================================
> RCS file: /cvs/gcc/gcc/gcc/java/parse.y,v
> retrieving revision 1.353.2.17
> diff -u -r1.353.2.17 parse.y
> --- parse.y 15 Apr 2002 09:28:53 -0000 1.353.2.17
> +++ parse.y 23 Apr 2002 21:01:01 -0000
> @@ -11219,11 +11219,8 @@
> {
> case CALL_EXPR:
> qual_wfl = TREE_OPERAND (qual_wfl, 0);
> - if (TREE_CODE (qual_wfl) != EXPR_WITH_FILE_LOCATION)
> - {
> - qual = EXPR_WFL_QUALIFICATION (qual_wfl);
> - qual_wfl = QUAL_WFL (qual);
> - }
> + qual = EXPR_WFL_QUALIFICATION (qual_wfl);
> + qual_wfl = QUAL_WFL (qual);
> break;
> case NEW_ARRAY_EXPR:
> case NEW_ANONYMOUS_ARRAY_EXPR:
This patch causes building Kawa to break even earlier (while
generating class files).
--
--Per Bothner
per@bothner.com http://www.bothner.com/per/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: GCC 3.1 Prerelease
2002-04-23 16:05 ` Per Bothner
@ 2002-04-23 16:55 ` Tom Tromey
2002-04-24 10:27 ` Alexandre Petit-Bianco
0 siblings, 1 reply; 6+ messages in thread
From: Tom Tromey @ 2002-04-23 16:55 UTC (permalink / raw)
To: Per Bothner; +Cc: gcc, Alexandre Petit-Bianco, Java Discuss List
>>>>> "Per" == Per Bothner <per@bothner.com> writes:
Per> This patch causes building Kawa to break even earlier (while
Per> generating class files).
Yeah, I saw that once I started rebuilding libgcj with it. Try the
appended. We really need Alex to look at this though.
Tom
Index: ChangeLog
from Tom Tromey <tromey@redhat.com>
* parse.y (qualify_ambiguous_name) [case CALL_EXPR]: Always choose
EXPR_WFL_QUALIFICATION of qual_wfl.
Index: parse.y
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/parse.y,v
retrieving revision 1.353.2.17
diff -u -r1.353.2.17 parse.y
--- parse.y 15 Apr 2002 09:28:53 -0000 1.353.2.17
+++ parse.y 23 Apr 2002 23:04:15 -0000
@@ -11219,7 +11219,9 @@
{
case CALL_EXPR:
qual_wfl = TREE_OPERAND (qual_wfl, 0);
- if (TREE_CODE (qual_wfl) != EXPR_WITH_FILE_LOCATION)
+ if (TREE_CODE (qual_wfl) != EXPR_WITH_FILE_LOCATION
+ || (EXPR_WFL_QUALIFICATION (qual_wfl)
+ && TREE_CODE (EXPR_WFL_QUALIFICATION (qual_wfl)) == TREE_LIST))
{
qual = EXPR_WFL_QUALIFICATION (qual_wfl);
qual_wfl = QUAL_WFL (qual);
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: GCC 3.1 Prerelease
2002-04-23 16:55 ` Tom Tromey
@ 2002-04-24 10:27 ` Alexandre Petit-Bianco
2002-04-24 10:29 ` Tom Tromey
0 siblings, 1 reply; 6+ messages in thread
From: Alexandre Petit-Bianco @ 2002-04-24 10:27 UTC (permalink / raw)
To: tromey; +Cc: Per Bothner, gcc, Java Discuss List
Tom Tromey writes:
> Yeah, I saw that once I started rebuilding libgcj with it. Try the
> appended. We really need Alex to look at this though.
From the debug session information that you sent, this is making
sense. I'm not seing any regression in all my build tests (3500 files)
and I believe it improves the situation with my (old) copy of Freenet.
I'll be able to do some real debugging tonight at the earliest. In the
meantime, if we're short on time, this should probably go in.
Thank you for looking into this,
./A
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: GCC 3.1 Prerelease
2002-04-24 10:27 ` Alexandre Petit-Bianco
@ 2002-04-24 10:29 ` Tom Tromey
2002-04-24 11:09 ` Mark Mitchell
0 siblings, 1 reply; 6+ messages in thread
From: Tom Tromey @ 2002-04-24 10:29 UTC (permalink / raw)
To: apbianco; +Cc: Per Bothner, gcc, Java Discuss List, Mark Mitchell
>>>>> "Alex" == Alexandre Petit-Bianco <apbianco@cygnus.com> writes:
Alex> From the debug session information that you sent, this is making
Alex> sense. I'm not seing any regression in all my build tests (3500
Alex> files) and I believe it improves the situation with my (old)
Alex> copy of Freenet.
Alex> I'll be able to do some real debugging tonight at the
Alex> earliest. In the meantime, if we're short on time, this should
Alex> probably go in.
Thanks.
It rebuilt libgcj fine. I'll run the test suite (plus Mauve) shortly.
I also plan to rebuild rhug with this patch.
Mark, assuming the tests go well, is this ok for the branch? It fixes
the last high priority gcj PR.
Alex,
Tom
Index: ChangeLog
from Tom Tromey <tromey@redhat.com>
For PR java/6425:
* parse.y (qualify_ambiguous_name) [case CALL_EXPR]: Always choose
EXPR_WFL_QUALIFICATION of qual_wfl.
Index: parse.y
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/parse.y,v
retrieving revision 1.353.2.17
diff -u -r1.353.2.17 parse.y
--- parse.y 15 Apr 2002 09:28:53 -0000 1.353.2.17
+++ parse.y 24 Apr 2002 17:24:30 -0000
@@ -11219,7 +11219,9 @@
{
case CALL_EXPR:
qual_wfl = TREE_OPERAND (qual_wfl, 0);
- if (TREE_CODE (qual_wfl) != EXPR_WITH_FILE_LOCATION)
+ if (TREE_CODE (qual_wfl) != EXPR_WITH_FILE_LOCATION
+ || (EXPR_WFL_QUALIFICATION (qual_wfl)
+ && TREE_CODE (EXPR_WFL_QUALIFICATION (qual_wfl)) == TREE_LIST))
{
qual = EXPR_WFL_QUALIFICATION (qual_wfl);
qual_wfl = QUAL_WFL (qual);
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: GCC 3.1 Prerelease
2002-04-24 10:29 ` Tom Tromey
@ 2002-04-24 11:09 ` Mark Mitchell
0 siblings, 0 replies; 6+ messages in thread
From: Mark Mitchell @ 2002-04-24 11:09 UTC (permalink / raw)
To: tromey, apbianco; +Cc: Per Bothner, gcc, Java Discuss List, Mark Mitchell
> Mark, assuming the tests go well, is this ok for the branch? It fixes
> the last high priority gcj PR.
Yes, thanks!
--
Mark Mitchell mark@codesourcery.com
CodeSourcery, LLC http://www.codesourcery.com
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2002-04-24 17:29 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <14800000.1019552485@gandalf.codesourcery.com>
[not found] ` <3CC583C5.6030101@bothner.com>
[not found] ` <20980000.1019578223@gandalf.codesourcery.com>
[not found] ` <3CC5909E.7070704@bothner.com>
2002-04-23 14:36 ` GCC 3.1 Prerelease Tom Tromey
2002-04-23 16:05 ` Per Bothner
2002-04-23 16:55 ` Tom Tromey
2002-04-24 10:27 ` Alexandre Petit-Bianco
2002-04-24 10:29 ` Tom Tromey
2002-04-24 11:09 ` Mark Mitchell
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).