Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Mathieu Lacage <mathieu.lacage@gmail.com>
Cc: gdb@sourceware.org
Subject: Re: _r_debug_state getting screwed on x86_64 ?
Date: Mon, 20 Jul 2009 12:03:00 -0000	[thread overview]
Message-ID: <20090720120323.GA27912@caradoc.them.org> (raw)
In-Reply-To: <74fef6df0907200417q503ca457m642ebab9d953edb@mail.gmail.com>

On Mon, Jul 20, 2009 at 01:17:58PM +0200, Mathieu Lacage wrote:
> ----------- Ok, before calling, the stack contains this value for a
> local variable
> 
> (gdb) disas _r_debug_state
> Dump of assembler code for function _r_debug_state:
> 0x00007ffff7df7564 <_r_debug_state+0>:	push   %rbp
> 0x00007ffff7df7565 <_r_debug_state+1>:	mov    %rsp,%rbp
> 0x00007ffff7df7568 <_r_debug_state+4>:	leaveq
> 0x00007ffff7df7569 <_r_debug_state+5>:	retq
> End of assembler dump.
> (gdb) si
> warning: Temporarily disabling breakpoints for unloaded shared library "../ldso"
> Stopped due to shared library event

This is your problem.  You're supposed to have ldso in the list
already.

> ------------ and, yes, we can see the gdb int3 instruction in the
> function. -------------

And that's not a feature.  You should never be able to observe gdb's
software breakpoints by reading memory with GDB; if you do, it means
something has already gone wrong.

-- 
Daniel Jacobowitz
CodeSourcery


  reply	other threads:[~2009-07-20 12:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-20 11:18 Mathieu Lacage
2009-07-20 12:03 ` Daniel Jacobowitz [this message]
2009-07-20 14:43   ` Mathieu Lacage

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=20090720120323.GA27912@caradoc.them.org \
    --to=drow@false.org \
    --cc=gdb@sourceware.org \
    --cc=mathieu.lacage@gmail.com \
    /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