This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug cli/19304] New: GDB crashed freezes on autocomplete
- From: "szotsaki at gmail dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Sun, 29 Nov 2015 19:54:41 +0000
- Subject: [Bug cli/19304] New: GDB crashed freezes on autocomplete
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=19304
Bug ID: 19304
Summary: GDB crashed freezes on autocomplete
Product: gdb
Version: 7.9
Status: NEW
Severity: normal
Priority: P2
Component: cli
Assignee: unassigned at sourceware dot org
Reporter: szotsaki at gmail dot com
Target Milestone: ---
I paused my program run (Ctrl+C) then I started recording for backstepping.
Then I used <TAB> for autocompletion. Somewhere at "back<TAB>" GDB froze,
didn't respond to anything and just ate memory all the time (in half a minute
its consumption went up to 5 GB).
I have a complete core file in 700 MB size, if you're interested.
Version: 7.9.1.
The commands I issued:
(gdb) record
(gdb) c
Continuing.
[Thread 0x7fff8cab7700 (LWP 30462) exited]
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fff966f5700 (LWP 30422)]
0x00000000400a0d71 in ?? ()
(gdb) next
next nexti
(gdb) backtrace <tab> ^C^C^C^C^C^C^C^C^C^CKilled
The backtrace:
#0 bfd_getl32 (p=0x7faa1629487c) at ../../bfd/libbfd.c:549
#1 0x000000000069da76 in read_initial_length (buf=buf@entry=0x7faa1629487c
"\267\311\001", bytes_read=bytes_read@entry=0x7fff124ebe4c, abfd=0xd1d2550) at
../../gdb/dwarf2read.c:16569
#2 0x000000000069e1e4 in read_comp_unit_head
(cu_header=cu_header@entry=0xd4418458, info_ptr=info_ptr@entry=0x7faa1629487c
"\267\311\001", abfd=0xd1d2550) at ../../gdb/dwarf2read.c:4292
#3 0x00000000006a076e in read_and_check_comp_unit_head (header=0xd4418458,
section=section@entry=0x136d9a28,
abbrev_section=abbrev_section@entry=0x136d9a50, info_ptr=0x7faa1629487c
"\267\311\001", is_debug_types_section=is_debug_types_section@entry=0) at
../../gdb/dwarf2read.c:4378
#4 0x00000000006ab5fd in init_cutu_and_read_dies (this_cu=0x14300860,
abbrev_table=abbrev_table@entry=0x0, use_existing_cu=use_existing_cu@entry=1,
keep=keep@entry=1, die_reader_func=die_reader_func@entry=0x6ae7a0
<load_full_comp_unit_reader>, data=data@entry=0x7fff124ebfcc) at
../../gdb/dwarf2read.c:5493
#5 0x00000000006ababa in load_full_comp_unit (this_cu=<optimized out>,
pretend_language=language_minimal) at ../../gdb/dwarf2read.c:7707
#6 0x00000000006ade22 in load_cu (per_cu=0x14300860) at
../../gdb/dwarf2read.c:2648
#7 0x00000000006b8d95 in dw2_do_instantiate_symtab (per_cu=0x14300860) at
../../gdb/dwarf2read.c:2674
#8 0x00000000006b9f27 in psymtab_to_symtab_1 (pst=pst@entry=0x13983dc0) at
../../gdb/dwarf2read.c:7634
#9 0x00000000006ba048 in dwarf2_read_symtab (self=0x13983dc0,
objfile=0x11de28a0) at ../../gdb/dwarf2read.c:7414
#10 0x0000000000619fe1 in psymtab_to_symtab (objfile=objfile@entry=0x11de28a0,
pst=pst@entry=0x13983dc0) at ../../gdb/psymtab.c:788
#11 0x000000000061b24f in psym_expand_symtabs_matching (objfile=0x11de28a0,
file_matcher=0x0, symbol_matcher=0x612670 <symbol_completion_matcher>,
kind=ALL_DOMAIN, data=0x7fff124ec1d0) at ../../gdb/psymtab.c:1454
#12 0x000000000062256a in expand_symtabs_matching
(file_matcher=file_matcher@entry=0x0,
symbol_matcher=symbol_matcher@entry=0x612670 <symbol_completion_matcher>,
kind=kind@entry=ALL_DOMAIN, data=data@entry=0x7fff124ec1d0) at
../../gdb/symfile.c:3959
#13 0x00000000006184db in default_make_symbol_completion_list_break_on
(text=0x7fff124ec26a "", word=0x7fff124ec26a "", break_on=<optimized out>,
code=TYPE_CODE_UNDEF) at ../../gdb/symtab.c:4627
#14 0x0000000000653c2b in complete_line_internal (text=text@entry=0x1e37b410
"", line_buffer=line_buffer@entry=0x225fe80 "backtrace ", point=point@entry=10,
reason=reason@entry=handle_completions) at ../../gdb/completer.c:777
#15 0x00000000006546c9 in complete_line (point=10, line_buffer=0x225fe80
"backtrace ", text=0x1e37b410 "") at ../../gdb/completer.c:799
#16 line_completion_function (point=10, line_buffer=0x225fe80 "backtrace ",
matches=<optimized out>, text=<optimized out>) at ../../gdb/completer.c:939
#17 readline_line_completion_function (text=0x1e37b410 "", matches=<optimized
out>) at ../../gdb/completer.c:103
#18 0x00007faa3aeb39f1 in rl_completion_matches (text=text@entry=0x1e37b410 "",
entry_function=entry_function@entry=0x654670
<readline_line_completion_function>) at ../complete.c:1992
#19 0x00007faa3aeb3ae5 in gen_completion_matches (text=text@entry=0x1e37b410
"", start=start@entry=10, end=end@entry=10, our_func=our_func@entry=0x654670
<readline_line_completion_function>, found_quote=<optimized out>,
quote_char=<optimized out>) at ../complete.c:1075
#20 0x00007faa3aeb3c14 in rl_complete_internal (what_to_do=9) at
../complete.c:1830
#21 0x00007faa3aeabc2e in _rl_dispatch_subseq (key=9, map=<optimized out>,
got_subseq=0) at ../readline.c:836
#22 0x00007faa3aeabec1 in _rl_dispatch (key=<optimized out>, map=<optimized
out>) at ../readline.c:782
#23 0x00007faa3aeabf72 in readline_internal_char () at ../readline.c:610
#24 0x00007faa3aec0ecd in rl_callback_read_char () at ../callback.c:201
#25 0x0000000000652bb9 in rl_callback_read_char_wrapper (client_data=<optimized
out>) at ../../gdb/event-top.c:172
#26 0x0000000000652c03 in stdin_event_handler (error=<optimized out>,
client_data=0x0) at ../../gdb/event-top.c:437
#27 0x0000000000651a95 in gdb_wait_for_event (block=block@entry=1) at
../../gdb/event-loop.c:772
#28 0x0000000000651d92 in gdb_do_one_event () at ../../gdb/event-loop.c:309
#29 0x0000000000651e17 in start_event_loop () at ../../gdb/event-loop.c:334
#30 0x000000000064b573 in captured_command_loop (data=data@entry=0x0) at
../../gdb/main.c:322
#31 0x0000000000648b85 in catch_errors (func=func@entry=0x64b560
<captured_command_loop>, func_args=func_args@entry=0x0,
errstring=errstring@entry=0x8b2cbc "", mask=mask@entry=RETURN_MASK_ALL) at
../../gdb/exceptions.c:237
#32 0x000000000064c376 in captured_main (data=data@entry=0x7fff124ec6e0) at
../../gdb/main.c:1243
#33 0x0000000000648b85 in catch_errors (func=func@entry=0x64bb30
<captured_main>, func_args=func_args@entry=0x7fff124ec6e0,
errstring=errstring@entry=0x8b2cbc "", mask=mask@entry=RETURN_MASK_ALL) at
../../gdb/exceptions.c:237
#34 0x000000000064ceab in gdb_main (args=args@entry=0x7fff124ec6e0) at
../../gdb/main.c:1252
#35 0x00000000004709b5 in main (argc=<optimized out>, argv=<optimized out>) at
../../gdb/gdb.c:32
Full backtrace:
#0 bfd_getl32 (p=0x7faa1629487c) at ../../bfd/libbfd.c:549
addr = 0x7faa1629487c "\267\311\001"
v = <optimized out>
#1 0x000000000069da76 in read_initial_length (buf=buf@entry=0x7faa1629487c
"\267\311\001", bytes_read=bytes_read@entry=0x7fff124ebe4c, abfd=0xd1d2550) at
../../gdb/dwarf2read.c:16569
length = <optimized out>
#2 0x000000000069e1e4 in read_comp_unit_head
(cu_header=cu_header@entry=0xd4418458, info_ptr=info_ptr@entry=0x7faa1629487c
"\267\311\001", abfd=0xd1d2550) at ../../gdb/dwarf2read.c:4292
signed_addr = <optimized out>
bytes_read = 0
#3 0x00000000006a076e in read_and_check_comp_unit_head (header=0xd4418458,
section=section@entry=0x136d9a28,
abbrev_section=abbrev_section@entry=0x136d9a50, info_ptr=0x7faa1629487c
"\267\311\001", is_debug_types_section=is_debug_types_section@entry=0) at
../../gdb/dwarf2read.c:4378
beg_of_comp_unit = 0x7faa1629487c "\267\311\001"
abfd = <optimized out>
#4 0x00000000006ab5fd in init_cutu_and_read_dies (this_cu=0x14300860,
abbrev_table=abbrev_table@entry=0x0, use_existing_cu=use_existing_cu@entry=1,
keep=keep@entry=1, die_reader_func=die_reader_func@entry=0x6ae7a0
<load_full_comp_unit_reader>, data=data@entry=0x7fff124ebfcc) at
../../gdb/dwarf2read.c:5493
objfile = <optimized out>
section = 0x136d9a28
abfd = 0xd1d2550
cu = 0xd4418450
begin_info_ptr = 0x7faa1629487c "\267\311\001"
info_ptr = 0x7faa1629487c "\267\311\001"
reader = {abfd = 0x100000000, cu = 0x684ee0
<end_symtab_with_blockvector+1360>, dwo_file = 0x100000000, die_section =
0x6ad498 <dwarf2_record_block_ranges+392>, buffer = 0x100000000
"P\235\026\023", buffer_end = 0x7faa39785620 <main_arena> "", comp_dir = 0x18
<error: Cannot access memory at address 0x18>}
comp_unit_die = 0x46f95b90
has_children = 32682
attr = <optimized out>
cleanups = 0xdea17670
free_cu_cleanup = <optimized out>
sig_type = 0x0
rereading_dwo_cu = <optimized out>
__PRETTY_FUNCTION__ = "init_cutu_and_read_dies"
#5 0x00000000006ababa in load_full_comp_unit (this_cu=<optimized out>,
pretend_language=language_minimal) at ../../gdb/dwarf2read.c:7707
No locals.
#6 0x00000000006ade22 in load_cu (per_cu=0x14300860) at
../../gdb/dwarf2read.c:2648
No locals.
#7 0x00000000006b8d95 in dw2_do_instantiate_symtab (per_cu=0x14300860) at
../../gdb/dwarf2read.c:2674
back_to = 0x1c75a290
#8 0x00000000006b9f27 in psymtab_to_symtab_1 (pst=pst@entry=0x13983dc0) at
../../gdb/dwarf2read.c:7634
per_cu = <optimized out>
i = <optimized out>
#9 0x00000000006ba048 in dwarf2_read_symtab (self=0x13983dc0,
objfile=0x11de28a0) at ../../gdb/dwarf2read.c:7414
No locals.
#10 0x0000000000619fe1 in psymtab_to_symtab (objfile=objfile@entry=0x11de28a0,
pst=pst@entry=0x13983dc0) at ../../gdb/psymtab.c:788
back_to = 0x2537010
#11 0x000000000061b24f in psym_expand_symtabs_matching (objfile=0x11de28a0,
file_matcher=0x0, symbol_matcher=0x612670 <symbol_completion_matcher>,
kind=ALL_DOMAIN, data=0x7fff124ec1d0) at ../../gdb/psymtab.c:1454
ps = 0x13983dc0
#12 0x000000000062256a in expand_symtabs_matching
(file_matcher=file_matcher@entry=0x0,
symbol_matcher=symbol_matcher@entry=0x612670 <symbol_completion_matcher>,
kind=kind@entry=ALL_DOMAIN, data=data@entry=0x7fff124ec1d0) at
../../gdb/symfile.c:3959
objfile = 0x11de28a0
#13 0x00000000006184db in default_make_symbol_completion_list_break_on
(text=0x7fff124ec26a "", word=0x7fff124ec26a "", break_on=<optimized out>,
code=TYPE_CODE_UNDEF) at ../../gdb/symtab.c:4627
sym = <optimized out>
cust = <optimized out>
msymbol = <optimized out>
objfile = <optimized out>
b = <optimized out>
surrounding_static_block = <optimized out>
surrounding_global_block = <optimized out>
iter = {d = {compunit_symtab = 0x1ae1d50, block = 0x1ae1d50}, idx = 1,
which = STATIC_BLOCK, dict_iter = {dict = 0x7fff124ec1e4, index = 307151332,
current = 0x100000001}}
sym_text = 0x7fff124ec26a ""
sym_text_len = 0
datum = {sym_text = 0x7fff124ec26a "", sym_text_len = 0, text =
0x7fff124ec26a "", word = 0x7fff124ec26a ""}
back_to = 0x904600 <sentinel_cleanup>
__PRETTY_FUNCTION__ = "default_make_symbol_completion_list_break_on"
#14 0x0000000000653c2b in complete_line_internal (text=text@entry=0x1e37b410
"", line_buffer=line_buffer@entry=0x225fe80 "backtrace ", point=point@entry=10,
reason=reason@entry=handle_completions) at ../../gdb/completer.c:777
list = 0x0
tmp_command = 0x7fff124ec260 "backtrace "
p = 0x7fff124ec26a ""
ignore_help_classes = 1
word = 0x7fff124ec26a ""
c = 0x1abdf90
result_list = 0x1ae1d50
#15 0x00000000006546c9 in complete_line (point=10, line_buffer=0x225fe80
"backtrace ", text=0x1e37b410 "") at ../../gdb/completer.c:799
No locals.
#16 line_completion_function (point=10, line_buffer=0x225fe80 "backtrace ",
matches=<optimized out>, text=<optimized out>) at ../../gdb/completer.c:939
output = 0x0
list = 0x0
index = 0
#17 readline_line_completion_function (text=0x1e37b410 "", matches=<optimized
out>) at ../../gdb/completer.c:103
No locals.
#18 0x00007faa3aeb39f1 in rl_completion_matches (text=text@entry=0x1e37b410 "",
entry_function=entry_function@entry=0x654670
<readline_line_completion_function>) at ../complete.c:1992
match_list_size = 10
match_list = 0x15d96670
matches = 0
string = <optimized out>
#19 0x00007faa3aeb3ae5 in gen_completion_matches (text=text@entry=0x1e37b410
"", start=start@entry=10, end=end@entry=10, our_func=our_func@entry=0x654670
<readline_line_completion_function>, found_quote=<optimized out>,
quote_char=<optimized out>) at ../complete.c:1075
matches = <optimized out>
#20 0x00007faa3aeb3c14 in rl_complete_internal (what_to_do=9) at
../complete.c:1830
matches = 0x7faa3b0da340 <rl_display_fixed>
our_func = <optimized out>
start = 10
end = 10
delimiter = 0
found_quote = 0
i = <optimized out>
nontrivial_lcd = <optimized out>
text = 0x1e37b410 ""
saved_line_buffer = 0x4e9ab80 "backtrace "
quote_char = 0 '\000'
tlen = <optimized out>
mlen = <optimized out>
#21 0x00007faa3aeabc2e in _rl_dispatch_subseq (key=9, map=<optimized out>,
got_subseq=0) at ../readline.c:836
r = 0
newkey = <optimized out>
func = <optimized out>
cxt = <optimized out>
#22 0x00007faa3aeabec1 in _rl_dispatch (key=<optimized out>, map=<optimized
out>) at ../readline.c:782
No locals.
#23 0x00007faa3aeabf72 in readline_internal_char () at ../readline.c:610
lastc = 9
eof_found = 0
c = <optimized out>
code = <optimized out>
lk = 0
#24 0x00007faa3aec0ecd in rl_callback_read_char () at ../callback.c:201
line = <optimized out>
eof = <optimized out>
jcode = <optimized out>
olevel = {{__jmpbuf = {140369111917648, 4066462856272357048,
140733500549562, 0, 140733500540904, 26490112, 4090580088538474168,
4066461988160612024}, __mask_was_saved = 1, __saved_mask = {__val =
{4294967296, 0 <repeats 15 times>}}}}
#25 0x0000000000652bb9 in rl_callback_read_char_wrapper (client_data=<optimized
out>) at ../../gdb/event-top.c:172
No locals.
#26 0x0000000000652c03 in stdin_event_handler (error=<optimized out>,
client_data=0x0) at ../../gdb/event-top.c:437
No locals.
#27 0x0000000000651a95 in gdb_wait_for_event (block=block@entry=1) at
../../gdb/event-loop.c:772
mask = <optimized out>
file_ptr = <optimized out>
num_found = 0
i = <optimized out>
#28 0x0000000000651d92 in gdb_do_one_event () at ../../gdb/event-loop.c:309
event_source_head = 2
current = 3
#29 0x0000000000651e17 in start_event_loop () at ../../gdb/event-loop.c:334
ex = {reason = 0, error = GDB_NO_ERROR, message = 0x0}
result = 0
#30 0x000000000064b573 in captured_command_loop (data=data@entry=0x0) at
../../gdb/main.c:322
No locals.
#31 0x0000000000648b85 in catch_errors (func=func@entry=0x64b560
<captured_command_loop>, func_args=func_args@entry=0x0,
errstring=errstring@entry=0x8b2cbc "", mask=mask@entry=RETURN_MASK_ALL) at
../../gdb/exceptions.c:237
val = 0
exception = {reason = 0, error = GDB_NO_ERROR, message = 0x0}
saved_uiout = 0x1e93c20
#32 0x000000000064c376 in captured_main (data=data@entry=0x7fff124ec6e0) at
../../gdb/main.c:1243
context = 0x7fff124ec6e0
argc = 2
argv = 0x7fff124ec7e8
quiet = 0
set_args = 0
inhibit_home_gdbinit = 0
symarg = <optimized out>
execarg = <optimized out>
pidarg = 0x0
corearg = <optimized out>
pid_or_core_arg = 0x0
cdarg = 0x0
ttyarg = 0x0
python_script = <optimized out>
print_help = 0
print_version = 0
print_configuration = 0
cmdarg_vec = 0x0
cmdarg_p = 0x0
dirarg = <optimized out>
dirsize = <optimized out>
ndir = 1
system_gdbinit = 0x1bb5af0 "/etc/gdbinit"
home_gdbinit = 0x0
local_gdbinit = 0x0
i = <optimized out>
save_auto_load = 1
objfile = <optimized out>
pre_stat_chain = 0x904600 <sentinel_cleanup>
#33 0x0000000000648b85 in catch_errors (func=func@entry=0x64bb30
<captured_main>, func_args=func_args@entry=0x7fff124ec6e0,
errstring=errstring@entry=0x8b2cbc "", mask=mask@entry=RETURN_MASK_ALL) at
../../gdb/exceptions.c:237
val = 0
exception = {reason = 0, error = GDB_NO_ERROR, message = 0x0}
saved_uiout = 0xdf3b00 <def_uiout>
#34 0x000000000064ceab in gdb_main (args=args@entry=0x7fff124ec6e0) at
../../gdb/main.c:1252
No locals.
#35 0x00000000004709b5 in main (argc=<optimized out>, argv=<optimized out>) at
../../gdb/gdb.c:32
args = {argc = 2, argv = 0x7fff124ec7e8, interpreter_p = 0x898764
"console"}
--
You are receiving this mail because:
You are on the CC list for the bug.