Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@redhat.com>
To: Joel Brobecker <brobecker@gnat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFC/RFA/frame stuff] Fix build failure in alpha-osf1-tdep.c
Date: Wed, 04 Jun 2003 02:47:00 -0000	[thread overview]
Message-ID: <3EDD5DAA.1060300@redhat.com> (raw)
In-Reply-To: <20030604002702.GP919@gnat.com>

> This is the second source of problems in alpha-osf-tdep.c: The
> frame_info structure has become opaque, but this file still had some
> references to its old fields.
> 
> Looking at the documentation in frames.h (very useful, btw), it seems
> that the following change should be correct. Andrew, could you have a
> close look (I am unable to test it, as I have a 3rd build failure, which
> I will report shortly)? Regardless of your review, I will NOT commit
> this change until have I have full build that I can test.
> 
> 2003-06-03  J. Brobecker  <brobecker@gnat.com>
> 
>         * alpha-osf1-tdep.c (alpha_osf1_skip_sigtramp_frame): Replace
>         references to struct frame_info fields by calls to the equivalent
>         accessors. Necessary now that frame_info is opaque.
>         (alpha_osf1_pc_in_sigtramp): Likewise.
> 
> Looks ok?

Yes.  If you're feeling game you could use get_frame_memory, but either way.

Andrew


> Thanks,
> -- Joel
> 
> 
> 
> Index: alpha-osf1-tdep.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/alpha-osf1-tdep.c,v
> retrieving revision 1.12
> diff -u -3 -p -r1.12 alpha-osf1-tdep.c
> --- alpha-osf1-tdep.c	3 Jun 2003 23:49:32 -0000	1.12
> +++ alpha-osf1-tdep.c	4 Jun 2003 00:19:41 -0000
> @@ -37,7 +37,7 @@ alpha_osf1_skip_sigtramp_frame (struct f
>  
>    find_pc_partial_function (pc, &name, (CORE_ADDR *) NULL, (CORE_ADDR *) NULL);
>    if (PC_IN_SIGTRAMP (pc, name))
> -    return frame->frame;
> +    return get_frame_base (frame);
>    return 0;
>  }
>  
> @@ -50,8 +50,12 @@ alpha_osf1_pc_in_sigtramp (CORE_ADDR pc,
>  static CORE_ADDR
>  alpha_osf1_sigcontext_addr (struct frame_info *frame)
>  {
> -  return (read_memory_integer (frame->next ? frame->next->frame
> -					   : frame->frame, 8));
> +  struct frame_info *next_frame = get_next_frame (frame);
> +
> +  if (next_frame != NULL)
> +    return (read_memory_integer (get_frame_base (next_frame), 8));
> +  else
> +    return (read_memory_integer (get_frame_base (frame), 8));
>  }
>  
>  /* This is the definition of CALL_DUMMY_ADDRESS.  It's a heuristic that is used



  reply	other threads:[~2003-06-04  2:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-04  0:27 Joel Brobecker
2003-06-04  2:47 ` Andrew Cagney [this message]
2003-06-04  5:31   ` Joel Brobecker
2003-06-04  6:05   ` Joel Brobecker
2003-06-04 17:33     ` Andrew Cagney
2003-06-04 17:40       ` David Carlton
2003-06-04 20:41       ` Joel Brobecker

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=3EDD5DAA.1060300@redhat.com \
    --to=ac131313@redhat.com \
    --cc=brobecker@gnat.com \
    --cc=gdb-patches@sources.redhat.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