Fail to debug openjdk7 with gdb

Lokesh Gidra lokesh.gidra at yahoo.com
Thu Nov 3 18:08:50 UTC 2011


Thanks a lot. It worked with what you said.


Lokesh


>________________________________
>From: John Cuthbertson <john.cuthbertson at oracle.com>
>To: Lokesh Gidra <lokesh.gidra at yahoo.com>
>Cc: hotspot_gc <hotspot-gc-dev at openjdk.java.net>
>Sent: Thursday, 3 November 2011 5:47 PM
>Subject: Re: Fail to debug openjdk7 with gdb
>
>
>Hi Lokesh,
>
>The Hotspot JVM uses certain signals for it's own use and SIGSEGV is
one such signal. The code below is generating the signal to act as a
pseudo memory barrier. SIGSEGV can also generated by JIT generated code
as a null check. To continue debugging use the gdb command:
>
>> handle SIGSEGV nostop noprint
>
>I think the other signals the JVM can legitimately generate are SIGBUS
and SIGFPE.
>
>Hope this helps.
>
>JohnC
>
>On 11/03/11 08:56, Lokesh Gidra wrote: 
>Hi,
>>
>>
>>I am trying to debug openjdk7 using gdb, and everytime it fails
with the following trace:
>>
>>
>>Program received signal SIGSEGV, Segmentation fault.
>>[Switching to Thread 0x7fffe1df7700 (LWP 14211)]
>>0x00007ffff634bf60 in os::write_memory_serialize_page
(thread=0x7fffe81d9800)
>>    at
/home/lokesh/code/phd_openjdk7/hotspot/src/share/vm/runtime/os.hpp:319
>>319        *(volatile int32_t
*)((uintptr_t)_mem_serialize_page+page_offset) = 1;
>>(gdb) 
>>
>>
>>
>>Running the same build without gdb works fine. Also, there are
no changes made by me. The code is freshly downloaded from the website.
Can someone please point out what could be going wrong.
>>
>>
>>
>>
>>Thanks in advance,
>>
>>
>>Best Regards,
>>Lokesh
>
>
>



More information about the hotspot-gc-dev mailing list