public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "arsenm2 at gmail dot com" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug gdb/17043] New: Stack overflow in demangler when debugging clover Date: Tue, 10 Jun 2014 02:33:00 -0000 [thread overview] Message-ID: <bug-17043-4717@http.sourceware.org/bugzilla/> (raw) https://sourceware.org/bugzilla/show_bug.cgi?id=17043 Bug ID: 17043 Summary: Stack overflow in demangler when debugging clover Product: gdb Version: HEAD Status: NEW Severity: normal Priority: P2 Component: gdb Assignee: unassigned at sourceware dot org Reporter: arsenm2 at gmail dot com When debugging something that links to clover's libOpenCL in Mesa, there is a stack overflow and crash in the demangler. From this sample of the backtrace, the offending symbol name appears to be: "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv" #71785 0x00000000007474c0 in d_print_comp (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, dc=dc@entry=0x7fffffffb2e8) at ./cp-demangle.c:5368 #71786 0x0000000000747b32 in d_print_mod (dpi=0x7fffffffa4c0, options=259, mod=0x7fffffffb2e8) at ./cp-demangle.c:5581 #71787 0x0000000000747ed2 in d_print_mod_list (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, mods=0x7fffffffae68, mods@entry=0x7fffffffa3e0, suffix=34, suffix@entry=0) at ./cp-demangle.c:5510 #71788 0x00000000007482d7 in d_print_function_type (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, dc=dc@entry=0x7fffffffb330, mods=0x7fffffffa3e0) at ./cp-demangle.c:5651 #71789 0x0000000000745aa7 in d_print_comp_inner (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, dc=0x7fffffffb330) at ./cp-demangle.c:4835 #71790 0x00000000007474c0 in d_print_comp (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, dc=<optimized out>) at ./cp-demangle.c:5368 #71791 0x0000000000744a16 in d_print_comp_inner (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, dc=dc@entry=0x7fffffffb348) at ./cp-demangle.c:4442 #71792 0x00000000007474c0 in d_print_comp (dpi=dpi@entry=0x7fffffffa4c0, options=options@entry=259, dc=dc@entry=0x7fffffffb348) at ./cp-demangle.c:5368 #71793 0x000000000074b52c in cplus_demangle_print_callback (options=options@entry=259, dc=0x7fffffffb348, callback=callback@entry=0x7441ba <d_growable_string_callback_adapter>, opaque=opaque@entry=0x7fffffffd510) at ./cp-demangle.c:4071 #71794 0x000000000074b7db in d_demangle_callback (mangled=<optimized out>, mangled@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", options=options@entry=259, callback=callback@entry=0x7441ba <d_growable_string_callback_adapter>, opaque=opaque@entry=0x7fffffffd510) at ./cp-demangle.c:5898 #71795 0x000000000074b823 in d_demangle ( mangled=mangled@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", options=259, palc=palc@entry=0x7fffffffd558) at ./cp-demangle.c:5919 #71796 0x000000000074b957 in cplus_demangle_v3 ( mangled=mangled@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", options=<optimized out>) at ./cp-demangle.c:6076 #71797 0x000000000073f0e7 in cplus_demangle ( mangled=mangled@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", options=options@entry=3) at ./cplus-dem.c:858 #71798 0x00000000006c7d50 in bfd_demangle (abfd=abfd@entry=0x0, name=name@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", options=options@entry=3) at bfd.c:1885 #71799 0x000000000067fe3d in gdb_demangle ( name=name@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", options=options@entry=3) at cp-support.c:1490 #71800 0x0000000000584f9b in symbol_find_demangled_name (gsymbol=gsymbol@entry=0x18db598, mangled=mangled@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv") at symtab.c:661 #71801 0x0000000000586900 in symbol_set_names (gsymbol=gsymbol@entry=0x18db598, linkage_name=linkage_name@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", len=len@entry=210, copy_name=copy_name@entry=0, objfile=objfile@entry=0x1767b30) at symtab.c:871 #71802 0x00000000005ed014 in prim_record_minimal_symbol_full (name=<optimized out>, name@entry=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", name_len=name_len@entry=210, copy_name=copy_name@entry=0, address=address@entry=459968, ms_type=ms_type@entry=mst_file_text, section=10, objfile=0x1767b30) at minsyms.c:960 #71803 0x0000000000522fc8 in record_minimal_symbol ( name=0x7ffff0b368c2 "_ZNK6clover6detail11basic_rangeINS_13adaptor_rangeINS_9addressesEINS2_IRFRNS_5eventEP9_cl_eventEINS_14iterator_rangeIPKS7_EEEEEEEENS0_16iterator_adaptorIS3_INSG_IS9_ISC_EEEEEESI_EcvT_ISt6vectorIPS4_SaISN_EEvEEv", name_len=210, copy_name=copy_name@entry=0, address=address@entry=459968, ms_type=ms_type@entry=mst_file_text, bfd_section=0x15128b8, objfile=0x1767b30) at elfread.c:206 #71804 0x00000000005238a6 in elf_symtab_read (objfile=objfile@entry=0x1767b30, type=type@entry=0, number_of_symbols=number_of_symbols@entry=17235, symbol_table=symbol_table@entry=0x7ffff0ede010, copy_names=copy_names@entry=0) at elfread.c:543 #71805 0x0000000000523bb1 in elf_read_minimal_symbols (objfile=objfile@entry=0x1767b30, symfile_flags=symfile_flags@entry=8, ei=ei@entry=0x7fffffffd8c0) at elfread.c:1148 #71806 0x0000000000523d8e in elf_symfile_read (objfile=0x1767b30, symfile_flags=8) at elfread.c:1264 #71807 0x0000000000591549 in read_symbols (objfile=objfile@entry=0x1767b30, add_flags=add_flags@entry=8) at symfile.c:877 #71808 0x00000000005917b0 in syms_from_objfile_1 (objfile=objfile@entry=0x1767b30, addrs=addrs@entry=0x17675c0, add_flags=add_flags@entry=8) at symfile.c:1080 #71809 0x00000000005917d8 in syms_from_objfile (objfile=objfile@entry=0x1767b30, addrs=addrs@entry=0x17675c0, add_flags=add_flags@entry=8) at symfile.c:1096 #71810 0x00000000005913b2 in symbol_file_add_with_addrs (abfd=0x1490b40, name=name@entry=0x14d4d90 "/home/matt/src/mesa/build_debug/lib/gallium/libOpenCL.so.1", add_flags=add_flags@entry=8, addrs=addrs@entry=0x17675c0, flags=flags@entry=2, parent=parent@entry=0x0) at symfile.c:1193 #71811 0x00000000005917eb in symbol_file_add_from_bfd (abfd=<optimized out>, name=name@entry=0x14d4d90 "/home/matt/src/mesa/build_debug/lib/gallium/libOpenCL.so.1", add_flags=add_flags@entry=8, addrs=addrs@entry=0x17675c0, flags=flags@entry=2, parent=parent@entry=0x0) at symfile.c:1282 ---Type <return> to continue, or q <return> to quit--- #71812 0x0000000000684b9a in solib_read_symbols (so=so@entry=0x14d4b80, flags=flags@entry=8) at solib.c:640 #71813 0x0000000000685087 in solib_add (pattern=pattern@entry=0x0, from_tty=from_tty@entry=0, target=<optimized out>, readsyms=1) at solib.c:962 #71814 0x000000000068536b in handle_solib_event () at solib.c:1278 #71815 0x000000000055230e in bpstat_stop_status (aspace=0xda05c0, bp_addr=bp_addr@entry=140737351956576, ptid=..., ws=ws@entry=0x7fffffffdc40) at breakpoint.c:5522 #71816 0x00000000005a9262 in handle_signal_stop (ecs=ecs@entry=0x7fffffffdc20) at infrun.c:4142 #71817 0x00000000005aa366 in handle_inferior_event (ecs=ecs@entry=0x7fffffffdc20) at infrun.c:3819 #71818 0x00000000005aae6e in fetch_inferior_event (client_data=client_data@entry=0x0) at infrun.c:2921 #71819 0x00000000005bf5db in fetch_inferior_event_wrapper (client_data=client_data@entry=0x0) at inf-loop.c:147 #71820 0x00000000005b546e in catch_errors (func=func@entry=0x5bf5d2 <fetch_inferior_event_wrapper>, func_args=func_args@entry=0x0, errstring=errstring@entry=0x76a908 "", mask=mask@entry=RETURN_MASK_ALL) at exceptions.c:524 #71821 0x00000000005bf627 in inferior_event_handler (event_type=INF_REG_EVENT, client_data=0x0) at inf-loop.c:55 #71822 0x00000000004a30ed in handle_target_event (error=<optimized out>, client_data=<optimized out>) at linux-nat.c:4670 #71823 0x00000000005bd367 in handle_file_event (data=..., data@entry=...) at event-loop.c:766 #71824 0x00000000005bde60 in process_event () at event-loop.c:343 #71825 0x00000000005be14d in gdb_do_one_event () at event-loop.c:395 #71826 0x00000000005be1af in start_event_loop () at event-loop.c:432 #71827 0x00000000005bef3a in cli_command_loop (data=<optimized out>) at event-top.c:182 #71828 0x00000000005b75f1 in current_interp_command_loop () at interps.c:328 #71829 0x00000000005b809e in captured_command_loop (data=data@entry=0x0) at main.c:301 #71830 0x00000000005b546e in catch_errors (func=func@entry=0x5b808b <captured_command_loop>, func_args=func_args@entry=0x0, errstring=errstring@entry=0x76a908 "", mask=mask@entry=RETURN_MASK_ALL) at exceptions.c:524 #71831 0x00000000005b94ab in captured_main (data=data@entry=0x7fffffffdfc0) at main.c:1097 #71832 0x00000000005b546e in catch_errors (func=func@entry=0x5b8612 <captured_main>, func_args=func_args@entry=0x7fffffffdfc0, errstring=errstring@entry=0x76a908 "", mask=mask@entry=RETURN_MASK_ALL) at exceptions.c:524 #71833 0x00000000005b94c8 in gdb_main (args=args@entry=0x7fffffffdfc0) at main.c:1105 #71834 0x000000000046289b in main (argc=<optimized out>, argv=<optimized out>) at gdb.c:33 -- You are receiving this mail because: You are on the CC list for the bug.
next reply other threads:[~2014-06-10 2:33 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2014-06-10 2:33 arsenm2 at gmail dot com [this message] 2014-06-10 8:07 ` [Bug gdb/17043] " gbenson at redhat dot com 2014-06-18 8:40 ` jan.kratochvil at redhat dot com 2014-11-12 11:32 ` gbenson at redhat dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-17043-4717@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).