Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Andrew Cagney <cagney@gnu.org>
Cc: jim.houston@comcast.net, gdb-patches@sources.redhat.com
Subject: Re: [patch] allow switching stacks
Date: Fri, 09 Apr 2004 22:40:00 -0000	[thread overview]
Message-ID: <20040409215453.GA1090@nevyn.them.org> (raw)
In-Reply-To: <404E2745.2090405@gnu.org>

On Tue, Mar 09, 2004 at 03:21:25PM -0500, Andrew Cagney wrote:
> >Hi Everyone,
> >
> >This patch against gdb-6.0 adds an option to disable an error check
> >which reports a non-contiguous stack as corrupted. I need this
> >option to get a reliable stack trace using kgdb on the x86-64 Linux
> >kernel because it uses a separate per-processor interrupt stack.
> >
> >This option is enabled with:
> >
> >     set backtrace switch-stacks on
> >
> >Jim Houston - Concurrent Computer Corp.
> 
> Can you provide more details of the problem -- exactly what do things 
> look like at the stack switch?
> 
> Your problem sounds very similar to the combination of a signal altstack 
> and a signal trampoline - for such a situtation the stack direction 
> check isn't applicable (pointing to the real bug).

They're going to look like normal frames unless GDB has magic to
recognize the interrupt handler, which doesn't seem like a good idea to
me - we can just use CFI to unwind through these things, otherwise.

There's no way in unwind information to annotate a non-call frame,
which is the common relevant property for signal frames, dummy frames,
and interrupt handler frames.   Should there be?

The other question is whether the order check is really safe at all.  I
can write (un-portable, using assembly, sure) code to call a function
on an alternate stack.  It would be nice to be able to backtrace
through something like that, if practical.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


  parent reply	other threads:[~2004-04-09 22:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-08 18:06 Jim Houston
2004-03-08 22:58 ` Michael Snyder
2004-03-19  0:09   ` Michael Snyder
2004-03-19  0:09   ` Eli Zaretskii
2004-03-09  6:06     ` Eli Zaretskii
2004-03-09 20:21 ` Andrew Cagney
2004-03-19  0:09   ` Andrew Cagney
2004-04-02 22:06   ` Andrew Cagney
2004-04-09 22:40   ` Daniel Jacobowitz [this message]
2004-04-12 21:05     ` Jim Blandy
2004-04-12 21:13       ` Daniel Jacobowitz
2004-03-19  0:09 ` Jim Houston

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=20040409215453.GA1090@nevyn.them.org \
    --to=drow@false.org \
    --cc=cagney@gnu.org \
    --cc=gdb-patches@sources.redhat.com \
    --cc=jim.houston@comcast.net \
    /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