Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Sofia <rodinasophie@gmail.com>
To: gdb@sourceware.org
Subject: GDB breakpoint implementation for multithreaded programms
Date: Sat, 10 May 2014 22:00:00 -0000	[thread overview]
Message-ID: <loom.20140510T235440-169@post.gmane.org> (raw)

I'm writing my GDB stub and trying to set breakpoints on different threads. 
When I don't ask GDB about the number of threads, It works fine as a single-
threaded application and breakpoints are set correctly. But when I enter - 
'info threads', something strange happens.

Firstly, GDB reads the contents of all threads' registers(it's OK). Then I 
enter 'continue' and see that breakpoints are not set at all threads my 
program has. I don't understand why, but the packet Z0(breakpoint packet) is 
only sent to inactive thread. The documentation says that if the thread id is 
not specified, breakpoints will be set at all threads. What's wrong with this 
or where can I read about such GDB behavior?


             reply	other threads:[~2014-05-10 22:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-10 22:00 Sofia [this message]
2014-05-11  3:27 ` Luis Machado

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=loom.20140510T235440-169@post.gmane.org \
    --to=rodinasophie@gmail.com \
    --cc=gdb@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