Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: Mark Kettenis <mark.kettenis@xs4all.nl>
Cc: gdb-patches@sourceware.org
Subject: Re: [patch] workaround gcc46: prologue skip skips too far (PR 12435) #2
Date: Sun, 24 Jul 2011 20:00:00 -0000	[thread overview]
Message-ID: <20110724181008.GA8727@host1.jankratochvil.net> (raw)
In-Reply-To: <201107241803.p6OI3rMR008990@glazunov.sibelius.xs4all.nl>

On Sun, 24 Jul 2011 20:03:53 +0200, Mark Kettenis wrote:
> > It does not solve overlays well, but the code just does not work for
> > overlays, it has no other negative effect.
> 
> Sorry, but what do you mean with "overlays" here?

See skip_prologue_sal:
      /* If the function is in an unmapped overlay, use its unmapped LMA address,
         so that gdbarch_skip_prologue has something unique to work on.  */
      if (section_is_overlay (section) && !section_is_mapped (section))
        pc = overlay_unmapped_address (pc, section);

      /* Skip "first line" of function (which is actually its prologue).  */
      pc += gdbarch_deprecated_function_start_offset (gdbarch);
      if (skip)
        pc = gdbarch_skip_prologue (gdbarch, pc);

      /* For overlays, map pc back into its mapped VMA range.  */
      pc = overlay_mapped_address (pc, section);

So in gdbarch_skip_prologue the PC is LMA, I do not know how
gdbarch_skip_prologue could read the bytes at PC (without introducing new
parameter(s) to gdbarch_skip_prologue).


Thanks,
Jan


  reply	other threads:[~2011-07-24 18:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-22 23:04 Jan Kratochvil
2011-07-24 18:16 ` Mark Kettenis
2011-07-24 20:00   ` Jan Kratochvil [this message]
2011-09-08 15:54 ` Jan Kratochvil
2011-09-08 17:31 ` Doug Evans
2011-09-08 19:13   ` Jan Kratochvil
2011-09-09 19:52     ` Jan Kratochvil
2011-09-12 17:23       ` Doug Evans

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=20110724181008.GA8727@host1.jankratochvil.net \
    --to=jan.kratochvil@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=mark.kettenis@xs4all.nl \
    /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