public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "palves at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug remote/17397] i686-w64-mingw32 remote multiprocess debugging: thread.c:1002: internal-error: switch_to_thread: Assertion `inf != NULL' failed.
Date: Thu, 19 Mar 2015 11:26:00 -0000	[thread overview]
Message-ID: <bug-17397-4717-y1Tr635ttr@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-17397-4717@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=17397

--- Comment #9 from Pedro Alves <palves at redhat dot com> ---
Thanks.  I can reproduce this with GNU/Linux gdbserver.

On one shell:

$ gdbserver --multi :9999 a.out

On another, connect with extended-remote, so we can start
two processes under the same gdbserver:

$ gdb a.out -ex "tar extended-remote :9999"
...
GNU gdb (GDB) 7.9.50.20150318-cvs
...
Reading symbols from ./a.out...done.
Remote debugging using :9999
...
0x0000003615a011f0 in _start () from /lib64/ld-linux-x86-64.so.2
(gdb) info inferiors 
  Num  Description       Executable        
* 1    process 24970     a.out
(gdb) add-inferior 
Added inferior 2
(gdb) inferior 2
[Switching to inferior 2 [<null>] (<noexec>)]
(gdb) info inferiors 
  Num  Description       Executable        
* 2    <null>                              
  1    process 24970     a.out
(gdb) file a.out
Reading symbols from a.out...done.
(gdb) info inferiors 
  Num  Description       Executable        
* 2    <null>            a.out
  1    process 24970     a.out
(gdb) start
Temporary breakpoint 1 at 0x411b67: main. (2 locations)
Starting program: /home/pedro/a.out

Temporary breakpoint 1, main (argc=1, argv=0x7fffffffd908) at
/home/pedro/foo.c:10
10      return 0;
(gdb) info inferiors 
  Num  Description       Executable        
* 2    process 24977     a.out
  1    process 24970     a.out

Now, disconnect, and reconnect, to emulate the OPs use case.

(gdb) disconnect 
Ending remote debugging.
(gdb) info inferiors 
  Num  Description       Executable        
* 2    <null>            a.out
  1    <null>            a.out
(gdb) tar remote :9999
Remote debugging using :9999
Reading symbols from /lib64/libdl.so.2...Reading symbols from /usr/lib/debug
(...)
main (argc=1, argv=0x7fffffffd908) at /home/pedro/foo.c:10
10      return 0;
(gdb) info inferiors 
  Num  Description       Executable        
* 2    process 24977     a.out
  1    <null>            a.out
(gdb) info threads 
  Id   Target Id         Frame 
* 2    Thread 24977      main (argc=1, argv=0x7fffffffd908) at
/home/pedro/foo.c:10
  1    Thread 24970      
/home/pedro/gdb/mygit/src/gdb/thread.c:1182: internal-error: switch_to_thread:
Assertion `inf != NULL' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n)

-- 
You are receiving this mail because:
You are on the CC list for the bug.


  parent reply	other threads:[~2015-03-19 11:16 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-16 13:13 [Bug remote/17397] New: " jerome.gardou at reactos dot org
2015-02-26 19:44 ` [Bug remote/17397] " jerome.gardou at reactos dot org
2015-02-27 10:08 ` jerome.gardou at reactos dot org
2015-02-27 11:45 ` palves at redhat dot com
2015-02-27 12:01 ` jerome.gardou at reactos dot org
2015-02-27 12:03 ` jerome.gardou at reactos dot org
2015-02-27 14:02 ` jerome.gardou at reactos dot org
2015-02-27 16:48 ` jerome.gardou at reactos dot org
2015-03-19 11:26 ` palves at redhat dot com [this message]
2015-04-04 14:59 ` jerome.gardou at reactos dot org
2015-04-07  8:35 ` palves 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-17397-4717-y1Tr635ttr@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: link
Be 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).