Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Klee Dienes <klee@apple.com>
To: Andrew Cagney <ac131313@redhat.com>
Cc: Daniel Jacobowitz <drow@mvista.com>, gdb-patches@sources.redhat.com
Subject: Re: [PATCH] Use read_memory_unsigned_integer when reading to CORE_ADDR
Date: Mon, 04 Nov 2002 19:45:00 -0000	[thread overview]
Message-ID: <038EC655-F071-11D6-8361-00039396EEB8@apple.com> (raw)
In-Reply-To: <3DB44FFB.2090205@redhat.com>

I used extract_type_address to honor the comment about not causing a 
memory_error.

I'll check in the change from builtin_type_void_data_ptr to 
builtin_type_void_code_ptr.

Unless someone objects, I'll also change

   int ptrbytes = TARGET_PTR_BIT / TARGET_CHAR_BIT;

to

   int ptrbytes = TYPE_LENGTH (builtin_type_void_code_ptr);

at the start of the function.

On Monday, October 21, 2002, at 03:05 PM, Andrew Cagney wrote:

>>    /* Don't cause a memory_error when accessing sigcontext in case 
>> the stack
>>       layout has changed or the stack is corrupt.  */
>>    target_read_memory (sigcontext_addr + SIGCONTEXT_PC_OFFSET, buf, 
>> ptrbytes);
>> -  return extract_unsigned_integer (buf, ptrbytes);
>> +  return extract_typed_address (buf, builtin_type_void_data_ptr);
>
> This should be builtin_type_void_code_ptr since it is extracting a 
> code pointer (the PC).  It, also, might as well use 
> read_memory_typed_address().
>
> Andrew
>
>


  reply	other threads:[~2002-11-05  3:45 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-05 19:48 Klee Dienes
2002-10-05 19:56 ` Daniel Jacobowitz
2002-10-05 23:52   ` Klee Dienes
2002-10-06  8:09     ` Daniel Jacobowitz
2002-10-06  9:41       ` Klee Dienes
2002-10-06  9:51         ` Daniel Jacobowitz
2002-10-07 14:19         ` Jim Blandy
2002-10-21 12:08         ` Andrew Cagney
2002-11-04 19:45           ` Klee Dienes [this message]
2002-11-06 14:37             ` Andrew Cagney
2002-10-21 12:08     ` Andrew Cagney
2002-10-07 14:14   ` Jim Blandy

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=038EC655-F071-11D6-8361-00039396EEB8@apple.com \
    --to=klee@apple.com \
    --cc=ac131313@redhat.com \
    --cc=drow@mvista.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