public inbox for java-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug java/27756]  New: ICE in update_aliases, at java/decl.c:192
@ 2006-05-24 14:54 tromey at gcc dot gnu dot org
  2006-05-24 14:56 ` [Bug java/27756] " tromey at gcc dot gnu dot org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-05-24 14:54 UTC (permalink / raw)
  To: java-prs

Compile the attached bytecode to see the ICE:

opsy. gcj -c -findirect-dispatch
./bin/org/eclipse/jdt/internal/core/NameLookup.class
org/eclipse/jdt/internal/core/NameLookup.java: In class
'org.eclipse.jdt.internal.core.NameLookup':
org/eclipse/jdt/internal/core/NameLookup.java: In method
'org.eclipse.jdt.internal.core.NameLookup.seekTypesInBinaryPackage(java.lang.String,org.eclipse.jdt.core.IPackageFragment,boolean,int,org.eclipse.jdt.internal.core.IJavaElementRequestor)':
org/eclipse/jdt/internal/core/NameLookup.java:980: internal compiler error: in
update_aliases, at java/decl.c:192
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.


This happens for me with 4.1 and svn head.
The bytecode is a class generated by ecj;
the corresponding source code also comes from ecj.


-- 
           Summary: ICE in update_aliases, at java/decl.c:192
           Product: gcc
           Version: 4.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: java
        AssignedTo: aph at gcc dot gnu dot org
        ReportedBy: tromey at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
@ 2006-05-24 14:56 ` tromey at gcc dot gnu dot org
  2006-05-25 10:02 ` aph at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-05-24 14:56 UTC (permalink / raw)
  To: java-prs



------- Comment #1 from tromey at gcc dot gnu dot org  2006-05-24 14:56 -------
Created an attachment (id=11504)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=11504&action=view)
failing class file


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
  2006-05-24 14:56 ` [Bug java/27756] " tromey at gcc dot gnu dot org
@ 2006-05-25 10:02 ` aph at gcc dot gnu dot org
  2006-05-25 10:12 ` aph at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: aph at gcc dot gnu dot org @ 2006-05-25 10:02 UTC (permalink / raw)
  To: java-prs



------- Comment #2 from aph at gcc dot gnu dot org  2006-05-25 10:02 -------
Created an attachment (id=11512)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=11512&action=view)
Patch

Try this.  If it works for you I'll check it in.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
  2006-05-24 14:56 ` [Bug java/27756] " tromey at gcc dot gnu dot org
  2006-05-25 10:02 ` aph at gcc dot gnu dot org
@ 2006-05-25 10:12 ` aph at gcc dot gnu dot org
  2006-05-25 22:53 ` tromey at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: aph at gcc dot gnu dot org @ 2006-05-25 10:12 UTC (permalink / raw)
  To: java-prs



------- Comment #3 from aph at gcc dot gnu dot org  2006-05-25 10:12 -------
This is caused by ecj generating non-nested variable scopes.

In Method name:"seekTypesInBinaryPackage":

  slot#13: name: i, type: int (pc: 254 length: 82)

  slot#15: name: elementName, type: java.lang.String (pc: 240 length: 86)

So, i extends from pc 254-336, and elementName from pc 240-326.

Although gcj should correctly handle this, it must be a bug in ecj.  It's quite
impossible for Java variables to have non-nested ranges.


-- 

aph at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2006-05-25 10:12 ` aph at gcc dot gnu dot org
@ 2006-05-25 22:53 ` tromey at gcc dot gnu dot org
  2006-05-26 10:20 ` aph at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-05-25 22:53 UTC (permalink / raw)
  To: java-prs



------- Comment #4 from tromey at gcc dot gnu dot org  2006-05-25 22:53 -------
Thanks Andrew. With this I'm able to BC compile ecj again.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2006-05-25 22:53 ` tromey at gcc dot gnu dot org
@ 2006-05-26 10:20 ` aph at gcc dot gnu dot org
  2006-05-26 10:23 ` aph at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: aph at gcc dot gnu dot org @ 2006-05-26 10:20 UTC (permalink / raw)
  To: java-prs



------- Comment #5 from aph at gcc dot gnu dot org  2006-05-26 10:20 -------
I have found the real cause of these weird non-nested variable ranges.

It's because ecj reorganizes for loops in this way:

for (a; b; c)
{
  foo;
}

becomes

goto barf;
do
{
  foo;
  c;
barf:
  a;
  if (!b)
    goto x;   
} forever;
x:

And this movement of the for body causes variable ranges to be discontinuous. 
Duplicate variable definitions are issued.

It would be very nice if ecj could be prevented from doing this, at least for
the purpose of acting as a gcj front end.


-- 

aph at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |ASSIGNED
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2006-05-26 10:20:22
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2006-05-26 10:20 ` aph at gcc dot gnu dot org
@ 2006-05-26 10:23 ` aph at gcc dot gnu dot org
  2006-05-26 13:52 ` aph at gcc dot gnu dot org
  2006-05-26 13:54 ` aph at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: aph at gcc dot gnu dot org @ 2006-05-26 10:23 UTC (permalink / raw)
  To: java-prs



------- Comment #6 from aph at gcc dot gnu dot org  2006-05-26 10:23 -------
Err, I mean:

a;
goto barf;
do
{
  foo;
  c;
barf:
  if (!b)
    goto x;   
} forever;
x:


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2006-05-26 10:23 ` aph at gcc dot gnu dot org
@ 2006-05-26 13:52 ` aph at gcc dot gnu dot org
  2006-05-26 13:54 ` aph at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: aph at gcc dot gnu dot org @ 2006-05-26 13:52 UTC (permalink / raw)
  To: java-prs



------- Comment #7 from aph at gcc dot gnu dot org  2006-05-26 13:52 -------
Subject: Bug 27756

Author: aph
Date: Fri May 26 13:52:18 2006
New Revision: 114131

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=114131
Log:
2006-05-25  Andrew Haley  <aph@redhat.com>

        PR java/27756
        * decl.c (maybe_pushlevels): When variable ranges are non-nested
        update all lifetimes, not just the first one.


Modified:
    trunk/gcc/java/ChangeLog
    trunk/gcc/java/decl.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug java/27756] ICE in update_aliases, at java/decl.c:192
  2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
                   ` (6 preceding siblings ...)
  2006-05-26 13:52 ` aph at gcc dot gnu dot org
@ 2006-05-26 13:54 ` aph at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: aph at gcc dot gnu dot org @ 2006-05-26 13:54 UTC (permalink / raw)
  To: java-prs



------- Comment #8 from aph at gcc dot gnu dot org  2006-05-26 13:54 -------
What am I supposed to write here, anyway?  It's fixed because I fixed it.


-- 

aph at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27756


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2006-05-26 13:54 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-24 14:54 [Bug java/27756] New: ICE in update_aliases, at java/decl.c:192 tromey at gcc dot gnu dot org
2006-05-24 14:56 ` [Bug java/27756] " tromey at gcc dot gnu dot org
2006-05-25 10:02 ` aph at gcc dot gnu dot org
2006-05-25 10:12 ` aph at gcc dot gnu dot org
2006-05-25 22:53 ` tromey at gcc dot gnu dot org
2006-05-26 10:20 ` aph at gcc dot gnu dot org
2006-05-26 10:23 ` aph at gcc dot gnu dot org
2006-05-26 13:52 ` aph at gcc dot gnu dot org
2006-05-26 13:54 ` aph at gcc dot gnu dot org

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).