Rebase to FSF GDB 7.8.

- Display Fortran strings in backtraces.
This commit is contained in:
Jan Kratochvil 2014-08-02 12:58:20 +02:00
commit 191ccfbccd
11 changed files with 493 additions and 787 deletions

View file

@ -96,10 +96,10 @@ Content-Type: text/x-patch
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename=bitpos-wp.patch
Index: gdb-7.7.90.20140613/gdb/arm-linux-nat.c
Index: gdb-7.8/gdb/arm-linux-nat.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/arm-linux-nat.c 2014-06-13 22:23:09.630440699 +0200
+++ gdb-7.7.90.20140613/gdb/arm-linux-nat.c 2014-06-13 22:23:54.666492199 +0200
--- gdb-7.8.orig/gdb/arm-linux-nat.c 2014-08-01 23:27:30.183773676 +0200
+++ gdb-7.8/gdb/arm-linux-nat.c 2014-08-01 23:27:30.241773754 +0200
@@ -1296,7 +1296,7 @@ arm_linux_stopped_by_watchpoint (struct
static int
arm_linux_watchpoint_addr_within_range (struct target_ops *target,
@ -109,11 +109,11 @@ Index: gdb-7.7.90.20140613/gdb/arm-linux-nat.c
{
return start <= addr && start + length - 1 >= addr;
}
Index: gdb-7.7.90.20140613/gdb/ppc-linux-nat.c
Index: gdb-7.8/gdb/ppc-linux-nat.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/ppc-linux-nat.c 2014-06-13 22:23:09.635440704 +0200
+++ gdb-7.7.90.20140613/gdb/ppc-linux-nat.c 2014-06-13 22:23:54.672492206 +0200
@@ -1857,11 +1857,11 @@ can_use_watchpoint_cond_accel (void)
--- gdb-7.8.orig/gdb/ppc-linux-nat.c 2014-08-01 23:27:30.202773701 +0200
+++ gdb-7.8/gdb/ppc-linux-nat.c 2014-08-01 23:29:38.311944925 +0200
@@ -1862,11 +1862,11 @@ can_use_watchpoint_cond_accel (void)
CONDITION_VALUE will hold the value which should be put in the
DVC register. */
static void
@ -128,7 +128,7 @@ Index: gdb-7.7.90.20140613/gdb/ppc-linux-nat.c
CORE_ADDR addr_end_data, addr_end_dvc;
/* The DVC register compares bytes within fixed-length windows which
@@ -1948,7 +1948,7 @@ num_memory_accesses (struct value *v)
@@ -1953,7 +1953,7 @@ num_memory_accesses (struct value *v)
of the constant. */
static int
check_condition (CORE_ADDR watch_addr, struct expression *cond,
@ -137,7 +137,16 @@ Index: gdb-7.7.90.20140613/gdb/ppc-linux-nat.c
{
int pc = 1, num_accesses_left, num_accesses_right;
struct value *left_val, *right_val, *left_chain, *right_chain;
@@ -2033,7 +2033,7 @@ ppc_linux_can_accel_watchpoint_condition
@@ -2021,7 +2021,7 @@ check_condition (CORE_ADDR watch_addr, s
true. */
static int
ppc_linux_can_accel_watchpoint_condition (struct target_ops *self,
- CORE_ADDR addr, int len, int rw,
+ CORE_ADDR addr, LONGEST len, int rw,
struct expression *cond)
{
CORE_ADDR data_value;
@@ -2038,7 +2038,7 @@ ppc_linux_can_accel_watchpoint_condition
static void
create_watchpoint_request (struct ppc_hw_breakpoint *p, CORE_ADDR addr,
@ -146,7 +155,7 @@ Index: gdb-7.7.90.20140613/gdb/ppc-linux-nat.c
int insert)
{
if (len == 1
@@ -2299,7 +2299,7 @@ ppc_linux_stopped_by_watchpoint (struct
@@ -2304,7 +2304,7 @@ ppc_linux_stopped_by_watchpoint (struct
static int
ppc_linux_watchpoint_addr_within_range (struct target_ops *target,
CORE_ADDR addr,
@ -155,10 +164,10 @@ Index: gdb-7.7.90.20140613/gdb/ppc-linux-nat.c
{
int mask;
Index: gdb-7.7.90.20140613/gdb/procfs.c
Index: gdb-7.8/gdb/procfs.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/procfs.c 2014-06-13 22:23:09.638440708 +0200
+++ gdb-7.7.90.20140613/gdb/procfs.c 2014-06-13 22:23:54.673492207 +0200
--- gdb-7.8.orig/gdb/procfs.c 2014-08-01 23:27:30.203773703 +0200
+++ gdb-7.8/gdb/procfs.c 2014-08-01 23:27:30.243773756 +0200
@@ -2429,7 +2429,7 @@ procfs_address_to_host_pointer (CORE_ADD
#endif
@ -177,11 +186,11 @@ Index: gdb-7.7.90.20140613/gdb/procfs.c
int after)
{
#ifndef AIX5
Index: gdb-7.7.90.20140613/gdb/remote.c
Index: gdb-7.8/gdb/remote.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/remote.c 2014-06-13 22:23:09.643440713 +0200
+++ gdb-7.7.90.20140613/gdb/remote.c 2014-06-13 22:23:54.680492215 +0200
@@ -8199,7 +8199,7 @@ remote_insert_watchpoint (struct target_
--- gdb-7.8.orig/gdb/remote.c 2014-08-01 23:27:30.205773705 +0200
+++ gdb-7.8/gdb/remote.c 2014-08-01 23:27:30.246773760 +0200
@@ -8206,7 +8206,7 @@ remote_insert_watchpoint (struct target_
p = strchr (rs->buf, '\0');
addr = remote_address_masked (addr);
p += hexnumstr (p, (ULONGEST) addr);
@ -190,7 +199,7 @@ Index: gdb-7.7.90.20140613/gdb/remote.c
putpkt (rs->buf);
getpkt (&rs->buf, &rs->buf_size, 0);
@@ -8219,7 +8219,7 @@ remote_insert_watchpoint (struct target_
@@ -8226,7 +8226,7 @@ remote_insert_watchpoint (struct target_
static int
remote_watchpoint_addr_within_range (struct target_ops *target, CORE_ADDR addr,
@ -199,7 +208,7 @@ Index: gdb-7.7.90.20140613/gdb/remote.c
{
CORE_ADDR diff = remote_address_masked (addr - start);
@@ -8249,7 +8249,7 @@ remote_remove_watchpoint (struct target_
@@ -8256,7 +8256,7 @@ remote_remove_watchpoint (struct target_
p = strchr (rs->buf, '\0');
addr = remote_address_masked (addr);
p += hexnumstr (p, (ULONGEST) addr);
@ -208,10 +217,10 @@ Index: gdb-7.7.90.20140613/gdb/remote.c
putpkt (rs->buf);
getpkt (&rs->buf, &rs->buf_size, 0);
Index: gdb-7.7.90.20140613/gdb/target.c
Index: gdb-7.8/gdb/target.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/target.c 2014-06-13 22:23:09.645440716 +0200
+++ gdb-7.7.90.20140613/gdb/target.c 2014-06-13 22:26:24.077661601 +0200
--- gdb-7.8.orig/gdb/target.c 2014-08-01 23:27:30.206773707 +0200
+++ gdb-7.8/gdb/target.c 2014-08-01 23:29:38.314944857 +0200
@@ -52,7 +52,7 @@ static void target_info (char *, int);
static void default_terminal_info (struct target_ops *, const char *, int);
@ -221,7 +230,7 @@ Index: gdb-7.7.90.20140613/gdb/target.c
static int default_region_ok_for_hw_watchpoint (struct target_ops *,
CORE_ADDR, LONGEST);
@@ -150,7 +150,7 @@ static int debug_to_remove_watchpoint (s
@@ -150,13 +150,13 @@ static int debug_to_remove_watchpoint (s
static int debug_to_stopped_data_address (struct target_ops *, CORE_ADDR *);
static int debug_to_watchpoint_addr_within_range (struct target_ops *,
@ -230,7 +239,14 @@ Index: gdb-7.7.90.20140613/gdb/target.c
static int debug_to_region_ok_for_hw_watchpoint (struct target_ops *self,
CORE_ADDR, LONGEST);
@@ -2959,7 +2959,7 @@ default_region_ok_for_hw_watchpoint (str
static int debug_to_can_accel_watchpoint_condition (struct target_ops *self,
- CORE_ADDR, int, int,
+ CORE_ADDR, LONGEST, int,
struct expression *);
static void debug_to_terminal_init (struct target_ops *self);
@@ -2960,7 +2960,7 @@ default_region_ok_for_hw_watchpoint (str
static int
default_watchpoint_addr_within_range (struct target_ops *target,
CORE_ADDR addr,
@ -239,7 +255,16 @@ Index: gdb-7.7.90.20140613/gdb/target.c
{
return addr >= start && addr < start + length;
}
@@ -3691,8 +3691,8 @@ debug_to_can_accel_watchpoint_condition
@@ -3681,7 +3681,7 @@ debug_to_region_ok_for_hw_watchpoint (st
static int
debug_to_can_accel_watchpoint_condition (struct target_ops *self,
- CORE_ADDR addr, int len, int rw,
+ CORE_ADDR addr, LONGEST len, int rw,
struct expression *cond)
{
int retval;
@@ -3692,8 +3692,8 @@ debug_to_can_accel_watchpoint_condition
fprintf_unfiltered (gdb_stdlog,
"target_can_accel_watchpoint_condition "
@ -250,7 +275,7 @@ Index: gdb-7.7.90.20140613/gdb/target.c
host_address_to_string (cond), (unsigned long) retval);
return retval;
}
@@ -3727,7 +3727,7 @@ debug_to_stopped_data_address (struct ta
@@ -3728,7 +3728,7 @@ debug_to_stopped_data_address (struct ta
static int
debug_to_watchpoint_addr_within_range (struct target_ops *target,
CORE_ADDR addr,
@ -259,7 +284,7 @@ Index: gdb-7.7.90.20140613/gdb/target.c
{
int retval;
@@ -3735,9 +3735,9 @@ debug_to_watchpoint_addr_within_range (s
@@ -3736,9 +3736,9 @@ debug_to_watchpoint_addr_within_range (s
start, length);
fprintf_filtered (gdb_stdlog,
@ -271,10 +296,10 @@ Index: gdb-7.7.90.20140613/gdb/target.c
return retval;
}
Index: gdb-7.7.90.20140613/gdb/target.h
Index: gdb-7.8/gdb/target.h
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/target.h 2014-06-13 22:23:54.683492219 +0200
+++ gdb-7.7.90.20140613/gdb/target.h 2014-06-13 22:25:41.372613039 +0200
--- gdb-7.8.orig/gdb/target.h 2014-08-01 23:27:30.207773708 +0200
+++ gdb-7.8/gdb/target.h 2014-08-01 23:29:38.315944839 +0200
@@ -469,7 +469,7 @@ struct target_ops
int (*to_stopped_data_address) (struct target_ops *, CORE_ADDR *)
TARGET_DEFAULT_RETURN (0);
@ -284,10 +309,19 @@ Index: gdb-7.7.90.20140613/gdb/target.h
TARGET_DEFAULT_FUNC (default_watchpoint_addr_within_range);
/* Documentation of this routine is provided with the corresponding
Index: gdb-7.7.90.20140613/gdb/aarch64-linux-nat.c
@@ -479,7 +479,7 @@ struct target_ops
TARGET_DEFAULT_FUNC (default_region_ok_for_hw_watchpoint);
int (*to_can_accel_watchpoint_condition) (struct target_ops *,
- CORE_ADDR, int, int,
+ CORE_ADDR, LONGEST, int,
struct expression *)
TARGET_DEFAULT_RETURN (0);
int (*to_masked_watch_num_registers) (struct target_ops *,
Index: gdb-7.8/gdb/aarch64-linux-nat.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/aarch64-linux-nat.c 2014-06-13 22:23:09.647440718 +0200
+++ gdb-7.7.90.20140613/gdb/aarch64-linux-nat.c 2014-06-13 22:23:54.683492219 +0200
--- gdb-7.8.orig/gdb/aarch64-linux-nat.c 2014-08-01 23:27:30.212773715 +0200
+++ gdb-7.8/gdb/aarch64-linux-nat.c 2014-08-01 23:27:30.248773763 +0200
@@ -428,14 +428,14 @@ aarch64_notify_debug_reg_change (const s
static void
aarch64_show_debug_reg_state (struct aarch64_debug_reg_state *state,
@ -366,10 +400,10 @@ Index: gdb-7.7.90.20140613/gdb/aarch64-linux-nat.c
{
return start <= addr && start + length - 1 >= addr;
}
Index: gdb-7.7.90.20140613/gdb/target-delegates.c
Index: gdb-7.8/gdb/target-delegates.c
===================================================================
--- gdb-7.7.90.20140613.orig/gdb/target-delegates.c 2014-06-13 22:22:37.917404611 +0200
+++ gdb-7.7.90.20140613/gdb/target-delegates.c 2014-06-13 22:26:06.092640924 +0200
--- gdb-7.8.orig/gdb/target-delegates.c 2014-08-01 23:27:30.212773715 +0200
+++ gdb-7.8/gdb/target-delegates.c 2014-08-01 23:29:38.313944877 +0200
@@ -261,7 +261,7 @@ tdefault_stopped_data_address (struct ta
}
@ -379,3 +413,20 @@ Index: gdb-7.7.90.20140613/gdb/target-delegates.c
{
self = self->beneath;
return self->to_watchpoint_addr_within_range (self, arg1, arg2, arg3);
@@ -275,14 +275,14 @@ delegate_region_ok_for_hw_watchpoint (st
}
static int
-delegate_can_accel_watchpoint_condition (struct target_ops *self, CORE_ADDR arg1, int arg2, int arg3, struct expression *arg4)
+delegate_can_accel_watchpoint_condition (struct target_ops *self, CORE_ADDR arg1, LONGEST arg2, int arg3, struct expression *arg4)
{
self = self->beneath;
return self->to_can_accel_watchpoint_condition (self, arg1, arg2, arg3, arg4);
}
static int
-tdefault_can_accel_watchpoint_condition (struct target_ops *self, CORE_ADDR arg1, int arg2, int arg3, struct expression *arg4)
+tdefault_can_accel_watchpoint_condition (struct target_ops *self, CORE_ADDR arg1, LONGEST arg2, int arg3, struct expression *arg4)
{
return 0;
}