public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libgcj/30742]  New: ResourceBundle regression
@ 2007-02-09  3:58 tromey at gcc dot gnu dot org
  2007-02-09  3:59 ` [Bug libgcj/30742] " tromey at gcc dot gnu dot org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2007-02-09  3:58 UTC (permalink / raw)
  To: gcc-bugs

ResourceBundle on svn head has a regression.
It doesn't find the correct class loader from the stack.
I'll attach a test case.  To see the bug:

cd Fail
gij -cp main.jar F


-- 
           Summary: ResourceBundle regression
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgcj
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tromey at gcc dot gnu dot org


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
@ 2007-02-09  3:59 ` tromey at gcc dot gnu dot org
  2007-02-09 17:05 ` aph at gcc dot gnu dot org
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2007-02-09  3:59 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from tromey at gcc dot gnu dot org  2007-02-09 03:58 -------
Created an attachment (id=13024)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13024&action=view)
bug tar


-- 


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
  2007-02-09  3:59 ` [Bug libgcj/30742] " tromey at gcc dot gnu dot org
@ 2007-02-09 17:05 ` aph at gcc dot gnu dot org
  2007-02-09 20:50 ` tromey at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: aph at gcc dot gnu dot org @ 2007-02-09 17:05 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from aph at gcc dot gnu dot org  2007-02-09 17:05 -------
I can't reproduce this with trunk or any of the Red Hat test builds.

zebedee:/tmp/Fail $ gij -cp main.jar F
class Z
java.util.PropertyResourceBundle@3169d8b5
zebedee:/tmp/Fail $ gij --version
java version "1.5.0"
gij (GNU libgcj) version 4.1.1 20070202 (Red Hat 4.1.1-55)
zebedee:/tmp/Fail $ ~/gcc/trunk/install/bin/gij -cp main.jar F
class Z
java.util.PropertyResourceBundle@319b98f5
zebedee:/tmp/Fail $ ~/gcc/trunk/install/bin/gij --version     
java version "1.5.0"
gij (GNU libgcj) version 4.3.0 20070208 (experimental)

Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


-- 

aph at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |aph at gcc dot gnu dot org
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |WORKSFORME


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
  2007-02-09  3:59 ` [Bug libgcj/30742] " tromey at gcc dot gnu dot org
  2007-02-09 17:05 ` aph at gcc dot gnu dot org
@ 2007-02-09 20:50 ` tromey at gcc dot gnu dot org
  2007-02-09 21:59 ` tromey at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2007-02-09 20:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from tromey at gcc dot gnu dot org  2007-02-09 20:49 -------
Definitely fails with trunk on x86.


-- 

tromey at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|WORKSFORME                  |


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2007-02-09 20:50 ` tromey at gcc dot gnu dot org
@ 2007-02-09 21:59 ` tromey at gcc dot gnu dot org
  2007-02-09 22:28 ` tromey at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2007-02-09 21:59 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from tromey at gcc dot gnu dot org  2007-02-09 21:59 -------
So far the bug seems to be that we reach the
"CALLER_OF_CALLER" state in stackwalker_trace_fn
with ResourceBundle as the class.
There seems to be one more frame on the stack
than this code expects.


-- 


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2007-02-09 21:59 ` tromey at gcc dot gnu dot org
@ 2007-02-09 22:28 ` tromey at gcc dot gnu dot org
  2007-02-10 11:02 ` aph at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2007-02-09 22:28 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from tromey at gcc dot gnu dot org  2007-02-09 22:28 -------
Created an attachment (id=13028)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13028&action=view)
first patch

This patch fixes the problem for me.
In my run, the GetStackWalkerCallingClass call in
getCallingClass returns ResourceBundle -- but what we
want it ResourceBundle's caller.

This is pretty awful though.  I think perhaps we need a new
API in _Jv_StackTrace for this case.

Also I think there must be something here I am missing,
since I don't see how this code could work on any platform.


