[PATCHv6,4/9] gdb/x86: move have_ptrace_getregset global into gdb/nat directory
Checks
Context |
Check |
Description |
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_build--master-arm |
fail
|
Testing failed
|
linaro-tcwg-bot/tcwg_gdb_check--master-aarch64 |
success
|
Testing passed
|
Commit Message
Just like the previous commit, this commit moves have_ptrace_getregset
into the nat/ directory. This global is currently declared and
defined in both GDB and gdbserver, but this can be merged and shared.
There should be no user visible changes after this commit.
---
gdb/linux-nat.c | 3 ---
gdb/linux-nat.h | 3 ---
gdb/nat/x86-linux.c | 3 +++
gdb/nat/x86-linux.h | 3 +++
gdbserver/linux-low.cc | 3 ---
gdbserver/linux-low.h | 2 --
6 files changed, 6 insertions(+), 11 deletions(-)
Comments
On 5/8/24 9:46 AM, Andrew Burgess wrote:
> Just like the previous commit, this commit moves have_ptrace_getregset
> into the nat/ directory. This global is currently declared and
> defined in both GDB and gdbserver, but this can be merged and shared.
>
> There should be no user visible changes after this commit.
Approved-By: John Baldwin <jhb@FreeBSD.org>
@@ -243,9 +243,6 @@ PTRACE_PEEKTEXT/PTRACE_POKETEXT or process_vm_readv/process_vm_writev:
struct linux_nat_target *linux_target;
-/* Does the current host support PTRACE_GETREGSET? */
-enum tribool have_ptrace_getregset = TRIBOOL_UNKNOWN;
-
/* When true, print debug messages relating to the linux native target. */
static bool debug_linux_nat;
@@ -299,9 +299,6 @@ lwp_info_range all_lwps ();
lwp_info_safe_range all_lwps_safe ();
-/* Does the current host support PTRACE_GETREGSET? */
-extern enum tribool have_ptrace_getregset;
-
/* Called from the LWP layer to inform the thread_db layer that PARENT
spawned CHILD. Both LWPs are currently stopped. This function
does whatever is required to have the child LWP under the
@@ -29,6 +29,9 @@ tribool have_ptrace_getfpxregs =
#endif
;
+/* See nat/x86-linux.h. */
+tribool have_ptrace_getregset = TRIBOOL_UNKNOWN;
+
/* Per-thread arch-specific data we want to keep. */
struct arch_lwp_info
@@ -36,6 +36,9 @@
variable. */
extern tribool have_ptrace_getfpxregs;
+/* Does the current host support PTRACE_GETREGSET? */
+extern tribool have_ptrace_getregset;
+
/* Set whether our local mirror of LWP's debug registers has been
changed since the values were last written to the thread. Nonzero
indicates that a change has been made, zero indicates no change. */
@@ -133,9 +133,6 @@ typedef struct
} Elf64_auxv_t;
#endif
-/* Does the current host support PTRACE_GETREGSET? */
-enum tribool have_ptrace_getregset = TRIBOOL_UNKNOWN;
-
/* Return TRUE if THREAD is the leader thread of the process. */
static bool
@@ -951,8 +951,6 @@ void thread_db_notice_clone (struct thread_info *parent_thr, ptid_t child_ptid);
bool thread_db_thread_handle (ptid_t ptid, gdb_byte **handle, int *handle_len);
-extern enum tribool have_ptrace_getregset;
-
/* Search for the value with type MATCH in the auxv vector, with entries of
length WORDSIZE bytes, of process with pid PID. If found, store the
value in *VALP and return 1. If not found or if there is an error,