This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: GDB hang on "run"
- From: Tom Tromey <tom at tromey dot com>
- To: Uri Moszkowicz <uri at 4refs dot com>
- Cc: gdb at sourceware dot org
- Date: Wed, 08 Aug 2018 08:37:13 -0600
- Subject: Re: GDB hang on "run"
- References: <CAMJd5ATLRMPfJibDbJHr_pQBQN1=RW5-QTmJWTNJ0d_6_PkNhw@mail.gmail.com>
>>>>> "Uri" == Uri Moszkowicz <uri@4refs.com> writes:
Uri> Lately gdb has been hanging for me when running my executable. I'm using
Uri> GDB 8.1 but it occurs with older versions as well. Here's what I see:
Uri> (gdb) source run.gdb
Uri> Temporary breakpoint 1 at 0xbaf645: file <path>/<file>.cc, line 3501.
Uri> ^CTraceback (most recent call last):
Uri> File "/<path>/gcc-6.2.0/redhat6/lib64/libstdc++.so.6.0.22-gdb.py", line
Uri> 18, in <module>
Uri> import gdb
Uri> ImportError: No module named gdb
Uri> What I see is a hang right before the Traceback message, that's only
Uri> bypassed by sending a SIGINT. Anyone know why this might be and what I can
Uri> do to avoid it? Or tips on how to debug this problem?
If your program uses a very large shared library, gdb might be reading
debug info for it. Sometimes this can take a while and by default it
isn't announced.
Otherwise all I can suggest is attaching to gdb with another gdb,
interrupting it, and see what is going on.
If you suspect it is the "run" command itself, sometimes infrun logging
is interesting. That is "set debug infrun 1".
Tom