How to debug hotspot integrated with java codes
Colin(Du Li)
dawn2004 at gmail.com
Mon Dec 15 10:55:44 PST 2008
The error message is below:
Exception in thread "main" java.lang.NoClassDefFoundError:
Caused by: java.lang.ClassNotFoundException:
at java.net.URLClassLoader$1.run(URLClassLoader.java:221)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:209)
at java.lang.ClassLoader.loadClass(ClassLoader.java:324)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:269)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:337)
I don't think it give much hint.
What I did is just move some object in heap to a new location, then, this
kind of exceptions are always thrown.
Thanks.
NeoJia wrote:
>
> What is the error message?
>
> Thanks,
> Neo
>
> ---------
> I would remember that if researchers were not ambitious
> probably today we haven't the technology we are using!
>
> On Dec 13, 2008, at 9:27 AM, Karen Kinnear <Karen.Kinnear at Sun.COM>
> wrote:
>
>> Colin,
>>
>> For this specific problem, you can also try vm command line flags:
>> -XX:+TraceClassResolution -XX:+TraceClassLoading
>>
>> You might get a bit more information about what exception you get
>> when trying to load
>> a class.
>>
>> hope this helps,
>> Karen
>>
>> On Dec 12, 2008, at 6:15 PM, Xiaobin Lu wrote:
>>
>>> Refer to
>>> http://developers.sun.com/sunstudio/overview/topics/debug_index.html
>>> to find more details on how to use Sun Studio which is available
>>> on Linux to debug mixed Java and native code.
>>>
>>> -Xiaobin
>>>
>>> Colin(Du Li) wrote:
>>>> Hi, guys.
>>>>
>>>> Now I'm debugging Hotspot. I'm using GDB. When I debug the source
>>>> codes
>>>> written in c++, it's fine. But if the VM has launched, I cannot
>>>> trace into
>>>> the source codes written in java. e.g. When I find Hotspot cannot
>>>> load some
>>>> class, and I wanna step into the class java.lang.ClassLoader , I
>>>> don't know
>>>> how to trace it. Apparently, I cannot do that with GDB. Can you
>>>> guys give me some suggestion for debug in this situation?
>>>> I spend several days on this problem, and really need some help
>>>> on the
>>>> debug things.
>>>>
>>>> Thanks a lot in advance!!
>>>>
>>>>
>>>>
>>>>
>>>
>>
>
>
--
View this message in context: http://www.nabble.com/How-to-debug-hotspot-integrated-with-java-codes-tp20984867p21019434.html
Sent from the OpenJDK Hotspot Virtual Machine mailing list archive at Nabble.com.
More information about the hotspot-dev
mailing list