bug-gdb
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gdb (5.0 and later) crash on C++ program


From: Petr Ovchenkov
Subject: gdb (5.0 and later) crash on C++ program
Date: Thu, 5 Oct 2000 22:28:38 +0400 (MSD)

gdb (5.0 and later) crash on C++ program that compliled with debug
symbols. The result same (gdb stack below) in any attempt to read info
about symbols, like:

gdb <program>
...
(gdb) break main
<the same crash>

The same without -g compiler option work fine.

uname -a: SunOS icecle 5.7 Generic_106542-10 i86pc i386 i86pc


<begin of listing lost, but it's sense:>
gdb obj/gcc/shared-g/procurator 123456
....

....
[Switching to Thread 4        ]
0xdf730605 in _lwp_sema_wait () from /usr/lib/libc.so.1
(gdb) where
#0  0xdf730605 in _lwp_sema_wait () from /usr/lib/libc.so.1
#1  0xdf79ccf1 in _park () from /usr/lib/libthread.so.1
gdb-internal-error: virtual memory exhausted: can't allocate 671088640 bytes.
An internal GDB error was detected.  This may make make further
debugging unreliable.  Continue this debugging session? (y or n) n

Create a core file containing the current state of GDB? (y or n) y
Abort (core dumped)
4.86u 1.88s 0:31.55 21.3%
> gdb `which gdb` core
GNU gdb 20000803
Copyright 2000 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-pc-solaris2.7"...
Core was generated by `gdb obj/gcc/shared-g/procurator 14759'.
Program terminated with signal 6, Aborted.
Reading symbols from /usr/lib/libcurses.so.1...done.
Loaded symbols for /usr/lib/libcurses.so.1
Reading symbols from /usr/lib/libdl.so.1...done.
Loaded symbols for /usr/lib/libdl.so.1
Reading symbols from /export/home/opt/SUNWspro/lib/libm.so.1...done.
Loaded symbols for /export/home/opt/SUNWspro/lib/libm.so.1
Reading symbols from /usr/lib/libsocket.so.1...done.
Loaded symbols for /usr/lib/libsocket.so.1
Reading symbols from /usr/lib/libc.so.1...done.
Loaded symbols for /usr/lib/libc.so.1
Reading symbols from /usr/lib/libnsl.so.1...done.
Loaded symbols for /usr/lib/libnsl.so.1
Reading symbols from /usr/lib/libmp.so.2...done.
Loaded symbols for /usr/lib/libmp.so.2
Reading symbols from /usr/lib/libthread_db.so.1...done.
Loaded symbols for /usr/lib/libthread_db.so.1
#0  0xdfb7d6c8 in _libc_kill () from /usr/lib/libc.so.1
(gdb) where
#0  0xdfb7d6c8 in _libc_kill () from /usr/lib/libc.so.1
#1  0xdfb41f76 in raise () from /usr/lib/libc.so.1
#2  0xdfb32334 in abort () from /usr/lib/libc.so.1
#3  0x80d6c79 in internal_verror (
    fmt=0x8194a00 "virtual memory exhausted: can't allocate %ld bytes.", 
ap=0x8046374)
    at utils.c:722
#4  0x80d6cba in internal_error () at utils.c:737
#5  0x80d6f8a in nomem (size=671088640) at utils.c:1003
#6  0x80d700a in xmrealloc (md=0x0, ptr=0x9fd7670, size=671088640) at 
utils.c:1049
#7  0x80d706b in xrealloc (ptr=0x9fd7670, size=671088640) at utils.c:1079
#8  0x810d894 in dbx_lookup_type (typenums=0x8046450) at stabsread.c:346
#9  0x810d9b1 in dbx_alloc_type (typenums=0x8046450, objfile=0x82b7b38) at 
stabsread.c:412
#10 0x810fdc4 in read_type (pp=0x80465a0, objfile=0x82b7b38) at stabsread.c:2351
#11 0x8110a88 in read_member_functions (fip=0x80464e0, pp=0x80465a0, 
type=0xa03f008, 
    objfile=0x82b7b38) at stabsread.c:3026
#12 0x8111f77 in read_struct_type (pp=0x80465a0, type=0xa03f008, 
objfile=0x82b7b38)
    at stabsread.c:4055
#13 0x8110494 in read_type (pp=0x80465a0, objfile=0x82b7b38) at stabsread.c:2707
#14 0x810f7bb in define_symbol (valu=0, 
    string=0x83ad785 
"__pack_base:Tt(0,1005)=s4.vf(0,1005):(0,810),0;operator=::(0,1052)=##(0,1053)=&(0,1005);:__as__Q23EDS11__pack_baseRCQ23EDS11__pack_base;2A.;__pack_base::(0,1054)=##(0,1004);:__Q23EDS11__pack_baseRCQ23"...,
 desc=246, type=128, objfile=0x82b7b38) at stabsread.c:1981
#15 0x80ff6b3 in process_one_symbol (type=128, desc=246, valu=0, 
    name=0x83ad785 
"__pack_base:Tt(0,1005)=s4.vf(0,1005):(0,810),0;operator=::(0,1052)=##(0,1053)=&(0,1005);:__as__Q23EDS11__pack_baseRCQ23EDS11__pack_base;2A.;__pack_base::(0,1054)=##(0,1004);:__Q23EDS11__pack_baseRCQ23"...,
 section_offsets=0x82c42f8, objfile=0x82b7b38)
    at dbxread.c:2359
#16 0x80ff053 in read_ofile_symtab (pst=0x83df5a8) at dbxread.c:1787
#17 0x80febee in dbx_psymtab_to_symtab_1 (pst=0x83df5a8) at dbxread.c:1619
#18 0x80fec88 in dbx_psymtab_to_symtab (pst=0x83df5a8) at dbxread.c:1660
#19 0x8094a14 in psymtab_to_symtab (pst=0x83df5a8) at symfile.c:380
#20 0x809092e in find_pc_sect_symtab (pc=134727476, section=0x8280a1c) at 
symtab.c:1445
#21 0x808fce8 in lookup_symbol (name=0x819604e "main", block=0x0, 
namespace=VAR_NAMESPACE, 
    is_a_field_of_this=0x0, symtab=0x0) at symtab.c:704
#22 0x80e0638 in inside_main_func (pc=3749301489) at blockframe.c:122
#23 0x80e0580 in func_frame_chain_valid (chain=3743439276, thisframe=0x81f03bc)
    at blockframe.c:57
#24 0x80e0a33 in get_prev_frame (next_frame=0x81f03bc) at blockframe.c:385
#25 0x80a37bb in backtrace_command_1 (count_exp=0x0, show_locals=0, from_tty=1) 
at stack.c:1142
#26 0x80a39a0 in backtrace_command (arg=0x0, from_tty=1) at stack.c:1216
#27 0x80d3259 in execute_command (p=0x81ede55 "", from_tty=1) at top.c:1519
#28 0x80a5c4e in command_handler (command=0x81ede50 "where") at event-top.c:515
#29 0x80a629d in command_line_handler (rl=0x9bad930 "@ы╨\t") at event-top.c:811
#30 0x815bba2 in rl_callback_read_char () at callback.c:114
#31 0x80a5b37 in stdin_event_handler (error=0, client_data=0x0) at 
event-top.c:422
#32 0x80ea7ba in handle_file_event (event_file_desc=0) at event-loop.c:748
#33 0x80ea22c in process_event () at event-loop.c:383
#34 0x80ea271 in gdb_do_one_event (data=0x0) at event-loop.c:420
#35 0x80d2541 in catch_errors (func=0x80ea248 <gdb_do_one_event>, args=0x0, 
    errstring=0x819aea0 "", mask=6) at top.c:607
#36 0x80ea2a4 in start_event_loop () at event-loop.c:456
#37 0x807c086 in captured_command_loop (data=0x0) at main.c:104
#38 0x80d2541 in catch_errors (func=0x807c06c <captured_command_loop>, 
args=0x0, 
    errstring=0x816c6f1 "", mask=6) at top.c:607
#39 0x807ca23 in captured_main (data=0x8047280) at main.c:749
#40 0x80d2541 in catch_errors (func=0x807c0b0 <captured_main>, args=0x8047280, 
    errstring=0x816c6f1 "", mask=6) at top.c:607
#41 0x807ca4f in main (argc=3, argv=0x80472bc) at main.c:761
(gdb) print *(int *)0x8046450
$3 = 0
(gdb) print *((int *)0x8046450 + 1)
$5 = 147483648
(gdb) 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]