Bug 161401
| Summary: | gdb fails when a break point is placed inside a library. | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Gilboa Davara <gilboad> | ||||||||||
| Component: | gdb | Assignee: | Jan Kratochvil <jan.kratochvil> | ||||||||||
| Status: | CLOSED INSUFFICIENT_DATA | QA Contact: | |||||||||||
| Severity: | high | Docs Contact: | |||||||||||
| Priority: | medium | ||||||||||||
| Version: | 4 | CC: | cagney, paul+rhbugz | ||||||||||
| Target Milestone: | --- | ||||||||||||
| Target Release: | --- | ||||||||||||
| Hardware: | x86_64 | ||||||||||||
| OS: | Linux | ||||||||||||
| URL: | gdb SIGSEGV at dwarf2_read_section | ||||||||||||
| Whiteboard: | |||||||||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||||||||
| Doc Text: | Story Points: | --- | |||||||||||
| Clone Of: | Environment: | ||||||||||||
| Last Closed: | 2008-02-26 05:14:38 UTC | Type: | --- | ||||||||||
| Regression: | --- | Mount Type: | --- | ||||||||||
| Documentation: | --- | CRM: | |||||||||||
| Verified Versions: | Category: | --- | |||||||||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||||||||
| Embargoed: | |||||||||||||
| Attachments: |
|
||||||||||||
|
Description
Gilboa Davara
2005-06-22 21:38:01 UTC
Created attachment 115835 [details]
Test case makefile
Created attachment 115836 [details]
Library test file.
Created attachment 115837 [details]
Main test file (main())
Test case working just fine on FC3/i386. Oh... Forgot to add (in Steps to Reproduce:) 2. export LD_LIBRARY_PATH=. Checked again with latest kernel/gcc. Same crash. gcc-4.0.1-4.fc4 kernel-smp-2.6.12-1.1398_FC4 I get this too, the below is using the 'aspathtest' programme from the 'quagga'
package (upstream version, not currently in FC I think):
#0 0x00000000004f6562 in process_die (die=Variable "die" is not available.
)
at ../../gdb-6.3/gdb/dwarf2read.c:8861
8861 if (IS_ABSOLUTE_PATH (fe->name))
(gdb) bt
#0 0x00000000004f6562 in process_die (die=Variable "die" is not available.
)
at ../../gdb-6.3/gdb/dwarf2read.c:8861
#1 0x00000000004fa562 in psymtab_to_symtab_1 (pst=Variable "pst" is not available.
)
at ../../gdb-6.3/gdb/dwarf2read.c:2598
#2 0x00000000004fa69d in dwarf2_psymtab_to_symtab (pst=0x883810)
at ../../gdb-6.3/gdb/dwarf2read.c:2334
#3 0x00000000004b2a0a in psymtab_to_symtab (pst=0x883810)
at ../../gdb-6.3/gdb/symfile.c:278
#4 0x00000000004aef5e in lookup_symbol_aux_psymtabs (block_index=0,
name=0x7fffffcb9750 "aspath_cmp_left", linkage_name=0x0,
domain=VAR_DOMAIN, symtab=0x0) at ../../gdb-6.3/gdb/symtab.c:1276
#5 0x00000000004af233 in lookup_symbol (
name=0x7fffffcb9750 "aspath_cmp_left", block=0x7fffffcb9750,
domain=VAR_DOMAIN, is_a_field_of_this=0x0, symtab=0x0)
at ../../gdb-6.3/gdb/symtab.c:1118
#6 0x0000000000512b7f in find_imps (symtab=0x0, block=0x0,
method=0x7bf006 "aspath_cmp_left", syms=0x0, nsym=0x7fffffcb986c,
ndebug=0x7fffffcb9868) at ../../gdb-6.3/gdb/objc-lang.c:1436
#7 0x00000000004b92a0 in decode_objc (argptr=0x7fffffcb9cb8, funfirstline=1,
file_symtab=0x0, canonical=0x7fffffcb9d60, saved_arg=Variable "saved_arg" is
not available.
)
at ../../gdb-6.3/gdb/linespec.c:1322
#8 0x00000000004ba4d9 in decode_line_1 (argptr=0x7fffffcb9cb8,
funfirstline=1, default_symtab=0x0, default_line=0,
---Type <return> to continue, or q <return> to quit---
canonical=0x7fffffcb9d60, not_found_ptr=0x7fffffcb9d7c)
at ../../gdb-6.3/gdb/linespec.c:947
#9 0x000000000049174e in parse_breakpoint_sals (address=0x7fffffcb9cb8,
sals=0x7fffffcb9d40, addr_string=0x7fffffcb9d60,
not_found_ptr=0x7fffffcb9d7c) at ../../gdb-6.3/gdb/breakpoint.c:5208
#10 0x00000000004918b4 in do_captured_parse_breakpoint (ui=Variable "ui" is not
available.
)
at ../../gdb-6.3/gdb/breakpoint.c:5300
#11 0x000000000044678c in catcher (
func=0x491899 <do_captured_parse_breakpoint>, func_uiout=0x810250,
func_args=0x7fffffcb9d20, func_val=0x7fffffcb9c34,
func_caught=0x7fffffcb9c30, errstring=Variable "errstring" is not available.
) at ../../gdb-6.3/gdb/top.c:431
#12 0x000000000044684f in catch_exceptions_with_msg (uiout=Variable "uiout" is
not available.
)
at ../../gdb-6.3/gdb/top.c:506
#13 0x0000000000491bfe in break_command_1 (arg=0x7bf006 "aspath_cmp_left",
flag=0, from_tty=1, pending_bp=0x0) at ../../gdb-6.3/gdb/breakpoint.c:5346
#14 0x0000000000446c5a in execute_command (p=0x7bf014 "t", from_tty=1)
at ../../gdb-6.3/gdb/top.c:733
#15 0x00000000004cd554 in command_handler (
command=0x7bf000 "break aspath_cmp_left")
at ../../gdb-6.3/gdb/event-top.c:500
#16 0x00000000004cda0c in command_line_handler (
rl=0x8305c0 "break aspath_cmp_left") at ../../gdb-6.3/gdb/event-top.c:793
#17 0x00000000005a690a in rl_callback_read_char ()
---Type <return> to continue, or q <return> to quit---
at ../../gdb-6.3/readline/callback.c:123
#18 0x00000000004cce99 in rl_callback_read_char_wrapper (client_data=Variable
"client_data" is not available.
)
at ../../gdb-6.3/gdb/event-top.c:166
#19 0x00000000004cc18a in process_event ()
at ../../gdb-6.3/gdb/event-loop.c:334
#20 0x00000000004cca40 in gdb_do_one_event (data=Variable "data" is not available.
)
at ../../gdb-6.3/gdb/event-loop.c:371
#21 0x000000000044678c in catcher (func=0x4468aa <do_catch_errors>,
func_uiout=0x810250, func_args=0x7fffffcba040, func_val=0x7fffffcba05c,
func_caught=0x7fffffcba058, errstring=Variable "errstring" is not available.
) at ../../gdb-6.3/gdb/top.c:431
#22 0x00000000004468f7 in catch_errors (func=Variable "func" is not available.
) at ../../gdb-6.3/gdb/top.c:536
#23 0x0000000000480b44 in tui_command_loop (data=Variable "data" is not available.
)
at ../../gdb-6.3/gdb/tui/tui-interp.c:150
#24 0x000000000043da09 in captured_command_loop (data=Variable "data" is not
available.
)
at ../../gdb-6.3/gdb/main.c:91
#25 0x000000000044678c in catcher (func=0x4468aa <do_catch_errors>,
func_uiout=0x810250, func_args=0x7fffffcba200, func_val=0x7fffffcba21c,
func_caught=0x7fffffcba218, errstring=Variable "errstring" is not available.
) at ../../gdb-6.3/gdb/top.c:431
#26 0x00000000004468f7 in catch_errors (func=Variable "func" is not available.
) at ../../gdb-6.3/gdb/top.c:536
#27 0x000000000043e105 in captured_main (data=Variable "data" is not available.
) at ../../gdb-6.3/gdb/main.c:801
#28 0x000000000044678c in catcher (func=0x4468aa <do_catch_errors>,
func_uiout=0x7977e0, func_args=0x7fffffcba580, func_val=0x7fffffcba59c,
func_caught=0x7fffffcba598, errstring=Variable "errstring" is not available.
) at ../../gdb-6.3/gdb/top.c:431
---Type <return> to continue, or q <return> to quit---
#29 0x00000000004468f7 in catch_errors (func=Variable "func" is not available.
) at ../../gdb-6.3/gdb/top.c:536
#30 0x000000000043da59 in gdb_main (args=Variable "args" is not available.
) at ../../gdb-6.3/gdb/main.c:810
#31 0x000000000043d9ee in main (argc=Variable "argc" is not available.
) at ../../gdb-6.3/gdb/gdb.c:35
Bug still not assigned :/ Updated to latest version (gdb-6.3.0.0-1.84) still doesn't work. Here's a recent gdb-debuginfo crash dump. $ gdb gdb gdb) r ./test [snip] gdb) b TestFunc gdb) btFunction "TestFunc" not defined. Make breakpoint pending on future shared library load? (y or [n]) y Breakpoint 1 (TestFunc) pending. (gdb) r Starting program: /home/gilboa/Logs/gdb/test Detaching after fork from child process 7905. Detaching after fork from child process 7906. [Thread debugging using libthread_db enabled] [New Thread 46912497358656 (LWP 7905)] Program received signal SIGSEGV, Segmentation fault. 0x00000000004f6852 in process_die (die=Variable "die" is not available.) at ../../gdb-6.3/gdb/dwarf2read.c:8863 8863 if (IS_ABSOLUTE_PATH (fe->name)) (gdb) bt #0 0x00000000004f6852 in process_die (die=Variable "die" is not available.) at ../../gdb-6.3/gdb/dwarf2read.c:8863 #1 0x00000000004fa85e in psymtab_to_symtab_1 (pst=Variable "pst" is not available.) at ../../gdb-6.3/gdb/dwarf2read.c:2600 #2 0x00000000004fa99b in dwarf2_psymtab_to_symtab (pst=0xa9c420) at ../../gdb-6.3/gdb/dwarf2read.c:2336 #3 0x00000000004b2cba in psymtab_to_symtab (pst=0xa9c420) at ../../gdb-6.3/gdb/symfile.c:279 #4 0x00000000004af1fe in lookup_symbol_aux_psymtabs (block_index=0, name=0x7ffffffd63c0 "TestFunc", linkage_name=0x0, domain=VAR_DOMAIN, symtab=0x0)at ../../gdb-6.3/gdb/symtab.c:1276 #5 0x00000000004af4d3 in lookup_symbol (name=0x7ffffffd63c0 "TestFunc", block=0x7ffffffd63c0, domain=VAR_DOMAIN, is_a_field_of_this=0x0, symtab=0x0) at ../../gdb-6.3/gdb/symtab.c:1118 #6 0x0000000000512e6f in find_imps (symtab=0x0, block=0x0, method=0x94adf0 "TestFunc", syms=0x0, nsym=0x7ffffffd64dc, ndebug=0x7ffffffd64d8) at ../../gdb-6.3/gdb/objc-lang.c:1436 #7 0x00000000004b9550 in decode_objc (argptr=0x7ffffffd6928, funfirstline=1, file_symtab=0x0, canonical=0x7ffffffd69d0, saved_arg=Variable "saved_arg" is not available.) at ../../gdb-6.3/gdb/linespec.c:1322 #8 0x00000000004ba7a9 in decode_line_1 (argptr=0x7ffffffd6928, funfirstline=1, default_symtab=0x0, default_line=0, canonical=0x7ffffffd69d0, not_found_ptr=0x7ffffffd69ec) at ../../gdb-6.3/gdb/linespec.c:947 #9 0x00000000004919fe in parse_breakpoint_sals (address=0x7ffffffd6928, sals=0x7ffffffd69b0, addr_string=0x7ffffffd69d0, not_found_ptr=0x7ffffffd69ec) at ../../gdb-6.3/gdb/breakpoint.c:5208 #10 0x0000000000491b64 in do_captured_parse_breakpoint (ui=Variable "ui" is not available.) at ../../gdb-6.3/gdb/breakpoint.c:5300 #11 0x00000000004468cc in catcher (func=0x491b49 <do_captured_parse_breakpoint>, func_uiout=0x908d60, func_args=0x7ffffffd6990, func_val=0x7ffffffd68a4, func_caught=0x7ffffffd68a0, errstring=Variable "errstring" is not available.) at ../../gdb-6.3/gdb/top.c:431 #12 0x000000000044698f in catch_exceptions_with_msg (uiout=Variable "uiout" is not available.) at ../../gdb-6.3/gdb/top.c:506 #13 0x0000000000491eae in break_command_1 (arg=0x94adf0 "TestFunc", flag=0, from_tty=1, pending_bp=0x8cefb0) at ../../gdb-6.3/gdb/breakpoint.c:5346 #14 0x000000000049247b in resolve_pending_breakpoint (b=0x8cefb0) at ../../gdb-6.3/gdb/breakpoint.c:4446 #15 0x0000000000494325 in re_enable_breakpoints_in_shlibs () at ../../gdb-6.3/gdb/breakpoint.c:4571 #16 0x00000000004c1b8f in handle_inferior_event (ecs=0x7ffffffd6d90) at ../../gdb-6.3/gdb/infrun.c:2233 #17 0x00000000004c35b9 in wait_for_inferior () at ../../gdb-6.3/gdb/infrun.c:990 #18 0x00000000004c3745 in proceed (addr=Variable "addr" is not available.) at ../../gdb-6.3/gdb/infrun.c:811 #19 0x00000000004bce9b in run_command (args=0x0, from_tty=1) at ../../gdb-6.3/gdb/infcmd.c:482 #20 0x0000000000446d9a in execute_command (p=0x8b7ff1 "", from_tty=1) at ../../gdb-6.3/gdb/top.c:733 #21 0x00000000004cd844 in command_handler (command=0x8b7ff0 "") at ../../gdb-6.3/gdb/event-top.c:500 #22 0x00000000004cdcfc in command_line_handler (rl=0x8cf0d0 "r") at ../../gdb-6.3/gdb/event-top.c:793 #23 0x00000000005a743a in rl_callback_read_char () at ../../gdb-6.3/readline/callback.c:123 #24 0x00000000004cd189 in rl_callback_read_char_wrapper (client_data=Variable "client_data" is not available.) at ../../gdb-6.3/gdb/event-top.c:166 #25 0x00000000004cc46a in process_event () at ../../gdb-6.3/gdb/event-loop.c:334 #26 0x00000000004ccd2c in gdb_do_one_event (data=Variable "data" is not available.) at ../../gdb-6.3/gdb/event-loop.c:371 #27 0x00000000004468cc in catcher (func=0x4469ea <do_catch_errors>, func_uiout=0x908d60, func_args=0x7ffffffd71f0, func_val=0x7ffffffd720c, func_caught=0x7ffffffd7208, errstring=Variable "errstring" is not available.) at ../../gdb-6.3/gdb/top.c:431 #28 0x0000000000446a37 in catch_errors (func=Variable "func" is not available.) at ../../gdb-6.3/gdb/top.c:536 #29 0x0000000000480e04 in tui_command_loop (data=Variable "data" is not available.) at ../../gdb-6.3/gdb/tui/tui-interp.c:150 #30 0x000000000043db49 in captured_command_loop (data=Variable "data" is not available.) at ../../gdb-6.3/gdb/main.c:91 #31 0x00000000004468cc in catcher (func=0x4469ea <do_catch_errors>, func_uiout=0x908d60, func_args=0x7ffffffd73b0, func_val=0x7ffffffd73cc, func_caught=0x7ffffffd73c8, errstring=Variable "errstring" is not available.) at ../../gdb-6.3/gdb/top.c:431 #32 0x0000000000446a37 in catch_errors (func=Variable "func" is not available.) at ../../gdb-6.3/gdb/top.c:536 #33 0x000000000043e242 in captured_main (data=Variable "data" is not available.) at ../../gdb-6.3/gdb/main.c:802 #34 0x00000000004468cc in catcher (func=0x4469ea <do_catch_errors>, func_uiout=0x7984a0, func_args=0x7ffffffd7730, func_val=0x7ffffffd774c, func_caught=0x7ffffffd7748, errstring=Variable "errstring" is not available.) at ../../gdb-6.3/gdb/top.c:431 #35 0x0000000000446a37 in catch_errors (func=Variable "func" is not available.) at ../../gdb-6.3/gdb/top.c:536 #36 0x000000000043db99 in gdb_main (args=Variable "args" is not available.) at ../../gdb-6.3/gdb/main.c:811 #37 0x000000000043db2e in main (argc=Variable "argc" is not available.) at ../../gdb-6.3/gdb/gdb.c:35 Just for the heck of it, I added "-m32" to the makefile, building it as 32bit binary/library and it worked just fine. Seems to be 64bit only problem. Reported up-stream: Problem 1997. FYI, fixed in FC6. - Gilboa Created attachment 145370 [details]
One reproducer tarball built on FC4-GOLD.x86_64.
Thanks for the report and sorry the resolving lacked so far.
FC4 built FC4 debugged: gdb crash
FC4 built FC6 debugged: works
FC6 built FC6 debugged: works
Still to evaluate the specific reason, it may just be unreproducibility.
This report targets the FC3 or FC4 products, which have now been EOL'd. Could you please check that it still applies to a current Fedora release, and either update the target product or close it ? Thanks. Fedora Core 4 is no longer maintained. Setting status to "INSUFFICIENT_DATA". If you can reproduce this bug in the current Fedora release, please reopen this bug and assign it to the corresponding Fedora version. |