AArch64: Implement memory tagging target methods for AArch64
authorLuis Machado <luis.machado@linaro.org>
Fri, 19 Jun 2020 20:33:13 +0000 (17:33 -0300)
committerLuis Machado <luis.machado@linaro.org>
Wed, 24 Mar 2021 17:53:56 +0000 (14:53 -0300)
commit4601818e8c06bb8a5bf4b63fa527c69d3f81c6f0
treea8650e0d1beb52fdf709a0198be63a61d29f4b49
parent3f3bd8b8c14d844533b70b25c7f1a8cbdbac2639
AArch64: Implement memory tagging target methods for AArch64

The patch implements the memory tagging target hooks for AArch64, so we
can handle MTE.

gdb/ChangeLog:

2021-03-24  Luis Machado  <luis.machado@linaro.org>

* Makefile.in (ALL_64_TARGET_OBS): Add arch/aarch64-mte-linux.o.
(HFILES_NO_SRCDIR): Add arch/aarch64-mte-linux.h and
nat/aarch64-mte-linux-ptrace.h.
* aarch64-linux-nat.c: Include nat/aarch64-mte-linux-ptrace.h.
(aarch64_linux_nat_target) <supports_memory_tagging>: New method
override.
<fetch_memtags>: New method override.
<store_memtags>: New method override.
(aarch64_linux_nat_target::supports_memory_tagging): New method.
(aarch64_linux_nat_target::fetch_memtags): New method.
(aarch64_linux_nat_target::store_memtags): New method.
* arch/aarch64-mte-linux.c: New file.
* arch/aarch64-mte-linux.h: Include gdbsupport/common-defs.h.
(AARCH64_MTE_GRANULE_SIZE): Define.
(aarch64_memtag_type): New enum.
(aarch64_mte_get_tag_granules): New prototype.
* configure.nat (NATDEPFILES): Add nat/aarch64-mte-linux-ptrace.o.
* configure.tgt (aarch64*-*-linux*): Add arch/aarch64-mte-linux.o.
* nat/aarch64-mte-linux-ptrace.c: New file.
* nat/aarch64-mte-linux-ptrace.h: New file.
gdb/ChangeLog
gdb/Makefile.in
gdb/aarch64-linux-nat.c
gdb/arch/aarch64-mte-linux.c [new file with mode: 0644]
gdb/arch/aarch64-mte-linux.h
gdb/configure.nat
gdb/configure.tgt
gdb/nat/aarch64-mte-linux-ptrace.c [new file with mode: 0644]
gdb/nat/aarch64-mte-linux-ptrace.h