From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: arnez@linux.vnet.ibm.com (Andreas Arnez)
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] PR gdb/21226: Take DWARF stack value pieces from LSB end
Date: Fri, 10 Mar 2017 17:57:00 -0000 [thread overview]
Message-ID: <20170310175740.21D9CD806AB@oc3748833570.ibm.com> (raw)
In-Reply-To: <m3o9xboca5.fsf@oc1027705133.ibm.com> from "Andreas Arnez" at Mar 08, 2017 07:26:26 PM
Andreas Arnez wrote:
Sorry, I overlooked one other issue:
> + /* Piece offset is from least significant bit end. */
> + if (bits_big_endian)
> + source_offset_bits += obj_size - (p->offset + p->size);
> + else
> + source_offset_bits += p->offset;
Should this really consult bits_big_endian, as opposed to the
regular byte order? Note that in the DWARF_VALUE_REGISTER case,
we have the same issue, and there the byte order is consulted.
(This doesn't make much of a difference today since in GDB
bit order is always the same a byte order, but we might as
well get it right ...)
Also, is p->size the right value here? Note that the code before
the loop might already have partially reduced the size and updated
the this_size(_bits) variables. Again, I think this case basically
ought to work the same as the DWARF_VALUE_REGISTER case. (Hmmm.
On the other hand, maybe the DWARF_VALUE_REGISTER case is wrong.
Either way, it should be the same :-))
Bye,
Ulrich
--
Dr. Ulrich Weigand
GNU/Linux compilers and toolchain
Ulrich.Weigand@de.ibm.com
next prev parent reply other threads:[~2017-03-10 17:57 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-08 18:26 Andreas Arnez
2017-03-10 17:43 ` Ulrich Weigand
2017-03-10 19:24 ` Andreas Arnez
2017-03-10 17:57 ` Ulrich Weigand [this message]
2017-03-10 19:27 ` Andreas Arnez
2017-03-10 20:01 ` Ulrich Weigand
2017-03-13 12:18 ` Andreas Arnez
2017-03-10 19:29 ` Pedro Alves
2017-03-13 12:24 ` Andreas Arnez
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=20170310175740.21D9CD806AB@oc3748833570.ibm.com \
--to=uweigand@de.ibm.com \
--cc=arnez@linux.vnet.ibm.com \
--cc=gdb-patches@sourceware.org \
/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