* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
@ 2006-02-22 14:31 ` pinskia at gcc dot gnu dot org
2006-03-09 3:16 ` mckinlay at redhat dot com
` (11 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-02-22 14:31 UTC (permalink / raw)
To: java-prs
------- Comment #1 from pinskia at gcc dot gnu dot org 2006-02-22 14:31 -------
I have seen a bug like this before.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
2006-02-22 14:31 ` [Bug java/26390] " pinskia at gcc dot gnu dot org
@ 2006-03-09 3:16 ` mckinlay at redhat dot com
2006-03-10 18:13 ` mark at gcc dot gnu dot org
` (10 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: mckinlay at redhat dot com @ 2006-03-09 3:16 UTC (permalink / raw)
To: java-prs
------- Comment #2 from mckinlay at redhat dot com 2006-03-09 03:16 -------
Can anyone make a test case for this? I was unable to reproduce it.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
2006-02-22 14:31 ` [Bug java/26390] " pinskia at gcc dot gnu dot org
2006-03-09 3:16 ` mckinlay at redhat dot com
@ 2006-03-10 18:13 ` mark at gcc dot gnu dot org
2006-03-10 23:00 ` tromey at gcc dot gnu dot org
` (9 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: mark at gcc dot gnu dot org @ 2006-03-10 18:13 UTC (permalink / raw)
To: java-prs
------- Comment #3 from mark at gcc dot gnu dot org 2006-03-10 18:13 -------
While importing 0.90 into libgcj I also noticed this. Setting this package to
bc (like the other awt peer implementations) gives:
make[3]: Entering directory `/home/mark/src/gcc-obj/i686-pc-linux-gnu/libjava'
/bin/sh ./libtool --mode=compile /home/mark/src/gcc-obj/gcc/gcj
-B/home/mark/src/gcc-obj/i686-pc-linux-gnu/libjava/
-B/home/mark/src/gcc-obj/gcc/ -ffloat-store -fomit-frame-pointer -fclasspath=
-fbootclasspath=/home/mark/src/gcc-obj/i686-pc-linux-gnu/libjava/classpath/lib
--encoding=UTF-8 -Wno-deprecated -fbootstrap-classes -g -O2 -fjni
-findirect-dispatch -c -o gnu-java-awt-peer-swing.lo
@gnu-java-awt-peer-swing.list
/home/mark/src/gcc-obj/gcc/gcj
-B/home/mark/src/gcc-obj/i686-pc-linux-gnu/libjava/
-B/home/mark/src/gcc-obj/gcc/ -ffloat-store -fomit-frame-pointer -fclasspath=
-fbootclasspath=/home/mark/src/gcc-obj/i686-pc-linux-gnu/libjava/classpath/lib
--encoding=UTF-8 -Wno-deprecated -fbootstrap-classes -g -O2 -fjni
-findirect-dispatch -c @gnu-java-awt-peer-swing.list -fPIC -o
.libs/gnu-java-awt-peer-swing.o
gnu/java/awt/peer/swing/SwingFramePeer.java: In class
'gnu.java.awt.peer.swing.SwingFramePeer':
gnu/java/awt/peer/swing/SwingFramePeer.java: In method
'gnu.java.awt.peer.swing.SwingFramePeer.setBounds(int,int,int,int)':
gnu/java/awt/peer/swing/SwingFramePeer.java:118: error: verification failed at
PC=6: didn't see expected constant
make[3]: *** [gnu-java-awt-peer-swing.lo] Error 1
where line 118 is indeed:
super.setBounds(x, y, w, h);
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (2 preceding siblings ...)
2006-03-10 18:13 ` mark at gcc dot gnu dot org
@ 2006-03-10 23:00 ` tromey at gcc dot gnu dot org
2006-03-11 1:40 ` tromey at gcc dot gnu dot org
` (8 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-10 23:00 UTC (permalink / raw)
To: java-prs
--
tromey at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tromey at gcc dot gnu dot
| |org
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2006-03-10 23:00:01
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (3 preceding siblings ...)
2006-03-10 23:00 ` tromey at gcc dot gnu dot org
@ 2006-03-11 1:40 ` tromey at gcc dot gnu dot org
2006-03-13 17:10 ` tromey at gcc dot gnu dot org
` (7 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-11 1:40 UTC (permalink / raw)
To: java-prs
------- Comment #4 from tromey at gcc dot gnu dot org 2006-03-11 01:40 -------
Mark's problem appears to be a bytecode generation bug.
We are generating:
6: invokespecial #65=<InterfaceMethod java.awt.peer.WindowPeer.setBounds
(int,int,int,int)void>
But this is incorrect as you cannot invoke an interface method
with invokespecial. And, super.foo() should never call an
interface method anyway.
I don't know whether or how the original report is related,
but it isn't unreasonable to assume that it is.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (4 preceding siblings ...)
2006-03-11 1:40 ` tromey at gcc dot gnu dot org
@ 2006-03-13 17:10 ` tromey at gcc dot gnu dot org
2006-03-13 17:12 ` tromey at gcc dot gnu dot org
` (6 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-13 17:10 UTC (permalink / raw)
To: java-prs
------- Comment #5 from tromey at gcc dot gnu dot org 2006-03-13 17:10 -------
Created an attachment (id=11043)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=11043&action=view)
reduced test case
I'm attaching a reduced test case.
If you remove one of the intermediate classes, the
output is correct.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (5 preceding siblings ...)
2006-03-13 17:10 ` tromey at gcc dot gnu dot org
@ 2006-03-13 17:12 ` tromey at gcc dot gnu dot org
2006-03-13 19:07 ` tromey at gcc dot gnu dot org
` (5 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-13 17:12 UTC (permalink / raw)
To: java-prs
------- Comment #6 from tromey at gcc dot gnu dot org 2006-03-13 17:12 -------
I added a main to the reduced test case:
public static void main(String[] args)
{
SwingFramePeer s = new SwingFramePeer();
s.setBounds();
}
With this I can almost reproduce the original bug:
opsy. gcj --main=pr26390 -o P pr26390.java
/tmp/cczetk2m.o(.text+0xd): In function `void
pr26390$SwingFramePeer::setBounds()':
pr26390.java: undefined reference to `void pr26390$WindowPeer::setBounds()'
I say "almost" since from the original report I would expect
the missing method to come from SwingWindowPeer.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (6 preceding siblings ...)
2006-03-13 17:12 ` tromey at gcc dot gnu dot org
@ 2006-03-13 19:07 ` tromey at gcc dot gnu dot org
2006-03-15 18:29 ` tromey at gcc dot gnu dot org
` (4 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-13 19:07 UTC (permalink / raw)
To: java-prs
------- Comment #7 from tromey at gcc dot gnu dot org 2006-03-13 19:07 -------
The bug here is that gcj implements method inheritance incorrectly.
In particular it does not consider SwingWindowPeer.setBounds
as a candidate method for the super.setBounds() call, because it
has no notion that there is a method named "SwingWindowPeer.setBounds".
Instead it only considers SwingComponentPeer.setBounds -- which is
not maximal and thus not selected.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (7 preceding siblings ...)
2006-03-13 19:07 ` tromey at gcc dot gnu dot org
@ 2006-03-15 18:29 ` tromey at gcc dot gnu dot org
2006-03-15 18:31 ` tromey at gcc dot gnu dot org
` (3 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-15 18:29 UTC (permalink / raw)
To: java-prs
------- Comment #8 from tromey at gcc dot gnu dot org 2006-03-15 18:29 -------
Subject: Bug 26390
Author: tromey
Date: Wed Mar 15 18:29:44 2006
New Revision: 112093
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=112093
Log:
gcc/java
PR java/26390:
* class.c (get_interface_method_index): Don't put <clinit> into
interface table.
libjava
PR java/26390:
* link.cc (get_interfaces): Skip <clinit>.
(append_partial_itable): Likewise.
Modified:
trunk/gcc/java/ChangeLog
trunk/gcc/java/class.c
trunk/libjava/ChangeLog
trunk/libjava/link.cc
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (8 preceding siblings ...)
2006-03-15 18:29 ` tromey at gcc dot gnu dot org
@ 2006-03-15 18:31 ` tromey at gcc dot gnu dot org
2006-03-29 16:32 ` tromey at gcc dot gnu dot org
` (2 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-15 18:31 UTC (permalink / raw)
To: java-prs
------- Comment #9 from tromey at gcc dot gnu dot org 2006-03-15 18:31 -------
Oops -- that was the wrong PR number in that patch.
That commit was for PR 26638.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (9 preceding siblings ...)
2006-03-15 18:31 ` tromey at gcc dot gnu dot org
@ 2006-03-29 16:32 ` tromey at gcc dot gnu dot org
2006-03-29 16:36 ` tromey at gcc dot gnu dot org
2006-12-28 15:45 ` rob1weld at aol dot com
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-29 16:32 UTC (permalink / raw)
To: java-prs
------- Comment #10 from tromey at gcc dot gnu dot org 2006-03-29 16:32 -------
Subject: Bug 26390
Author: tromey
Date: Wed Mar 29 16:31:53 2006
New Revision: 112499
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=112499
Log:
gcc/java
PR java/26390:
* parse.y (find_most_specific_methods_list): Added 'class'
argument.
(lookup_method_invoke): Updated.
libjava
PR java/26390:
* testsuite/libjava.lang/pr26390.out: New file.
* testsuite/libjava.lang/pr26390.java: New file.
* sources.am, Makefile.in: Rebuilt.
* scripts/makemake.tcl: Compile gnu/java/awt/peer/swing.
Added:
trunk/libjava/testsuite/libjava.lang/pr26390.java
trunk/libjava/testsuite/libjava.lang/pr26390.out
Modified:
trunk/gcc/java/ChangeLog
trunk/gcc/java/parse.y
trunk/libjava/ChangeLog
trunk/libjava/Makefile.in
trunk/libjava/scripts/makemake.tcl
trunk/libjava/sources.am
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (10 preceding siblings ...)
2006-03-29 16:32 ` tromey at gcc dot gnu dot org
@ 2006-03-29 16:36 ` tromey at gcc dot gnu dot org
2006-12-28 15:45 ` rob1weld at aol dot com
12 siblings, 0 replies; 14+ messages in thread
From: tromey at gcc dot gnu dot org @ 2006-03-29 16:36 UTC (permalink / raw)
To: java-prs
------- Comment #11 from tromey at gcc dot gnu dot org 2006-03-29 16:36 -------
Fix checked in.
--
tromey at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.2.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug java/26390] Problem dispatching method call when method does not exist in superclass
2006-02-21 8:32 [Bug java/26390] New: Problem dispatching method call when method does not exist in superclass david at jpackage dot org
` (11 preceding siblings ...)
2006-03-29 16:36 ` tromey at gcc dot gnu dot org
@ 2006-12-28 15:45 ` rob1weld at aol dot com
12 siblings, 0 replies; 14+ messages in thread
From: rob1weld at aol dot com @ 2006-12-28 15:45 UTC (permalink / raw)
To: java-prs
------- Comment #12 from rob1weld at aol dot com 2006-12-28 15:45 -------
(In reply to comment #11)
> Fix checked in.
I'm not an expert with Java but am trying to compile gcc 4_2 branch (CVS)
and I have the same problem as is described in this bug report. The fixes
mentioned in this report _seem_ to have been applied but am getting a 'similar'
error message:
Here is the part of the make where it fails:
/bin/sh ./libtool --mode=compile /cygdrive/c/gcc-4_2-branch-build/gcc/gcj
-B/cygdrive/c/gcc-4_2-branch-build/athlon_xp-pc-cygwin/libjava/
-B/cygdrive/c/gcc-4_2-branch-build/gcc/ -ffloat-store -fomit-frame-pointer
-fclasspath=
-fbootclasspath=/cygdrive/c/gcc-4_2-branch-build/athlon_xp-pc-cygwin/libjava/classpath/lib
--encoding=UTF-8 -Wno-deprecated -fbootstrap-classes -g -O2 -fjni
-findirect-dispatch -fno-indirect-classes -c -o gnu-java-awt-peer-swing.lo
@gnu-java-awt-peer-swing.list
/cygdrive/c/gcc-4_2-branch-build/gcc/gcj
-B/cygdrive/c/gcc-4_2-branch-build/athlon_xp-pc-cygwin/libjava/
-B/cygdrive/c/gcc-4_2-branch-build/gcc/ -ffloat-store -fomit-frame-pointer
-fclasspath= -fbootclasspath=/
cygdrive/c/gcc-4_2-branch-build/athlon_xp-pc-cygwin/libjava/classpath/lib
--encoding=UTF-8 -Wno-deprecate
d -fbootstrap-classes -g -O2 -fjni -findirect-dispatch -fno-indirect-classes -c
@gnu-java-awt-peer-swing.list
-o gnu-java-awt-peer-swing.o
gnu/java/awt/peer/swing/SwingFramePeer.java: In class
'gnu.java.awt.peer.swing.SwingFramePeer':
gnu/java/awt/peer/swing/SwingFramePeer.java: In method
'gnu.java.awt.peer.swing.SwingFramePeer.setBounds(int,int,int,int)':
gnu/java/awt/peer/swing/SwingFramePeer.java:118: error: verification failed at
PC=6: didn't see expected constant
make[3]: *** [gnu-java-awt-peer-swing.lo] Error 1
make[3]: Target `all-am' not remade because of errors.
make[3]: Leaving directory
`/cygdrive/c/gcc-4_2-branch-build/athlon_xp-pc-cygwin/libjava'
I'll leave any 'fixing' to someone more expert at java (so I don't break gcc
somewhere else :( ). I tried changing to above to simply use system's gcj:
gcj -c -o gnu-java-awt-peer-swing.lo @gnu-java-awt-peer-swing.list
This is the message I got:
gnu/java/awt/peer/swing/SwingFramePeer.java: In class
'gnu.java.awt.peer.swing.SwingFramePeer':
gnu/java/awt/peer/swing/SwingFramePeer.java: In method
'gnu.java.awt.peer.swing.SwingFramePeer.setBounds(int,int,int,int)':
gnu/java/awt/peer/swing/SwingFramePeer.java:118: error: verification failed at
PC=6: didn't see expected constant
gnu/java/awt/peer/swing/SwingFramePeer.java:118: error: class
'java.awt.peer.WindowPeer' has no method named 'setBounds' matching signature
'(IIII)V'
gnu/java/awt/peer/swing/SwingFramePeer.java:119: confused by earlier errors,
bailing out
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26390
^ permalink raw reply [flat|nested] 14+ messages in thread