diff options
author | Alan Hayward <alan.hayward@arm.com> | 2018-06-04 11:39:41 +0100 |
---|---|---|
committer | Alan Hayward <alan.hayward@arm.com> | 2018-06-04 12:07:26 +0100 |
commit | ba2d2bb24ea593c7fb17f51ef23f122064bb17d7 (patch) | |
tree | e1dbceba0189155252d0eecd789902888fe21498 /gdb/aarch64-tdep.h | |
parent | 39bfb9373c5cca78948c94174d46891c1a3d3613 (diff) | |
download | gdb-ba2d2bb24ea593c7fb17f51ef23f122064bb17d7.zip gdb-ba2d2bb24ea593c7fb17f51ef23f122064bb17d7.tar.gz gdb-ba2d2bb24ea593c7fb17f51ef23f122064bb17d7.tar.bz2 |
Enable SVE for GDB
Enable SVE support for GDB by reading the VQ when creating a
target description.
Also ensurse that SVE is taken into account when creating
the tdep structure, and store the current VQ value directly in tdep.
gdb/
* aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
* aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
(aarch64_gdbarch_init): Check for SVE.
* aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
Diffstat (limited to 'gdb/aarch64-tdep.h')
-rw-r--r-- | gdb/aarch64-tdep.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gdb/aarch64-tdep.h b/gdb/aarch64-tdep.h index e41a597..b6b9b30 100644 --- a/gdb/aarch64-tdep.h +++ b/gdb/aarch64-tdep.h @@ -73,6 +73,15 @@ struct gdbarch_tdep /* syscall record. */ int (*aarch64_syscall_record) (struct regcache *regcache, unsigned long svc_number); + + /* The VQ value for SVE targets, or zero if SVE is not supported. */ + long vq; + + /* Returns true if the target supports SVE. */ + bool has_sve () const + { + return vq != 0; + } }; const target_desc *aarch64_read_description (uint64_t vq); |