From: Andrew Burgess <aburgess@broadcom.com>
To: Pedro Alves <palves@redhat.com>
Cc: <gdb-patches@sourceware.org>
Subject: Re: [PATCH [2/2] Convert the unavailable vector to be bit, not byte, based.
Date: Tue, 17 Dec 2013 17:30:00 -0000 [thread overview]
Message-ID: <52B08A05.6000306@broadcom.com> (raw)
In-Reply-To: <52A8B2B3.2060901@redhat.com>
On 11/12/2013 6:45 PM, Pedro Alves wrote:
> On 12/11/2013 04:28 PM, Andrew Burgess wrote:
>> +
>> + It is assumed that memory can be accessed from:
>> + PTR + (OFFSET_BITS / TARGET_CHAR_BIT)
>> + to:
>> + PTR + ((OFFSET_BITS + TARGET_CHAR_BIT - 1)/ TARGET_CHAR_BIT) */
>
> The "to:" part doesn't look right -- LENGTH_BITS seems to be
> missing somewhere? Also, missing space before second "/".
Fixed as:
+ It is assumed that memory can be accessed from:
+ PTR + (OFFSET_BITS / TARGET_CHAR_BIT)
+ to:
+ PTR + ((OFFSET_BITS + LENGTH_BITS + TARGET_CHAR_BIT - 1)
+ / TARGET_CHAR_BIT) */
>
>> + bits = TARGET_CHAR_BIT - (offset1_bits % TARGET_CHAR_BIT);
>
> Unnecessary parens.
Tightened up on this throughout.
>
>> + b1 = *((bfd_byte *) ((uintptr_t) ptr1 + (o1 / TARGET_CHAR_BIT)));
>> + b2 = *((bfd_byte *) ((uintptr_t) ptr2 + (o2 / TARGET_CHAR_BIT)));
>
> No need for uintptr_t, nor the rightmost set of parens:
Fixed.
>
> Otherwise looks OK. Thanks a lot for doing this!
I've pushed a version with those minor fixes.
Thanks for all your reviews.
Andrew
next prev parent reply other threads:[~2013-12-17 17:30 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-04 15:22 PATCH [0/2] Convert " Andrew Burgess
2013-12-04 15:25 ` [PATCH [1/2] Add support for DW_OP_bit_piece and DW_OP_plus_uconst to DWARF assembler Andrew Burgess
2013-12-05 16:23 ` Pedro Alves
2013-12-05 18:53 ` Tom Tromey
2013-12-06 13:30 ` Andrew Burgess
2013-12-04 15:26 ` [PATCH [0/2] Convert the unavailable vector to be bit, not byte, based Andrew Burgess
2013-12-05 16:18 ` [PATCH [2/2] " Pedro Alves
2013-12-09 21:04 ` Andrew Burgess
2013-12-10 11:32 ` Pedro Alves
2013-12-11 16:28 ` Andrew Burgess
2013-12-11 18:45 ` Pedro Alves
2013-12-17 17:30 ` Andrew Burgess [this message]
2013-12-05 16:18 ` PATCH [0/2] Convert " Pedro Alves
2013-12-05 18:14 ` 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=52B08A05.6000306@broadcom.com \
--to=aburgess@broadcom.com \
--cc=gdb-patches@sourceware.org \
--cc=palves@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