diff options
Diffstat (limited to 'gdb/gdbserver/linux-aarch64-low.c')
-rw-r--r-- | gdb/gdbserver/linux-aarch64-low.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gdb/gdbserver/linux-aarch64-low.c b/gdb/gdbserver/linux-aarch64-low.c index eccac4da13..d49c6e15e7 100644 --- a/gdb/gdbserver/linux-aarch64-low.c +++ b/gdb/gdbserver/linux-aarch64-low.c @@ -477,7 +477,12 @@ aarch64_arch_setup (void) is_elf64 = linux_pid_exe_is_elf_64_file (tid, &machine); - if (is_elf64) + /* There are problems with ptrace when gdbserver is 32 bits and the + program being debugged is 64 bits. */ + if (sizeof (void *) == 4 && is_elf64) + error (_("Can't debug 64-bit process with 32-bit GDBserver")); + + if (machine == EM_AARCH64) current_process ()->tdesc = aarch64_linux_read_description (); else current_process ()->tdesc = tdesc_arm_with_neon; |