-- 


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2007-02-09 22:28 ` tromey at gcc dot gnu dot org
@ 2007-02-10 11:02 ` aph at gcc dot gnu dot org
  2007-02-10 11:50 ` aph at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: aph at gcc dot gnu dot org @ 2007-02-10 11:02 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from aph at gcc dot gnu dot org  2007-02-10 11:01 -------
Definitely a 32-bit only issue:

zorro:/tmp/Fail $
~/gcc/trunk/obj-x86_64-unknown-linux-gnu/x86_64-unknown-linux-gnu/libjava/gij
-cp main.jar F
class Z
java.util.PropertyResourceBundle@317b08f5
zorro:/tmp/Fail $
~/gcc/trunk/obj-x86_64-unknown-linux-gnu/x86_64-unknown-linux-gnu/32/libjava/gij
-cp main.jar F
class Z
Exception in thread "main" java.lang.ExceptionInInitializerError
   at java.lang.Class.initializeClass(natClass.cc:767)
   at java.lang.Class.newInstance(Class.h:733)
   at F.main(F.java:9)
Caused by: java.util.MissingResourceException: Bundle org/test not found for
locale en_US by classloader
gnu.gcj.runtime.SystemClassLoader{urls=[file:main.jar],
parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}
   at java.util.ResourceBundle.getBundle(ResourceBundle.java:410)
   at java.util.ResourceBundle.getBundle(ResourceBundle.java:231)
   at Z.<clinit>(Z.java:6)
   at java.lang.Class.initializeClass(natClass.cc:755)
   ...2 more


-- 

aph at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |aph at gcc dot gnu dot org
                   |dot org                     |
             Status|UNCONFIRMED                 |ASSIGNED
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2007-02-10 11:01:57
               date|                            |


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2007-02-10 11:02 ` aph at gcc dot gnu dot org
@ 2007-02-10 11:50 ` aph at gcc dot gnu dot org
  2007-02-10 14:23 ` aph at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: aph at gcc dot gnu dot org @ 2007-02-10 11:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from aph at gcc dot gnu dot org  2007-02-10 11:50 -------
Created an attachment (id=13029)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13029&action=view)
It's a patch!

This is the correct patch.  The key here is that it is never correct for one
VMStackWalker method to call another, becasue that introduces another level of
nesting.


-- 


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (6 preceding siblings ...)
  2007-02-10 11:50 ` aph at gcc dot gnu dot org
@ 2007-02-10 14:23 ` aph at gcc dot gnu dot org
  2007-02-10 14:36 ` aph at gcc dot gnu dot org
  2007-02-16 21:51 ` tromey at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: aph at gcc dot gnu dot org @ 2007-02-10 14:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from aph at gcc dot gnu dot org  2007-02-10 14:23 -------
Subject: Bug 30742

Author: aph
Date: Sat Feb 10 14:22:54 2007
New Revision: 121798

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=121798
Log:
2007-02-10  Andrew Haley  <aph@redhat.com>

        PR java/30742
        * gnu/classpath/natVMStackWalker.cc (GET_CALLING_CLASS): New.
        (getCallingClass): Call GET_CALLING_CLASS.
        (getCallingClassLoader): Likewise.


Modified:
    trunk/libjava/ChangeLog
    trunk/libjava/gnu/classpath/natVMStackWalker.cc


-- 


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (7 preceding siblings ...)
  2007-02-10 14:23 ` aph at gcc dot gnu dot org
@ 2007-02-10 14:36 ` aph at gcc dot gnu dot org
  2007-02-16 21:51 ` tromey at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: aph at gcc dot gnu dot org @ 2007-02-10 14:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from aph at gcc dot gnu dot org  2007-02-10 14:36 -------
Subject: Bug 30742

Author: aph
Date: Sat Feb 10 14:36:28 2007
New Revision: 121799

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=121799
Log:
2007-02-10  Andrew Haley  <aph@redhat.com>

        PR java/30742
        * gnu/classpath/natVMStackWalker.cc (GET_CALLING_CLASS): New.
        (getCallingClass): Call GET_CALLING_CLASS.
        (getCallingClassLoader): Likewise.


Modified:
    branches/redhat/gcc-4_1-branch-java-merge-20070117/libjava/ChangeLog
   
branches/redhat/gcc-4_1-branch-java-merge-20070117/libjava/gnu/classpath/natVMStackWalker.cc


-- 


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


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

* [Bug libgcj/30742] ResourceBundle regression
  2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
                   ` (8 preceding siblings ...)
  2007-02-10 14:36 ` aph at gcc dot gnu dot org
@ 2007-02-16 21:51 ` tromey at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: tromey at gcc dot gnu dot org @ 2007-02-16 21:51 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from tromey at gcc dot gnu dot org  2007-02-16 21:51 -------
Fix checked in.


-- 

tromey at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |4.3.0


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


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

end of thread, other threads:[~2007-02-16 21:51 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-09  3:58 [Bug libgcj/30742] New: ResourceBundle regression tromey at gcc dot gnu dot org
2007-02-09  3:59 ` [Bug libgcj/30742] " tromey at gcc dot gnu dot org
2007-02-09 17:05 ` aph at gcc dot gnu dot org
2007-02-09 20:50 ` tromey at gcc dot gnu dot org
2007-02-09 21:59 ` tromey at gcc dot gnu dot org
2007-02-09 22:28 ` tromey at gcc dot gnu dot org
2007-02-10 11:02 ` aph at gcc dot gnu dot org
2007-02-10 11:50 ` aph at gcc dot gnu dot org
2007-02-10 14:23 ` aph at gcc dot gnu dot org
2007-02-10 14:36 ` aph at gcc dot gnu dot org
2007-02-16 21:51 ` tromey 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).