This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 4/7] range stepping: gdb
- From: Yao Qi <yao at codesourcery dot com>
- To: <gdb-patches at sourceware dot org>
- Date: Fri, 12 Apr 2013 14:55:47 +0800
- Subject: Re: [PATCH 4/7] range stepping: gdb
- References: <1363006291-13334-1-git-send-email-yao at codesourcery dot com> <1365648222-12540-1-git-send-email-yao at codesourcery dot com> <1365648222-12540-5-git-send-email-yao at codesourcery dot com> <51666804 dot 6060903 at codesourcery dot com>
On 04/11/2013 03:36 PM, Yao Qi wrote:
It is incorrect to copy address to buffer via phex_nz here and
somewhere else in remote.c. We should use remote_address_masked first
to mask the CORE_ADDR and then call hexnumstr to copy address to
buffer. Here is an updated one.
After a further thought, I decide to withdraw the updated patch 4/7, and
keep using the original V2 patch 4/7. The comments of variable
'remote_address_size' say:
/* This variable sets the number of bits in an address that are to be
sent in a memory ("M" or "m") packet. Normally, after stripping
leading zeros, the entire address would be sent. This variable
restricts the address to REMOTE_ADDRESS_SIZE bits. HISTORY: The
initial implementation of remote.c restricted the address sent in
memory packets to ``host::sizeof long'' bytes - (typically 32
bits). Consequently, for 64 bit targets, the upper 32 bits of an
address was never sent. Since fixing this bug may cause a break in
some remote targets this variable is principly provided to
facilitate backward compatibility. */
static unsigned int remote_address_size;
variable 'remote_address_size' has only effect on memory packet and
breakpoint packet (it is not documented, but actually used). Address in
these packets should be masked by remote_address_masked, and address in
new packets should not be, because the stub supports these new packets
should be able to parse address correctly.
--
Yao (éå)