aboutsummaryrefslogtreecommitdiff
path: root/gdb/aarch64-linux-tdep.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-08-27 11:55:39 -0600
committerTom Tromey <tom@tromey.com>2018-08-27 12:00:12 -0600
commit1885053bcb12dd05a6f129146cf514e966082c27 (patch)
treeb87e292e8047546f1ca4e6877a4ca5887a3d51b5 /gdb/aarch64-linux-tdep.c
parentb4f183d23ec5f99765f0d6c64c1e3139e1d54093 (diff)
downloadfsf-binutils-gdb-1885053bcb12dd05a6f129146cf514e966082c27.zip
fsf-binutils-gdb-1885053bcb12dd05a6f129146cf514e966082c27.tar.gz
fsf-binutils-gdb-1885053bcb12dd05a6f129146cf514e966082c27.tar.bz2
Avoid -Wnarrowing warnings in aarch64-linux-tdep.c
This avoids -Wnarrowing warnings in aarch64_linux_iterate_over_regset_sections, by adding some casts to int. gdb/ChangeLog 2018-08-27 Tom Tromey <tom@tromey.com> * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add casts to int.
Diffstat (limited to 'gdb/aarch64-linux-tdep.c')
-rw-r--r--gdb/aarch64-linux-tdep.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c
index 0d46acd..dc2b891 100644
--- a/gdb/aarch64-linux-tdep.c
+++ b/gdb/aarch64-linux-tdep.c
@@ -411,8 +411,8 @@ aarch64_linux_iterate_over_regset_sections (struct gdbarch *gdbarch,
/* Create this on the fly in order to handle vector register sizes. */
const struct regcache_map_entry sve_regmap[] =
{
- { 32, AARCH64_SVE_Z0_REGNUM, tdep->vq * 16 },
- { 16, AARCH64_SVE_P0_REGNUM, tdep->vq * 16 / 8 },
+ { 32, AARCH64_SVE_Z0_REGNUM, (int) (tdep->vq * 16) },
+ { 16, AARCH64_SVE_P0_REGNUM, (int) (tdep->vq * 16 / 8) },
{ 1, AARCH64_SVE_FFR_REGNUM, 4 },
{ 1, AARCH64_FPSR_REGNUM, 4 },
{ 1, AARCH64_FPCR_REGNUM, 4 },