From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: arnez@linux.vnet.ibm.com (Andreas Arnez)
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH v2 03/13] S390: Migrate to regcache_supply/collect_regset.
Date: Tue, 15 Jul 2014 09:27:00 -0000 [thread overview]
Message-ID: <201407150906.s6F96DA5005632@d06av02.portsmouth.uk.ibm.com> (raw)
In-Reply-To: <1403714949-28133-4-git-send-email-arnez@linux.vnet.ibm.com> from "Andreas Arnez" at Jun 25, 2014 06:48:59 PM
Andreas Arnez wrote:
> gdb/
> * s390-linux-nat.c: Include "regset.h".
> (regmap_gregset): Delete macro.
> (s390_64_regmap_gregset): New register map for
> regcache_supply/_collect_regset.
> (s390_64_gregset): New regset.
> (S390_PSWM_OFFSET, S390_PSWA_OFFSET): New macros.
> (regmap_fpregset): Delete macro.
> (s390_native_supply, s390_native_collect): Delete functions.
> (supply_gregset, fill_gregset): Replace s390-specific regmap
> handling by a call to regcache_supply/_collect_regset.
> (supply_fpregset, fill_fpregset): Call regcache_supply/
> _collect_regset instead of s390_native_supply/_collect.
> (fetch_regset, store_regset): Likewise. Also change the last
> parameter to a regset instead of a regmap.
> (s390_linux_fetch_inferior_registers)
> (390_linux_store_inferior_registers): Adjust last parameter in
> calls to fetch_regset and store_regset.
> * s390-linux-tdep.c (s390_regmap_gregset): Rename to...
> (s390_gregmap): ... this. Also make static const and convert to
> regcache_map_entry format.
> (s390x_regmap_gregset): Delete.
> (s390_regmap_fpregset): Rename to...
> (s390_fpregmap): ... this. Make static const and convert to
> regcache_map_entry format.
> (s390_regmap_upper, s390_regmap_last_break)
> (s390x_regmap_last_break, s390_regmap_system_call)
> (s390_regmap_tdb): Likewise.
> (s390_supply_regset, s390_collect_regset): Remove functions.
> (s390_supply_tdb_regset): Call regcache_supply_regset instead of
> s390_supply_regset.
> (s390_gregset, s390_fpregset, s390_upper_regset)
> (s390_last_break_regset, s390x_last_break_regset)
> (s390_system_call_regset, s390_tdb_regset): Make global and
> replace s390_supply/_collect_regset by regcache_supply/
> _collect_regset.
> (s390x_gregset): Delete.
> (s390_gdbarch_init): Replace s390x_gregset by s390_gregset.
> * s390-linux-tdep.h (s390_regmap_gregset, s390x_regmap_gregset)
> (s390_regmap_fpregset, s390_regmap_last_break)
> (s390x_regmap_last_break, s390_regmap_system_call)
> (s390_regmap_tdb): Delete global variable declarations.
> (s390_gregset, s390_fpregset, s390_last_break_regset)
> (s390x_last_break_regset, s390_system_call_regset)
> (s390_tdb_regset): New global variable declarations.
This is OK, except that:
> -const short s390_regmap_last_break[] =
> - {
> - 0x04, S390_LAST_BREAK_REGNUM,
> - -1, -1
> - };
> -
> -const short s390x_regmap_last_break[] =
> - {
> - 0x00, S390_LAST_BREAK_REGNUM,
> - -1, -1
> - };
These two are deliberately different, but the replacements
are identical:
> +static const struct regcache_map_entry s390_regmap_last_break[] =
> + {
> + { 1, S390_LAST_BREAK_REGNUM },
> + { 0 }
> + };
>
> +static const struct regcache_map_entry s390x_regmap_last_break[] =
> + {
> + { 1, S390_LAST_BREAK_REGNUM },
> + { 0 }
> + };
That seems wrong, I think s390_regmap_last_break needs to
skip the initial 4 bytes.
Bye,
Ulrich
--
Dr. Ulrich Weigand
GNU/Linux compilers and toolchain
Ulrich.Weigand@de.ibm.com
next prev parent reply other threads:[~2014-07-15 9:06 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-25 16:49 [PATCH v2 00/13] Regset rework preparations part 2 Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 01/13] Rename 'descr' field in regset structure to 'regmap' Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 06/13] FRV Linux: Fill 'collect_regset' in regset structures Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 13/13] IA64 Linux: Define " Andreas Arnez
2014-07-15 13:01 ` Ulrich Weigand
2014-07-18 9:06 ` Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 11/13] TILEGX Linux: Fill 'collect_regset' in regset structure Andreas Arnez
2014-07-15 10:12 ` Ulrich Weigand
2014-07-16 13:30 ` Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 12/13] M68K Linux: Define regset structures Andreas Arnez
2014-07-15 12:13 ` Ulrich Weigand
2014-07-16 18:01 ` Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 03/13] S390: Migrate to regcache_supply/collect_regset Andreas Arnez
2014-07-15 9:27 ` Ulrich Weigand [this message]
2014-07-15 12:07 ` Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 10/13] SCORE: Fill 'collect_regset' in regset structure Andreas Arnez
2014-07-15 10:01 ` Ulrich Weigand
2014-07-15 12:25 ` Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 02/13] regcache: Add functions suitable for regset_supply/collect Andreas Arnez
2014-07-07 9:32 ` Omair Javaid
2014-07-08 11:32 ` Andreas Arnez
2014-07-08 19:09 ` Omair Javaid
2014-07-10 7:54 ` Andreas Arnez
2014-07-19 13:10 ` Omair Javaid
2014-06-25 16:49 ` [PATCH v2 04/13] AARCH64 Linux: Fill 'collect_regset' in regset structures Andreas Arnez
2014-07-07 9:57 ` Omair Javaid
2014-06-25 16:49 ` [PATCH v2 05/13] ALPHA " Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 08/13] M32R Linux: Fill 'collect_regset' in regset structure Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 09/13] NIOS2 " Andreas Arnez
2014-06-25 16:49 ` [PATCH v2 07/13] HPPA Linux: Fill 'collect_regset' in regset structures Andreas Arnez
2014-07-01 8:00 ` [ping][PATCH v2 00/13] Regset rework preparations part 2 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=201407150906.s6F96DA5005632@d06av02.portsmouth.uk.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