- Rebase to gdb version 7.11 as of version in Fedora 24:
* Per-inferior thread numbers. * Breakpoint "explicit locations" (via CLI and GDB/MI). * New convenience variables ($_gthread, $_inferior). * Record btrace now supports non-stop mode. * Various improvements on AArch64 GNU/Linux: - Multi-architecture debugging support. - displaced stepping. - tracepoint support added in GDBserver. * In Ada, the overloads selection menu provides the parameter types and return types for the matching overloaded subprograms. * Various remote protocol improvements, including several new packets which can be used to support features such as follow-exec-mode, exec catchpoints, syscall catchpoints, etc. * Some minor improvements in the Python API for extending GDB. - Added new patches from Fedora: gdb-fedora-libncursesw.patch gdb-fortran-stride-intel-1of6.patch gdb-fortran-stride-intel-2of6.patch gdb-fortran-stride-intel-3of6.patch gdb-fortran-stride-intel-4of6.patch gdb-fortran-stride-intel-5of6.patch gdb-fortran-stride-intel-6of6-nokfail.patch gdb-fortran-stride-intel-6of6.patch gdb-opcodes-clflushopt-test.patch gdb-testsuite-readline63-sigint.patch - Removed obsolete patches: gdb-6.3-bz231832-obstack-2gb.patch gdb-pahole-python2.patch gdb-probes-based-interface-robust-1of2.patch OBS-URL: https://build.opensuse.org/package/show/devel:gcc/gdb?expand=0&rev=132
This commit is contained in:
parent
8ad36d9ba6
commit
b288fe5a9a
@ -1,5 +1,7 @@
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/attach-see-vdso.c 6 Jul 2007 14:14:44 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-see-vdso.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-see-vdso.c 2016-02-15 23:25:36.749601045 +0100
|
||||
@@ -0,0 +1,25 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -26,8 +28,10 @@
|
||||
+ pause ();
|
||||
+ return 1;
|
||||
+}
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/attach-see-vdso.exp 6 Jul 2007 14:14:44 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-see-vdso.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-see-vdso.exp 2016-02-15 23:25:44.889658840 +0100
|
||||
@@ -0,0 +1,72 @@
|
||||
+# Copyright 2007
|
||||
+
|
||||
@ -54,8 +58,8 @@
|
||||
+
|
||||
+set testfile "attach-see-vdso"
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set escapedbinfile [string_to_regexp ${objdir}/${subdir}/${testfile}]
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+set escapedbinfile [string_to_regexp [standard_output_file ${testfile}]]
|
||||
+
|
||||
+# The kernel VDSO is used for the syscalls returns only on i386 (not x86_64).
|
||||
+#
|
||||
|
@ -3,8 +3,10 @@
|
||||
* gdb.threads/threaded-exec.exp, gdb.threads/threaded-exec.c: New files.
|
||||
|
||||
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.threads/threaded-exec.c 17 Jan 2007 23:10:22 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.c 2016-02-16 09:54:06.936904418 +0100
|
||||
@@ -0,0 +1,46 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -52,8 +54,10 @@
|
||||
+ execl ("/bin/true", "/bin/true", NULL);
|
||||
+ abort ();
|
||||
+}
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.threads/threaded-exec.exp 17 Jan 2007 23:10:22 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.exp 2016-02-16 09:54:19.965992585 +0100
|
||||
@@ -0,0 +1,41 @@
|
||||
+# threaded-exec.exp -- Check reset of the tracked threads on exec*(2)
|
||||
+# Copyright (C) 2007 Free Software Foundation, Inc.
|
||||
@ -77,7 +81,7 @@
|
||||
+
|
||||
+set testfile threaded-exec
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable []] != "" } {
|
||||
+ return -1
|
||||
|
@ -1,177 +0,0 @@
|
||||
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=231832
|
||||
|
||||
|
||||
Index: gdb-7.8.50.20141228/include/obstack.h
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/include/obstack.h 2015-01-01 17:02:53.254820447 +0100
|
||||
+++ gdb-7.8.50.20141228/include/obstack.h 2015-01-01 17:02:53.880820084 +0100
|
||||
@@ -188,31 +188,31 @@ struct obstack /* control current objec
|
||||
|
||||
/* Declare the external functions we use; they are in obstack.c. */
|
||||
|
||||
-extern void _obstack_newchunk (struct obstack *, int);
|
||||
+extern void _obstack_newchunk (struct obstack *, PTR_INT_TYPE);
|
||||
extern void _obstack_free (struct obstack *, void *);
|
||||
-extern int _obstack_begin (struct obstack *, int, int,
|
||||
+extern int _obstack_begin (struct obstack *, PTR_INT_TYPE, int,
|
||||
void *(*) (long), void (*) (void *));
|
||||
-extern int _obstack_begin_1 (struct obstack *, int, int,
|
||||
+extern int _obstack_begin_1 (struct obstack *, PTR_INT_TYPE, int,
|
||||
void *(*) (void *, long),
|
||||
void (*) (void *, void *), void *);
|
||||
-extern int _obstack_memory_used (struct obstack *);
|
||||
+extern PTR_INT_TYPE _obstack_memory_used (struct obstack *);
|
||||
|
||||
/* Do the function-declarations after the structs
|
||||
but before defining the macros. */
|
||||
|
||||
void obstack_init (struct obstack *obstack);
|
||||
|
||||
-void * obstack_alloc (struct obstack *obstack, int size);
|
||||
+void * obstack_alloc (struct obstack *obstack, PTR_INT_TYPE size);
|
||||
|
||||
-void * obstack_copy (struct obstack *obstack, void *address, int size);
|
||||
-void * obstack_copy0 (struct obstack *obstack, void *address, int size);
|
||||
+void * obstack_copy (struct obstack *obstack, void *address, PTR_INT_TYPE size);
|
||||
+void * obstack_copy0 (struct obstack *obstack, void *address, PTR_INT_TYPE size);
|
||||
|
||||
void obstack_free (struct obstack *obstack, void *block);
|
||||
|
||||
-void obstack_blank (struct obstack *obstack, int size);
|
||||
+void obstack_blank (struct obstack *obstack, PTR_INT_TYPE size);
|
||||
|
||||
-void obstack_grow (struct obstack *obstack, void *data, int size);
|
||||
-void obstack_grow0 (struct obstack *obstack, void *data, int size);
|
||||
+void obstack_grow (struct obstack *obstack, void *data, PTR_INT_TYPE size);
|
||||
+void obstack_grow0 (struct obstack *obstack, void *data, PTR_INT_TYPE size);
|
||||
|
||||
void obstack_1grow (struct obstack *obstack, int data_char);
|
||||
void obstack_ptr_grow (struct obstack *obstack, void *data);
|
||||
@@ -220,20 +220,20 @@ void obstack_int_grow (struct obstack *o
|
||||
|
||||
void * obstack_finish (struct obstack *obstack);
|
||||
|
||||
-int obstack_object_size (struct obstack *obstack);
|
||||
+PTR_INT_TYPE obstack_object_size (struct obstack *obstack);
|
||||
|
||||
-int obstack_room (struct obstack *obstack);
|
||||
-void obstack_make_room (struct obstack *obstack, int size);
|
||||
+PTR_INT_TYPE obstack_room (struct obstack *obstack);
|
||||
+void obstack_make_room (struct obstack *obstack, PTR_INT_TYPE size);
|
||||
void obstack_1grow_fast (struct obstack *obstack, int data_char);
|
||||
void obstack_ptr_grow_fast (struct obstack *obstack, void *data);
|
||||
void obstack_int_grow_fast (struct obstack *obstack, int data);
|
||||
-void obstack_blank_fast (struct obstack *obstack, int size);
|
||||
+void obstack_blank_fast (struct obstack *obstack, PTR_INT_TYPE size);
|
||||
|
||||
void * obstack_base (struct obstack *obstack);
|
||||
void * obstack_next_free (struct obstack *obstack);
|
||||
int obstack_alignment_mask (struct obstack *obstack);
|
||||
-int obstack_chunk_size (struct obstack *obstack);
|
||||
-int obstack_memory_used (struct obstack *obstack);
|
||||
+size_t obstack_chunk_size (struct obstack *obstack);
|
||||
+size_t obstack_memory_used (struct obstack *obstack);
|
||||
|
||||
/* Error handler called when `obstack_chunk_alloc' failed to allocate
|
||||
more memory. This can be set to a user defined function. The
|
||||
@@ -318,7 +318,7 @@ extern int obstack_exit_failure;
|
||||
# define obstack_make_room(OBSTACK,length) \
|
||||
__extension__ \
|
||||
({ struct obstack *__o = (OBSTACK); \
|
||||
- int __len = (length); \
|
||||
+ PTR_INT_TYPE __len = (length); \
|
||||
if (__o->chunk_limit - __o->next_free < __len) \
|
||||
_obstack_newchunk (__o, __len); \
|
||||
(void) 0; })
|
||||
@@ -331,7 +331,7 @@ __extension__ \
|
||||
# define obstack_grow(OBSTACK,where,length) \
|
||||
__extension__ \
|
||||
({ struct obstack *__o = (OBSTACK); \
|
||||
- int __len = (length); \
|
||||
+ PTR_INT_TYPE __len = (length); \
|
||||
if (__o->next_free + __len > __o->chunk_limit) \
|
||||
_obstack_newchunk (__o, __len); \
|
||||
_obstack_memcpy (__o->next_free, (where), __len); \
|
||||
@@ -341,7 +341,7 @@ __extension__ \
|
||||
# define obstack_grow0(OBSTACK,where,length) \
|
||||
__extension__ \
|
||||
({ struct obstack *__o = (OBSTACK); \
|
||||
- int __len = (length); \
|
||||
+ PTR_INT_TYPE __len = (length); \
|
||||
if (__o->next_free + __len + 1 > __o->chunk_limit) \
|
||||
_obstack_newchunk (__o, __len + 1); \
|
||||
_obstack_memcpy (__o->next_free, (where), __len); \
|
||||
@@ -392,7 +392,7 @@ __extension__ \
|
||||
# define obstack_blank(OBSTACK,length) \
|
||||
__extension__ \
|
||||
({ struct obstack *__o = (OBSTACK); \
|
||||
- int __len = (length); \
|
||||
+ PTR_INT_TYPE __len = (length); \
|
||||
if (__o->chunk_limit - __o->next_free < __len) \
|
||||
_obstack_newchunk (__o, __len); \
|
||||
obstack_blank_fast (__o, __len); \
|
||||
Index: gdb-7.8.50.20141228/libiberty/obstack.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/libiberty/obstack.c 2015-01-01 17:02:53.254820447 +0100
|
||||
+++ gdb-7.8.50.20141228/libiberty/obstack.c 2015-01-01 17:02:53.880820084 +0100
|
||||
@@ -44,9 +44,11 @@
|
||||
#if !defined (_LIBC) && defined (__GNU_LIBRARY__) && __GNU_LIBRARY__ > 1
|
||||
#include <gnu-versions.h>
|
||||
#if _GNU_OBSTACK_INTERFACE_VERSION == OBSTACK_INTERFACE_VERSION
|
||||
+#if 0 /* 64-bit obstack is not compatible with any glibc implementation. */
|
||||
#define ELIDE_CODE
|
||||
#endif
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
|
||||
#ifndef ELIDE_CODE
|
||||
@@ -139,7 +141,7 @@ struct obstack *_obstack;
|
||||
free up some memory, then call this again. */
|
||||
|
||||
int
|
||||
-_obstack_begin (struct obstack *h, int size, int alignment,
|
||||
+_obstack_begin (struct obstack *h, PTR_INT_TYPE size, int alignment,
|
||||
POINTER (*chunkfun) (long), void (*freefun) (void *))
|
||||
{
|
||||
register struct _obstack_chunk *chunk; /* points to new chunk */
|
||||
@@ -183,7 +185,7 @@ _obstack_begin (struct obstack *h, int s
|
||||
}
|
||||
|
||||
int
|
||||
-_obstack_begin_1 (struct obstack *h, int size, int alignment,
|
||||
+_obstack_begin_1 (struct obstack *h, PTR_INT_TYPE size, int alignment,
|
||||
POINTER (*chunkfun) (POINTER, long),
|
||||
void (*freefun) (POINTER, POINTER), POINTER arg)
|
||||
{
|
||||
@@ -235,7 +237,7 @@ _obstack_begin_1 (struct obstack *h, int
|
||||
to the beginning of the new one. */
|
||||
|
||||
void
|
||||
-_obstack_newchunk (struct obstack *h, int length)
|
||||
+_obstack_newchunk (struct obstack *h, PTR_INT_TYPE length)
|
||||
{
|
||||
register struct _obstack_chunk *old_chunk = h->chunk;
|
||||
register struct _obstack_chunk *new_chunk;
|
||||
@@ -388,11 +390,11 @@ obstack_free (struct obstack *h, POINTER
|
||||
abort ();
|
||||
}
|
||||
|
||||
-int
|
||||
+PTR_INT_TYPE
|
||||
_obstack_memory_used (struct obstack *h)
|
||||
{
|
||||
register struct _obstack_chunk* lp;
|
||||
- register int nbytes = 0;
|
||||
+ register PTR_INT_TYPE nbytes = 0;
|
||||
|
||||
for (lp = h->chunk; lp != 0; lp = lp->prev)
|
||||
{
|
||||
@@ -421,6 +423,7 @@ print_and_abort (void)
|
||||
}
|
||||
|
||||
#if 0
|
||||
+/* These functions are now broken for 64-bit obstack! */
|
||||
/* These are now turned off because the applications do not use it
|
||||
and it uses bcopy via obstack_grow, which causes trouble on sysV. */
|
||||
|
@ -9,10 +9,10 @@
|
||||
|
||||
* gdb.base/attach-32.exp: Fix forgotten $GDBFLAGS as set.
|
||||
|
||||
Index: gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-32.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.c 2011-03-20 20:15:57.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-32.c 2016-02-15 23:23:02.923499512 +0100
|
||||
@@ -0,0 +1,20 @@
|
||||
+/* This program is intended to be started outside of gdb, and then
|
||||
+ attached to by gdb. Thus, it simply spins in a loop. The loop
|
||||
@ -34,10 +34,10 @@ Index: gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.c
|
||||
+ }
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-32.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.exp 2011-03-20 20:20:03.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-32.exp 2016-02-15 23:25:11.385420957 +0100
|
||||
@@ -0,0 +1,245 @@
|
||||
+# Copyright 2005 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -77,9 +77,9 @@ Index: gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.exp
|
||||
+set testfile "attach-32"
|
||||
+set srcfile ${testfile}.c
|
||||
+set srcfile2 ${testfile}b.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile2 ${objdir}/${subdir}/${testfile}b
|
||||
+set escapedbinfile [string_to_regexp ${objdir}/${subdir}/${testfile}]
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+set binfile2 [standard_output_file ${testfile}b]
|
||||
+set escapedbinfile [string_to_regexp [standard_output_file ${testfile}]]
|
||||
+
|
||||
+#execute_anywhere "rm -f ${binfile} ${binfile2}"
|
||||
+remote_exec build "rm -f ${binfile} ${binfile2}"
|
||||
@ -284,10 +284,10 @@ Index: gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32.exp
|
||||
+do_call_attach_tests
|
||||
+
|
||||
+return 0
|
||||
Index: gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32b.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-32b.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.2.50.20110320/gdb/testsuite/gdb.base/attach-32b.c 2011-03-20 20:15:57.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/attach-32b.c 2016-02-15 23:23:02.924499519 +0100
|
||||
@@ -0,0 +1,24 @@
|
||||
+/* This program is intended to be started outside of gdb, and then
|
||||
+ attached to by gdb. Thus, it simply spins in a loop. The loop
|
||||
|
@ -5,10 +5,10 @@
|
||||
* gdb.cp/b146835b.cc: Ditto.
|
||||
* gdb.cp/b146835.h: Ditto.
|
||||
|
||||
Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835b.cc
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835b.cc
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835b.cc 2009-08-12 06:07:50.000000000 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835b.cc 2016-02-16 09:49:08.743886620 +0100
|
||||
@@ -0,0 +1,11 @@
|
||||
+#include "b146835.h"
|
||||
+
|
||||
@ -21,10 +21,10 @@ Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835b.cc
|
||||
+void A::funcD (class E *e, class D *d) {}
|
||||
+void A::funcE (E *e, D *d) {}
|
||||
+void A::funcF (unsigned long x, D *d) {}
|
||||
Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.cc
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835.cc
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.cc 2009-08-12 06:07:50.000000000 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835.cc 2016-02-16 09:49:08.744886627 +0100
|
||||
@@ -0,0 +1,32 @@
|
||||
+#include "b146835.h"
|
||||
+#include <iostream>
|
||||
@ -58,10 +58,10 @@ Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.cc
|
||||
+ f.foo();
|
||||
+}
|
||||
+
|
||||
Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.exp 2009-08-12 06:58:28.000000000 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835.exp 2016-02-16 09:51:48.601968339 +0100
|
||||
@@ -0,0 +1,47 @@
|
||||
+# This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -87,7 +87,7 @@ Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.exp
|
||||
+set testfile "b146835"
|
||||
+set srcfile ${testfile}.cc
|
||||
+set srcfile2 ${testfile}b.cc
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if {[gdb_compile "${srcdir}/${subdir}/${srcfile} ${srcdir}/${subdir}/${srcfile2}" "${binfile}" executable {debug c++}] != "" } {
|
||||
+ return -1
|
||||
+}
|
||||
@ -110,10 +110,10 @@ Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.exp
|
||||
+
|
||||
+# Verify that we can access the inherited member d
|
||||
+gdb_test "p d" " = \\(D \\*\\) *0x0" "Verify inherited member d accessible"
|
||||
Index: gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.h
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835.h
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20090811/gdb/testsuite/gdb.cp/b146835.h 2009-08-12 06:07:50.000000000 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/b146835.h 2016-02-16 09:49:08.744886627 +0100
|
||||
@@ -0,0 +1,36 @@
|
||||
+
|
||||
+class A {
|
||||
|
@ -11,10 +11,10 @@
|
||||
|
||||
* gdb.texinfo (File Options): Document --readnever.
|
||||
|
||||
Index: gdb-7.9.50.20150520/gdb/doc/gdb.texinfo
|
||||
Index: gdb-7.10.50.20151022/gdb/doc/gdb.texinfo
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/doc/gdb.texinfo 2015-05-31 16:34:58.436379663 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/doc/gdb.texinfo 2015-05-31 16:35:03.452416381 +0200
|
||||
--- gdb-7.10.50.20151022.orig/gdb/doc/gdb.texinfo 2015-10-22 22:16:50.483482288 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/doc/gdb.texinfo 2015-10-22 22:28:22.042554142 +0200
|
||||
@@ -1032,6 +1032,12 @@ Read each symbol file's entire symbol ta
|
||||
the default, which is to read it incrementally as it is needed.
|
||||
This makes startup slower, but makes future operations faster.
|
||||
@ -28,10 +28,10 @@ Index: gdb-7.9.50.20150520/gdb/doc/gdb.texinfo
|
||||
@end table
|
||||
|
||||
@node Mode Options
|
||||
Index: gdb-7.9.50.20150520/gdb/main.c
|
||||
Index: gdb-7.10.50.20151022/gdb/main.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/main.c 2015-05-31 16:34:58.439379685 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/main.c 2015-05-31 16:35:20.547541518 +0200
|
||||
--- gdb-7.10.50.20151022.orig/gdb/main.c 2015-10-22 22:16:50.485482299 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/main.c 2015-10-22 22:28:22.042554142 +0200
|
||||
@@ -604,6 +604,7 @@ captured_main (void *data)
|
||||
{"tui", no_argument, 0, OPT_TUI},
|
||||
{"dbx", no_argument, &dbx_commands, 1},
|
||||
@ -48,10 +48,10 @@ Index: gdb-7.9.50.20150520/gdb/main.c
|
||||
--write Set writing into executable and core files.\n\n\
|
||||
"), stream);
|
||||
fputs_unfiltered (_("\
|
||||
Index: gdb-7.9.50.20150520/gdb/symfile.c
|
||||
Index: gdb-7.10.50.20151022/gdb/symfile.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/symfile.c 2015-05-31 16:34:58.440379692 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/symfile.c 2015-05-31 16:35:03.454416395 +0200
|
||||
--- gdb-7.10.50.20151022.orig/gdb/symfile.c 2015-10-22 22:16:50.486482305 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/symfile.c 2015-10-22 22:28:22.043554148 +0200
|
||||
@@ -80,6 +80,7 @@ static void clear_symtab_users_cleanup (
|
||||
|
||||
/* Global variables owned by this file. */
|
||||
@ -60,33 +60,33 @@ Index: gdb-7.9.50.20150520/gdb/symfile.c
|
||||
|
||||
/* Functions this file defines. */
|
||||
|
||||
Index: gdb-7.9.50.20150520/gdb/dwarf2read.c
|
||||
Index: gdb-7.10.50.20151022/gdb/dwarf2read.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/dwarf2read.c 2015-05-31 16:34:58.446379736 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/dwarf2read.c 2015-05-31 16:35:03.459416432 +0200
|
||||
@@ -69,6 +69,7 @@
|
||||
#include "source.h"
|
||||
--- gdb-7.10.50.20151022.orig/gdb/dwarf2read.c 2015-10-22 22:28:22.046554165 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/dwarf2read.c 2015-10-22 22:29:17.664881642 +0200
|
||||
@@ -70,6 +70,7 @@
|
||||
#include "filestuff.h"
|
||||
#include "build-id.h"
|
||||
#include "namespace.h"
|
||||
+#include "top.h"
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/types.h>
|
||||
@@ -2050,7 +2051,8 @@ dwarf2_has_info (struct objfile *objfile
|
||||
@@ -2059,7 +2060,8 @@ dwarf2_has_info (struct objfile *objfile
|
||||
(void *) names);
|
||||
dwarf2_per_objfile->objfile = objfile;
|
||||
}
|
||||
- return (!dwarf2_per_objfile->info.is_virtual
|
||||
+ return !readnever_symbol_files &&
|
||||
+ (!dwarf2_per_objfile->info.is_virtual
|
||||
&& dwarf2_per_objfile->info.s.asection != NULL
|
||||
&& dwarf2_per_objfile->info.s.section != NULL
|
||||
&& !dwarf2_per_objfile->abbrev.is_virtual
|
||||
&& dwarf2_per_objfile->abbrev.s.asection != NULL);
|
||||
Index: gdb-7.9.50.20150520/gdb/top.h
|
||||
&& dwarf2_per_objfile->abbrev.s.section != NULL);
|
||||
Index: gdb-7.10.50.20151022/gdb/top.h
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/top.h 2015-05-31 16:34:58.448379751 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/top.h 2015-05-31 16:35:03.459416432 +0200
|
||||
@@ -67,6 +67,7 @@ extern void set_prompt (const char *s);
|
||||
--- gdb-7.10.50.20151022.orig/gdb/top.h 2015-10-22 22:16:50.490482329 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/top.h 2015-10-22 22:28:22.047554171 +0200
|
||||
@@ -74,6 +74,7 @@ extern int gdb_in_secondary_prompt_p (vo
|
||||
|
||||
/* From random places. */
|
||||
extern int readnow_symbol_files;
|
||||
|
@ -1,7 +1,7 @@
|
||||
Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.cp/constructortest.cc
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/constructortest.cc
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.4.50.20111219/gdb/testsuite/gdb.cp/constructortest.cc 2011-12-19 22:05:02.825431735 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/constructortest.cc 2016-02-16 09:49:08.681886201 +0100
|
||||
@@ -0,0 +1,99 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -102,10 +102,10 @@ Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.cp/constructortest.cc
|
||||
+{
|
||||
+ y = 2; /* First line D */
|
||||
+}
|
||||
Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.cp/constructortest.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/constructortest.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.4.50.20111219/gdb/testsuite/gdb.cp/constructortest.exp 2011-12-19 23:07:24.148290893 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/constructortest.exp 2016-02-16 09:52:12.609130779 +0100
|
||||
@@ -0,0 +1,130 @@
|
||||
+# This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -129,7 +129,7 @@ Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.cp/constructortest.exp
|
||||
+
|
||||
+set testfile "constructortest"
|
||||
+set srcfile ${testfile}.cc
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+# PIE is required for testing proper BREAKPOINT_RE_SET of the multiple-PC
|
||||
+# breakpoints.
|
||||
+if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++ "additional_flags=-fpie -pie"}] != "" } {
|
||||
|
@ -4,10 +4,10 @@
|
||||
* gdb.base/move-dir.c: Ditto.
|
||||
* gdb.base/move-dir.h: Ditto.
|
||||
|
||||
Index: gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/move-dir.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.c 2008-12-07 23:57:41.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/move-dir.c 2016-02-15 23:23:02.892499288 +0100
|
||||
@@ -0,0 +1,10 @@
|
||||
+#include <stdio.h>
|
||||
+#include <stdlib.h>
|
||||
@ -19,10 +19,10 @@ Index: gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.c
|
||||
+ other();
|
||||
+}
|
||||
+
|
||||
Index: gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/move-dir.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.exp 2008-12-07 10:13:01.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/move-dir.exp 2016-02-15 23:29:58.768461406 +0100
|
||||
@@ -0,0 +1,57 @@
|
||||
+# Copyright 2005
|
||||
+# Free Software Foundation, Inc.
|
||||
@ -44,17 +44,17 @@ Index: gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.exp
|
||||
+set testfile "move-dir"
|
||||
+set srcfile ${testfile}.c
|
||||
+set incfile ${testfile}.h
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+set testdir "${objdir}/${subdir}/incdir"
|
||||
+set testdir [standard_output_file incdir]
|
||||
+
|
||||
+remote_exec build "mkdir $testdir"
|
||||
+remote_exec build "cp ${srcdir}/${subdir}/${srcfile} ${objdir}/${subdir}"
|
||||
+remote_exec build "cp ${srcdir}/${subdir}/${incfile} ${testdir}"
|
||||
+remote_exec build "cp ${srcdir}/${subdir}/${srcfile} [standard_output_file ${srcfile}]"
|
||||
+remote_exec build "cp ${srcdir}/${subdir}/${incfile} [standard_output_file ${incfile}]"
|
||||
+
|
||||
+set additional_flags "additional_flags=-I${subdir}/incdir"
|
||||
+
|
||||
+if { [gdb_compile "${objdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug $additional_flags]] != "" } {
|
||||
+if { [gdb_compile [standard_output_file ${srcfile}] "${binfile}" executable [list debug $additional_flags]] != "" } {
|
||||
+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
|
||||
+}
|
||||
+
|
||||
@ -81,10 +81,10 @@ Index: gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.exp
|
||||
+
|
||||
+set timeout $oldtimeout
|
||||
+return 0
|
||||
Index: gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.h
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/move-dir.h
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.8.50.20081128/gdb/testsuite/gdb.base/move-dir.h 2008-12-07 10:13:01.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/move-dir.h 2016-02-15 23:23:02.892499288 +0100
|
||||
@@ -0,0 +1,7 @@
|
||||
+#include <stdlib.h>
|
||||
+
|
||||
|
@ -1,39 +1,7 @@
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/configure.ac
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/testsuite/configure.ac 2015-05-31 16:34:02.396969450 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/configure.ac 2015-05-31 16:34:33.443196711 +0200
|
||||
@@ -114,5 +114,5 @@ AC_OUTPUT([Makefile \
|
||||
gdb.guile/Makefile gdb.linespec/Makefile \
|
||||
gdb.mi/Makefile gdb.modula2/Makefile gdb.multi/Makefile \
|
||||
gdb.objc/Makefile gdb.opencl/Makefile gdb.opt/Makefile gdb.pascal/Makefile \
|
||||
- gdb.perf/Makefile gdb.python/Makefile gdb.reverse/Makefile gdb.stabs/Makefile \
|
||||
+ gdb.perf/Makefile gdb.pie/Makefile gdb.python/Makefile gdb.reverse/Makefile gdb.stabs/Makefile \
|
||||
gdb.threads/Makefile gdb.trace/Makefile gdb.xml/Makefile])
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/configure
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/testsuite/configure 2015-05-31 16:33:53.154901798 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/configure 2015-05-31 16:34:48.654308057 +0200
|
||||
@@ -3514,7 +3514,7 @@ program_transform_name=`$as_echo "$progr
|
||||
ac_config_files="$ac_config_files lib/pdtrace"
|
||||
|
||||
|
||||
-ac_config_files="$ac_config_files Makefile gdb.ada/Makefile gdb.arch/Makefile gdb.asm/Makefile gdb.base/Makefile gdb.btrace/Makefile gdb.cell/Makefile gdb.compile/Makefile gdb.cp/Makefile gdb.disasm/Makefile gdb.dwarf2/Makefile gdb.dlang/Makefile gdb.fortran/Makefile gdb.gdb/Makefile gdb.go/Makefile gdb.server/Makefile gdb.java/Makefile gdb.guile/Makefile gdb.linespec/Makefile gdb.mi/Makefile gdb.modula2/Makefile gdb.multi/Makefile gdb.objc/Makefile gdb.opencl/Makefile gdb.opt/Makefile gdb.pascal/Makefile gdb.perf/Makefile gdb.python/Makefile gdb.reverse/Makefile gdb.stabs/Makefile gdb.threads/Makefile gdb.trace/Makefile gdb.xml/Makefile"
|
||||
+ac_config_files="$ac_config_files Makefile gdb.ada/Makefile gdb.arch/Makefile gdb.asm/Makefile gdb.base/Makefile gdb.btrace/Makefile gdb.cell/Makefile gdb.compile/Makefile gdb.cp/Makefile gdb.disasm/Makefile gdb.dwarf2/Makefile gdb.dlang/Makefile gdb.fortran/Makefile gdb.gdb/Makefile gdb.go/Makefile gdb.server/Makefile gdb.java/Makefile gdb.guile/Makefile gdb.linespec/Makefile gdb.mi/Makefile gdb.modula2/Makefile gdb.multi/Makefile gdb.objc/Makefile gdb.opencl/Makefile gdb.opt/Makefile gdb.pascal/Makefile gdb.perf/Makefile gdb.pie/Makefile gdb.python/Makefile gdb.reverse/Makefile gdb.stabs/Makefile gdb.threads/Makefile gdb.trace/Makefile gdb.xml/Makefile"
|
||||
|
||||
cat >confcache <<\_ACEOF
|
||||
# This file is a shell script that caches the results of configure
|
||||
@@ -4242,6 +4242,7 @@ do
|
||||
"gdb.opt/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.opt/Makefile" ;;
|
||||
"gdb.pascal/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.pascal/Makefile" ;;
|
||||
"gdb.perf/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.perf/Makefile" ;;
|
||||
+ "gdb.pie/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.pie/Makefile" ;;
|
||||
"gdb.python/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.python/Makefile" ;;
|
||||
"gdb.reverse/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.reverse/Makefile" ;;
|
||||
"gdb.stabs/Makefile") CONFIG_FILES="$CONFIG_FILES gdb.stabs/Makefile" ;;
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/attach.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.c 2015-05-31 16:34:02.398969465 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/attach.c 2016-02-15 23:23:02.843498936 +0100
|
||||
@@ -0,0 +1,20 @@
|
||||
+/* This program is intended to be started outside of gdb, and then
|
||||
+ attached to by gdb. Thus, it simply spins in a loop. The loop
|
||||
@ -55,10 +23,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.c
|
||||
+ }
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach2.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/attach2.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach2.c 2015-05-31 16:34:02.398969465 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/attach2.c 2016-02-15 23:23:02.843498936 +0100
|
||||
@@ -0,0 +1,24 @@
|
||||
+/* This program is intended to be started outside of gdb, and then
|
||||
+ attached to by gdb. Thus, it simply spins in a loop. The loop
|
||||
@ -84,10 +52,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach2.c
|
||||
+ }
|
||||
+ return (0);
|
||||
+}
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/break.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.c 2015-05-31 16:34:02.399969472 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/break.c 2016-02-15 23:23:02.844498943 +0100
|
||||
@@ -0,0 +1,146 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -235,10 +203,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.c
|
||||
+ }
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break1.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/break1.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break1.c 2015-05-31 16:34:02.399969472 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/break1.c 2016-02-15 23:23:02.844498943 +0100
|
||||
@@ -0,0 +1,44 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -284,10 +252,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break1.c
|
||||
+void marker3 (a, b) char *a, *b; {} /* set breakpoint 18 here */
|
||||
+void marker4 (d) long d; {} /* set breakpoint 13 here */
|
||||
+#endif
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/coremaker.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/coremaker.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/coremaker.c 2015-05-31 16:34:02.399969472 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/coremaker.c 2016-02-15 23:23:02.844498943 +0100
|
||||
@@ -0,0 +1,142 @@
|
||||
+/* Copyright 1992, 1993, 1994, 1995, 1996, 1999
|
||||
+ Free Software Foundation, Inc.
|
||||
@ -431,11 +399,11 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/coremaker.c
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/attach.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.exp 2015-05-31 16:34:02.400969480 +0200
|
||||
@@ -0,0 +1,417 @@
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/attach.exp 2016-02-15 23:37:15.190560048 +0100
|
||||
@@ -0,0 +1,416 @@
|
||||
+# Copyright 1997, 1999, 2002 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
@ -471,10 +439,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.exp
|
||||
+set testfile "attach"
|
||||
+set srcfile ${testfile}.c
|
||||
+set srcfile2 ${testfile}2.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile2 ${objdir}/${subdir}/${testfile}2
|
||||
+set escapedbinfile [string_to_regexp ${objdir}/${subdir}/${testfile}]
|
||||
+set cleanupfile ${objdir}/${subdir}/${testfile}.awk
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+set binfile2 [standard_output_file ${testfile}2]
|
||||
+set escapedbinfile [string_to_regexp [standard_output_file ${testfile}]]
|
||||
+set cleanupfile [standard_output_file ${testfile}.awk]
|
||||
+
|
||||
+#execute_anywhere "rm -f ${binfile} ${binfile2}"
|
||||
+remote_exec build "rm -f ${binfile} ${binfile2}"
|
||||
@ -508,7 +476,6 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.exp
|
||||
+ global escapedbinfile
|
||||
+ global srcfile
|
||||
+ global testfile
|
||||
+ global objdir
|
||||
+ global subdir
|
||||
+ global timeout
|
||||
+
|
||||
@ -716,7 +683,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.exp
|
||||
+ # when we're cd'd to some directory that doesn't contain the
|
||||
+ # a.out. (We use the source path set by the "dir" command.)
|
||||
+ #
|
||||
+ send_gdb "dir ${objdir}/${subdir}\n"
|
||||
+ send_gdb "dir [file dirname [standard_output_file ${testfile}]]\n"
|
||||
+ gdb_expect {
|
||||
+ -re ".*Source directories searched: .*$gdb_prompt $"\
|
||||
+ {pass "set source path"}
|
||||
@ -853,11 +820,11 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/attach.exp
|
||||
+do_call_attach_tests
|
||||
+
|
||||
+return 0
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/break.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp 2015-05-31 16:34:02.401969487 +0200
|
||||
@@ -0,0 +1,962 @@
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/break.exp 2016-02-15 23:37:15.191560055 +0100
|
||||
@@ -0,0 +1,954 @@
|
||||
+# Copyright 1988, 1990, 1991, 1992, 1994, 1995, 1996, 1997, 1998, 1999,
|
||||
+# 2000, 2002, 2003, 2004
|
||||
+# Free Software Foundation, Inc.
|
||||
@ -886,7 +853,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp
|
||||
+set testfile "break"
|
||||
+set srcfile ${testfile}.c
|
||||
+set srcfile1 ${testfile}1.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}0.o" object {debug "additional_flags=-w -fpie -pie"}] != "" } {
|
||||
+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
|
||||
@ -1018,11 +985,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp
|
||||
+ set main_line $bp_location6
|
||||
+}
|
||||
+
|
||||
+if {$hp_aCC_compiler} {
|
||||
+ set proto "\\(int\\)"
|
||||
+} else {
|
||||
+ set proto ""
|
||||
+}
|
||||
+set proto ""
|
||||
+
|
||||
+set bp_location7 [gdb_get_line_number "set breakpoint 7 here"]
|
||||
+set bp_location8 [gdb_get_line_number "set breakpoint 8 here" $srcfile1]
|
||||
@ -1359,14 +1322,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp
|
||||
+ {fail "thread-specific breakpoint on non-existent thread disallowed"}
|
||||
+ timeout {fail "(timeout) thread-specific breakpoint on non-existent thread disallowed"}
|
||||
+}
|
||||
+send_gdb "break $bp_location12 thread foo\n"
|
||||
+gdb_expect {
|
||||
+ -re "Junk after thread keyword..*$gdb_prompt $"\
|
||||
+ {pass "thread-specific breakpoint on bogus thread ID disallowed"}
|
||||
+ -re "$gdb_prompt $"\
|
||||
+ {fail "thread-specific breakpoint on bogus thread ID disallowed"}
|
||||
+ timeout {fail "(timeout) thread-specific breakpoint on bogus thread ID disallowed"}
|
||||
+}
|
||||
+
|
||||
+gdb_test "break $bp_location12 thread foo" \
|
||||
+ "Invalid thread ID: foo" \
|
||||
+ "thread-specific breakpoint on bogus thread ID disallowed"
|
||||
+
|
||||
+# Verify that GDB responds gracefully to a breakpoint command with
|
||||
+# trailing garbage.
|
||||
@ -1707,7 +1666,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp
|
||||
+# build a new file with optimization enabled so that we can try breakpoints
|
||||
+# on targets with optimized prologues
|
||||
+
|
||||
+set binfileo2 ${objdir}/${subdir}/${testfile}o2
|
||||
+set binfileo2 [standard_output_file ${testfile}o2]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}O0.o" object {debug "additional_flags=-w -O2 -fpie -pie"}] != "" } {
|
||||
+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
|
||||
@ -1820,10 +1779,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/break.exp
|
||||
+ send_gdb "set args main\n"
|
||||
+ gdb_expect -re ".*$gdb_prompt $" {}
|
||||
+}
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/corefile.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp 2015-05-31 16:34:02.401969487 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pie/corefile.exp 2016-02-15 23:37:15.191560055 +0100
|
||||
@@ -0,0 +1,233 @@
|
||||
+# Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000
|
||||
+# Free Software Foundation, Inc.
|
||||
@ -1851,7 +1810,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+
|
||||
+set testfile "coremaker"
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug "additional_flags=-fpie -pie"}] != "" } {
|
||||
+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
|
||||
+}
|
||||
@ -1876,13 +1835,13 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+# could have many core files lying around, and it may be difficult to
|
||||
+# tell which one is ours, so let's run the program in a subdirectory.
|
||||
+set found 0
|
||||
+set coredir "${objdir}/${subdir}/coredir.[getpid]"
|
||||
+set coredir [standard_output_file coredir.[getpid]]
|
||||
+file mkdir $coredir
|
||||
+catch "system \"(cd ${coredir}; ulimit -c unlimited; ${binfile}; true) >/dev/null 2>&1\""
|
||||
+# remote_exec host "${binfile}"
|
||||
+foreach i "${coredir}/core ${coredir}/core.coremaker.c ${binfile}.core" {
|
||||
+ if [remote_file build exists $i] {
|
||||
+ remote_exec build "mv $i ${objdir}/${subdir}/corefile"
|
||||
+ remote_exec build "mv $i [standard_output_file corefile]"
|
||||
+ set found 1
|
||||
+ }
|
||||
+}
|
||||
@ -1891,7 +1850,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+ set names [glob -nocomplain -directory $coredir core.*]
|
||||
+ if {[llength $names] == 1} {
|
||||
+ set corefile [file join $coredir [lindex $names 0]]
|
||||
+ remote_exec build "mv $corefile ${objdir}/${subdir}/corefile"
|
||||
+ remote_exec build "mv $corefile [standard_output_file corefile]"
|
||||
+ set found 1
|
||||
+ }
|
||||
+}
|
||||
@ -1901,10 +1860,10 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+ # ulimit here if we didn't find a core file above.
|
||||
+ # Oh, I should mention that any "braindamaged" non-Unix system has
|
||||
+ # the same problem. I like the cd bit too, it's really neat'n stuff.
|
||||
+ catch "system \"(cd ${objdir}/${subdir}; ${binfile}; true) >/dev/null 2>&1\""
|
||||
+ foreach i "${objdir}/${subdir}/core ${objdir}/${subdir}/core.coremaker.c ${binfile}.core" {
|
||||
+ catch "system \"(cd [file dirname [standard_output_file ${binfile}]]; ${binfile}; true) >/dev/null 2>&1\""
|
||||
+ foreach i "[standard_output_file core] [standard_output_file core.coremaker.c] ${binfile}.core" {
|
||||
+ if [remote_file build exists $i] {
|
||||
+ remote_exec build "mv $i ${objdir}/${subdir}/corefile"
|
||||
+ remote_exec build "mv $i [standard_output_file corefile]"
|
||||
+ set found 1
|
||||
+ }
|
||||
+ }
|
||||
@ -1937,13 +1896,13 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+
|
||||
+gdb_exit
|
||||
+if $verbose>1 then {
|
||||
+ send_user "Spawning $GDB -nw $GDBFLAGS -core=$objdir/$subdir/corefile\n"
|
||||
+ send_user "Spawning $GDB -nw $GDBFLAGS -core=[standard_output_file corefile]\n"
|
||||
+}
|
||||
+
|
||||
+set oldtimeout $timeout
|
||||
+set timeout [expr "$timeout + 60"]
|
||||
+verbose "Timeout is now $timeout seconds" 2
|
||||
+eval "spawn $GDB -nw $GDBFLAGS -core=$objdir/$subdir/corefile"
|
||||
+eval "spawn $GDB -nw $GDBFLAGS -core=[standard_output_file corefile]"
|
||||
+expect {
|
||||
+ -re "Couldn't find .* registers in core file.*$gdb_prompt $" {
|
||||
+ fail "args: -core=corefile (couldn't find regs)"
|
||||
@ -1970,11 +1929,11 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+close;
|
||||
+
|
||||
+if $verbose>1 then {
|
||||
+ send_user "Spawning $GDB -nw $GDBFLAGS $binfile -core=$objdir/$subdir/corefile\n"
|
||||
+ send_user "Spawning $GDB -nw $GDBFLAGS $binfile -core=[standard_output_file corefile]\n"
|
||||
+}
|
||||
+
|
||||
+
|
||||
+eval "spawn $GDB -nw $GDBFLAGS $binfile -core=$objdir/$subdir/corefile";
|
||||
+eval "spawn $GDB -nw $GDBFLAGS $binfile -core=[standard_output_file corefile]";
|
||||
+expect {
|
||||
+ -re "Core was generated by .*coremaker.*\r\n\#0 .*\(\).*\r\n$gdb_prompt $" {
|
||||
+ pass "args: execfile -core=corefile"
|
||||
@ -2001,7 +1960,7 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+
|
||||
+# Test basic corefile recognition via core-file command.
|
||||
+
|
||||
+send_gdb "core-file $objdir/$subdir/corefile\n"
|
||||
+send_gdb "core-file [standard_output_file corefile]\n"
|
||||
+gdb_expect {
|
||||
+ -re ".* program is being debugged already.*y or n. $" {
|
||||
+ # gdb_load may connect us to a gdbserver.
|
||||
@ -2058,27 +2017,3 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/corefile.exp
|
||||
+gdb_test "up" "#\[0-9\]* *\[0-9xa-fH'\]* in .* \\(.*\\).*" "up in corefile.exp (reinit)"
|
||||
+
|
||||
+gdb_test "core" "No core file now."
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/Makefile.in
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.pie/Makefile.in 2015-05-31 16:34:02.401969487 +0200
|
||||
@@ -0,0 +1,19 @@
|
||||
+VPATH = @srcdir@
|
||||
+srcdir = @srcdir@
|
||||
+
|
||||
+EXECUTABLES =
|
||||
+MISCELLANEOUS = arch.inc
|
||||
+
|
||||
+all info install-info dvi install uninstall installcheck check:
|
||||
+ @echo "Nothing to be done for $@..."
|
||||
+
|
||||
+clean mostlyclean:
|
||||
+ -rm -f *~ *.o a.out *.x *.ci *.tmp
|
||||
+ -rm -f core core.coremaker coremaker.core corefile $(EXECUTABLES)
|
||||
+ -rm -f $(MISCELLANEOUS)
|
||||
+
|
||||
+distclean maintainer-clean realclean: clean
|
||||
+ -rm -f *~ core
|
||||
+ -rm -f Makefile config.status config.log
|
||||
+ -rm -f *-init.exp
|
||||
+ -rm -fr *.log summary detail *.plog *.sum *.psum site.*
|
||||
|
@ -42,10 +42,10 @@
|
||||
|
||||
FIXME: The testcase does not expects multiple watchpoints hits per one stop.
|
||||
|
||||
Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.threads/watchthreads-threaded.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/watchthreads-threaded.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.4.50.20111219/gdb/testsuite/gdb.threads/watchthreads-threaded.c 2011-12-19 22:05:02.867431570 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/watchthreads-threaded.c 2016-02-15 23:37:39.766734541 +0100
|
||||
@@ -0,0 +1,66 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -113,10 +113,10 @@ Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.threads/watchthreads-threaded.c
|
||||
+ pthread_exit(NULL);
|
||||
+}
|
||||
+
|
||||
Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.threads/watchthreads-threaded.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/watchthreads-threaded.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.4.50.20111219/gdb/testsuite/gdb.threads/watchthreads-threaded.exp 2011-12-19 22:28:33.294911982 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/watchthreads-threaded.exp 2016-02-15 23:40:32.484960858 +0100
|
||||
@@ -0,0 +1,126 @@
|
||||
+# This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -146,7 +146,7 @@ Index: gdb-7.4.50.20111219/gdb/testsuite/gdb.threads/watchthreads-threaded.exp
|
||||
+
|
||||
+set testfile "watchthreads-threaded"
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "incdir=${objdir}"]] != "" } {
|
||||
+ return -1
|
||||
+}
|
||||
|
@ -1,7 +1,7 @@
|
||||
Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.c 2013-05-21 13:35:45.592059786 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.c 2016-02-15 23:37:39.884735379 +0100
|
||||
@@ -0,0 +1,301 @@
|
||||
+/*
|
||||
+ * The point of this program is to crash in a multi-threaded app.
|
||||
@ -304,10 +304,10 @@ Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.c
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.exp 2013-05-21 13:36:01.451056746 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.exp 2016-02-15 23:38:58.486293458 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+# threadcrash.exp - The point of this program is to crash in a multi-threaded app.
|
||||
+
|
||||
@ -315,7 +315,7 @@ Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.exp
|
||||
+set testfile threadcrash
|
||||
+set srcfile ${testfile}.c
|
||||
+set shellfile ${srcdir}/${subdir}/${testfile}.sh
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+set GDB_abs ${GDB}
|
||||
+if [regexp "^\[^/\]" ${GDB_abs}] {
|
||||
@ -346,10 +346,10 @@ Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.exp
|
||||
+}
|
||||
+
|
||||
+return 0
|
||||
Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.sh
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.sh
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.sh 2013-05-21 13:35:45.593059786 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.sh 2016-02-15 23:37:39.885735386 +0100
|
||||
@@ -0,0 +1,324 @@
|
||||
+#! /bin/bash
|
||||
+
|
||||
@ -675,10 +675,10 @@ Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.sh
|
||||
+rm -rf $WORKDIR
|
||||
+
|
||||
+exit $FAILURES
|
||||
Index: gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.sh-orig
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.sh-orig
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.6/gdb/testsuite/gdb.threads/threadcrash.sh-orig 2013-05-21 13:35:45.593059786 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threadcrash.sh-orig 2016-02-15 23:37:39.885735386 +0100
|
||||
@@ -0,0 +1,248 @@
|
||||
+#! /bin/bash
|
||||
+
|
||||
|
@ -16,8 +16,10 @@ http://sourceware.org/ml/gdb-patches/2007-01/msg00434.html
|
||||
* gdb.dwarf2/dw2-included.exp, gdb.dwarf2/dw2-included.c,
|
||||
gdb.dwarf2/dw2-included.h: New files.
|
||||
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.dwarf2/dw2-included.c 2 Jan 2007 00:20:27 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-included.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-included.c 2016-02-16 09:52:29.861247534 +0100
|
||||
@@ -0,0 +1,26 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -45,8 +47,10 @@ http://sourceware.org/ml/gdb-patches/2007-01/msg00434.html
|
||||
+{
|
||||
+ return 0;
|
||||
+}
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.dwarf2/dw2-included.exp 2 Jan 2007 00:20:27 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-included.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-included.exp 2016-02-16 09:52:36.481292330 +0100
|
||||
@@ -0,0 +1,47 @@
|
||||
+# Copyright 2006 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -79,7 +83,7 @@ http://sourceware.org/ml/gdb-patches/2007-01/msg00434.html
|
||||
+
|
||||
+set testfile "dw2-included"
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ return -1
|
||||
@ -95,8 +99,10 @@ http://sourceware.org/ml/gdb-patches/2007-01/msg00434.html
|
||||
+gdb_test "ptype integer" "type = int\r"
|
||||
+# Path varies depending on the build location.
|
||||
+gdb_test "info variables integer" "\r\nFile \[^\r\n\]*/gdb.dwarf2/dw2-included.h:\r\nint integer;\r"
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.dwarf2/dw2-included.h 2 Jan 2007 00:20:27 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-included.h
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-included.h 2016-02-16 09:52:29.862247541 +0100
|
||||
@@ -0,0 +1,20 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
|
@ -34,11 +34,11 @@ glibc-debuginfo-2.7-2.x86_64: /usr/lib/debug/lib64/libc.so.6.debug:
|
||||
<81a2> DW_AT_name : (indirect string, offset: 0x280e): __errno_location
|
||||
<81a8> DW_AT_MIPS_linkage_name: (indirect string, offset: 0x2808): *__GI___errno_location
|
||||
|
||||
Index: gdb-7.8.1/gdb/printcmd.c
|
||||
Index: gdb-7.10.90.20160211/gdb/printcmd.c
|
||||
===================================================================
|
||||
--- gdb-7.8.1.orig/gdb/printcmd.c 2014-11-21 19:05:44.699959209 +0100
|
||||
+++ gdb-7.8.1/gdb/printcmd.c 2014-11-21 19:05:44.868959291 +0100
|
||||
@@ -980,6 +980,10 @@ print_command_1 (const char *exp, int vo
|
||||
--- gdb-7.10.90.20160211.orig/gdb/printcmd.c 2016-02-15 23:29:53.062420893 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/printcmd.c 2016-02-15 23:33:31.068968762 +0100
|
||||
@@ -1003,6 +1003,10 @@
|
||||
|
||||
if (exp && *exp)
|
||||
{
|
||||
@ -49,10 +49,10 @@ Index: gdb-7.8.1/gdb/printcmd.c
|
||||
expr = parse_expression (exp);
|
||||
make_cleanup (free_current_contents, &expr);
|
||||
val = evaluate_expression (expr);
|
||||
Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.c 2014-11-21 19:05:44.869959291 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno.c 2016-02-15 23:30:20.703617148 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -82,10 +82,10 @@ Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.c
|
||||
+
|
||||
+ return 0; /* breakpoint */
|
||||
+}
|
||||
Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.exp 2014-11-21 19:05:44.869959291 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno.exp 2016-02-15 23:35:25.582781821 +0100
|
||||
@@ -0,0 +1,60 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -104,7 +104,7 @@ Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.exp
|
||||
+
|
||||
+set testfile dw2-errno
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+proc prep {} {
|
||||
+ global srcdir subdir binfile
|
||||
@ -147,10 +147,10 @@ Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno.exp
|
||||
+
|
||||
+# TODO: Test the error on resolving ERRNO with only libc loaded.
|
||||
+# Just how to find the current libc filename?
|
||||
Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno2.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno2.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno2.c 2014-11-21 19:05:44.869959291 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno2.c 2016-02-15 23:30:20.703617148 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -180,10 +180,10 @@ Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno2.c
|
||||
+
|
||||
+ return 0; /* breakpoint */
|
||||
+}
|
||||
Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno2.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno2.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno2.exp 2014-11-21 19:13:01.553171326 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-errno2.exp 2016-02-15 23:35:25.582781821 +0100
|
||||
@@ -0,0 +1,71 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -202,7 +202,7 @@ Index: gdb-7.8.1/gdb/testsuite/gdb.dwarf2/dw2-errno2.exp
|
||||
+
|
||||
+set testfile dw2-errno2
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+proc prep { message {do_xfail 0} } { with_test_prefix $message {
|
||||
+ global srcdir subdir binfile variant
|
||||
|
@ -23,11 +23,11 @@ instead.
|
||||
|
||||
Port to GDB-6.7.
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/amd64-linux-tdep.c
|
||||
Index: gdb-7.10.90.20160211/gdb/amd64-linux-tdep.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/amd64-linux-tdep.c 2015-01-01 17:01:51.506856241 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/amd64-linux-tdep.c 2015-01-01 17:01:54.769854349 +0100
|
||||
@@ -290,6 +290,80 @@ amd64_linux_register_reggroup_p (struct
|
||||
--- gdb-7.10.90.20160211.orig/gdb/amd64-linux-tdep.c 2016-02-15 23:37:06.936501443 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/amd64-linux-tdep.c 2016-02-15 23:37:39.928735691 +0100
|
||||
@@ -292,6 +292,80 @@
|
||||
|
||||
/* Set the program counter for process PTID to PC. */
|
||||
|
||||
@ -108,7 +108,7 @@ Index: gdb-7.8.50.20141228/gdb/amd64-linux-tdep.c
|
||||
static void
|
||||
amd64_linux_write_pc (struct regcache *regcache, CORE_ADDR pc)
|
||||
{
|
||||
@@ -1657,6 +1731,8 @@ amd64_linux_init_abi_common(struct gdbar
|
||||
@@ -1800,6 +1874,8 @@
|
||||
|
||||
tdep->xsave_xcr0_offset = I386_LINUX_XSAVE_XCR0_OFFSET;
|
||||
|
||||
@ -117,11 +117,11 @@ Index: gdb-7.8.50.20141228/gdb/amd64-linux-tdep.c
|
||||
/* Add the %orig_rax register used for syscall restarting. */
|
||||
set_gdbarch_write_pc (gdbarch, amd64_linux_write_pc);
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/amd64-tdep.c
|
||||
Index: gdb-7.10.90.20160211/gdb/amd64-tdep.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/amd64-tdep.c 2015-01-01 17:01:51.507856240 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/amd64-tdep.c 2015-01-01 17:01:54.770854349 +0100
|
||||
@@ -2492,6 +2492,7 @@ amd64_frame_unwind_stop_reason (struct f
|
||||
--- gdb-7.10.90.20160211.orig/gdb/amd64-tdep.c 2016-02-15 23:37:06.936501443 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/amd64-tdep.c 2016-02-15 23:37:39.929735698 +0100
|
||||
@@ -2494,6 +2494,7 @@
|
||||
{
|
||||
struct amd64_frame_cache *cache =
|
||||
amd64_frame_cache (this_frame, this_cache);
|
||||
@ -129,7 +129,7 @@ Index: gdb-7.8.50.20141228/gdb/amd64-tdep.c
|
||||
|
||||
if (!cache->base_p)
|
||||
return UNWIND_UNAVAILABLE;
|
||||
@@ -2500,6 +2501,10 @@ amd64_frame_unwind_stop_reason (struct f
|
||||
@@ -2502,6 +2503,10 @@
|
||||
if (cache->base == 0)
|
||||
return UNWIND_OUTERMOST;
|
||||
|
||||
@ -140,7 +140,7 @@ Index: gdb-7.8.50.20141228/gdb/amd64-tdep.c
|
||||
return UNWIND_NO_REASON;
|
||||
}
|
||||
|
||||
@@ -2631,6 +2636,7 @@ amd64_sigtramp_frame_this_id (struct fra
|
||||
@@ -2636,6 +2641,7 @@
|
||||
{
|
||||
struct amd64_frame_cache *cache =
|
||||
amd64_sigtramp_frame_cache (this_frame, this_cache);
|
||||
@ -148,7 +148,7 @@ Index: gdb-7.8.50.20141228/gdb/amd64-tdep.c
|
||||
|
||||
if (!cache->base_p)
|
||||
(*this_id) = frame_id_build_unavailable_stack (get_frame_pc (this_frame));
|
||||
@@ -2639,6 +2645,11 @@ amd64_sigtramp_frame_this_id (struct fra
|
||||
@@ -2644,6 +2650,11 @@
|
||||
/* This marks the outermost frame. */
|
||||
return;
|
||||
}
|
||||
@ -160,11 +160,11 @@ Index: gdb-7.8.50.20141228/gdb/amd64-tdep.c
|
||||
else
|
||||
(*this_id) = frame_id_build (cache->base + 16, get_frame_pc (this_frame));
|
||||
}
|
||||
Index: gdb-7.8.50.20141228/gdb/i386-tdep.c
|
||||
Index: gdb-7.10.90.20160211/gdb/i386-tdep.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/i386-tdep.c 2015-01-01 17:01:51.509856239 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/i386-tdep.c 2015-01-01 17:01:54.772854348 +0100
|
||||
@@ -8286,6 +8286,9 @@ i386_gdbarch_init (struct gdbarch_info i
|
||||
--- gdb-7.10.90.20160211.orig/gdb/i386-tdep.c 2016-02-15 23:37:06.936501443 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/i386-tdep.c 2016-02-15 23:37:39.931735713 +0100
|
||||
@@ -8305,6 +8305,9 @@
|
||||
|
||||
tdep->xsave_xcr0_offset = -1;
|
||||
|
||||
@ -174,11 +174,11 @@ Index: gdb-7.8.50.20141228/gdb/i386-tdep.c
|
||||
tdep->record_regmap = i386_record_regmap;
|
||||
|
||||
set_gdbarch_long_long_align_bit (gdbarch, 32);
|
||||
Index: gdb-7.8.50.20141228/gdb/i386-tdep.h
|
||||
Index: gdb-7.10.90.20160211/gdb/i386-tdep.h
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/i386-tdep.h 2015-01-01 17:01:54.772854348 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/i386-tdep.h 2015-01-01 17:02:15.826842143 +0100
|
||||
@@ -240,6 +240,9 @@ struct gdbarch_tdep
|
||||
--- gdb-7.10.90.20160211.orig/gdb/i386-tdep.h 2016-02-15 23:37:06.936501443 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/i386-tdep.h 2016-02-15 23:37:39.932735720 +0100
|
||||
@@ -240,6 +240,9 @@
|
||||
|
||||
/* Regsets. */
|
||||
const struct regset *fpregset;
|
||||
@ -188,10 +188,10 @@ Index: gdb-7.8.50.20141228/gdb/i386-tdep.h
|
||||
};
|
||||
|
||||
/* Floating-point registers. */
|
||||
Index: gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/bt-clone-stop.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.c 2015-01-01 17:01:54.773854347 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/bt-clone-stop.c 2016-02-15 23:37:39.932735720 +0100
|
||||
@@ -0,0 +1,39 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -232,10 +232,10 @@ Index: gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.c
|
||||
+ for (;;)
|
||||
+ pause();
|
||||
+}
|
||||
Index: gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/bt-clone-stop.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.exp 2015-01-01 17:01:54.774854346 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/bt-clone-stop.exp 2016-02-15 23:37:56.197851204 +0100
|
||||
@@ -0,0 +1,61 @@
|
||||
+# Copyright 2006 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -261,7 +261,7 @@ Index: gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.exp
|
||||
+
|
||||
+set testfile bt-clone-stop
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -278,7 +278,7 @@ Index: gdb-7.8.50.20141228/gdb/testsuite/gdb.threads/bt-clone-stop.exp
|
||||
+# Program received signal SIGABRT, Aborted.
|
||||
+
|
||||
+gdb_test "run" \
|
||||
+ "Program received signal SIGABRT.*" \
|
||||
+ {Thread 2 "bt-clone-stop" received signal SIGABRT.*} \
|
||||
+ "run"
|
||||
+
|
||||
+# Former gdb unwind (the first function is `clone'):
|
||||
|
@ -1,8 +1,10 @@
|
||||
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=218379
|
||||
|
||||
|
||||
--- /dev/null 2006-12-17 14:18:21.881669220 -0500
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/step-over-trampoline.exp 2006-12-17 16:52:51.000000000 -0500
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/step-over-trampoline.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/step-over-trampoline.exp 2016-02-15 23:31:47.312232078 +0100
|
||||
@@ -0,0 +1,54 @@
|
||||
+# Copyright 2006 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -26,7 +28,7 @@ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=218379
|
||||
+
|
||||
+set testfile step-over-trampoline
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -58,8 +60,10 @@ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=218379
|
||||
+ fail "stepped into trampoline"
|
||||
+ }
|
||||
+}
|
||||
--- /dev/null 2006-12-17 14:18:21.881669220 -0500
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/step-over-trampoline.c 2006-12-17 16:18:12.000000000 -0500
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/step-over-trampoline.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/step-over-trampoline.c 2016-02-15 23:30:54.698858518 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
|
@ -1,6 +1,7 @@
|
||||
diff -u -X /home/jkratoch/.diffi.list -ruNp gdb-6.5/gdb/testsuite/gdb.base/gcore-excessive-memory.c gdb-6.5-unknown/gdb/testsuite/gdb.base/gcore-excessive-memory.c
|
||||
--- gdb-6.5/gdb/testsuite/gdb.base/gcore-excessive-memory.c 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ gdb-6.5-unknown/gdb/testsuite/gdb.base/gcore-excessive-memory.c 2008-01-08 11:25:45.000000000 +0100
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcore-excessive-memory.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcore-excessive-memory.c 2016-02-15 23:28:15.943731340 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -39,9 +40,10 @@ diff -u -X /home/jkratoch/.diffi.list -ruNp gdb-6.5/gdb/testsuite/gdb.base/gcore
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
diff -u -X /home/jkratoch/.diffi.list -ruNp gdb-6.5/gdb/testsuite/gdb.base/gcore-excessive-memory.exp gdb-6.5-unknown/gdb/testsuite/gdb.base/gcore-excessive-memory.exp
|
||||
--- gdb-6.5/gdb/testsuite/gdb.base/gcore-excessive-memory.exp 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ gdb-6.5-unknown/gdb/testsuite/gdb.base/gcore-excessive-memory.exp 2008-01-08 11:47:32.000000000 +0100
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcore-excessive-memory.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcore-excessive-memory.exp 2016-02-15 23:28:22.720779458 +0100
|
||||
@@ -0,0 +1,94 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -61,9 +63,9 @@ diff -u -X /home/jkratoch/.diffi.list -ruNp gdb-6.5/gdb/testsuite/gdb.base/gcore
|
||||
+
|
||||
+set testfile gcore-excessive-memory
|
||||
+set srcfile ${testfile}.c
|
||||
+set shfile ${objdir}/${subdir}/${testfile}-gdb.sh
|
||||
+set corefile ${objdir}/${subdir}/${testfile}.core
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set shfile [standard_output_file ${testfile}-gdb.sh]
|
||||
+set corefile [standard_output_file ${testfile}.core]
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
|
@ -1,6 +1,7 @@
|
||||
diff -u -rup gdb-6.3-orig/gdb/testsuite/gdb.base/unwind-leak.c gdb-6.3/gdb/testsuite/gdb.base/unwind-leak.c
|
||||
--- gdb-6.3-orig/gdb/testsuite/gdb.base/unwind-leak.c 2007-12-19 15:12:55.000000000 -0500
|
||||
+++ gdb-6.3/gdb/testsuite/gdb.base/unwind-leak.c 2007-12-19 13:55:22.000000000 -0500
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/unwind-leak.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/unwind-leak.c 2016-02-15 23:32:11.307402446 +0100
|
||||
@@ -0,0 +1,29 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -31,9 +32,10 @@ diff -u -rup gdb-6.3-orig/gdb/testsuite/gdb.base/unwind-leak.c gdb-6.3/gdb/tests
|
||||
+ alarm (0);
|
||||
+ return 0;
|
||||
+}
|
||||
diff -u -rup gdb-6.3-orig/gdb/testsuite/gdb.base/unwind-leak.exp gdb-6.3/gdb/testsuite/gdb.base/unwind-leak.exp
|
||||
--- gdb-6.3-orig/gdb/testsuite/gdb.base/unwind-leak.exp 2007-12-19 15:12:53.000000000 -0500
|
||||
+++ gdb-6.3/gdb/testsuite/gdb.base/unwind-leak.exp 2007-12-19 15:11:35.000000000 -0500
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/unwind-leak.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/unwind-leak.exp 2016-02-15 23:32:18.559453937 +0100
|
||||
@@ -0,0 +1,83 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -53,8 +55,8 @@ diff -u -rup gdb-6.3-orig/gdb/testsuite/gdb.base/unwind-leak.exp gdb-6.3/gdb/tes
|
||||
+
|
||||
+set testfile unwind-leak
|
||||
+set srcfile ${testfile}.c
|
||||
+set shfile ${objdir}/${subdir}/${testfile}-gdb.sh
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set shfile [standard_output_file ${testfile}-gdb.sh]
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
|
@ -1,8 +1,10 @@
|
||||
Fix has been committed to:
|
||||
gdb-6.6-scheduler_locking-step-sw-watchpoints2.patch
|
||||
|
||||
--- /dev/null 2007-12-14 20:45:09.113039517 +0100
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/watchpoint-during-step.exp 2007-12-24 19:42:00.000000000 +0100
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-during-step.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-during-step.exp 2016-02-15 23:34:10.455248408 +0100
|
||||
@@ -0,0 +1,44 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -22,7 +24,7 @@ Fix has been committed to:
|
||||
+
|
||||
+set testfile watchpoint-during-step
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -48,8 +50,10 @@ Fix has been committed to:
|
||||
+# we step from as in this case it is a valid upstream KFAIL gdb/38
|
||||
+
|
||||
+gdb_test "step" ".*Old value = 2.*New value = 3.*" "Catch the watchpoint"
|
||||
--- /dev/null 2007-12-14 20:45:09.113039517 +0100
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/watchpoint-during-step.c 2007-12-24 19:38:10.000000000 +0100
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-during-step.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-during-step.c 2016-02-15 23:32:51.846690279 +0100
|
||||
@@ -0,0 +1,30 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
|
@ -1,13 +1,11 @@
|
||||
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=214196
|
||||
|
||||
|
||||
Index: ./gdb/testsuite/gdb.base/readline-overflow.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/readline-overflow.exp
|
||||
===================================================================
|
||||
RCS file: ./gdb/testsuite/gdb.base/readline-overflow.exp
|
||||
diff -N ./gdb/testsuite/gdb.base/readline-overflow.exp
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/readline-overflow.exp 13 Nov 2006 23:42:50 -0000
|
||||
@@ -0,0 +1,125 @@
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/readline-overflow.exp 2016-02-15 23:30:29.191677414 +0100
|
||||
@@ -0,0 +1,126 @@
|
||||
+# Copyright 2006 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
@ -110,7 +108,8 @@ diff -N ./gdb/testsuite/gdb.base/readline-overflow.exp
|
||||
+ gdb_clear_suppressed
|
||||
+ }
|
||||
+}
|
||||
+gdb_test "\r" \
|
||||
+send_gdb "\r"
|
||||
+gdb_test "" \
|
||||
+ "No executable file specified..*" \
|
||||
+ "All the characters transferred"
|
||||
+
|
||||
@ -133,4 +132,3 @@ diff -N ./gdb/testsuite/gdb.base/readline-overflow.exp
|
||||
+}
|
||||
+set timeout $oldtimeout1
|
||||
+
|
||||
+return 0
|
||||
|
@ -1,6 +1,7 @@
|
||||
diff -up -ruNp gdb-6.5-orig/gdb/testsuite/gdb.base/datalib-lib.c gdb-6.5/gdb/testsuite/gdb.base/datalib-lib.c
|
||||
--- gdb-6.5-orig/gdb/testsuite/gdb.base/datalib-lib.c 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/datalib-lib.c 2008-05-29 13:51:50.000000000 -0400
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/datalib-lib.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/datalib-lib.c 2016-02-15 23:27:19.654331680 +0100
|
||||
@@ -0,0 +1,22 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -24,9 +25,10 @@ diff -up -ruNp gdb-6.5-orig/gdb/testsuite/gdb.base/datalib-lib.c gdb-6.5/gdb/tes
|
||||
+ bug-gdb@prep.ai.mit.edu */
|
||||
+
|
||||
+int var;
|
||||
diff -up -ruNp gdb-6.5-orig/gdb/testsuite/gdb.base/datalib-main.c gdb-6.5/gdb/testsuite/gdb.base/datalib-main.c
|
||||
--- gdb-6.5-orig/gdb/testsuite/gdb.base/datalib-main.c 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/datalib-main.c 2008-05-29 13:51:39.000000000 -0400
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/datalib-main.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/datalib-main.c 2016-02-15 23:27:19.654331680 +0100
|
||||
@@ -0,0 +1,26 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -54,9 +56,10 @@ diff -up -ruNp gdb-6.5-orig/gdb/testsuite/gdb.base/datalib-main.c gdb-6.5/gdb/te
|
||||
+{
|
||||
+ return 0;
|
||||
+}
|
||||
diff -up -ruNp gdb-6.5-orig/gdb/testsuite/gdb.base/datalib.exp gdb-6.5/gdb/testsuite/gdb.base/datalib.exp
|
||||
--- gdb-6.5-orig/gdb/testsuite/gdb.base/datalib.exp 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ gdb-6.5/gdb/testsuite/gdb.base/datalib.exp 2008-05-29 14:58:33.000000000 -0400
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/datalib.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/datalib.exp 2016-02-15 23:27:25.968376510 +0100
|
||||
@@ -0,0 +1,51 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -77,8 +80,8 @@ diff -up -ruNp gdb-6.5-orig/gdb/testsuite/gdb.base/datalib.exp gdb-6.5/gdb/tests
|
||||
+set testfile datalib
|
||||
+set srcfilemain ${testfile}-main.c
|
||||
+set srcfilelib ${testfile}-lib.c
|
||||
+set libfile ${objdir}/${subdir}/${testfile}-lib.so
|
||||
+set binfile ${objdir}/${subdir}/${testfile}-main
|
||||
+set libfile [standard_output_file ${testfile}-lib.so]
|
||||
+set binfile [standard_output_file ${testfile}-main]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfilelib}" "${libfile}" executable [list debug {additional_flags=-shared -nostdlib}]] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
|
@ -23,10 +23,10 @@ The testsuite needs `gdb-6.5-tls-of-separate-debuginfo.patch'.
|
||||
|
||||
Port to gdb-6.7.50.20080227.
|
||||
|
||||
Index: gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-main.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-sepdebug-main.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-main.c 2008-02-27 09:00:15.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-sepdebug-main.c 2016-02-16 10:16:12.629875073 +0100
|
||||
@@ -0,0 +1,25 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -53,10 +53,10 @@ Index: gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-main.c
|
||||
+{
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c 2008-02-27 09:00:15.000000000 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c 2016-02-16 10:16:12.630875080 +0100
|
||||
@@ -0,0 +1,22 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -80,9 +80,11 @@ Index: gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c
|
||||
+ bug-gdb@prep.ai.mit.edu */
|
||||
+
|
||||
+__thread int var = 42;
|
||||
--- /dev/null 2009-02-10 00:19:00.494289687 +0100
|
||||
+++ gdb-6.8.50.20090209-x/gdb/testsuite/gdb.threads/tls-sepdebug.exp 2009-02-10 00:49:38.000000000 +0100
|
||||
@@ -0,0 +1,86 @@
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-sepdebug.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-sepdebug.exp 2016-02-16 10:16:31.241001010 +0100
|
||||
@@ -0,0 +1,87 @@
|
||||
+# Copyright 2006 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
@ -107,10 +109,10 @@ Index: gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c
|
||||
+set srcmainfile ${testfile}-main.c
|
||||
+set srcsharedfile ${testfile}-shared.c
|
||||
+
|
||||
+set binmainfile ${objdir}/${subdir}/${testfile}-main
|
||||
+set binmainfile [standard_output_file ${testfile}-main]
|
||||
+set binsharedbase ${testfile}-shared.so
|
||||
+set binsharedfile ${objdir}/${subdir}/${binsharedbase}
|
||||
+set binshareddebugfile ${objdir}/${subdir}/${binsharedbase}.debug
|
||||
+set binsharedfile [standard_output_file ${binsharedbase}]
|
||||
+set binshareddebugfile [standard_output_file ${binsharedbase}.debug]
|
||||
+
|
||||
+# Use explicit -soname as otherwise the full path to the library would get
|
||||
+# encoded into ${binmainfile} making LD_LIBRARY_PATH tests useless.
|
||||
@ -144,7 +146,8 @@ Index: gdb-6.7.50.20080227/gdb/testsuite/gdb.threads/tls-sepdebug-shared.c
|
||||
+# \$PWD is easy - it is the absolute way
|
||||
+# ${subdir} would fail on "print var"
|
||||
+
|
||||
+foreach ld_library_path [list [pwd]/${subdir} ./${subdir}] name { absolute relative } {
|
||||
+set absdir [file dirname [standard_output_file ${binsharedbase}]]
|
||||
+foreach ld_library_path [list $absdir [relative_filename [pwd] $absdir]] name { absolute relative } {
|
||||
+
|
||||
+ gdb_exit
|
||||
+ gdb_start
|
||||
|
@ -15,10 +15,10 @@ Comments by Sergio Durigan Junior <sergiodj@redhat.com>:
|
||||
NULL after it is free'd, otherwise the code below thinks that it is still
|
||||
valid and doesn't print the necessary warning ("Try: yum install ...").
|
||||
|
||||
Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-install-warning.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-install-warning.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.90.20150709/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-install-warning.exp 2015-07-09 22:22:26.278304653 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-install-warning.exp 2016-02-15 23:31:06.327941085 +0100
|
||||
@@ -0,0 +1,97 @@
|
||||
+# Copyright (C) 2014 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -51,9 +51,9 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-inst
|
||||
+}
|
||||
+
|
||||
+# We first need to generate a corefile
|
||||
+set escapedfilename [string_to_regexp ${objdir}/${subdir}/gcore.test]
|
||||
+set escapedfilename [string_to_regexp [standard_output_file gcore.test]]
|
||||
+set core_supported 0
|
||||
+gdb_test_multiple "gcore ${objdir}/${subdir}/gcore.test" \
|
||||
+gdb_test_multiple "gcore [standard_output_file gcore.test]" \
|
||||
+ "save a corefile" \
|
||||
+{
|
||||
+ -re "Saved corefile ${escapedfilename}\[\r\n\]+$gdb_prompt $" {
|
||||
@ -84,19 +84,19 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-inst
|
||||
+ gdb_test "set build-id-verbose 1" "" \
|
||||
+ "set build-id-verbose"
|
||||
+
|
||||
+ gdb_test "set debug-file-directory ${objdir}/${subdir}" "" \
|
||||
+ gdb_test "set debug-file-directory [file dirname [standard_output_file gcore.test]]" "" \
|
||||
+ "set debug-file-directory"
|
||||
+
|
||||
+ gdb_test "core-file ${objdir}/${subdir}/gcore.test" \
|
||||
+ "Missing separate debuginfo for the main executable file\r\nTry: (yum|dnf) --enablerepo='\\*debug\\*' install $objdir/$subdir/$build_id_without_debug\r\n.*" \
|
||||
+ gdb_test "core-file [standard_output_file gcore.test]" \
|
||||
+ "Missing separate debuginfo for the main executable file\r\nTry: (yum|dnf) --enablerepo='\\*debug\\*' install [standard_output_file $build_id_without_debug]\r\n.*" \
|
||||
+ "test first yum/dnf warning"
|
||||
+}
|
||||
+
|
||||
+# Now we define and create our .build-id
|
||||
+file mkdir [file dirname ${objdir}/${subdir}/${build_id_without_debug}]
|
||||
+file mkdir [file dirname [standard_output_file ${build_id_without_debug}]]
|
||||
+# Cannot use "file link" (from TCL) because it requires the target file to
|
||||
+# exist.
|
||||
+remote_exec build "ln -s $binfile ${objdir}/${subdir}/${build_id_without_debug}"
|
||||
+remote_exec build "ln -s $binfile [standard_output_file ${build_id_without_debug}]"
|
||||
+
|
||||
+# Reinitialize GDB to get the second yum/dnf warning
|
||||
+gdb_exit
|
||||
@ -107,21 +107,21 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-inst
|
||||
+ gdb_test "set build-id-verbose 1" "" \
|
||||
+ "set build-id-verbose"
|
||||
+
|
||||
+ gdb_test "set debug-file-directory ${objdir}/${subdir}" "" \
|
||||
+ gdb_test "set debug-file-directory [file dirname [standard_output_file gcore.test]]" "" \
|
||||
+ "set debug-file-directory"
|
||||
+
|
||||
+ gdb_test "core-file ${objdir}/${subdir}/gcore.test" \
|
||||
+ gdb_test "core-file [standard_output_file gcore.test]" \
|
||||
+ "Missing separate debuginfo for the main executable file\r\nTry: (yum|dnf) --enablerepo='\\*debug\\*' install $binfile\r\n.*" \
|
||||
+ "test second yum/dnf warning"
|
||||
+}
|
||||
+
|
||||
+# Leaving the link there will cause breakage in the next run.
|
||||
+remote_exec build "rm -f ${objdir}/${subdir}/${build_id_without_debug}"
|
||||
Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
+remote_exec build "rm -f [standard_output_file ${build_id_without_debug}]"
|
||||
Index: gdb-7.10.90.20160211/gdb/build-id.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/build-id.c 2015-07-09 22:22:26.278304653 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/build-id.c 2015-07-09 22:22:51.398502329 +0200
|
||||
@@ -589,7 +589,10 @@ build_id_to_debug_bfd (size_t build_id_l
|
||||
--- gdb-7.10.90.20160211.orig/gdb/build-id.c 2016-02-15 23:30:55.389863424 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/build-id.c 2016-02-15 23:30:55.778866186 +0100
|
||||
@@ -589,7 +589,10 @@
|
||||
do_cleanups (inner);
|
||||
|
||||
if (abfd == NULL)
|
||||
|
@ -1,60 +1,38 @@
|
||||
warning: Skipping deprecated .gdb_index section
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=953585
|
||||
|
||||
Index: gdb-7.6.90.20140127/gdb/dwarf2read.c
|
||||
===================================================================
|
||||
--- gdb-7.6.90.20140127.orig/gdb/dwarf2read.c 2014-02-06 18:28:23.756232026 +0100
|
||||
+++ gdb-7.6.90.20140127/gdb/dwarf2read.c 2014-02-06 18:28:48.969259122 +0100
|
||||
@@ -3035,6 +3035,14 @@ read_index_from_section (struct objfile
|
||||
"set use-deprecated-index-sections on". */
|
||||
if (version < 6 && !deprecated_ok)
|
||||
{
|
||||
+ extern int rpm_verify_vendor (const char *filename);
|
||||
+
|
||||
+ /* Red Hat Developer Toolset exception. */
|
||||
+ if (rpm_verify_vendor (filename))
|
||||
+ {}
|
||||
+ else
|
||||
+ {
|
||||
+
|
||||
static int warning_printed = 0;
|
||||
if (!warning_printed)
|
||||
{
|
||||
@@ -3046,6 +3054,8 @@ to use the section anyway."),
|
||||
warning_printed = 1;
|
||||
}
|
||||
return 0;
|
||||
+
|
||||
+ }
|
||||
}
|
||||
/* Version 7 indices generated by gold refer to the CU for a symbol instead
|
||||
of the TU (for symbols coming from TUs),
|
||||
Index: gdb-7.6.90.20140127/gdb/build-id.c
|
||||
===================================================================
|
||||
--- gdb-7.6.90.20140127.orig/gdb/build-id.c 2014-02-06 18:28:23.758232029 +0100
|
||||
+++ gdb-7.6.90.20140127/gdb/build-id.c 2014-02-06 18:28:26.814235312 +0100
|
||||
@@ -711,7 +711,7 @@ static int missing_rpm_list_entries;
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/build-id.c gdb-7.10.50.20160106/gdb/build-id.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/build-id.c 2016-01-09 14:40:39.420385241 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/build-id.c 2016-01-09 14:41:05.944549393 +0100
|
||||
@@ -713,7 +713,11 @@ static int missing_rpm_list_entries;
|
||||
/* Returns the count of newly added rpms. */
|
||||
|
||||
static int
|
||||
-missing_rpm_enlist (const char *filename)
|
||||
+#ifndef GDB_INDEX_VERIFY_VENDOR
|
||||
missing_rpm_enlist (const char *filename)
|
||||
+#else
|
||||
+missing_rpm_enlist_1 (const char *filename, int verify_vendor)
|
||||
+#endif
|
||||
{
|
||||
static int rpm_init_done = 0;
|
||||
rpmts ts;
|
||||
@@ -815,7 +815,7 @@ missing_rpm_enlist (const char *filename
|
||||
@@ -817,7 +821,11 @@ missing_rpm_enlist (const char *filename
|
||||
mi = rpmtsInitIterator_p (ts, RPMTAG_BASENAMES, filename, 0);
|
||||
if (mi != NULL)
|
||||
{
|
||||
- for (;;)
|
||||
+#ifndef GDB_INDEX_VERIFY_VENDOR
|
||||
for (;;)
|
||||
+#else
|
||||
+ if (!verify_vendor) for (;;)
|
||||
+#endif
|
||||
{
|
||||
Header h;
|
||||
char *debuginfo, **slot, *s, *s2;
|
||||
@@ -933,6 +933,35 @@ missing_rpm_enlist (const char *filename
|
||||
@@ -935,6 +943,37 @@ missing_rpm_enlist (const char *filename
|
||||
xfree (debuginfo);
|
||||
count++;
|
||||
}
|
||||
+#ifdef GDB_INDEX_VERIFY_VENDOR
|
||||
+ else /* verify_vendor */
|
||||
+ {
|
||||
+ int vendor_pass = 0, vendor_fail = 0;
|
||||
@ -84,13 +62,15 @@ Index: gdb-7.6.90.20140127/gdb/build-id.c
|
||||
+ }
|
||||
+ count = vendor_pass != 0 && vendor_fail == 0;
|
||||
+ }
|
||||
+#endif
|
||||
|
||||
rpmdbFreeIterator_p (mi);
|
||||
}
|
||||
@@ -943,6 +972,19 @@ missing_rpm_enlist (const char *filename
|
||||
@@ -945,6 +984,21 @@ missing_rpm_enlist (const char *filename
|
||||
}
|
||||
|
||||
static int
|
||||
+#ifdef GDB_INDEX_VERIFY_VENDOR
|
||||
+missing_rpm_enlist (const char *filename)
|
||||
+{
|
||||
+ return missing_rpm_enlist_1 (filename, 0);
|
||||
@ -104,6 +84,38 @@ Index: gdb-7.6.90.20140127/gdb/build-id.c
|
||||
+}
|
||||
+
|
||||
+static int
|
||||
+#endif
|
||||
missing_rpm_list_compar (const char *const *ap, const char *const *bp)
|
||||
{
|
||||
return strcoll (*ap, *bp);
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/dwarf2read.c gdb-7.10.50.20160106/gdb/dwarf2read.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/dwarf2read.c 2016-01-09 14:40:39.416385216 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/dwarf2read.c 2016-01-09 14:41:05.942549381 +0100
|
||||
@@ -3111,6 +3111,16 @@ read_index_from_section (struct objfile
|
||||
"set use-deprecated-index-sections on". */
|
||||
if (version < 6 && !deprecated_ok)
|
||||
{
|
||||
+#ifdef GDB_INDEX_VERIFY_VENDOR
|
||||
+ extern int rpm_verify_vendor (const char *filename);
|
||||
+
|
||||
+ /* Red Hat Developer Toolset exception. */
|
||||
+ if (rpm_verify_vendor (filename))
|
||||
+ {}
|
||||
+ else
|
||||
+ {
|
||||
+
|
||||
+#endif
|
||||
static int warning_printed = 0;
|
||||
if (!warning_printed)
|
||||
{
|
||||
@@ -3122,6 +3132,10 @@ to use the section anyway."),
|
||||
warning_printed = 1;
|
||||
}
|
||||
return 0;
|
||||
+#ifdef GDB_INDEX_VERIFY_VENDOR
|
||||
+
|
||||
+ }
|
||||
+#endif
|
||||
}
|
||||
/* Version 7 indices generated by gold refer to the CU for a symbol instead
|
||||
of the TU (for symbols coming from TUs),
|
||||
|
@ -1,7 +1,7 @@
|
||||
Index: gdb-7.9.90.20150717/gdb/event-top.c
|
||||
Index: gdb-7.10.50.20160106/gdb/event-top.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/event-top.c 2015-07-17 03:59:12.000000000 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/event-top.c 2015-08-01 20:07:15.822993674 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/event-top.c
|
||||
+++ gdb-7.10.50.20160106/gdb/event-top.c
|
||||
@@ -37,6 +37,7 @@
|
||||
#include "gdbcmd.h" /* for dont_repeat() */
|
||||
#include "annotate.h"
|
||||
@ -28,10 +28,10 @@ Index: gdb-7.9.90.20150717/gdb/event-top.c
|
||||
old_chain = make_cleanup (free_current_contents, &actual_gdb_prompt);
|
||||
|
||||
/* Do not call the python hook on an explicit prompt change as
|
||||
Index: gdb-7.9.90.20150717/gdb/symfile.h
|
||||
Index: gdb-7.10.50.20160106/gdb/symfile.h
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/symfile.h 2015-08-01 20:07:15.787993404 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/symfile.h 2015-08-01 20:07:15.822993674 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/symfile.h
|
||||
+++ gdb-7.10.50.20160106/gdb/symfile.h
|
||||
@@ -587,6 +587,8 @@ void map_symbol_filenames (symbol_filena
|
||||
/* build-id support. */
|
||||
extern struct bfd_build_id *build_id_addr_get (CORE_ADDR addr);
|
||||
@ -41,11 +41,11 @@ Index: gdb-7.9.90.20150717/gdb/symfile.h
|
||||
|
||||
/* From dwarf2read.c */
|
||||
|
||||
Index: gdb-7.9.90.20150717/gdb/testsuite/lib/gdb.exp
|
||||
Index: gdb-7.10.50.20160106/gdb/testsuite/lib/gdb.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/testsuite/lib/gdb.exp 2015-08-01 20:07:15.789993420 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/testsuite/lib/gdb.exp 2015-08-01 20:07:15.824993689 +0200
|
||||
@@ -1573,7 +1573,7 @@ proc default_gdb_start { } {
|
||||
--- gdb-7.10.50.20160106.orig/gdb/testsuite/lib/gdb.exp
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/lib/gdb.exp
|
||||
@@ -1642,7 +1642,7 @@ proc default_gdb_start { } {
|
||||
warning "Couldn't set the width to 0."
|
||||
}
|
||||
}
|
||||
@ -54,11 +54,11 @@ Index: gdb-7.9.90.20150717/gdb/testsuite/lib/gdb.exp
|
||||
send_gdb "set build-id-verbose 0\n"
|
||||
gdb_expect 10 {
|
||||
-re "$gdb_prompt $" {
|
||||
Index: gdb-7.9.90.20150717/gdb/testsuite/lib/mi-support.exp
|
||||
Index: gdb-7.10.50.20160106/gdb/testsuite/lib/mi-support.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/testsuite/lib/mi-support.exp 2015-08-01 20:07:15.789993420 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/testsuite/lib/mi-support.exp 2015-08-01 20:07:15.824993689 +0200
|
||||
@@ -214,7 +214,7 @@ proc default_mi_gdb_start { args } {
|
||||
--- gdb-7.10.50.20160106.orig/gdb/testsuite/lib/mi-support.exp
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/lib/mi-support.exp
|
||||
@@ -204,7 +204,7 @@ proc default_mi_gdb_start { args } {
|
||||
warning "Couldn't set the width to 0."
|
||||
}
|
||||
}
|
||||
@ -67,10 +67,10 @@ Index: gdb-7.9.90.20150717/gdb/testsuite/lib/mi-support.exp
|
||||
send_gdb "190-gdb-set build-id-verbose 0\n"
|
||||
gdb_expect 10 {
|
||||
-re ".*190-gdb-set build-id-verbose 0\r\n190\\\^done\r\n$mi_gdb_prompt$" {
|
||||
Index: gdb-7.9.90.20150717/gdb/tui/tui-interp.c
|
||||
Index: gdb-7.10.50.20160106/gdb/tui/tui-interp.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/tui/tui-interp.c 2015-07-17 03:59:13.000000000 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/tui/tui-interp.c 2015-08-01 20:07:15.825993697 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/tui/tui-interp.c
|
||||
+++ gdb-7.10.50.20160106/gdb/tui/tui-interp.c
|
||||
@@ -31,6 +31,7 @@
|
||||
#include "tui/tui-io.h"
|
||||
#include "infrun.h"
|
||||
@ -79,10 +79,10 @@ Index: gdb-7.9.90.20150717/gdb/tui/tui-interp.c
|
||||
|
||||
static struct ui_out *tui_ui_out (struct interp *self);
|
||||
|
||||
Index: gdb-7.9.90.20150717/gdb/aclocal.m4
|
||||
Index: gdb-7.10.50.20160106/gdb/aclocal.m4
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/aclocal.m4 2015-07-17 03:59:12.000000000 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/aclocal.m4 2015-08-01 20:07:15.825993697 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/aclocal.m4
|
||||
+++ gdb-7.10.50.20160106/gdb/aclocal.m4
|
||||
@@ -11,6 +11,221 @@
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE.
|
||||
@ -305,10 +305,10 @@ Index: gdb-7.9.90.20150717/gdb/aclocal.m4
|
||||
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
|
||||
|
||||
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
|
||||
Index: gdb-7.9.90.20150717/gdb/config.in
|
||||
Index: gdb-7.10.50.20160106/gdb/config.in
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/config.in 2015-07-17 03:59:12.000000000 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/config.in 2015-08-01 20:07:15.826993704 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/config.in
|
||||
+++ gdb-7.10.50.20160106/gdb/config.in
|
||||
@@ -33,6 +33,9 @@
|
||||
/* Define to BFD's default target vector. */
|
||||
#undef DEFAULT_BFD_VEC
|
||||
@ -329,11 +329,11 @@ Index: gdb-7.9.90.20150717/gdb/config.in
|
||||
/* Define to 1 if you have the <libunwind-ia64.h> header file. */
|
||||
#undef HAVE_LIBUNWIND_IA64_H
|
||||
|
||||
Index: gdb-7.9.90.20150717/gdb/configure
|
||||
Index: gdb-7.10.50.20160106/gdb/configure
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/configure 2015-07-17 03:59:12.000000000 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/configure 2015-08-01 20:07:15.830993735 +0200
|
||||
@@ -703,6 +703,11 @@ PKGVERSION
|
||||
--- gdb-7.10.50.20160106.orig/gdb/configure
|
||||
+++ gdb-7.10.50.20160106/gdb/configure
|
||||
@@ -705,6 +705,11 @@ PKGVERSION
|
||||
HAVE_NATIVE_GCORE_TARGET
|
||||
TARGET_OBS
|
||||
subdirs
|
||||
@ -345,7 +345,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
GDB_DATADIR
|
||||
DEBUGDIR
|
||||
MAKEINFO_EXTRA_FLAGS
|
||||
@@ -811,6 +816,7 @@ with_gdb_datadir
|
||||
@@ -813,6 +818,7 @@ with_gdb_datadir
|
||||
with_relocated_sources
|
||||
with_auto_load_dir
|
||||
with_auto_load_safe_path
|
||||
@ -353,7 +353,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
enable_targets
|
||||
enable_64_bit_bfd
|
||||
enable_gdbcli
|
||||
@@ -867,6 +873,11 @@ CCC
|
||||
@@ -869,6 +875,11 @@ CCC
|
||||
CPP
|
||||
MAKEINFO
|
||||
MAKEINFOFLAGS
|
||||
@ -365,7 +365,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
YACC
|
||||
YFLAGS
|
||||
XMKMF'
|
||||
@@ -1538,6 +1549,8 @@ Optional Packages:
|
||||
@@ -1540,6 +1551,8 @@ Optional Packages:
|
||||
[--with-auto-load-dir]
|
||||
--without-auto-load-safe-path
|
||||
do not restrict auto-loaded files locations
|
||||
@ -374,7 +374,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
--with-libunwind-ia64 use libunwind frame unwinding for ia64 targets
|
||||
--with-curses use the curses library instead of the termcap
|
||||
library
|
||||
@@ -1592,6 +1605,13 @@ Some influential environment variables:
|
||||
@@ -1595,6 +1608,13 @@ Some influential environment variables:
|
||||
MAKEINFO Parent configure detects if it is of sufficient version.
|
||||
MAKEINFOFLAGS
|
||||
Parameters for MAKEINFO.
|
||||
@ -388,7 +388,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
YACC The `Yet Another C Compiler' implementation to use. Defaults to
|
||||
the first program found out of: `bison -y', `byacc', `yacc'.
|
||||
YFLAGS The list of arguments that will be passed by default to $YACC.
|
||||
@@ -5608,6 +5628,491 @@ _ACEOF
|
||||
@@ -5655,6 +5675,494 @@ _ACEOF
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
|
||||
$as_echo "$with_auto_load_safe_path" >&6; }
|
||||
|
||||
@ -623,6 +623,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
+
|
||||
+
|
||||
+
|
||||
+
|
||||
+if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
|
||||
+ if test -n "$ac_tool_prefix"; then
|
||||
+ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
|
||||
@ -751,6 +752,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
+ test $ac_status = 0; }; then
|
||||
+ pkg_cv_RPM_CFLAGS=`$PKG_CONFIG --cflags "rpm" 2>/dev/null`
|
||||
+ test "x$?" != "x0" && pkg_failed=yes
|
||||
+else
|
||||
+ pkg_failed=yes
|
||||
+fi
|
||||
@ -767,6 +769,7 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
+ test $ac_status = 0; }; then
|
||||
+ pkg_cv_RPM_LIBS=`$PKG_CONFIG --libs "rpm" 2>/dev/null`
|
||||
+ test "x$?" != "x0" && pkg_failed=yes
|
||||
+else
|
||||
+ pkg_failed=yes
|
||||
+fi
|
||||
@ -786,9 +789,9 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
+ _pkg_short_errors_supported=no
|
||||
+fi
|
||||
+ if test $_pkg_short_errors_supported = yes; then
|
||||
+ RPM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "rpm" 2>&1`
|
||||
+ RPM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "rpm" 2>&1`
|
||||
+ else
|
||||
+ RPM_PKG_ERRORS=`$PKG_CONFIG --print-errors "rpm" 2>&1`
|
||||
+ RPM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "rpm" 2>&1`
|
||||
+ fi
|
||||
+ # Put the nasty error message in config.log where it belongs
|
||||
+ echo "$RPM_PKG_ERRORS" >&5
|
||||
@ -880,10 +883,10 @@ Index: gdb-7.9.90.20150717/gdb/configure
|
||||
|
||||
|
||||
subdirs="$subdirs testsuite"
|
||||
Index: gdb-7.9.90.20150717/gdb/configure.ac
|
||||
Index: gdb-7.10.50.20160106/gdb/configure.ac
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/configure.ac 2015-07-17 03:59:12.000000000 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/configure.ac 2015-08-01 20:07:15.831993743 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/configure.ac
|
||||
+++ gdb-7.10.50.20160106/gdb/configure.ac
|
||||
@@ -177,6 +177,199 @@ AC_DEFINE_DIR(AUTO_LOAD_SAFE_PATH, escap
|
||||
[Directories safe to hold auto-loaded files.])
|
||||
AC_MSG_RESULT([$with_auto_load_safe_path])
|
||||
@ -1084,10 +1087,10 @@ Index: gdb-7.9.90.20150717/gdb/configure.ac
|
||||
AC_CONFIG_SUBDIRS(testsuite)
|
||||
|
||||
# Check whether to support alternative target configurations
|
||||
Index: gdb-7.9.90.20150717/gdb/corelow.c
|
||||
Index: gdb-7.10.50.20160106/gdb/corelow.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/corelow.c 2015-08-01 20:07:15.775993312 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/corelow.c 2015-08-01 20:07:15.831993743 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/corelow.c
|
||||
+++ gdb-7.10.50.20160106/gdb/corelow.c
|
||||
@@ -310,7 +310,7 @@ build_id_locate_exec (int from_tty)
|
||||
symfile_objfile->flags |= OBJF_BUILD_ID_CORE_LOADED;
|
||||
}
|
||||
@ -1097,10 +1100,10 @@ Index: gdb-7.9.90.20150717/gdb/corelow.c
|
||||
|
||||
do_cleanups (back_to);
|
||||
|
||||
Index: gdb-7.9.90.20150717/gdb/build-id.c
|
||||
Index: gdb-7.10.50.20160106/gdb/build-id.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150717.orig/gdb/build-id.c 2015-08-01 20:07:15.791993435 +0200
|
||||
+++ gdb-7.9.90.20150717/gdb/build-id.c 2015-08-01 20:08:27.735546630 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/build-id.c
|
||||
+++ gdb-7.10.50.20160106/gdb/build-id.c
|
||||
@@ -35,6 +35,7 @@
|
||||
#include "elf/common.h"
|
||||
#include "elf-bfd.h"
|
||||
@ -1109,7 +1112,7 @@ Index: gdb-7.9.90.20150717/gdb/build-id.c
|
||||
|
||||
#define BUILD_ID_VERBOSE_NONE 0
|
||||
#define BUILD_ID_VERBOSE_FILENAMES 1
|
||||
@@ -665,8 +666,363 @@ build_id_to_filename (const struct bfd_b
|
||||
@@ -665,8 +666,366 @@ build_id_to_filename (const struct bfd_b
|
||||
return result;
|
||||
}
|
||||
|
||||
@ -1187,6 +1190,9 @@ Index: gdb-7.9.90.20150717/gdb/build-id.c
|
||||
+ if (strcmp (filename, BUILD_ID_MAIN_EXECUTABLE_FILENAME) == 0)
|
||||
+ return 0;
|
||||
+
|
||||
+ if (is_target_filename (filename))
|
||||
+ return 0;
|
||||
+
|
||||
+ if (filename[0] != '/')
|
||||
+ {
|
||||
+ warning (_("Ignoring non-absolute filename: <%s>"), filename);
|
||||
@ -1474,7 +1480,7 @@ Index: gdb-7.9.90.20150717/gdb/build-id.c
|
||||
avoidance. */
|
||||
|
||||
struct missing_filepair
|
||||
@@ -720,11 +1076,17 @@ missing_filepair_change (void)
|
||||
@@ -720,11 +1079,17 @@ missing_filepair_change (void)
|
||||
/* All their memory came just from missing_filepair_OBSTACK. */
|
||||
missing_filepair_hash = NULL;
|
||||
}
|
||||
@ -1492,7 +1498,7 @@ Index: gdb-7.9.90.20150717/gdb/build-id.c
|
||||
missing_filepair_change ();
|
||||
}
|
||||
|
||||
@@ -791,14 +1153,39 @@ debug_print_missing (const char *binary,
|
||||
@@ -791,14 +1156,39 @@ debug_print_missing (const char *binary,
|
||||
|
||||
*slot = missing_filepair;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
Index: gdb-7.9.90.20150709/gdb/corelow.c
|
||||
Index: gdb-7.10.90.20160211/gdb/corelow.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/corelow.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/corelow.c 2015-07-09 22:05:42.057222722 +0200
|
||||
--- gdb-7.10.90.20160211.orig/gdb/corelow.c 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/corelow.c 2016-02-15 23:26:46.516096395 +0100
|
||||
@@ -45,6 +45,10 @@
|
||||
#include "gdb_bfd.h"
|
||||
#include "completer.h"
|
||||
@ -13,7 +13,7 @@ Index: gdb-7.9.90.20150709/gdb/corelow.c
|
||||
|
||||
#ifndef O_LARGEFILE
|
||||
#define O_LARGEFILE 0
|
||||
@@ -266,6 +270,53 @@ add_to_thread_list (bfd *abfd, asection
|
||||
@@ -266,6 +270,53 @@
|
||||
inferior_ptid = ptid; /* Yes, make it current. */
|
||||
}
|
||||
|
||||
@ -67,7 +67,7 @@ Index: gdb-7.9.90.20150709/gdb/corelow.c
|
||||
/* This routine opens and sets up the core file bfd. */
|
||||
|
||||
static void
|
||||
@@ -404,6 +455,14 @@ core_open (const char *arg, int from_tty
|
||||
@@ -404,6 +455,14 @@
|
||||
switch_to_thread (thread->ptid);
|
||||
}
|
||||
|
||||
@ -82,7 +82,7 @@ Index: gdb-7.9.90.20150709/gdb/corelow.c
|
||||
post_create_inferior (&core_ops, from_tty);
|
||||
|
||||
/* Now go through the target stack looking for threads since there
|
||||
@@ -1058,4 +1117,11 @@ _initialize_corelow (void)
|
||||
@@ -1068,4 +1127,11 @@
|
||||
init_core_ops ();
|
||||
|
||||
add_target_with_completer (&core_ops, filename_completer);
|
||||
@ -94,11 +94,11 @@ Index: gdb-7.9.90.20150709/gdb/corelow.c
|
||||
+ NULL, NULL, NULL,
|
||||
+ &setlist, &showlist);
|
||||
}
|
||||
Index: gdb-7.9.90.20150709/gdb/doc/gdb.texinfo
|
||||
Index: gdb-7.10.90.20160211/gdb/doc/gdb.texinfo
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/doc/gdb.texinfo 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/doc/gdb.texinfo 2015-07-09 22:05:42.067222806 +0200
|
||||
@@ -18304,6 +18304,27 @@ information files.
|
||||
--- gdb-7.10.90.20160211.orig/gdb/doc/gdb.texinfo 2016-02-15 23:25:36.455598958 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/doc/gdb.texinfo 2016-02-15 23:26:06.362811302 +0100
|
||||
@@ -18684,6 +18684,27 @@
|
||||
|
||||
@end table
|
||||
|
||||
@ -126,10 +126,10 @@ Index: gdb-7.9.90.20150709/gdb/doc/gdb.texinfo
|
||||
@cindex @code{.gnu_debuglink} sections
|
||||
@cindex debug link sections
|
||||
A debug link is a special section of the executable file named
|
||||
Index: gdb-7.9.90.20150709/gdb/solib-svr4.c
|
||||
Index: gdb-7.10.90.20160211/gdb/solib-svr4.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/solib-svr4.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/solib-svr4.c 2015-07-09 22:05:42.068222815 +0200
|
||||
--- gdb-7.10.90.20160211.orig/gdb/solib-svr4.c 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/solib-svr4.c 2016-02-15 23:26:46.613097083 +0100
|
||||
@@ -45,6 +45,7 @@
|
||||
#include "auxv.h"
|
||||
#include "gdb_bfd.h"
|
||||
@ -138,7 +138,7 @@ Index: gdb-7.9.90.20150709/gdb/solib-svr4.c
|
||||
|
||||
static struct link_map_offsets *svr4_fetch_link_map_offsets (void);
|
||||
static int svr4_have_link_map_offsets (void);
|
||||
@@ -1379,9 +1380,52 @@ svr4_read_so_list (CORE_ADDR lm, CORE_AD
|
||||
@@ -1416,9 +1417,52 @@
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -194,11 +194,11 @@ Index: gdb-7.9.90.20150709/gdb/solib-svr4.c
|
||||
xfree (buffer);
|
||||
|
||||
/* If this entry has no name, or its name matches the name
|
||||
Index: gdb-7.9.90.20150709/gdb/elfread.c
|
||||
Index: gdb-7.10.90.20160211/gdb/elfread.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/elfread.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/elfread.c 2015-07-09 22:05:42.068222815 +0200
|
||||
@@ -1250,9 +1250,10 @@ elf_symfile_read (struct objfile *objfil
|
||||
--- gdb-7.10.90.20160211.orig/gdb/elfread.c 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/elfread.c 2016-02-15 23:26:06.364811316 +0100
|
||||
@@ -1259,9 +1259,10 @@
|
||||
&& objfile->separate_debug_objfile == NULL
|
||||
&& objfile->separate_debug_objfile_backlink == NULL)
|
||||
{
|
||||
@ -211,7 +211,7 @@ Index: gdb-7.9.90.20150709/gdb/elfread.c
|
||||
|
||||
if (debugfile == NULL)
|
||||
debugfile = find_separate_debug_file_by_debuglink (objfile);
|
||||
@@ -1266,6 +1267,12 @@ elf_symfile_read (struct objfile *objfil
|
||||
@@ -1275,6 +1276,12 @@
|
||||
symbol_file_add_separate (abfd, debugfile, symfile_flags, objfile);
|
||||
do_cleanups (cleanup);
|
||||
}
|
||||
@ -224,11 +224,11 @@ Index: gdb-7.9.90.20150709/gdb/elfread.c
|
||||
}
|
||||
}
|
||||
|
||||
Index: gdb-7.9.90.20150709/gdb/symfile.h
|
||||
Index: gdb-7.10.90.20160211/gdb/symfile.h
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/symfile.h 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/symfile.h 2015-07-09 22:05:42.068222815 +0200
|
||||
@@ -584,6 +584,10 @@ void expand_symtabs_matching (expand_sym
|
||||
--- gdb-7.10.90.20160211.orig/gdb/symfile.h 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/symfile.h 2016-02-15 23:26:46.516096395 +0100
|
||||
@@ -584,6 +584,10 @@
|
||||
void map_symbol_filenames (symbol_filename_ftype *fun, void *data,
|
||||
int need_fullname);
|
||||
|
||||
@ -239,11 +239,11 @@ Index: gdb-7.9.90.20150709/gdb/symfile.h
|
||||
/* From dwarf2read.c */
|
||||
|
||||
/* Names for a dwarf2 debugging section. The field NORMAL is the normal
|
||||
Index: gdb-7.9.90.20150709/gdb/testsuite/lib/gdb.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/lib/gdb.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/testsuite/lib/gdb.exp 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/testsuite/lib/gdb.exp 2015-07-09 22:05:42.070222832 +0200
|
||||
@@ -1573,6 +1573,16 @@ proc default_gdb_start { } {
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/lib/gdb.exp 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/lib/gdb.exp 2016-02-15 23:26:46.516096395 +0100
|
||||
@@ -1640,6 +1640,16 @@
|
||||
warning "Couldn't set the width to 0."
|
||||
}
|
||||
}
|
||||
@ -260,11 +260,11 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/lib/gdb.exp
|
||||
return 0
|
||||
}
|
||||
|
||||
Index: gdb-7.9.90.20150709/gdb/testsuite/lib/mi-support.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/lib/mi-support.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/testsuite/lib/mi-support.exp 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/testsuite/lib/mi-support.exp 2015-07-09 22:05:42.070222832 +0200
|
||||
@@ -214,6 +214,16 @@ proc default_mi_gdb_start { args } {
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/lib/mi-support.exp 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/lib/mi-support.exp 2016-02-15 23:26:46.516096395 +0100
|
||||
@@ -204,6 +204,16 @@
|
||||
warning "Couldn't set the width to 0."
|
||||
}
|
||||
}
|
||||
@ -278,14 +278,14 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/lib/mi-support.exp
|
||||
+ warning "Could not disable the missing debug infos warnings.."
|
||||
+ }
|
||||
+ }
|
||||
# If allowing the inferior to have its own PTY then assign the inferior
|
||||
# its own terminal device here.
|
||||
|
||||
# Create the new PTY for the inferior process.
|
||||
if { $separate_inferior_pty } {
|
||||
Index: gdb-7.9.90.20150709/gdb/objfiles.h
|
||||
Index: gdb-7.10.90.20160211/gdb/objfiles.h
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/objfiles.h 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/objfiles.h 2015-07-09 22:05:42.071222840 +0200
|
||||
@@ -459,6 +459,10 @@ struct objfile
|
||||
--- gdb-7.10.90.20160211.orig/gdb/objfiles.h 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/objfiles.h 2016-02-15 23:26:06.366811330 +0100
|
||||
@@ -489,6 +489,10 @@
|
||||
|
||||
#define OBJF_NOT_FILENAME (1 << 6)
|
||||
|
||||
@ -296,11 +296,11 @@ Index: gdb-7.9.90.20150709/gdb/objfiles.h
|
||||
/* Declarations for functions defined in objfiles.c */
|
||||
|
||||
extern struct objfile *allocate_objfile (bfd *, const char *name, int);
|
||||
Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/corefile.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/corefile.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/testsuite/gdb.base/corefile.exp 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/testsuite/gdb.base/corefile.exp 2015-07-09 22:05:42.071222840 +0200
|
||||
@@ -293,3 +293,33 @@ gdb_test_multiple "core-file $corefile"
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.base/corefile.exp 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/corefile.exp 2016-02-15 23:26:55.178157896 +0100
|
||||
@@ -293,3 +293,33 @@
|
||||
pass $test
|
||||
}
|
||||
}
|
||||
@ -316,7 +316,7 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/corefile.exp
|
||||
+ gdb_start
|
||||
+
|
||||
+ regsub {\.debug$} $buildid {} buildid
|
||||
+ set debugdir ${objdir}/${subdir}/${testfile}-debugdir
|
||||
+ set debugdir [standard_output_file ${testfile}-debugdir]
|
||||
+ file delete -force -- $debugdir
|
||||
+ file mkdir $debugdir/[file dirname $buildid]
|
||||
+ file copy $binfile $debugdir/$buildid
|
||||
@ -334,10 +334,10 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/corefile.exp
|
||||
+ gdb_test "info files" "Local exec file:\r\n\[ \t\]*`[string_to_regexp $debugdir/$buildid]', file type .*"
|
||||
+ pass $wholetest
|
||||
+}
|
||||
Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
Index: gdb-7.10.90.20160211/gdb/build-id.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/build-id.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/build-id.c 2015-07-09 22:19:35.022957009 +0200
|
||||
--- gdb-7.10.90.20160211.orig/gdb/build-id.c 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/build-id.c 2016-02-15 23:26:46.516096395 +0100
|
||||
@@ -26,11 +26,67 @@
|
||||
#include "objfiles.h"
|
||||
#include "filenames.h"
|
||||
@ -407,7 +407,7 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
{
|
||||
if (!bfd_check_format (abfd, bfd_object))
|
||||
return NULL;
|
||||
@@ -42,6 +98,348 @@ build_id_bfd_get (bfd *abfd)
|
||||
@@ -42,6 +98,348 @@
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -756,7 +756,7 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
/* See build-id.h. */
|
||||
|
||||
int
|
||||
@@ -50,7 +448,7 @@ build_id_verify (bfd *abfd, size_t check
|
||||
@@ -50,7 +448,7 @@
|
||||
const struct bfd_build_id *found;
|
||||
int retval = 0;
|
||||
|
||||
@ -765,7 +765,7 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
|
||||
if (found == NULL)
|
||||
warning (_("File \"%s\" has no build-id, file skipped"),
|
||||
@@ -65,20 +463,56 @@ build_id_verify (bfd *abfd, size_t check
|
||||
@@ -65,23 +463,56 @@
|
||||
return retval;
|
||||
}
|
||||
|
||||
@ -818,15 +818,18 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
struct cleanup *back_to;
|
||||
int ix;
|
||||
bfd *abfd = NULL;
|
||||
- int alloc_len;
|
||||
|
||||
/* DEBUG_FILE_DIRECTORY/.build-id/ab/cdef */
|
||||
- link = alloca (strlen (debug_file_directory) + (sizeof "/.build-id/" - 1) + 1
|
||||
- + 2 * build_id_len + (sizeof ".debug" - 1) + 1);
|
||||
- alloc_len = (strlen (debug_file_directory)
|
||||
- + (sizeof "/.build-id/" - 1) + 1
|
||||
- + 2 * build_id_len + (sizeof ".debug" - 1) + 1);
|
||||
- link = (char *) alloca (alloc_len);
|
||||
+ link = xmalloc (strlen (debug_file_directory) + 2 * build_id_len + 50);
|
||||
|
||||
/* Keep backward compatibility so that DEBUG_FILE_DIRECTORY being "" will
|
||||
cause "/.build-id/..." lookups. */
|
||||
@@ -91,9 +525,12 @@ build_id_to_debug_bfd (size_t build_id_l
|
||||
@@ -94,9 +525,12 @@
|
||||
size_t debugdir_len = strlen (debugdir);
|
||||
const gdb_byte *data = build_id;
|
||||
size_t size = build_id_len;
|
||||
@ -840,7 +843,7 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
|
||||
memcpy (link, debugdir, debugdir_len);
|
||||
s = &link[debugdir_len];
|
||||
@@ -107,47 +544,281 @@ build_id_to_debug_bfd (size_t build_id_l
|
||||
@@ -110,47 +544,281 @@
|
||||
*s++ = '/';
|
||||
while (size-- > 0)
|
||||
s += sprintf (s, "%02x", (unsigned) *data++);
|
||||
@ -1141,7 +1144,7 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
/* Prevent looping on a stripped .debug file. */
|
||||
if (abfd != NULL
|
||||
&& filename_cmp (bfd_get_filename (abfd),
|
||||
@@ -167,3 +838,21 @@ find_separate_debug_file_by_buildid (str
|
||||
@@ -170,3 +838,21 @@
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
@ -1163,10 +1166,10 @@ Index: gdb-7.9.90.20150709/gdb/build-id.c
|
||||
+
|
||||
+ observer_attach_executable_changed (debug_print_executable_changed);
|
||||
+}
|
||||
Index: gdb-7.9.90.20150709/gdb/build-id.h
|
||||
Index: gdb-7.10.90.20160211/gdb/build-id.h
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/build-id.h 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/build-id.h 2015-07-09 22:05:42.072222849 +0200
|
||||
--- gdb-7.10.90.20160211.orig/gdb/build-id.h 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/build-id.h 2016-02-15 23:26:06.368811345 +0100
|
||||
@@ -20,9 +20,10 @@
|
||||
#ifndef BUILD_ID_H
|
||||
#define BUILD_ID_H
|
||||
@ -1180,7 +1183,7 @@ Index: gdb-7.9.90.20150709/gdb/build-id.h
|
||||
|
||||
/* Return true if ABFD has NT_GNU_BUILD_ID matching the CHECK value.
|
||||
Otherwise, issue a warning and return false. */
|
||||
@@ -36,13 +37,18 @@ extern int build_id_verify (bfd *abfd,
|
||||
@@ -36,13 +37,18 @@
|
||||
the caller. */
|
||||
|
||||
extern bfd *build_id_to_debug_bfd (size_t build_id_len,
|
||||
@ -1201,11 +1204,11 @@ Index: gdb-7.9.90.20150709/gdb/build-id.h
|
||||
+ char **build_id_filename_return);
|
||||
|
||||
#endif /* BUILD_ID_H */
|
||||
Index: gdb-7.9.90.20150709/gdb/dwarf2read.c
|
||||
Index: gdb-7.10.90.20160211/gdb/dwarf2read.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/dwarf2read.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/dwarf2read.c 2015-07-09 22:05:42.077222891 +0200
|
||||
@@ -2507,7 +2507,7 @@ dwarf2_get_dwz_file (void)
|
||||
--- gdb-7.10.90.20160211.orig/gdb/dwarf2read.c 2016-02-15 23:25:36.461599001 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/dwarf2read.c 2016-02-15 23:26:06.373811380 +0100
|
||||
@@ -2516,7 +2516,7 @@
|
||||
}
|
||||
|
||||
if (dwz_bfd == NULL)
|
||||
@ -1214,11 +1217,11 @@ Index: gdb-7.9.90.20150709/gdb/dwarf2read.c
|
||||
|
||||
if (dwz_bfd == NULL)
|
||||
error (_("could not find '.gnu_debugaltlink' file for %s"),
|
||||
Index: gdb-7.9.90.20150709/gdb/python/py-objfile.c
|
||||
Index: gdb-7.10.90.20160211/gdb/python/py-objfile.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/python/py-objfile.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/python/py-objfile.c 2015-07-09 22:05:42.077222891 +0200
|
||||
@@ -139,7 +139,7 @@ objfpy_get_build_id (PyObject *self, voi
|
||||
--- gdb-7.10.90.20160211.orig/gdb/python/py-objfile.c 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/python/py-objfile.c 2016-02-15 23:26:06.373811380 +0100
|
||||
@@ -139,7 +139,7 @@
|
||||
|
||||
TRY
|
||||
{
|
||||
@ -1227,7 +1230,7 @@ Index: gdb-7.9.90.20150709/gdb/python/py-objfile.c
|
||||
}
|
||||
CATCH (except, RETURN_MASK_ALL)
|
||||
{
|
||||
@@ -548,7 +548,7 @@ objfpy_lookup_objfile_by_build_id (const
|
||||
@@ -548,7 +548,7 @@
|
||||
/* Don't return separate debug files. */
|
||||
if (objfile->separate_debug_objfile_backlink != NULL)
|
||||
continue;
|
||||
@ -1236,11 +1239,11 @@ Index: gdb-7.9.90.20150709/gdb/python/py-objfile.c
|
||||
if (obfd_build_id == NULL)
|
||||
continue;
|
||||
if (objfpy_build_id_matches (obfd_build_id, build_id))
|
||||
Index: gdb-7.9.90.20150709/gdb/coffread.c
|
||||
Index: gdb-7.10.90.20160211/gdb/coffread.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/coffread.c 2015-07-09 22:05:20.988044312 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/coffread.c 2015-07-09 22:05:42.078222899 +0200
|
||||
@@ -739,7 +739,7 @@ coff_symfile_read (struct objfile *objfi
|
||||
--- gdb-7.10.90.20160211.orig/gdb/coffread.c 2016-02-15 23:25:00.859346221 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/coffread.c 2016-02-15 23:26:06.374811387 +0100
|
||||
@@ -739,7 +739,7 @@
|
||||
{
|
||||
char *debugfile;
|
||||
|
||||
|
@ -7,20 +7,25 @@
|
||||
* gdb.base/gcorebg.exp, gdb.base/gcorebg.c: New files.
|
||||
|
||||
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/gcorebg.c 25 Feb 2007 12:21:20 -0000
|
||||
@@ -0,0 +1,43 @@
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcorebg.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcorebg.c 2016-02-16 10:44:48.998527259 +0100
|
||||
@@ -0,0 +1,49 @@
|
||||
+#include <stdio.h>
|
||||
+#include <sys/types.h>
|
||||
+#include <unistd.h>
|
||||
+#include <stdlib.h>
|
||||
+#include <signal.h>
|
||||
+#include <string.h>
|
||||
+#include <assert.h>
|
||||
+
|
||||
+int main (int argc, char **argv)
|
||||
+{
|
||||
+ pid_t pid = 0;
|
||||
+ pid_t ppid;
|
||||
+ char buf[256];
|
||||
+ char buf[1024*2 + 500];
|
||||
+ int gotint;
|
||||
+
|
||||
+ if (argc != 4)
|
||||
+ {
|
||||
@ -37,8 +42,10 @@
|
||||
+ if (strcmp (argv[1], "detached") == 0)
|
||||
+ setpgrp ();
|
||||
+ ppid = getppid ();
|
||||
+ sprintf (buf, "sh %s -o %s %d", argv[2], argv[3], (int) ppid);
|
||||
+ gotint = snprintf (buf, sizeof (buf), "sh %s -o %s %d", argv[2], argv[3], (int) ppid);
|
||||
+ assert (gotint < sizeof (buf));
|
||||
+ system (buf);
|
||||
+ fprintf (stderr, "Killing parent PID %d\n", ppid);
|
||||
+ kill (ppid, SIGTERM);
|
||||
+ break;
|
||||
+
|
||||
@ -48,13 +55,16 @@
|
||||
+ break;
|
||||
+
|
||||
+ default:
|
||||
+ fprintf (stderr,"Sleeping as PID %d\n", getpid ());
|
||||
+ sleep (60);
|
||||
+ }
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/gcorebg.exp 25 Feb 2007 12:21:20 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcorebg.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/gcorebg.exp 2016-02-16 10:44:48.999527265 +0100
|
||||
@@ -0,0 +1,113 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -81,14 +91,14 @@
|
||||
+# accessible terminal.
|
||||
+
|
||||
+if ![info exists GCORE] {
|
||||
+ set GCORE "${srcdir}/../gdb_gcore.sh"
|
||||
+ set GCORE "[standard_output_file ../../../../gcore]"
|
||||
+}
|
||||
+verbose "using GCORE = $GCORE" 2
|
||||
+
|
||||
+set testfile "gcorebg"
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set corefile ${objdir}/${subdir}/${testfile}.test
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+set corefile [standard_output_file ${testfile}.test]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested gcorebg.exp
|
||||
@ -137,11 +147,11 @@
|
||||
+ pass "Spawning $detached gcore"
|
||||
+ remote_expect target 20 {
|
||||
+ timeout {
|
||||
+ fail "Spawned $detached gcore finished"
|
||||
+ fail "Spawned $detached gcore finished (timeout)"
|
||||
+ remote_exec target "kill -9 -[exp_pid -i $res]"
|
||||
+ return 1
|
||||
+ }
|
||||
+ eof {
|
||||
+ "Saved corefile .*\r\nKilling parent PID " {
|
||||
+ pass "Spawned $detached gcore finished"
|
||||
+ remote_wait target 20
|
||||
+ }
|
||||
|
@ -3,10 +3,10 @@
|
||||
Port to GDB-6.8pre.
|
||||
Remove the `[' character from the GDB-6.8 default message.
|
||||
|
||||
Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/fork-detach.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.c 2015-05-31 18:23:49.008450716 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/fork-detach.c 2016-02-15 23:25:36.686600598 +0100
|
||||
@@ -0,0 +1,57 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -65,10 +65,10 @@ Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.c
|
||||
+ }
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/fork-detach.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.exp 2015-05-31 18:23:49.008450716 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/fork-detach.exp 2016-02-15 23:27:55.792588265 +0100
|
||||
@@ -0,0 +1,36 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -88,7 +88,7 @@ Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.exp
|
||||
+
|
||||
+set testfile fork-detach
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -106,11 +106,11 @@ Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.base/fork-detach.exp
|
||||
+gdb_test "" \
|
||||
+ "Detaching after fork from child process.*\\\[Inferior .* exited normally\\\]" \
|
||||
+ "Info message caught"
|
||||
Index: gdb-7.9.50.20150531/gdb/infrun.c
|
||||
Index: gdb-7.10.90.20160211/gdb/infrun.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150531.orig/gdb/infrun.c 2015-05-31 18:23:41.703405617 +0200
|
||||
+++ gdb-7.9.50.20150531/gdb/infrun.c 2015-05-31 18:23:49.011450735 +0200
|
||||
@@ -443,7 +443,7 @@ holding the child stopped. Try \"set de
|
||||
--- gdb-7.10.90.20160211.orig/gdb/infrun.c 2016-02-15 23:25:01.432350289 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/infrun.c 2016-02-15 23:27:49.274541986 +0100
|
||||
@@ -478,7 +478,7 @@
|
||||
remove_breakpoints_pid (ptid_get_pid (inferior_ptid));
|
||||
}
|
||||
|
||||
@ -119,3 +119,25 @@ Index: gdb-7.9.50.20150531/gdb/infrun.c
|
||||
{
|
||||
/* Ensure that we have a process ptid. */
|
||||
ptid_t process_ptid = pid_to_ptid (ptid_get_pid (child_ptid));
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/catch-syscall.exp
|
||||
===================================================================
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.base/catch-syscall.exp 2016-02-15 23:25:01.432350289 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/catch-syscall.exp 2016-02-15 23:25:36.689600619 +0100
|
||||
@@ -165,7 +165,7 @@
|
||||
# Deleting the catchpoints
|
||||
delete_breakpoints
|
||||
|
||||
- gdb_continue_to_end
|
||||
+ gdb_continue_to_end "" continue 1
|
||||
}
|
||||
|
||||
proc test_catch_syscall_without_args {} {
|
||||
@@ -236,7 +236,7 @@
|
||||
# If it doesn't, everything is right (since we don't have
|
||||
# a syscall named "mlock" in it). Otherwise, this is a failure.
|
||||
set thistest "catch syscall with unused syscall ($syscall_name)"
|
||||
- gdb_continue_to_end $thistest
|
||||
+ gdb_continue_to_end $thistest continue 1
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,21 +1,21 @@
|
||||
Index: gdb-7.7.50.20140609/gdb/infrun.c
|
||||
Index: gdb-7.10.50.20151022/gdb/infrun.c
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/infrun.c 2014-06-13 20:08:51.225699203 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/infrun.c 2014-06-13 20:08:55.515703466 +0200
|
||||
@@ -1661,7 +1661,7 @@ static const char *const scheduler_enums
|
||||
schedlock_step,
|
||||
--- gdb-7.10.50.20151022.orig/gdb/infrun.c 2015-10-22 22:30:15.887224452 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/infrun.c 2015-10-22 22:30:25.742282478 +0200
|
||||
@@ -2175,7 +2175,7 @@ static const char *const scheduler_enums
|
||||
schedlock_replay,
|
||||
NULL
|
||||
};
|
||||
-static const char *scheduler_mode = schedlock_off;
|
||||
-static const char *scheduler_mode = schedlock_replay;
|
||||
+static const char *scheduler_mode = schedlock_step;
|
||||
static void
|
||||
show_scheduler_mode (struct ui_file *file, int from_tty,
|
||||
struct cmd_list_element *c, const char *value)
|
||||
Index: gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-cli.exp
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.mi/mi-cli.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/testsuite/gdb.mi/mi-cli.exp 2014-06-13 20:08:55.515703466 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-cli.exp 2014-06-13 20:09:24.862732832 +0200
|
||||
@@ -181,7 +181,7 @@ mi_expect_stop "breakpoint-hit" "main" "
|
||||
--- gdb-7.10.50.20151022.orig/gdb/testsuite/gdb.mi/mi-cli.exp 2015-10-22 22:29:38.352003447 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.mi/mi-cli.exp 2015-10-22 22:30:15.888224458 +0200
|
||||
@@ -199,7 +199,7 @@ mi_expect_stop "breakpoint-hit" "main" "
|
||||
# Test that the token is output even for CLI commands
|
||||
# Also test that *stopped includes frame information.
|
||||
mi_gdb_test "34 next" \
|
||||
@ -24,10 +24,10 @@ Index: gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-cli.exp
|
||||
"34 next: run"
|
||||
|
||||
# Test that the new current source line is output to the console
|
||||
Index: gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-logging.exp
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.mi/mi-logging.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/testsuite/gdb.mi/mi-logging.exp 2014-06-13 20:08:51.227699205 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-logging.exp 2014-06-13 20:08:55.516703467 +0200
|
||||
--- gdb-7.10.50.20151022.orig/gdb/testsuite/gdb.mi/mi-logging.exp 2015-10-22 22:29:38.352003447 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.mi/mi-logging.exp 2015-10-22 22:30:15.888224458 +0200
|
||||
@@ -53,7 +53,7 @@ close $chan
|
||||
|
||||
set mi_log_prompt "\[(\]gdb\[)\] \[\r\n\]+"
|
||||
@ -46,10 +46,10 @@ Index: gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-logging.exp
|
||||
pass "Redirect log file contents"
|
||||
} else {
|
||||
fail "Redirect log file contents"
|
||||
Index: gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-console.exp
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.mi/mi-console.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/testsuite/gdb.mi/mi-console.exp 2014-06-13 20:08:51.227699205 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/testsuite/gdb.mi/mi-console.exp 2014-06-13 20:08:55.516703467 +0200
|
||||
--- gdb-7.10.50.20151022.orig/gdb/testsuite/gdb.mi/mi-console.exp 2015-10-22 22:29:38.353003453 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.mi/mi-console.exp 2015-10-22 22:30:15.888224458 +0200
|
||||
@@ -60,6 +60,9 @@ if { [gdb_compile "${srcdir}/${subdir}/
|
||||
|
||||
mi_run_to_main
|
||||
|
@ -8,8 +8,10 @@ http://sourceware.org/ml/gdb-patches/2007-12/msg00397.html
|
||||
|
||||
* gdb.arch/i386-interface.exp: Fix a testcase race.
|
||||
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.arch/i386-interface.S 22 Dec 2007 19:07:28 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/i386-interface.S
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/i386-interface.S 2016-02-15 23:23:03.318502357 +0100
|
||||
@@ -0,0 +1,628 @@
|
||||
+/* Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -639,8 +641,10 @@ http://sourceware.org/ml/gdb-patches/2007-12/msg00397.html
|
||||
+ .long 0x0
|
||||
+ .ident "GCC: (GNU) 4.3.0 20071221 (experimental)"
|
||||
+ .section .note.GNU-stack,"",@progbits
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.arch/i386-interface.exp 22 Dec 2007 19:07:28 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/i386-interface.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/i386-interface.exp 2016-02-15 23:23:15.978593556 +0100
|
||||
@@ -0,0 +1,59 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -672,7 +676,7 @@ http://sourceware.org/ml/gdb-patches/2007-12/msg00397.html
|
||||
+
|
||||
+set testfile "i386-interface"
|
||||
+set srcfile ${testfile}.S
|
||||
+set binfile ${objdir}/${subdir}/${testfile}.o
|
||||
+set binfile [standard_output_file ${testfile}.o]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {debug additional_flags=-m32}] != "" } {
|
||||
+ untested i386-gnu-cfi.exp
|
||||
|
@ -10,8 +10,10 @@ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=224128
|
||||
Port to GDB-6.7 - only the testcase left, patch has been reverted,
|
||||
char-vectors restricted.
|
||||
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/charsign.c 26 Jan 2007 10:32:00 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/charsign.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/charsign.c 2016-02-15 23:26:06.429811778 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -50,8 +52,10 @@ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=224128
|
||||
+char_n n_typed[]="A";
|
||||
+char_s s_typed[]="A";
|
||||
+char_u u_typed[]="A";
|
||||
--- /dev/null 1 Jan 1970 00:00:00 -0000
|
||||
+++ ./gdb/testsuite/gdb.base/charsign.exp 26 Jan 2007 10:32:00 -0000
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/charsign.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/charsign.exp 2016-02-15 23:26:12.409854237 +0100
|
||||
@@ -0,0 +1,63 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -71,7 +75,7 @@ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=224128
|
||||
+
|
||||
+set testfile charsign
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+proc do_test { cflags } {
|
||||
+ global srcdir
|
||||
|
@ -1,48 +1,87 @@
|
||||
Index: gdb-7.9.50.20150531/gdb/linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150531.orig/gdb/linux-nat.c 2015-05-31 18:23:56.147494790 +0200
|
||||
+++ gdb-7.9.50.20150531/gdb/linux-nat.c 2015-05-31 18:24:01.935530759 +0200
|
||||
@@ -168,6 +168,9 @@ blocked. */
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/infrun.c gdb-7.10.50.20160106/gdb/infrun.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/infrun.c 2016-01-09 15:05:06.127481758 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/infrun.c 2016-01-09 15:05:24.054593048 +0100
|
||||
@@ -626,6 +626,13 @@ holding the child stopped. Try \"set de
|
||||
target_pid_to_str (process_ptid));
|
||||
}
|
||||
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+ /* We should check PID_WAS_STOPPED and detach it stopped accordingly.
|
||||
+ In this point of code it cannot be 1 as we would not get FORK
|
||||
+ executed without CONTINUE first which resets PID_WAS_STOPPED.
|
||||
+ We would have to first TARGET_STOP and WAITPID it as with running
|
||||
+ inferior PTRACE_DETACH, SIGSTOP will ignore the signal. */
|
||||
+#endif
|
||||
target_detach (NULL, 0);
|
||||
}
|
||||
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/linux-nat.c gdb-7.10.50.20160106/gdb/linux-nat.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/linux-nat.c 2016-01-09 15:05:06.225482366 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/linux-nat.c 2016-01-09 15:05:24.050593023 +0100
|
||||
@@ -194,6 +194,11 @@ enum tribool have_ptrace_getregset = TRI
|
||||
static struct target_ops *linux_ops;
|
||||
static struct target_ops linux_ops_saved;
|
||||
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+/* PID of the inferior stopped by SIGSTOP before attaching (or zero). */
|
||||
+static pid_t pid_was_stopped;
|
||||
+
|
||||
+#endif
|
||||
/* The method to call, if any, when a new thread is attached. */
|
||||
static void (*linux_nat_new_thread) (struct lwp_info *);
|
||||
|
||||
@@ -981,6 +984,7 @@ linux_nat_post_attach_wait (ptid_t ptid,
|
||||
@@ -961,6 +966,9 @@ linux_nat_post_attach_wait (ptid_t ptid,
|
||||
if (debug_linux_nat)
|
||||
fprintf_unfiltered (gdb_stdlog,
|
||||
"LNPAW: Attaching to a stopped process\n");
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+ pid_was_stopped = ptid_get_pid (ptid);
|
||||
+#endif
|
||||
|
||||
/* The process is definitely stopped. It is in a job control
|
||||
stop, unless the kernel predates the TASK_STOPPED /
|
||||
@@ -1468,6 +1472,9 @@ get_pending_status (struct lwp_info *lp,
|
||||
@@ -1303,6 +1311,25 @@ get_pending_status (struct lwp_info *lp,
|
||||
gdb_signal_to_string (signo));
|
||||
}
|
||||
|
||||
+ if (*status == 0 && ptid_get_pid (lp->ptid) == pid_was_stopped)
|
||||
+ *status = W_STOPCODE (SIGSTOP);
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+ /* Workaround RHEL-5 kernel which has unreliable PTRACE_DETACH, SIGSTOP (that
|
||||
+ many TIDs are left unstopped). See RH Bug 496732. */
|
||||
+ if (ptid_get_pid (lp->ptid) == pid_was_stopped)
|
||||
+ {
|
||||
+ int err;
|
||||
+
|
||||
+ errno = 0;
|
||||
+ err = kill_lwp (ptid_get_lwp (lp->ptid), SIGSTOP);
|
||||
+ if (debug_linux_nat)
|
||||
+ {
|
||||
+ fprintf_unfiltered (gdb_stdlog,
|
||||
+ "SC: lwp kill %d %s\n",
|
||||
+ err,
|
||||
+ errno ? safe_strerror (errno) : "ERRNO-OK");
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1581,6 +1588,8 @@ linux_nat_detach (struct target_ops *ops
|
||||
@@ -1416,6 +1443,10 @@ linux_nat_detach (struct target_ops *ops
|
||||
}
|
||||
else
|
||||
linux_ops->to_detach (ops, args, from_tty);
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+
|
||||
+ pid_was_stopped = 0;
|
||||
+#endif
|
||||
}
|
||||
|
||||
/* Resume execution of the inferior process. If STEP is nonzero,
|
||||
@@ -1839,6 +1848,14 @@ linux_nat_resume (struct target_ops *ops
|
||||
@@ -1674,6 +1705,16 @@ linux_nat_resume (struct target_ops *ops
|
||||
return;
|
||||
}
|
||||
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+ /* At this point, we are going to resume the inferior and if we
|
||||
+ have attached to a stopped process, we no longer should leave
|
||||
+ it as stopped if the user detaches. PTID variable has PID set to LWP
|
||||
@ -51,23 +90,25 @@ Index: gdb-7.9.50.20150531/gdb/linux-nat.c
|
||||
+ if (!step && lp && pid_was_stopped == ptid_get_pid (lp->ptid))
|
||||
+ pid_was_stopped = 0;
|
||||
+
|
||||
+#endif
|
||||
if (resume_many)
|
||||
iterate_over_lwps (ptid, linux_nat_resume_callback, lp);
|
||||
|
||||
@@ -3935,6 +3952,8 @@ linux_nat_mourn_inferior (struct target_
|
||||
@@ -3618,6 +3659,10 @@ linux_nat_mourn_inferior (struct target_
|
||||
|
||||
/* Let the arch-specific native code know this process is gone. */
|
||||
linux_nat_forget_process (pid);
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+
|
||||
+ pid_was_stopped = 0;
|
||||
+#endif
|
||||
}
|
||||
|
||||
/* Convert a native/host siginfo object, into/from the siginfo in the
|
||||
Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.threads/attach-stopped.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150531.orig/gdb/testsuite/gdb.threads/attach-stopped.exp 2015-05-31 18:23:56.148494796 +0200
|
||||
+++ gdb-7.9.50.20150531/gdb/testsuite/gdb.threads/attach-stopped.exp 2015-05-31 18:24:01.935530759 +0200
|
||||
@@ -61,7 +61,65 @@ proc corefunc { threadtype } {
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/testsuite/gdb.threads/attach-stopped.exp gdb-7.10.50.20160106/gdb/testsuite/gdb.threads/attach-stopped.exp
|
||||
--- gdb-7.10.50.20160106-orig/gdb/testsuite/gdb.threads/attach-stopped.exp 2016-01-06 02:48:38.000000000 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/gdb.threads/attach-stopped.exp 2016-01-09 15:05:48.917747101 +0100
|
||||
@@ -56,7 +56,65 @@ proc corefunc { threadtype } {
|
||||
gdb_reinitialize_dir $srcdir/$subdir
|
||||
gdb_load ${binfile}
|
||||
|
||||
@ -134,19 +175,3 @@ Index: gdb-7.9.50.20150531/gdb/testsuite/gdb.threads/attach-stopped.exp
|
||||
|
||||
set test "$threadtype: attach2 to stopped, after setting file"
|
||||
gdb_test_multiple "attach $testpid" "$test" {
|
||||
Index: gdb-7.9.50.20150531/gdb/infrun.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150531.orig/gdb/infrun.c 2015-05-31 18:23:56.150494809 +0200
|
||||
+++ gdb-7.9.50.20150531/gdb/infrun.c 2015-05-31 18:24:01.938530778 +0200
|
||||
@@ -591,6 +591,11 @@ holding the child stopped. Try \"set de
|
||||
target_pid_to_str (process_ptid));
|
||||
}
|
||||
|
||||
+ /* We should check PID_WAS_STOPPED and detach it stopped accordingly.
|
||||
+ In this point of code it cannot be 1 as we would not get FORK
|
||||
+ executed without CONTINUE first which resets PID_WAS_STOPPED.
|
||||
+ We would have to first TARGET_STOP and WAITPID it as with running
|
||||
+ inferior PTRACE_DETACH, SIGSTOP will ignore the signal. */
|
||||
target_detach (NULL, 0);
|
||||
}
|
||||
|
||||
|
@ -1,8 +1,9 @@
|
||||
Test various forms of threads tracking across exec(2).
|
||||
|
||||
diff -up -u -X /root/jkratoch/.diffi.list -rup gdb-6.8/gdb/testsuite/gdb.threads/threaded-exec.c gdb-6.8-patched/gdb/testsuite/gdb.threads/threaded-exec.c
|
||||
--- gdb-6.8/gdb/testsuite/gdb.threads/threaded-exec.c 2008-04-16 17:05:19.000000000 -0400
|
||||
+++ gdb-6.8-patched/gdb/testsuite/gdb.threads/threaded-exec.c 2008-04-16 14:43:50.000000000 -0400
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.c
|
||||
===================================================================
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.threads/threaded-exec.c 2016-02-16 09:54:45.157163049 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.c 2016-02-16 09:54:46.210170175 +0100
|
||||
@@ -18,21 +18,95 @@
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
@ -102,7 +103,7 @@ diff -up -u -X /root/jkratoch/.diffi.list -rup gdb-6.8/gdb/testsuite/gdb.threads
|
||||
pthread_t t1;
|
||||
int i;
|
||||
|
||||
@@ -40,7 +114,34 @@ main (void)
|
||||
@@ -40,7 +114,34 @@
|
||||
assert (i == 0);
|
||||
i = pthread_join (t1, NULL);
|
||||
assert (i == 0);
|
||||
@ -139,16 +140,17 @@ diff -up -u -X /root/jkratoch/.diffi.list -rup gdb-6.8/gdb/testsuite/gdb.threads
|
||||
+ execl (cmd, cmd, exec_nothreads, exec_threads, phase_s, NULL);
|
||||
+ assert (0);
|
||||
}
|
||||
diff -up -u -X /root/jkratoch/.diffi.list -rup gdb-6.8/gdb/testsuite/gdb.threads/threaded-exec.exp gdb-6.8-patched/gdb/testsuite/gdb.threads/threaded-exec.exp
|
||||
--- gdb-6.8/gdb/testsuite/gdb.threads/threaded-exec.exp 2008-04-16 17:05:19.000000000 -0400
|
||||
+++ gdb-6.8-patched/gdb/testsuite/gdb.threads/threaded-exec.exp 2008-04-16 14:42:49.000000000 -0400
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.exp
|
||||
===================================================================
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.threads/threaded-exec.exp 2016-02-16 09:54:45.157163049 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/threaded-exec.exp 2016-02-16 09:55:27.397448879 +0100
|
||||
@@ -20,9 +20,14 @@
|
||||
|
||||
set testfile threaded-exec
|
||||
set srcfile ${testfile}.c
|
||||
-set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile_nothreads ${objdir}/${subdir}/${testfile}N
|
||||
+set binfile_threads ${objdir}/${subdir}/${testfile}Y
|
||||
-set binfile [standard_output_file ${testfile}]
|
||||
+set binfile_nothreads [standard_output_file ${testfile}N]
|
||||
+set binfile_threads [standard_output_file ${testfile}Y]
|
||||
|
||||
-if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable []] != "" } {
|
||||
+if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile_nothreads}" executable {additional_flags=-UTHREADS}] != "" } {
|
||||
@ -159,7 +161,7 @@ diff -up -u -X /root/jkratoch/.diffi.list -rup gdb-6.8/gdb/testsuite/gdb.threads
|
||||
return -1
|
||||
}
|
||||
|
||||
@@ -30,9 +35,9 @@ gdb_exit
|
||||
@@ -30,9 +35,9 @@
|
||||
gdb_start
|
||||
gdb_reinitialize_dir $srcdir/$subdir
|
||||
|
||||
|
@ -5,60 +5,65 @@ Some of the threads may not be properly PTRACE_DETACHed which hurts if they
|
||||
should have been detached with SIGSTOP (as they are accidentally left running
|
||||
on the debugger termination).
|
||||
|
||||
Index: gdb-7.9.50.20150520/gdb/defs.h
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/defs.h 2015-05-31 18:06:24.579002757 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/defs.h 2015-05-31 18:06:29.253031613 +0200
|
||||
@@ -145,6 +145,7 @@ extern void set_quit_flag (void);
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/defs.h gdb-7.10.50.20160106/gdb/defs.h
|
||||
--- gdb-7.10.50.20160106-orig/gdb/defs.h 2016-01-09 15:06:57.658172875 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/defs.h 2016-01-09 15:07:12.431264378 +0100
|
||||
@@ -145,6 +145,9 @@ extern void set_quit_flag (void);
|
||||
/* Flag that function quit should call quit_force. */
|
||||
extern volatile int sync_quit_force_run;
|
||||
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+extern int quit_flag_cleanup;
|
||||
+#endif
|
||||
extern int immediate_quit;
|
||||
|
||||
extern void quit (void);
|
||||
Index: gdb-7.9.50.20150520/gdb/top.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/top.c 2015-05-31 18:06:24.580002763 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/top.c 2015-05-31 18:06:29.254031619 +0200
|
||||
@@ -1463,7 +1463,9 @@ quit_force (char *args, int from_tty)
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/extension.c gdb-7.10.50.20160106/gdb/extension.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/extension.c 2016-01-06 02:48:37.000000000 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/extension.c 2016-01-09 15:07:12.434264396 +0100
|
||||
@@ -833,6 +833,11 @@ check_quit_flag (void)
|
||||
int i, result = 0;
|
||||
const struct extension_language_defn *extlang;
|
||||
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+ if (quit_flag_cleanup)
|
||||
+ return 0;
|
||||
+
|
||||
+#endif
|
||||
ALL_ENABLED_EXTENSION_LANGUAGES (i, extlang)
|
||||
{
|
||||
if (extlang->ops->check_quit_flag != NULL)
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/top.c gdb-7.10.50.20160106/gdb/top.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/top.c 2016-01-06 02:48:38.000000000 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/top.c 2016-01-09 15:07:12.432264384 +0100
|
||||
@@ -1557,7 +1557,13 @@ quit_force (char *args, int from_tty)
|
||||
qt.args = args;
|
||||
qt.from_tty = from_tty;
|
||||
|
||||
- /* We want to handle any quit errors and exit regardless. */
|
||||
+#ifndef NEED_DETACH_SIGSTOP
|
||||
/* We want to handle any quit errors and exit regardless. */
|
||||
+#else
|
||||
+ /* We want to handle any quit errors and exit regardless but we should never
|
||||
+ get user-interrupted to properly detach the inferior. */
|
||||
+ quit_flag_cleanup = 1;
|
||||
+#endif
|
||||
|
||||
/* Get out of tfind mode, and kill or detach all inferiors. */
|
||||
TRY
|
||||
Index: gdb-7.9.50.20150520/gdb/utils.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/utils.c 2015-05-31 18:06:24.582002776 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/utils.c 2015-05-31 18:06:29.255031625 +0200
|
||||
@@ -122,6 +122,11 @@ int job_control;
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/utils.c gdb-7.10.50.20160106/gdb/utils.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/utils.c 2016-01-09 15:06:57.654172850 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/utils.c 2016-01-09 15:07:12.433264390 +0100
|
||||
@@ -122,6 +122,13 @@ int job_control;
|
||||
|
||||
int immediate_quit;
|
||||
|
||||
+#ifdef NEED_DETACH_SIGSTOP
|
||||
+/* Nonzero means we are already processing the quitting cleanups and we should
|
||||
+ no longer get aborted. */
|
||||
+
|
||||
+int quit_flag_cleanup;
|
||||
+
|
||||
+#endif
|
||||
/* Nonzero means that strings with character values >0x7F should be printed
|
||||
as octal escapes. Zero means just print the value (e.g. it's an
|
||||
international character, and the terminal or window can cope.) */
|
||||
Index: gdb-7.9.50.20150520/gdb/extension.c
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/extension.c 2015-05-31 18:06:24.582002776 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/extension.c 2015-05-31 18:06:29.256031632 +0200
|
||||
@@ -833,6 +833,9 @@ check_quit_flag (void)
|
||||
int i, result = 0;
|
||||
const struct extension_language_defn *extlang;
|
||||
|
||||
+ if (quit_flag_cleanup)
|
||||
+ return 0;
|
||||
+
|
||||
ALL_ENABLED_EXTENSION_LANGUAGES (i, extlang)
|
||||
{
|
||||
if (extlang->ops->check_quit_flag != NULL)
|
||||
|
@ -2,8 +2,10 @@ For:
|
||||
http://sourceware.org/ml/gdb-patches/2008-04/msg00379.html
|
||||
http://sourceware.org/ml/gdb-cvs/2008-04/msg00104.html
|
||||
|
||||
--- /dev/null 2008-11-04 06:31:10.599601840 +0100
|
||||
+++ gdb-6.8/gdb/testsuite/gdb.base/watchpoint-cond.exp 2008-11-04 06:43:29.000000000 +0100
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-cond.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-cond.exp 2016-02-15 23:33:49.519099759 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -22,7 +24,7 @@ http://sourceware.org/ml/gdb-cvs/2008-04/msg00104.html
|
||||
+
|
||||
+set testfile watchpoint-cond
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -42,8 +44,10 @@ http://sourceware.org/ml/gdb-cvs/2008-04/msg00104.html
|
||||
+
|
||||
+gdb_test "watch i if i < 20" "atchpoint \[0-9\]+: i"
|
||||
+gdb_test "cont" "atchpoint \[0-9\]+: i.*Old value = 20.*New value = 19.*"
|
||||
--- /dev/null 2008-11-04 06:31:10.599601840 +0100
|
||||
+++ gdb-6.8/gdb/testsuite/gdb.base/watchpoint-cond.c 2008-11-04 06:42:48.000000000 +0100
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-cond.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-cond.c 2016-02-15 23:32:51.974691188 +0100
|
||||
@@ -0,0 +1,31 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:8c04434ab0bb23aa886076c89684cc6ce5edc5f106c467492e7dfe8175c88346
|
||||
size 26852345
|
3
gdb-7.11.tar.bz2
Normal file
3
gdb-7.11.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:2067c07a96dd5fc6fb4c4aafba0c439a50d0ba74e330d41a3d83d09933296d34
|
||||
size 27335115
|
@ -1,8 +1,8 @@
|
||||
Index: gdb-7.7.50.20140609/gdb/breakpoint.c
|
||||
Index: gdb-7.10.50.20160121/gdb/breakpoint.c
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/breakpoint.c 2014-06-13 20:24:34.564667225 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/breakpoint.c 2014-06-13 20:24:35.650668351 +0200
|
||||
@@ -16364,6 +16364,50 @@ initialize_breakpoint_ops (void)
|
||||
--- gdb-7.10.50.20160121.orig/gdb/breakpoint.c 2016-01-21 21:52:34.243387043 +0100
|
||||
+++ gdb-7.10.50.20160121/gdb/breakpoint.c 2016-01-21 21:53:00.365542925 +0100
|
||||
@@ -16139,6 +16139,50 @@
|
||||
static struct cmd_list_element *enablebreaklist = NULL;
|
||||
|
||||
void
|
||||
@ -53,23 +53,23 @@ Index: gdb-7.7.50.20140609/gdb/breakpoint.c
|
||||
_initialize_breakpoint (void)
|
||||
{
|
||||
struct cmd_list_element *c;
|
||||
Index: gdb-7.7.50.20140609/gdb/breakpoint.h
|
||||
Index: gdb-7.10.50.20160121/gdb/breakpoint.h
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/breakpoint.h 2014-06-13 20:24:34.566667227 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/breakpoint.h 2014-06-13 20:24:35.651668352 +0200
|
||||
@@ -1553,4 +1553,7 @@ extern void breakpoint_free_objfile (str
|
||||
|
||||
extern char *ep_parse_optional_if_clause (char **arg);
|
||||
--- gdb-7.10.50.20160121.orig/gdb/breakpoint.h 2016-01-21 21:52:34.244387049 +0100
|
||||
+++ gdb-7.10.50.20160121/gdb/breakpoint.h 2016-01-21 21:53:00.366542931 +0100
|
||||
@@ -1629,4 +1629,7 @@
|
||||
UIOUT iff debugging multiple threads. */
|
||||
extern void maybe_print_thread_hit_breakpoint (struct ui_out *uiout);
|
||||
|
||||
+extern void breakpoints_relocate (struct objfile *objfile,
|
||||
+ struct section_offsets *delta);
|
||||
+
|
||||
#endif /* !defined (BREAKPOINT_H) */
|
||||
Index: gdb-7.7.50.20140609/gdb/objfiles.c
|
||||
Index: gdb-7.10.50.20160121/gdb/objfiles.c
|
||||
===================================================================
|
||||
--- gdb-7.7.50.20140609.orig/gdb/objfiles.c 2014-06-13 20:24:35.652668353 +0200
|
||||
+++ gdb-7.7.50.20140609/gdb/objfiles.c 2014-06-13 20:25:10.867704891 +0200
|
||||
@@ -820,6 +820,11 @@ objfile_relocate1 (struct objfile *objfi
|
||||
--- gdb-7.10.50.20160121.orig/gdb/objfiles.c 2016-01-21 21:52:34.245387055 +0100
|
||||
+++ gdb-7.10.50.20160121/gdb/objfiles.c 2016-01-21 21:53:00.367542937 +0100
|
||||
@@ -916,6 +916,11 @@
|
||||
obj_section_addr (s));
|
||||
}
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.ada/packed_array.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.ada/packed_array.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/testsuite/gdb.ada/packed_array.exp 2014-06-13 03:59:37.000000000 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.ada/packed_array.exp 2014-06-16 23:30:30.107940483 +0200
|
||||
@@ -56,5 +56,11 @@ gdb_test_multiple "$test" "$test" {
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.ada/packed_array.exp 2016-02-15 23:33:29.830959972 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.ada/packed_array.exp 2016-02-15 23:35:56.289999846 +0100
|
||||
@@ -56,5 +56,11 @@
|
||||
# are. Observed with (FSF GNU Ada 4.5.3 20110124).
|
||||
xfail $test
|
||||
}
|
||||
@ -14,10 +14,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.ada/packed_array.exp
|
||||
+ }
|
||||
}
|
||||
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef-foo.S
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-vla-typedef-foo.S
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef-foo.S 2014-06-16 23:30:30.108940484 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-vla-typedef-foo.S 2016-02-15 23:35:56.290999853 +0100
|
||||
@@ -0,0 +1,455 @@
|
||||
+ .file "x86_64-vla-typedef.c"
|
||||
+ .section .debug_abbrev,"",@progbits
|
||||
@ -474,11 +474,11 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef-foo.S
|
||||
+ .string "GNU C 4.3.2 20081105 (Red Hat 4.3.2-7)"
|
||||
+ .ident "GCC: (GNU) 4.3.2 20081105 (Red Hat 4.3.2-7)"
|
||||
+ .section .note.GNU-stack,"",@progbits
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-vla-typedef.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.c 2014-06-16 23:30:30.109940484 +0200
|
||||
@@ -0,0 +1,43 @@
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-vla-typedef.c 2016-02-15 23:35:56.290999853 +0100
|
||||
@@ -0,0 +1,45 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
+ Copyright 2008 Free Software Foundation, Inc.
|
||||
@ -513,6 +513,8 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.c
|
||||
+
|
||||
+#else
|
||||
+
|
||||
+void foo (int size);
|
||||
+
|
||||
+int
|
||||
+main (void)
|
||||
+{
|
||||
@ -522,10 +524,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.c
|
||||
+}
|
||||
+
|
||||
+#endif
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-vla-typedef.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.exp 2014-06-16 23:30:30.109940484 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-vla-typedef.exp 2016-02-15 23:35:56.290999853 +0100
|
||||
@@ -0,0 +1,64 @@
|
||||
+# Copyright 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -552,8 +554,8 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.exp
|
||||
+set testfile x86_64-vla-typedef
|
||||
+set srcasmfile ${testfile}-foo.S
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binobjfile ${objdir}/${subdir}/${testfile}-foo.o
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+set binobjfile [standard_output_file ${testfile}-foo.o]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcasmfile}" "${binobjfile}" object {}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -591,10 +593,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.arch/x86_64-vla-typedef.exp
|
||||
+gdb_test "whatis array" "type = array_t" "second: whatis array"
|
||||
+
|
||||
+gdb_test "ptype array" "type = char \\\[78\\\]" "second: ptype array"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/arrayidx.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/arrayidx.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/testsuite/gdb.base/arrayidx.c 2014-06-13 03:59:37.000000000 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/arrayidx.c 2014-06-16 23:30:30.109940484 +0200
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.base/arrayidx.c 2016-02-15 23:33:29.830959972 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/arrayidx.c 2016-02-15 23:35:56.290999853 +0100
|
||||
@@ -17,6 +17,13 @@
|
||||
|
||||
int array[] = {1, 2, 3, 4};
|
||||
@ -609,11 +611,11 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/arrayidx.c
|
||||
int
|
||||
main (void)
|
||||
{
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/arrayidx.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/arrayidx.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/testsuite/gdb.base/arrayidx.exp 2014-06-13 03:59:37.000000000 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/arrayidx.exp 2014-06-16 23:30:30.109940484 +0200
|
||||
@@ -49,4 +49,12 @@ gdb_test "print array" \
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/gdb.base/arrayidx.exp 2016-02-15 23:33:29.830959972 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/arrayidx.exp 2016-02-15 23:35:56.291999860 +0100
|
||||
@@ -49,4 +49,12 @@
|
||||
"\\{\\\[0\\\] = 1, \\\[1\\\] = 2, \\\[2\\\] = 3, \\\[3\\\] = 4\\}" \
|
||||
"Print array with array-indexes on"
|
||||
|
||||
@ -627,10 +629,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/arrayidx.exp
|
||||
+ unsupported "$test (no GCC)"
|
||||
+ }
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/internal-var-field-address.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/internal-var-field-address.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/internal-var-field-address.c 2014-06-16 23:30:30.109940484 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/internal-var-field-address.c 2016-02-15 23:35:56.291999860 +0100
|
||||
@@ -0,0 +1,20 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -652,10 +654,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/internal-var-field-address.c
|
||||
+struct {
|
||||
+ int field;
|
||||
+} staticstruct = { 1 };
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/internal-var-field-address.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/internal-var-field-address.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/internal-var-field-address.exp 2014-06-16 23:30:30.109940484 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/internal-var-field-address.exp 2016-02-15 23:35:56.291999860 +0100
|
||||
@@ -0,0 +1,26 @@
|
||||
+# Copyright 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -683,10 +685,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/internal-var-field-address.exp
|
||||
+
|
||||
+gdb_test {set $varstruct = staticstruct}
|
||||
+gdb_test {p $varstruct.field} " = 1"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-frame.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-frame.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-frame.c 2014-06-16 23:30:30.110940485 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-frame.c 2016-02-15 23:35:56.291999860 +0100
|
||||
@@ -0,0 +1,31 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -719,10 +721,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-frame.c
|
||||
+ f (s);
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-frame.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-frame.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-frame.exp 2014-06-16 23:30:30.110940485 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-frame.exp 2016-02-15 23:35:56.291999860 +0100
|
||||
@@ -0,0 +1,38 @@
|
||||
+# Copyright 2011 Free Software Foundation, Inc.
|
||||
+#
|
||||
@ -762,10 +764,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-frame.exp
|
||||
+}
|
||||
+
|
||||
+gdb_test "bt full" "\r\n +s = \"X\\\\000\"\r\n.*"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-overflow.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.c 2014-06-16 23:30:30.110940485 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-overflow.c 2016-02-15 23:35:56.291999860 +0100
|
||||
@@ -0,0 +1,30 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -797,10 +799,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.c
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-overflow.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.exp 2014-06-16 23:30:30.110940485 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla-overflow.exp 2016-02-15 23:35:56.292999867 +0100
|
||||
@@ -0,0 +1,109 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -832,9 +834,9 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.exp
|
||||
+# #29 in backtrace_command_1 () at ../../gdb/stack.c:1273
|
||||
+
|
||||
+set testfile vla-overflow
|
||||
+set shfile ${objdir}/${subdir}/${testfile}-gdb.sh
|
||||
+set shfile [standard_output_file ${testfile}-gdb.sh]
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -911,10 +913,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla-overflow.exp
|
||||
+gdb_test "bt" "in \[^ \]*abort \\(.* in main \\(.*" "Backtrace after abort()"
|
||||
+
|
||||
+verbose -log "kb_found in bt after abort() = [expr [memory_v_pages_get] * $pagesize / 1024]"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.c 2014-06-16 23:30:30.110940485 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla.c 2016-02-15 23:35:56.292999867 +0100
|
||||
@@ -0,0 +1,55 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -971,10 +973,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.c
|
||||
+ foo (78);
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.exp 2014-06-16 23:30:30.110940485 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/vla.exp 2016-02-15 23:35:56.292999867 +0100
|
||||
@@ -0,0 +1,62 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -993,7 +995,7 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.exp
|
||||
+
|
||||
+set testfile vla
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -1038,10 +1040,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.base/vla.exp
|
||||
+gdb_test "p temp1" " = '1' <repeats 78 times>" "second: print temp1"
|
||||
+gdb_test "p temp2" " = '2' <repeats 78 times>" "second: print temp2"
|
||||
+gdb_test "p temp3" " = '3' <repeats 48 times>" "second: print temp3"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.S
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.S
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.S 2014-06-16 23:30:30.111940487 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.S 2016-02-15 23:35:56.292999867 +0100
|
||||
@@ -0,0 +1,246 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -1289,11 +1291,11 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.S
|
||||
+ .string "char"
|
||||
+.Luint_str:
|
||||
+ .string "unsigned int"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.exp 2014-06-16 23:30:30.111940487 +0200
|
||||
@@ -0,0 +1,63 @@
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.exp 2016-02-15 23:35:56.292999867 +0100
|
||||
@@ -0,0 +1,66 @@
|
||||
+# Copyright 2010 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
@ -1332,17 +1334,20 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.exp
|
||||
+
|
||||
+# Verify it behaves at least as an unbound array without inferior.
|
||||
+
|
||||
+set test "p a_string"
|
||||
+gdb_test_multiple $test $test {
|
||||
+ -re " = 0x\[0-9a-f\]+ \"seennotseen\"\r\n$gdb_prompt $" {
|
||||
+ pass $test
|
||||
+ }
|
||||
+ -re "No registers\\.\r\n$gdb_prompt $" {
|
||||
+ kfail "vlaregression" $test
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+gdb_test "ptype a_string" {type = char \[variable length\]}
|
||||
+# FIXME: FSF GDB crashes due to !has_stack_frames ().
|
||||
+# But in practice that should not happen.
|
||||
+# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43762
|
||||
+#set test "p a_string"
|
||||
+#gdb_test_multiple $test $test {
|
||||
+# -re " = 0x\[0-9a-f\]+ \"seennotseen\"\r\n$gdb_prompt $" {
|
||||
+# pass $test
|
||||
+# }
|
||||
+# -re "No registers\\.\r\n$gdb_prompt $" {
|
||||
+# kfail "vlaregression" $test
|
||||
+# }
|
||||
+#}
|
||||
+#
|
||||
+#gdb_test "ptype a_string" {type = char \[variable length\]}
|
||||
+
|
||||
+# Not runto_main as dw2-bound-loclist.S handles only the first byte of main.
|
||||
+if ![runto "*main"] {
|
||||
@ -1357,10 +1362,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-bound-loclist.exp
|
||||
+
|
||||
+# The register contains unpredictable value - the array size.
|
||||
+gdb_test "ptype reg_string" {type = char \[-?[0-9]+\]}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-stripped.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-stripped.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-stripped.c 2014-06-16 23:30:30.111940487 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-stripped.c 2016-02-15 23:35:56.293999874 +0100
|
||||
@@ -0,0 +1,42 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -1404,10 +1409,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-stripped.c
|
||||
+ func1 (1, 2);
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-stripped.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-stripped.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-stripped.exp 2014-06-16 23:30:30.111940487 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-stripped.exp 2016-02-15 23:35:56.293999874 +0100
|
||||
@@ -0,0 +1,79 @@
|
||||
+# Copyright 2006 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -1488,10 +1493,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-stripped.exp
|
||||
+gdb_test "step" \
|
||||
+ "func.* \\(.*\\) at .*" \
|
||||
+ "step"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.S
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.S
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.S 2014-06-16 23:30:30.112940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.S 2016-02-15 23:35:56.293999874 +0100
|
||||
@@ -0,0 +1,83 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -1576,10 +1581,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-locat
|
||||
+
|
||||
+ .byte 0x0 /* Terminator */
|
||||
+ .byte 0x0 /* Terminator */
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.exp 2014-06-16 23:30:30.112940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-location.exp 2016-02-15 23:35:56.293999874 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+# Copyright 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -1618,10 +1623,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-struct-member-data-locat
|
||||
+clean_restart $binfile
|
||||
+
|
||||
+gdb_test "ptype struct some_struct" "type = struct some_struct {\[\r\n \t\]*void field;\[\r\n \t\]*}"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.S
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.S
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.S 2014-06-16 23:30:30.112940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.S 2016-02-15 23:35:56.293999874 +0100
|
||||
@@ -0,0 +1,121 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -1744,10 +1749,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.S
|
||||
+ .byte 0x0 /* Terminator */
|
||||
+
|
||||
+ .byte 0x0 /* Terminator */
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.exp 2014-06-16 23:30:30.112940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.exp 2016-02-15 23:35:56.293999874 +0100
|
||||
@@ -0,0 +1,39 @@
|
||||
+# Copyright 2012 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -1788,10 +1793,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.dwarf2/dw2-subrange-no-type.exp
|
||||
+
|
||||
+gdb_test "ptype notype_string" {type = char \[129\]}
|
||||
+gdb_test "p notype_string" " = 'x' <repeats 129 times>"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dwarf-stride.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dwarf-stride.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dwarf-stride.exp 2014-06-16 23:30:30.112940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dwarf-stride.exp 2016-02-15 23:35:56.294999881 +0100
|
||||
@@ -0,0 +1,42 @@
|
||||
+# Copyright 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -1835,10 +1840,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dwarf-stride.exp
|
||||
+gdb_continue_to_breakpoint "break-here" ".*break-here.*"
|
||||
+gdb_test "p c40pt(1)" " = '0-hello.*"
|
||||
+gdb_test "p c40pt(2)" " = '1-hello.*"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dwarf-stride.f90
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dwarf-stride.f90
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dwarf-stride.f90 2014-06-16 23:30:30.112940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dwarf-stride.f90 2016-02-15 23:35:56.294999881 +0100
|
||||
@@ -0,0 +1,40 @@
|
||||
+! Copyright 2009 Free Software Foundation, Inc.
|
||||
+!
|
||||
@ -1880,10 +1885,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dwarf-stride.f90
|
||||
+ print *, c40pt ! break-here
|
||||
+
|
||||
+end program repro
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dynamic.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.exp 2014-06-16 23:37:45.568362563 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dynamic.exp 2016-02-15 23:36:39.358305635 +0100
|
||||
@@ -0,0 +1,151 @@
|
||||
+# Copyright 2007 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -1910,7 +1915,7 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.exp
|
||||
+
|
||||
+set testfile "dynamic"
|
||||
+set srcfile ${testfile}.f90
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug f90 quiet}] != "" } {
|
||||
+ untested "Couldn't compile ${srcfile}"
|
||||
@ -1931,9 +1936,9 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.exp
|
||||
+gdb_continue_to_breakpoint "varx-init"
|
||||
+gdb_test "p varx" "\\$\[0-9\]* = <not allocated>" "p varx unallocated"
|
||||
+gdb_test "ptype varx" "type = <not allocated>" "ptype varx unallocated"
|
||||
+gdb_test "p varx(1,5,17)" "no such vector element because not allocated" "p varx(1,5,17) unallocated"
|
||||
+gdb_test "p varx(1,5,17)=1" "no such vector element because not allocated" "p varx(1,5,17)=1 unallocated"
|
||||
+gdb_test "ptype varx(1,5,17)" "no such vector element because not allocated" "ptype varx(1,5,17) unallocated"
|
||||
+gdb_test "p varx(1,5,17)" {no such vector element \(vector not allocated\)} "p varx(1,5,17) unallocated"
|
||||
+gdb_test "p varx(1,5,17)=1" {no such vector element \(vector not allocated\)} "p varx(1,5,17)=1 unallocated"
|
||||
+gdb_test "ptype varx(1,5,17)" {no such vector element \(vector not allocated\)} "ptype varx(1,5,17) unallocated"
|
||||
+
|
||||
+gdb_breakpoint [gdb_get_line_number "varx-allocated"]
|
||||
+gdb_continue_to_breakpoint "varx-allocated"
|
||||
@ -1979,16 +1984,16 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.exp
|
||||
+gdb_test "p varv" "\\$\[0-9\]* = (<not associated>|.*(Cannot access it|Unable to access the object) because the object is not associated.)" "p varv deassociated"
|
||||
+gdb_test "ptype varv" "type = (<not associated>|.*(Cannot access it|Unable to access the object) because the object is not associated.)" "ptype varv deassociated"
|
||||
+gdb_test "p l" "\\$\[0-9\]* = \\.FALSE\\." "p l if varv deassociated"
|
||||
+gdb_test "p varv(1,5,17)" "no such vector element because not associated"
|
||||
+gdb_test "ptype varv(1,5,17)" "no such vector element because not associated"
|
||||
+gdb_test "p varv(1,5,17)" {no such vector element \(vector not associated\)}
|
||||
+gdb_test "ptype varv(1,5,17)" {no such vector element \(vector not associated\)}
|
||||
+
|
||||
+gdb_breakpoint [gdb_get_line_number "varx-deallocated"]
|
||||
+gdb_continue_to_breakpoint "varx-deallocated"
|
||||
+gdb_test "p varx" "\\$\[0-9\]* = <not allocated>" "p varx deallocated"
|
||||
+gdb_test "ptype varx" "type = <not allocated>" "ptype varx deallocated"
|
||||
+gdb_test "p l" "\\$\[0-9\]* = \\.FALSE\\." "p l if varx deallocated"
|
||||
+gdb_test "p varx(1,5,17)" "no such vector element because not allocated" "p varx(1,5,17) deallocated"
|
||||
+gdb_test "ptype varx(1,5,17)" "no such vector element because not allocated" "ptype varx(1,5,17) deallocated"
|
||||
+gdb_test "p varx(1,5,17)" {no such vector element \(vector not allocated\)} "p varx(1,5,17) deallocated"
|
||||
+gdb_test "ptype varx(1,5,17)" {no such vector element \(vector not allocated\)} "ptype varx(1,5,17) deallocated"
|
||||
+
|
||||
+gdb_breakpoint [gdb_get_line_number "vary-passed"]
|
||||
+gdb_continue_to_breakpoint "vary-passed"
|
||||
@ -2036,10 +2041,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.exp
|
||||
+gdb_test "p vart(3,8)" "\\$\[0-9\]* = 9"
|
||||
+# maps to foo::vary(1,3)
|
||||
+gdb_test "p vart(2,9)" "\\$\[0-9\]* = 10"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.f90
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dynamic.f90
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.f90 2014-06-16 23:30:30.113940488 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/dynamic.f90 2016-02-15 23:35:56.294999881 +0100
|
||||
@@ -0,0 +1,98 @@
|
||||
+! Copyright 2007 Free Software Foundation, Inc.
|
||||
+!
|
||||
@ -2139,10 +2144,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/dynamic.f90
|
||||
+ if (x (1, 1) .ne. 8 .or. x (2, 2) .ne. 9 .or. x (1, 2) .ne. 4) call abort
|
||||
+ if (x (3, 1) .ne. 10) call abort
|
||||
+end
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/string.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.exp 2014-06-16 23:30:30.114940489 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/string.exp 2016-02-15 23:36:39.359305642 +0100
|
||||
@@ -0,0 +1,59 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -2167,7 +2172,7 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.exp
|
||||
+
|
||||
+set testfile "string"
|
||||
+set srcfile ${testfile}.f90
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug f90 quiet}] != "" } {
|
||||
+ untested "Couldn't compile ${srcfile}"
|
||||
@ -2203,10 +2208,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.exp
|
||||
+gdb_continue_to_breakpoint "var-finish"
|
||||
+gdb_test "p e" "\\$\[0-9\]* = 'e '" "p e re-set"
|
||||
+gdb_test "p f" "\\$\[0-9\]* = \\(\\( 'f ', 'f ', 'f ', 'f ', 'f ', 'f ', 'f '\\) \\( 'f2 ', 'f ', 'f ', 'f ', 'f ', 'f ', 'f '\\) \\( 'f ', 'f ', 'f ', 'f ', 'f ', 'f ', 'f '\\) \\)" "p *f re-set"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.f90
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/string.f90
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.f90 2014-06-16 23:30:30.114940489 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/string.f90 2016-02-15 23:35:56.295999888 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+! Copyright 2008 Free Software Foundation, Inc.
|
||||
+!
|
||||
@ -2245,10 +2250,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/string.f90
|
||||
+ h = 'h'
|
||||
+ call foo (g, h)
|
||||
+end
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/subrange.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/subrange.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/subrange.exp 2014-06-16 23:30:30.114940489 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/subrange.exp 2016-02-15 23:35:56.295999888 +0100
|
||||
@@ -0,0 +1,72 @@
|
||||
+# Copyright 2011 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -2322,10 +2327,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/subrange.exp
|
||||
+gdb_unload
|
||||
+setup_kfail "*-*-*" "vlaregression/9999"
|
||||
+gdb_test {p $a (3, 2:2)} { = \(23\)}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/subrange.f90
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/subrange.f90
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/subrange.f90 2014-06-16 23:30:30.114940489 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.fortran/subrange.f90 2016-02-15 23:35:56.295999888 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+! Copyright 2011 Free Software Foundation, Inc.
|
||||
+!
|
||||
@ -2355,10 +2360,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.fortran/subrange.f90
|
||||
+ ptr => a
|
||||
+ write (*,*) a ! break-static
|
||||
+end
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.mi/mi2-var-stale-type.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.mi/mi2-var-stale-type.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.mi/mi2-var-stale-type.c 2014-06-16 23:30:30.114940489 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.mi/mi2-var-stale-type.c 2016-02-15 23:35:56.295999888 +0100
|
||||
@@ -0,0 +1,26 @@
|
||||
+/* Copyright 2011 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -2386,10 +2391,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.mi/mi2-var-stale-type.c
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.mi/mi2-var-stale-type.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.mi/mi2-var-stale-type.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.mi/mi2-var-stale-type.exp 2014-06-16 23:30:30.114940489 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.mi/mi2-var-stale-type.exp 2016-02-15 23:35:56.295999888 +0100
|
||||
@@ -0,0 +1,57 @@
|
||||
+# Copyright 2011 Free Software Foundation, Inc.
|
||||
+#
|
||||
@ -2448,10 +2453,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.mi/mi2-var-stale-type.exp
|
||||
+mi_create_varobj "vla" "vla" "create local variable vla"
|
||||
+
|
||||
+mi_gdb_test "-var-update *" "\\^done,changelist=.*" "-var-update *"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register-func.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.opt/array-from-register-func.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register-func.c 2014-06-16 23:30:30.115940490 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.opt/array-from-register-func.c 2016-02-15 23:35:56.295999888 +0100
|
||||
@@ -0,0 +1,22 @@
|
||||
+/* This file is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -2475,10 +2480,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register-func.c
|
||||
+{
|
||||
+ return arr[0];
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.opt/array-from-register.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register.c 2014-06-16 23:30:30.115940490 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.opt/array-from-register.c 2016-02-15 23:35:56.296999895 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* This file is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -2508,10 +2513,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register.c
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.opt/array-from-register.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register.exp 2014-06-16 23:30:30.115940490 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.opt/array-from-register.exp 2016-02-15 23:35:56.296999895 +0100
|
||||
@@ -0,0 +1,33 @@
|
||||
+# Copyright 2009 Free Software Foundation, Inc.
|
||||
+#
|
||||
@ -2546,10 +2551,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.opt/array-from-register.exp
|
||||
+# Seen regression:
|
||||
+# Address requested for identifier "arr" which is in register $rdi
|
||||
+gdb_test "p arr\[0\]" "\\$\[0-9\]+ = 42"
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pascal/arrays.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.exp 2014-06-16 23:30:30.115940490 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pascal/arrays.exp 2016-02-15 23:36:39.359305642 +0100
|
||||
@@ -0,0 +1,104 @@
|
||||
+# Copyright 2008, 2009 Free Software Foundation, Inc.
|
||||
+#
|
||||
@ -2574,7 +2579,7 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.exp
|
||||
+
|
||||
+set testfile "arrays"
|
||||
+set srcfile ${testfile}.pas
|
||||
+set binfile ${objdir}/${subdir}/${testfile}$EXEEXT
|
||||
+set binfile [standard_output_file ${testfile}$EXEEXT]
|
||||
+
|
||||
+# These tests only work with fpc, using the -gw3 compile-option
|
||||
+pascal_init
|
||||
@ -2655,10 +2660,10 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.exp
|
||||
+}
|
||||
+gdb_test "print DynArrChar" ".* = 'abcdefghijklm'" "Print dynamic array of char"
|
||||
+
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.pas
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.pascal/arrays.pas
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.pas 2014-06-16 23:30:30.115940490 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.pascal/arrays.pas 2016-02-15 23:35:56.296999895 +0100
|
||||
@@ -0,0 +1,82 @@
|
||||
+{
|
||||
+ Copyright 2008, 2009 Free Software Foundation, Inc.
|
||||
@ -2742,11 +2747,11 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/gdb.pascal/arrays.pas
|
||||
+ s := 'test'#0'string';
|
||||
+ writeln(s); { set breakpoint 2 here }
|
||||
+end.
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/lib/gdb.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/lib/gdb.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/testsuite/lib/gdb.exp 2014-06-16 23:30:29.278939700 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/lib/gdb.exp 2014-06-16 23:30:30.117940492 +0200
|
||||
@@ -159,6 +159,11 @@ proc gdb_unload {} {
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/lib/gdb.exp 2016-02-15 23:35:55.326993008 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/lib/gdb.exp 2016-02-15 23:35:56.297999903 +0100
|
||||
@@ -173,6 +173,11 @@
|
||||
send_gdb "y\n"
|
||||
exp_continue
|
||||
}
|
||||
@ -2758,11 +2763,11 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/lib/gdb.exp
|
||||
-re "Discard symbol table from .*y or n.*$" {
|
||||
send_gdb "y\n"
|
||||
exp_continue
|
||||
Index: gdb-7.7.90.20140613/gdb/testsuite/lib/pascal.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/lib/pascal.exp
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/testsuite/lib/pascal.exp 2014-06-13 03:59:37.000000000 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/testsuite/lib/pascal.exp 2014-06-16 23:30:30.117940492 +0200
|
||||
@@ -37,6 +37,9 @@ proc pascal_init {} {
|
||||
--- gdb-7.10.90.20160211.orig/gdb/testsuite/lib/pascal.exp 2016-02-15 23:33:29.830959972 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/lib/pascal.exp 2016-02-15 23:35:56.298999910 +0100
|
||||
@@ -37,6 +37,9 @@
|
||||
global pascal_compiler_is_fpc
|
||||
global gpc_compiler
|
||||
global fpc_compiler
|
||||
@ -2772,7 +2777,7 @@ Index: gdb-7.7.90.20140613/gdb/testsuite/lib/pascal.exp
|
||||
global env
|
||||
|
||||
if { $pascal_init_done == 1 } {
|
||||
@@ -64,6 +67,20 @@ proc pascal_init {} {
|
||||
@@ -64,6 +67,20 @@
|
||||
set pascal_compiler_is_fpc 1
|
||||
verbose -log "Free Pascal compiler found"
|
||||
}
|
||||
|
@ -37,13 +37,13 @@ gdb/gdbserver/
|
||||
(linux_create_inferior, linux_tracefork_child): Call it instead of
|
||||
direct ptrace.
|
||||
|
||||
Index: gdb-7.9.90.20150709/gdb/nat/linux-ptrace.c
|
||||
Index: gdb-7.10.50.20160106/gdb/nat/linux-ptrace.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/nat/linux-ptrace.c 2015-07-09 18:24:13.705140384 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/nat/linux-ptrace.c 2015-07-09 18:24:24.911235973 +0200
|
||||
@@ -23,6 +23,10 @@
|
||||
#include "buffer.h"
|
||||
--- gdb-7.10.50.20160106.orig/gdb/nat/linux-ptrace.c 2016-01-08 19:15:57.580707944 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/nat/linux-ptrace.c 2016-01-08 19:16:02.654736246 +0100
|
||||
@@ -24,6 +24,10 @@
|
||||
#include "gdb_wait.h"
|
||||
#include "gdb_ptrace.h"
|
||||
|
||||
+#ifdef HAVE_SELINUX_SELINUX_H
|
||||
+# include <selinux/selinux.h>
|
||||
@ -52,7 +52,7 @@ Index: gdb-7.9.90.20150709/gdb/nat/linux-ptrace.c
|
||||
/* Stores the ptrace options supported by the running kernel.
|
||||
A value of -1 means we did not check for features yet. A value
|
||||
of 0 means there are no supported features. */
|
||||
@@ -47,6 +51,8 @@ linux_ptrace_attach_fail_reason (pid_t p
|
||||
@@ -48,6 +52,8 @@
|
||||
buffer_xml_printf (buffer, _("process %d is a zombie "
|
||||
"- the process has already terminated"),
|
||||
(int) pid);
|
||||
@ -61,7 +61,7 @@ Index: gdb-7.9.90.20150709/gdb/nat/linux-ptrace.c
|
||||
}
|
||||
|
||||
/* See linux-ptrace.h. */
|
||||
@@ -581,6 +587,22 @@ linux_ptrace_init_warnings (void)
|
||||
@@ -594,6 +600,22 @@
|
||||
linux_ptrace_test_ret_to_nx ();
|
||||
}
|
||||
|
||||
@ -84,11 +84,11 @@ Index: gdb-7.9.90.20150709/gdb/nat/linux-ptrace.c
|
||||
/* Extract extended ptrace event from wait status. */
|
||||
|
||||
int
|
||||
Index: gdb-7.9.90.20150709/gdb/nat/linux-ptrace.h
|
||||
Index: gdb-7.10.50.20160106/gdb/nat/linux-ptrace.h
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/nat/linux-ptrace.h 2015-07-09 18:24:13.706140392 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/nat/linux-ptrace.h 2015-07-09 18:24:24.912235981 +0200
|
||||
@@ -157,6 +157,7 @@ extern void linux_ptrace_attach_fail_rea
|
||||
--- gdb-7.10.50.20160106.orig/gdb/nat/linux-ptrace.h 2016-01-08 19:15:57.581707950 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/nat/linux-ptrace.h 2016-01-08 19:16:02.655736251 +0100
|
||||
@@ -164,6 +164,7 @@
|
||||
extern char *linux_ptrace_attach_fail_reason_string (ptid_t ptid, int err);
|
||||
|
||||
extern void linux_ptrace_init_warnings (void);
|
||||
@ -96,11 +96,11 @@ Index: gdb-7.9.90.20150709/gdb/nat/linux-ptrace.h
|
||||
extern void linux_check_ptrace_features (void);
|
||||
extern void linux_enable_event_reporting (pid_t pid, int attached);
|
||||
extern void linux_disable_event_reporting (pid_t pid);
|
||||
Index: gdb-7.9.90.20150709/gdb/configure.ac
|
||||
Index: gdb-7.10.50.20160106/gdb/configure.ac
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/configure.ac 2015-07-09 18:24:13.707140401 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/configure.ac 2015-07-09 18:24:24.913235990 +0200
|
||||
@@ -2150,6 +2150,10 @@ case $host_os in
|
||||
--- gdb-7.10.50.20160106.orig/gdb/configure.ac 2016-01-08 19:15:57.582707955 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/configure.ac 2016-01-08 19:16:02.656736257 +0100
|
||||
@@ -2077,6 +2077,10 @@
|
||||
esac
|
||||
AC_DEFINE_UNQUOTED(GDBINIT,"$gdbinit",[The .gdbinit filename.])
|
||||
|
||||
@ -111,11 +111,11 @@ Index: gdb-7.9.90.20150709/gdb/configure.ac
|
||||
dnl Handle optional features that can be enabled.
|
||||
|
||||
# Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
|
||||
Index: gdb-7.9.90.20150709/gdb/gdbserver/configure.ac
|
||||
Index: gdb-7.10.50.20160106/gdb/gdbserver/configure.ac
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/gdbserver/configure.ac 2015-07-09 18:24:13.707140401 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/gdbserver/configure.ac 2015-07-09 18:24:24.913235990 +0200
|
||||
@@ -499,6 +499,10 @@ if $want_ipa ; then
|
||||
--- gdb-7.10.50.20160106.orig/gdb/gdbserver/configure.ac 2016-01-08 19:15:57.582707955 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/gdbserver/configure.ac 2016-01-08 19:16:02.656736257 +0100
|
||||
@@ -524,6 +524,10 @@
|
||||
fi
|
||||
fi
|
||||
|
||||
@ -126,11 +126,11 @@ Index: gdb-7.9.90.20150709/gdb/gdbserver/configure.ac
|
||||
AC_SUBST(GDBSERVER_DEPFILES)
|
||||
AC_SUBST(GDBSERVER_LIBS)
|
||||
AC_SUBST(srv_xmlbuiltin)
|
||||
Index: gdb-7.9.90.20150709/gdb/gdbserver/linux-low.c
|
||||
Index: gdb-7.10.50.20160106/gdb/gdbserver/linux-low.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/gdbserver/linux-low.c 2015-07-09 18:24:13.709140418 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/gdbserver/linux-low.c 2015-07-09 18:24:24.914235998 +0200
|
||||
@@ -755,6 +755,29 @@ add_lwp (ptid_t ptid)
|
||||
--- gdb-7.10.50.20160106.orig/gdb/gdbserver/linux-low.c 2016-01-08 19:15:57.585707972 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/gdbserver/linux-low.c 2016-01-08 19:16:02.658736268 +0100
|
||||
@@ -853,6 +853,29 @@
|
||||
return lwp;
|
||||
}
|
||||
|
||||
@ -160,20 +160,20 @@ Index: gdb-7.9.90.20150709/gdb/gdbserver/linux-low.c
|
||||
/* Start an inferior process and returns its pid.
|
||||
ALLARGS is a vector of program-name and args. */
|
||||
|
||||
@@ -778,7 +801,7 @@ linux_create_inferior (char *program, ch
|
||||
@@ -876,7 +899,7 @@
|
||||
if (pid == 0)
|
||||
{
|
||||
close_most_fds ();
|
||||
- ptrace (PTRACE_TRACEME, 0, (PTRACE_TYPE_ARG3) 0, (PTRACE_TYPE_ARG4) 0);
|
||||
+ linux_traceme (program);
|
||||
|
||||
#ifndef __ANDROID__ /* Bionic doesn't use SIGRTMIN the way glibc does. */
|
||||
signal (__SIGRTMIN + 1, SIG_DFL);
|
||||
Index: gdb-7.9.90.20150709/gdb/inf-ptrace.c
|
||||
setpgid (0, 0);
|
||||
|
||||
Index: gdb-7.10.50.20160106/gdb/inf-ptrace.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/inf-ptrace.c 2015-07-09 18:24:13.710140426 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/inf-ptrace.c 2015-07-09 18:24:24.915236007 +0200
|
||||
@@ -79,7 +79,15 @@ static void
|
||||
--- gdb-7.10.50.20160106.orig/gdb/inf-ptrace.c 2016-01-08 19:15:57.586707977 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/inf-ptrace.c 2016-01-08 19:16:02.659736274 +0100
|
||||
@@ -79,7 +79,15 @@
|
||||
inf_ptrace_me (void)
|
||||
{
|
||||
/* "Trace me, Dr. Memory!" */
|
||||
@ -189,11 +189,11 @@ Index: gdb-7.9.90.20150709/gdb/inf-ptrace.c
|
||||
}
|
||||
|
||||
/* Start a new inferior Unix child process. EXEC_FILE is the file to
|
||||
Index: gdb-7.9.90.20150709/gdb/linux-nat.c
|
||||
Index: gdb-7.10.50.20160106/gdb/linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/linux-nat.c 2015-07-09 18:24:13.712140443 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/linux-nat.c 2015-07-09 18:24:24.916236015 +0200
|
||||
@@ -1184,6 +1184,7 @@ linux_nat_create_inferior (struct target
|
||||
--- gdb-7.10.50.20160106.orig/gdb/linux-nat.c 2016-01-08 19:15:57.587707983 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/linux-nat.c 2016-01-08 19:16:02.660736279 +0100
|
||||
@@ -1016,6 +1016,7 @@
|
||||
{
|
||||
struct cleanup *restore_personality
|
||||
= maybe_disable_address_space_randomization (disable_randomization);
|
||||
@ -201,7 +201,7 @@ Index: gdb-7.9.90.20150709/gdb/linux-nat.c
|
||||
|
||||
/* The fork_child mechanism is synchronous and calls target_wait, so
|
||||
we have to mask the async mode. */
|
||||
@@ -1191,7 +1192,28 @@ linux_nat_create_inferior (struct target
|
||||
@@ -1023,7 +1024,28 @@
|
||||
/* Make sure we report all signals during startup. */
|
||||
linux_nat_pass_signals (ops, 0, NULL);
|
||||
|
||||
@ -231,10 +231,10 @@ Index: gdb-7.9.90.20150709/gdb/linux-nat.c
|
||||
|
||||
do_cleanups (restore_personality);
|
||||
}
|
||||
Index: gdb-7.9.90.20150709/gdb/config.in
|
||||
Index: gdb-7.10.50.20160106/gdb/config.in
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/config.in 2015-07-09 18:24:13.713140452 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/config.in 2015-07-09 18:24:24.916236015 +0200
|
||||
--- gdb-7.10.50.20160106.orig/gdb/config.in 2016-01-08 19:15:57.588707989 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/config.in 2016-01-08 19:16:02.660736279 +0100
|
||||
@@ -264,6 +264,9 @@
|
||||
/* Define if librpm library is being used. */
|
||||
#undef HAVE_LIBRPM
|
||||
@ -255,11 +255,11 @@ Index: gdb-7.9.90.20150709/gdb/config.in
|
||||
/* Define to 1 if you have the `setlocale' function. */
|
||||
#undef HAVE_SETLOCALE
|
||||
|
||||
Index: gdb-7.9.90.20150709/gdb/configure
|
||||
Index: gdb-7.10.50.20160106/gdb/configure
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/configure 2015-07-09 18:24:13.718140495 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/configure 2015-07-09 18:24:24.920236049 +0200
|
||||
@@ -14228,6 +14228,64 @@ cat >>confdefs.h <<_ACEOF
|
||||
--- gdb-7.10.50.20160106.orig/gdb/configure 2016-01-08 19:15:57.593708017 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/configure 2016-01-08 19:16:02.665736307 +0100
|
||||
@@ -14653,6 +14653,64 @@
|
||||
_ACEOF
|
||||
|
||||
|
||||
@ -324,11 +324,11 @@ Index: gdb-7.9.90.20150709/gdb/configure
|
||||
|
||||
# Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
|
||||
# except that the argument to --with-sysroot is optional.
|
||||
Index: gdb-7.9.90.20150709/gdb/gdbserver/config.in
|
||||
Index: gdb-7.10.50.20160106/gdb/gdbserver/config.in
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/gdbserver/config.in 2015-07-09 18:24:13.719140503 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/gdbserver/config.in 2015-07-09 18:24:24.920236049 +0200
|
||||
@@ -113,6 +113,9 @@
|
||||
--- gdb-7.10.50.20160106.orig/gdb/gdbserver/config.in 2016-01-08 19:15:57.595708028 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/gdbserver/config.in 2016-01-08 19:16:02.665736307 +0100
|
||||
@@ -117,6 +117,9 @@
|
||||
/* Define to 1 if you have the `mcheck' library (-lmcheck). */
|
||||
#undef HAVE_LIBMCHECK
|
||||
|
||||
@ -338,21 +338,21 @@ Index: gdb-7.9.90.20150709/gdb/gdbserver/config.in
|
||||
/* Define if the target supports branch tracing. */
|
||||
#undef HAVE_LINUX_BTRACE
|
||||
|
||||
@@ -189,6 +192,9 @@
|
||||
/* Define to 1 if you have the `setns' function. */
|
||||
#undef HAVE_SETNS
|
||||
@@ -193,6 +196,9 @@
|
||||
/* Define to 1 if you have the `pwrite' function. */
|
||||
#undef HAVE_PWRITE
|
||||
|
||||
+/* Define to 1 if you have the <selinux/selinux.h> header file. */
|
||||
+#undef HAVE_SELINUX_SELINUX_H
|
||||
+
|
||||
/* Define to 1 if you have the <sgtty.h> header file. */
|
||||
#undef HAVE_SGTTY_H
|
||||
/* Define to 1 if you have the `setns' function. */
|
||||
#undef HAVE_SETNS
|
||||
|
||||
Index: gdb-7.9.90.20150709/gdb/gdbserver/configure
|
||||
Index: gdb-7.10.50.20160106/gdb/gdbserver/configure
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/gdbserver/configure 2015-07-09 18:24:13.721140520 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/gdbserver/configure 2015-07-09 18:24:24.922236066 +0200
|
||||
@@ -7022,6 +7022,64 @@ if $want_ipa ; then
|
||||
--- gdb-7.10.50.20160106.orig/gdb/gdbserver/configure 2016-01-08 19:15:57.597708039 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/gdbserver/configure 2016-01-08 19:16:02.667736318 +0100
|
||||
@@ -7311,6 +7311,64 @@
|
||||
fi
|
||||
fi
|
||||
|
||||
|
@ -1,20 +1,20 @@
|
||||
Index: gdb-7.9.90.20150709/gdb/config/i386/linux64.mh
|
||||
Index: gdb-7.10.90.20160211/gdb/config/i386/linux64.mh
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/config/i386/linux64.mh 2015-07-09 18:23:32.173786118 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/config/i386/linux64.mh 2015-07-09 18:23:51.823953736 +0200
|
||||
@@ -7,7 +7,7 @@ NATDEPFILES= inf-ptrace.o fork-child.o \
|
||||
--- gdb-7.10.90.20160211.orig/gdb/config/i386/linux64.mh 2016-02-11 20:56:32.470674877 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/config/i386/linux64.mh 2016-02-11 20:56:51.158797712 +0100
|
||||
@@ -7,7 +7,7 @@
|
||||
linux-procfs.o linux-ptrace.o linux-btrace.o \
|
||||
linux-waitpid.o linux-personality.o x86-linux.o \
|
||||
x86-linux-dregs.o linux-namespaces.o
|
||||
x86-linux-dregs.o amd64-linux-siginfo.o linux-namespaces.o
|
||||
-NAT_FILE= config/nm-linux.h
|
||||
+NAT_FILE= nm-linux64.h
|
||||
NAT_CDEPS = $(srcdir)/proc-service.list
|
||||
|
||||
# The dynamically loaded libthread_db needs access to symbols in the
|
||||
Index: gdb-7.9.90.20150709/gdb/config/i386/linux.mh
|
||||
Index: gdb-7.10.90.20160211/gdb/config/i386/linux.mh
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/config/i386/linux.mh 2015-07-09 18:23:30.527772078 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/config/i386/linux.mh 2015-07-09 18:23:32.174786127 +0200
|
||||
--- gdb-7.10.90.20160211.orig/gdb/config/i386/linux.mh 2016-02-11 20:56:26.925638430 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/config/i386/linux.mh 2016-02-11 20:56:32.471674884 +0100
|
||||
@@ -1,6 +1,6 @@
|
||||
# Host: Intel 386 running GNU/Linux.
|
||||
|
||||
@ -23,10 +23,10 @@ Index: gdb-7.9.90.20150709/gdb/config/i386/linux.mh
|
||||
NATDEPFILES= inf-ptrace.o fork-child.o \
|
||||
x86-nat.o x86-dregs.o i386-linux-nat.o x86-linux-nat.o \
|
||||
proc-service.o linux-thread-db.o \
|
||||
Index: gdb-7.9.90.20150709/gdb/config/i386/nm-linux.h
|
||||
Index: gdb-7.10.90.20160211/gdb/config/i386/nm-linux.h
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.90.20150709/gdb/config/i386/nm-linux.h 2015-07-09 18:23:32.174786127 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/config/i386/nm-linux.h 2016-02-11 20:56:32.471674884 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* Native support for GNU/Linux i386.
|
||||
+
|
||||
@ -56,10 +56,10 @@ Index: gdb-7.9.90.20150709/gdb/config/i386/nm-linux.h
|
||||
+#define target_can_use_hardware_watchpoint(type, cnt, ot) 1
|
||||
+
|
||||
+#endif /* NM_LINUX64_H */
|
||||
Index: gdb-7.9.90.20150709/gdb/config/i386/nm-linux64.h
|
||||
Index: gdb-7.10.90.20160211/gdb/config/i386/nm-linux64.h
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.90.20150709/gdb/config/i386/nm-linux64.h 2015-07-09 18:23:32.174786127 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/config/i386/nm-linux64.h 2016-02-11 20:56:32.471674884 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* Native support for GNU/Linux amd64.
|
||||
+
|
||||
@ -89,11 +89,11 @@ Index: gdb-7.9.90.20150709/gdb/config/i386/nm-linux64.h
|
||||
+#define target_can_use_hardware_watchpoint(type, cnt, ot) 1
|
||||
+
|
||||
+#endif /* NM_LINUX64_H */
|
||||
Index: gdb-7.9.90.20150709/gdb/target.h
|
||||
Index: gdb-7.10.90.20160211/gdb/target.h
|
||||
===================================================================
|
||||
--- gdb-7.9.90.20150709.orig/gdb/target.h 2015-07-09 18:23:30.528772086 +0200
|
||||
+++ gdb-7.9.90.20150709/gdb/target.h 2015-07-09 18:23:32.175786135 +0200
|
||||
@@ -1849,9 +1849,11 @@ extern char *target_thread_name (struct
|
||||
--- gdb-7.10.90.20160211.orig/gdb/target.h 2016-02-11 20:56:26.926638437 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/target.h 2016-02-11 20:56:32.472674890 +0100
|
||||
@@ -1924,9 +1924,11 @@
|
||||
CNT is the number of such watchpoints used so far, including this
|
||||
one. OTHERTYPE is who knows what... */
|
||||
|
||||
@ -105,10 +105,10 @@ Index: gdb-7.9.90.20150709/gdb/target.h
|
||||
|
||||
/* Returns the number of debug registers needed to watch the given
|
||||
memory region, or zero if not supported. */
|
||||
Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/watchpoint-hw-before-run.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-hw-before-run.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.9.90.20150709/gdb/testsuite/gdb.base/watchpoint-hw-before-run.exp 2015-07-09 18:23:32.175786135 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/watchpoint-hw-before-run.exp 2016-02-11 20:56:32.472674890 +0100
|
||||
@@ -0,0 +1,40 @@
|
||||
+# Copyright 2009, 2010 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -149,4 +149,4 @@ Index: gdb-7.9.90.20150709/gdb/testsuite/gdb.base/watchpoint-hw-before-run.exp
|
||||
+}
|
||||
+gdb_test "" "main .* at .*" "start"
|
||||
+
|
||||
+gdb_test "continue" "Continuing.\r\nHardware read watchpoint \[0-9\]+: watchee\r\n\r\nValue = 0\r\n.*"
|
||||
+gdb_test "continue" "Continuing.\r\n\r\nHardware read watchpoint \[0-9\]+: watchee\r\n\r\nValue = 0\r\n.*"
|
||||
|
63
gdb-fedora-libncursesw.patch
Normal file
63
gdb-fedora-libncursesw.patch
Normal file
@ -0,0 +1,63 @@
|
||||
Fedora: Force libncursesw over libncurses to match the includes.
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=1270534
|
||||
|
||||
diff -dup -rup gdb-7.10.50.20151113-orig/gdb/configure gdb-7.10.50.20151113/gdb/configure
|
||||
--- gdb-7.10.50.20151113-orig/gdb/configure 2015-11-14 16:14:04.404118312 +0100
|
||||
+++ gdb-7.10.50.20151113/gdb/configure 2015-11-14 16:17:59.074566047 +0100
|
||||
@@ -8463,6 +8463,7 @@ if test x"$prefer_curses" = xyes; then
|
||||
# search /usr/local/include, if ncurses is installed in /usr/local. A
|
||||
# default installation of ncurses on alpha*-dec-osf* will lead to such
|
||||
# a situation.
|
||||
+ # Fedora: Force libncursesw over libncurses to match the includes.
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
|
||||
$as_echo_n "checking for library containing waddstr... " >&6; }
|
||||
if test "${ac_cv_search_waddstr+set}" = set; then :
|
||||
@@ -8487,7 +8488,7 @@ return waddstr ();
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
-for ac_lib in '' ncurses cursesX curses; do
|
||||
+for ac_lib in '' ncursesw; do
|
||||
if test -z "$ac_lib"; then
|
||||
ac_res="none required"
|
||||
else
|
||||
@@ -8561,6 +8562,7 @@ case $host_os in
|
||||
esac
|
||||
|
||||
# These are the libraries checked by Readline.
|
||||
+# Fedora: Force libncursesw over libncurses to match the includes.
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
|
||||
$as_echo_n "checking for library containing tgetent... " >&6; }
|
||||
if test "${ac_cv_search_tgetent+set}" = set; then :
|
||||
@@ -8585,7 +8587,7 @@ return tgetent ();
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
-for ac_lib in '' termcap tinfo curses ncurses; do
|
||||
+for ac_lib in '' termcap tinfo ncursesw; do
|
||||
if test -z "$ac_lib"; then
|
||||
ac_res="none required"
|
||||
else
|
||||
diff -dup -rup gdb-7.10.50.20151113-orig/gdb/configure.ac gdb-7.10.50.20151113/gdb/configure.ac
|
||||
--- gdb-7.10.50.20151113-orig/gdb/configure.ac 2015-11-14 16:14:04.404118312 +0100
|
||||
+++ gdb-7.10.50.20151113/gdb/configure.ac 2015-11-14 16:17:54.898540284 +0100
|
||||
@@ -771,7 +771,8 @@ if test x"$prefer_curses" = xyes; then
|
||||
# search /usr/local/include, if ncurses is installed in /usr/local. A
|
||||
# default installation of ncurses on alpha*-dec-osf* will lead to such
|
||||
# a situation.
|
||||
- AC_SEARCH_LIBS(waddstr, [ncurses cursesX curses])
|
||||
+ # Fedora: Force libncursesw over libncurses to match the includes.
|
||||
+ AC_SEARCH_LIBS(waddstr, [ncursesw])
|
||||
|
||||
if test "$ac_cv_search_waddstr" != no; then
|
||||
curses_found=yes
|
||||
@@ -813,7 +814,8 @@ case $host_os in
|
||||
esac
|
||||
|
||||
# These are the libraries checked by Readline.
|
||||
-AC_SEARCH_LIBS(tgetent, [termcap tinfo curses ncurses])
|
||||
+# Fedora: Force libncursesw over libncurses to match the includes.
|
||||
+AC_SEARCH_LIBS(tgetent, [termcap tinfo ncursesw])
|
||||
|
||||
if test "$ac_cv_search_tgetent" = no; then
|
||||
CONFIG_OBS="$CONFIG_OBS stub-termcap.o"
|
611
gdb-fortran-stride-intel-1of6.patch
Normal file
611
gdb-fortran-stride-intel-1of6.patch
Normal file
@ -0,0 +1,611 @@
|
||||
http://sourceware.org/ml/gdb-patches/2016-02/msg00843.html
|
||||
Subject: [PATCH v2 1/6] fortran: allow multi-dimensional subarrays
|
||||
|
||||
From: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
Add an argument count for subrange expressions in Fortran.
|
||||
Based on the counted value calculate a new array with the
|
||||
elements specified by the user. First parse the user input,
|
||||
secondly copy the desired array values into the return
|
||||
array, thirdly re-create the necessary ranges and bounds.
|
||||
|
||||
1| program prog
|
||||
2| integer :: ary(10,5) = (/ (i,i=1,10) (j, j=1,5) /)
|
||||
3| end program prog
|
||||
|
||||
(gdb) print ary(2:4,1:3)
|
||||
old> Syntax error in expression near ':3'
|
||||
new> $3 = ( ( 21, 31, 41) ( 22, 32, 42) ( 23, 33, 43) )
|
||||
|
||||
2013-11-25 Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
* eval.c (multi_f77_subscript): Remove function.
|
||||
* eval.c (evaluate_subrange_expr): When evaluating
|
||||
an array or string expression, call
|
||||
value_f90_subarray.
|
||||
* eval.c (value_f90_subarray): Add argument parsing
|
||||
and compute result array based on user input.
|
||||
* f-exp.y: Increment argument counter for every subrange
|
||||
expression entered by the user.
|
||||
* valops.c (value_slice): Call value_slice_1 with
|
||||
additional default argument.
|
||||
* valops.c (value_slice_1): Add functionality to
|
||||
copy and return result values based on input.
|
||||
* value.h: Add function definition.
|
||||
|
||||
|
||||
Signed-off-by: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
---
|
||||
gdb/eval.c | 309 ++++++++++++++++++++++++++++++++++++++++++++++-------------
|
||||
gdb/f-exp.y | 2 +
|
||||
gdb/valops.c | 157 ++++++++++++++++++++++++------
|
||||
gdb/value.h | 2 +
|
||||
4 files changed, 375 insertions(+), 95 deletions(-)
|
||||
|
||||
diff --git a/gdb/eval.c b/gdb/eval.c
|
||||
index 78ad946..c9f325f 100644
|
||||
--- a/gdb/eval.c
|
||||
+++ b/gdb/eval.c
|
||||
@@ -399,29 +399,253 @@ init_array_element (struct value *array, struct value *element,
|
||||
return index;
|
||||
}
|
||||
|
||||
+/* Evaluates any operation on Fortran arrays or strings with at least
|
||||
+ one user provided parameter. Expects the input ARRAY to be either
|
||||
+ an array, or a string. Evaluates EXP by incrementing POS, and
|
||||
+ writes the content from the elt stack into a local struct. NARGS
|
||||
+ specifies number of literal or range arguments the user provided.
|
||||
+ NARGS must be the same number as ARRAY has dimensions. */
|
||||
+
|
||||
static struct value *
|
||||
-value_f90_subarray (struct value *array,
|
||||
- struct expression *exp, int *pos, enum noside noside)
|
||||
+value_f90_subarray (struct value *array, struct expression *exp,
|
||||
+ int *pos, int nargs, enum noside noside)
|
||||
{
|
||||
- int pc = (*pos) + 1;
|
||||
+ int i, dim_count = 0;
|
||||
LONGEST low_bound, high_bound;
|
||||
struct type *range = check_typedef (TYPE_INDEX_TYPE (value_type (array)));
|
||||
- enum f90_range_type range_type
|
||||
- = (enum f90_range_type) longest_to_int (exp->elts[pc].longconst);
|
||||
-
|
||||
- *pos += 3;
|
||||
+ struct value *new_array = array;
|
||||
+ struct type *array_type = check_typedef (value_type (new_array));
|
||||
+ struct type *temp_type;
|
||||
+
|
||||
+ /* Local struct to hold user data for Fortran subarray dimensions. */
|
||||
+ struct subscript_store
|
||||
+ {
|
||||
+ /* For every dimension, we are either working on a range or an index
|
||||
+ expression, so we store this info separately for later. */
|
||||
+ enum
|
||||
+ {
|
||||
+ SUBSCRIPT_RANGE, /* e.g. "(lowbound:highbound)" */
|
||||
+ SUBSCRIPT_INDEX /* e.g. "(literal)" */
|
||||
+ } kind;
|
||||
+
|
||||
+ /* We also store either the lower and upper bound info, or the index
|
||||
+ number. Before evaluation of the input values, we do not know if we are
|
||||
+ actually working on a range of ranges, or an index in a range. So as a
|
||||
+ first step we store all input in a union. The array calculation itself
|
||||
+ deals with this later on. */
|
||||
+ union
|
||||
+ {
|
||||
+ struct subscript_range
|
||||
+ {
|
||||
+ enum f90_range_type f90_range_type;
|
||||
+ LONGEST low, high;
|
||||
+ }
|
||||
+ range;
|
||||
+ LONGEST number;
|
||||
+ };
|
||||
+ } *subscript_array;
|
||||
+
|
||||
+ /* Check if the number of arguments provided by the user matches
|
||||
+ the number of dimension of the array. A string has only one
|
||||
+ dimension. */
|
||||
+ if (nargs != calc_f77_array_dims (value_type (new_array)))
|
||||
+ error (_("Wrong number of subscripts"));
|
||||
+
|
||||
+ subscript_array = alloca (sizeof (*subscript_array) * nargs);
|
||||
+
|
||||
+ /* Parse the user input into the SUBSCRIPT_ARRAY to store it. We need
|
||||
+ to evaluate it first, as the input is from left-to-right. The
|
||||
+ array is stored from right-to-left. So we have to use the user
|
||||
+ input in reverse order. Later on, we need the input information to
|
||||
+ re-calculate the output array. For multi-dimensional arrays, we
|
||||
+ can be dealing with any possible combination of ranges and indices
|
||||
+ for every dimension. */
|
||||
+ for (i = 0; i < nargs; i++)
|
||||
+ {
|
||||
+ struct subscript_store *index = &subscript_array[i];
|
||||
|
||||
- if (range_type == LOW_BOUND_DEFAULT || range_type == BOTH_BOUND_DEFAULT)
|
||||
- low_bound = TYPE_LOW_BOUND (range);
|
||||
- else
|
||||
- low_bound = value_as_long (evaluate_subexp (NULL_TYPE, exp, pos, noside));
|
||||
+ /* The user input is a range, with or without lower and upper bound.
|
||||
+ E.g.: "p arry(2:5)", "p arry( :5)", "p arry( : )", etc. */
|
||||
+ if (exp->elts[*pos].opcode == OP_F90_RANGE)
|
||||
+ {
|
||||
+ int pc = (*pos) + 1;
|
||||
+ struct subscript_range *range;
|
||||
+
|
||||
+ index->kind = SUBSCRIPT_RANGE;
|
||||
+ range = &index->range;
|
||||
+
|
||||
+ *pos += 3;
|
||||
+ range->f90_range_type = longest_to_int (exp->elts[pc].longconst);
|
||||
+
|
||||
+ /* If a lower bound was provided by the user, the bit has been
|
||||
+ set and we can assign the value from the elt stack. Same for
|
||||
+ upper bound. */
|
||||
+ if ((range->f90_range_type == HIGH_BOUND_DEFAULT)
|
||||
+ || range->f90_range_type == NONE_BOUND_DEFAULT)
|
||||
+ range->low = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
+ pos, noside));
|
||||
+ if ((range->f90_range_type == LOW_BOUND_DEFAULT)
|
||||
+ || range->f90_range_type == NONE_BOUND_DEFAULT)
|
||||
+ range->high = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
+ pos, noside));
|
||||
+ }
|
||||
+ /* User input is an index. E.g.: "p arry(5)". */
|
||||
+ else
|
||||
+ {
|
||||
+ struct value *val;
|
||||
|
||||
- if (range_type == HIGH_BOUND_DEFAULT || range_type == BOTH_BOUND_DEFAULT)
|
||||
- high_bound = TYPE_HIGH_BOUND (range);
|
||||
- else
|
||||
- high_bound = value_as_long (evaluate_subexp (NULL_TYPE, exp, pos, noside));
|
||||
+ index->kind = SUBSCRIPT_INDEX;
|
||||
+
|
||||
+ /* Evaluate each subscript; it must be a legal integer in F77. This
|
||||
+ ensures the validity of the provided index. */
|
||||
+ val = evaluate_subexp_with_coercion (exp, pos, noside);
|
||||
+ index->number = value_as_long (val);
|
||||
+ }
|
||||
+
|
||||
+ }
|
||||
+
|
||||
+ /* Traverse the array from right to left and evaluate each corresponding
|
||||
+ user input. VALUE_SUBSCRIPT is called for every index, until a range
|
||||
+ expression is evaluated. After a range expression has been evaluated,
|
||||
+ every subsequent expression is also treated as a range. */
|
||||
+ for (i = nargs - 1; i >= 0; i--)
|
||||
+ {
|
||||
+ struct subscript_store *index = &subscript_array[i];
|
||||
+ struct type *index_type = TYPE_INDEX_TYPE (array_type);
|
||||
+
|
||||
+ switch (index->kind)
|
||||
+ {
|
||||
+ case SUBSCRIPT_RANGE:
|
||||
+ {
|
||||
+
|
||||
+ /* When we hit the first range specified by the user, we must
|
||||
+ treat any subsequent user entry as a range. We simply
|
||||
+ increment DIM_COUNT which tells us how many times we are
|
||||
+ calling VALUE_SLICE_1. */
|
||||
+ struct subscript_range *range = &index->range;
|
||||
+
|
||||
+ /* If no lower bound was provided by the user, we take the
|
||||
+ default boundary. Same for the high bound. */
|
||||
+ if ((range->f90_range_type == LOW_BOUND_DEFAULT)
|
||||
+ || (range->f90_range_type == BOTH_BOUND_DEFAULT))
|
||||
+ range->low = TYPE_LOW_BOUND (index_type);
|
||||
+
|
||||
+ if ((range->f90_range_type == HIGH_BOUND_DEFAULT)
|
||||
+ || (range->f90_range_type == BOTH_BOUND_DEFAULT))
|
||||
+ range->high = TYPE_HIGH_BOUND (index_type);
|
||||
+
|
||||
+ /* Both user provided low and high bound have to be inside the
|
||||
+ array bounds. Throw an error if not. */
|
||||
+ if (range->low < TYPE_LOW_BOUND (index_type)
|
||||
+ || range->low > TYPE_HIGH_BOUND (index_type)
|
||||
+ || range->high < TYPE_LOW_BOUND (index_type)
|
||||
+ || range->high > TYPE_HIGH_BOUND (index_type))
|
||||
+ error (_("provided bound(s) outside array bound(s)"));
|
||||
+
|
||||
+ /* DIM_COUNT counts every user argument that is treated as a range.
|
||||
+ This is necessary for expressions like 'print array(7, 8:9).
|
||||
+ Here the first argument is a literal, but must be treated as a
|
||||
+ range argument to allow the correct output representation. */
|
||||
+ dim_count++;
|
||||
+
|
||||
+ new_array
|
||||
+ = value_slice_1 (new_array,
|
||||
+ longest_to_int (range->low),
|
||||
+ longest_to_int (range->high - range->low + 1),
|
||||
+ dim_count);
|
||||
+ }
|
||||
+ break;
|
||||
+
|
||||
+ case SUBSCRIPT_INDEX:
|
||||
+ {
|
||||
+ /* DIM_COUNT only stays '0' when no range argument was processed
|
||||
+ before, starting from the last dimension. This way we can
|
||||
+ reduce the number of dimensions from the result array.
|
||||
+ However, if a range has been processed before an index, we
|
||||
+ treat the index like a range with equal low- and high bounds
|
||||
+ to get the value offset right. */
|
||||
+ if (dim_count == 0)
|
||||
+ new_array
|
||||
+ = value_subscripted_rvalue (new_array, index->number,
|
||||
+ f77_get_lowerbound (value_type
|
||||
+ (new_array)));
|
||||
+ else
|
||||
+ {
|
||||
+ /* Check for valid index input. */
|
||||
+ if (index->number < TYPE_LOW_BOUND (index_type)
|
||||
+ || index->number > TYPE_HIGH_BOUND (index_type))
|
||||
+ error (_("error no such vector element"));
|
||||
+
|
||||
+ dim_count++;
|
||||
+ new_array = value_slice_1 (new_array,
|
||||
+ longest_to_int (index->number),
|
||||
+ 1, /* length is '1' element */
|
||||
+ dim_count);
|
||||
+ }
|
||||
+
|
||||
+ }
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ /* With DIM_COUNT > 1 we currently have a one dimensional array, but expect
|
||||
+ an array of arrays, depending on how many ranges have been provided by
|
||||
+ the user. So we need to rebuild the array dimensions for printing it
|
||||
+ correctly.
|
||||
+ Starting from right to left in the user input, after we hit the first
|
||||
+ range argument every subsequent argument is also treated as a range.
|
||||
+ E.g.:
|
||||
+ "p ary(3, 7, 2:15)" in Fortran has only 1 dimension, but we calculated 3
|
||||
+ ranges.
|
||||
+ "p ary(3, 7:12, 4)" in Fortran has only 1 dimension, but we calculated 2
|
||||
+ ranges.
|
||||
+ "p ary(2:4, 5, 7)" in Fortran has only 1 dimension, and we calculated 1
|
||||
+ range. */
|
||||
+ if (dim_count > 1)
|
||||
+ {
|
||||
+ struct value *v = NULL;
|
||||
|
||||
- return value_slice (array, low_bound, high_bound - low_bound + 1);
|
||||
+ temp_type = TYPE_TARGET_TYPE (value_type (new_array));
|
||||
+
|
||||
+ /* Every SUBSCRIPT_RANGE in the user input signifies an actual range in
|
||||
+ the output array. So we traverse the SUBSCRIPT_ARRAY again, looking
|
||||
+ for a range entry. When we find one, we use the range info to create
|
||||
+ an additional range_type to set the correct bounds and dimensions for
|
||||
+ the output array. */
|
||||
+ for (i = 0; i < nargs; i++)
|
||||
+ {
|
||||
+ struct subscript_store *index = &subscript_array[i];
|
||||
+
|
||||
+ if (index->kind == SUBSCRIPT_RANGE)
|
||||
+ {
|
||||
+ struct type *range_type, *interim_array_type;
|
||||
+
|
||||
+ range_type
|
||||
+ = create_static_range_type (NULL,
|
||||
+ temp_type,
|
||||
+ 1,
|
||||
+ index->range.high - index->range.low + 1);
|
||||
+
|
||||
+ interim_array_type = create_array_type (NULL,
|
||||
+ temp_type,
|
||||
+ range_type);
|
||||
+
|
||||
+ /* For some reason the type code of the contents is missing, so
|
||||
+ reset it from the original array. */
|
||||
+ TYPE_CODE (interim_array_type)
|
||||
+ = TYPE_CODE (value_type (new_array));
|
||||
+
|
||||
+ v = allocate_value (interim_array_type);
|
||||
+
|
||||
+ temp_type = value_type (v);
|
||||
+ }
|
||||
+
|
||||
+ }
|
||||
+ value_contents_copy (v, 0, new_array, 0, TYPE_LENGTH (temp_type));
|
||||
+ return v;
|
||||
+ }
|
||||
+
|
||||
+ return new_array;
|
||||
}
|
||||
|
||||
|
||||
@@ -1810,14 +2034,11 @@ evaluate_subexp_standard (struct type *expect_type,
|
||||
switch (code)
|
||||
{
|
||||
case TYPE_CODE_ARRAY:
|
||||
- if (exp->elts[*pos].opcode == OP_F90_RANGE)
|
||||
- return value_f90_subarray (arg1, exp, pos, noside);
|
||||
- else
|
||||
- goto multi_f77_subscript;
|
||||
+ return value_f90_subarray (arg1, exp, pos, nargs, noside);
|
||||
|
||||
case TYPE_CODE_STRING:
|
||||
if (exp->elts[*pos].opcode == OP_F90_RANGE)
|
||||
- return value_f90_subarray (arg1, exp, pos, noside);
|
||||
+ return value_f90_subarray (arg1, exp, pos, 1, noside);
|
||||
else
|
||||
{
|
||||
arg2 = evaluate_subexp_with_coercion (exp, pos, noside);
|
||||
@@ -2222,49 +2443,6 @@ evaluate_subexp_standard (struct type *expect_type,
|
||||
}
|
||||
return (arg1);
|
||||
|
||||
- multi_f77_subscript:
|
||||
- {
|
||||
- LONGEST subscript_array[MAX_FORTRAN_DIMS];
|
||||
- int ndimensions = 1, i;
|
||||
- struct value *array = arg1;
|
||||
-
|
||||
- if (nargs > MAX_FORTRAN_DIMS)
|
||||
- error (_("Too many subscripts for F77 (%d Max)"), MAX_FORTRAN_DIMS);
|
||||
-
|
||||
- ndimensions = calc_f77_array_dims (type);
|
||||
-
|
||||
- if (nargs != ndimensions)
|
||||
- error (_("Wrong number of subscripts"));
|
||||
-
|
||||
- gdb_assert (nargs > 0);
|
||||
-
|
||||
- /* Now that we know we have a legal array subscript expression
|
||||
- let us actually find out where this element exists in the array. */
|
||||
-
|
||||
- /* Take array indices left to right. */
|
||||
- for (i = 0; i < nargs; i++)
|
||||
- {
|
||||
- /* Evaluate each subscript; it must be a legal integer in F77. */
|
||||
- arg2 = evaluate_subexp_with_coercion (exp, pos, noside);
|
||||
-
|
||||
- /* Fill in the subscript array. */
|
||||
-
|
||||
- subscript_array[i] = value_as_long (arg2);
|
||||
- }
|
||||
-
|
||||
- /* Internal type of array is arranged right to left. */
|
||||
- for (i = nargs; i > 0; i--)
|
||||
- {
|
||||
- struct type *array_type = check_typedef (value_type (array));
|
||||
- LONGEST index = subscript_array[i - 1];
|
||||
-
|
||||
- array = value_subscripted_rvalue (array, index,
|
||||
- f77_get_lowerbound (array_type));
|
||||
- }
|
||||
-
|
||||
- return array;
|
||||
- }
|
||||
-
|
||||
case BINOP_LOGICAL_AND:
|
||||
arg1 = evaluate_subexp (NULL_TYPE, exp, pos, noside);
|
||||
if (noside == EVAL_SKIP)
|
||||
@@ -3121,6 +3299,9 @@ calc_f77_array_dims (struct type *array_type)
|
||||
int ndimen = 1;
|
||||
struct type *tmp_type;
|
||||
|
||||
+ if (TYPE_CODE (array_type) == TYPE_CODE_STRING)
|
||||
+ return 1;
|
||||
+
|
||||
if ((TYPE_CODE (array_type) != TYPE_CODE_ARRAY))
|
||||
error (_("Can't get dimensions for a non-array type"));
|
||||
|
||||
diff --git a/gdb/f-exp.y b/gdb/f-exp.y
|
||||
index 4faac32..9343abb 100644
|
||||
--- a/gdb/f-exp.y
|
||||
+++ b/gdb/f-exp.y
|
||||
@@ -308,6 +308,8 @@ arglist : subrange
|
||||
|
||||
arglist : arglist ',' exp %prec ABOVE_COMMA
|
||||
{ arglist_len++; }
|
||||
+ | arglist ',' subrange %prec ABOVE_COMMA
|
||||
+ { arglist_len++; }
|
||||
;
|
||||
|
||||
/* There are four sorts of subrange types in F90. */
|
||||
diff --git a/gdb/valops.c b/gdb/valops.c
|
||||
index 5a244a9..09ea877 100644
|
||||
--- a/gdb/valops.c
|
||||
+++ b/gdb/valops.c
|
||||
@@ -3759,56 +3759,151 @@ value_of_this_silent (const struct language_defn *lang)
|
||||
struct value *
|
||||
value_slice (struct value *array, int lowbound, int length)
|
||||
{
|
||||
+ /* Pass unaltered arguments to VALUE_SLICE_1, plus a CALL_COUNT of '1' as we
|
||||
+ are only considering the highest dimension, or we are working on a one
|
||||
+ dimensional array. So we call VALUE_SLICE_1 exactly once. */
|
||||
+ return value_slice_1 (array, lowbound, length, 1);
|
||||
+}
|
||||
+
|
||||
+/* CALL_COUNT is used to determine if we are calling the function once, e.g.
|
||||
+ we are working on the current dimension of ARRAY, or if we are calling
|
||||
+ the function repeatedly. In the later case we need to take elements
|
||||
+ from the TARGET_TYPE of ARRAY.
|
||||
+ With a CALL_COUNT greater than 1 we calculate the offsets for every element
|
||||
+ that should be in the result array. Then we fetch the contents and then
|
||||
+ copy them into the result array. The result array will have one dimension
|
||||
+ less than the input array, so later on we need to recreate the indices and
|
||||
+ ranges in the calling function. */
|
||||
+
|
||||
+struct value *
|
||||
+value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
+{
|
||||
struct type *slice_range_type, *slice_type, *range_type;
|
||||
- LONGEST lowerbound, upperbound;
|
||||
- struct value *slice;
|
||||
- struct type *array_type;
|
||||
+ struct type *array_type = check_typedef (value_type (array));
|
||||
+ struct type *elt_type = check_typedef (TYPE_TARGET_TYPE (array_type));
|
||||
+ unsigned int elt_size, elt_offs;
|
||||
+ LONGEST elt_stride, ary_high_bound, ary_low_bound;
|
||||
+ struct value *v;
|
||||
+ int slice_range_size, i = 0, row_count = 1, elem_count = 1;
|
||||
|
||||
- array_type = check_typedef (value_type (array));
|
||||
+ /* Check for legacy code if we are actually dealing with an array or
|
||||
+ string. */
|
||||
if (TYPE_CODE (array_type) != TYPE_CODE_ARRAY
|
||||
&& TYPE_CODE (array_type) != TYPE_CODE_STRING)
|
||||
error (_("cannot take slice of non-array"));
|
||||
|
||||
- range_type = TYPE_INDEX_TYPE (array_type);
|
||||
- if (get_discrete_bounds (range_type, &lowerbound, &upperbound) < 0)
|
||||
- error (_("slice from bad array or bitstring"));
|
||||
+ ary_low_bound = TYPE_LOW_BOUND (TYPE_INDEX_TYPE (array_type));
|
||||
+ ary_high_bound = TYPE_HIGH_BOUND (TYPE_INDEX_TYPE (array_type));
|
||||
+
|
||||
+ /* When we are working on a multi-dimensional array, we need to get the
|
||||
+ attributes of the underlying type. */
|
||||
+ if (call_count > 1)
|
||||
+ {
|
||||
+ elt_type = check_typedef (TYPE_TARGET_TYPE (elt_type));
|
||||
+ row_count = TYPE_LENGTH (array_type)
|
||||
+ / TYPE_LENGTH (TYPE_TARGET_TYPE (array_type));
|
||||
+ }
|
||||
+
|
||||
+ elem_count = length;
|
||||
+ elt_size = TYPE_LENGTH (elt_type);
|
||||
+ elt_offs = longest_to_int (lowbound - ary_low_bound);
|
||||
+ elt_stride = TYPE_LENGTH (TYPE_INDEX_TYPE (array_type));
|
||||
+
|
||||
+ elt_offs *= elt_size;
|
||||
+
|
||||
+ /* Check for valid user input. In case of Fortran this was already done
|
||||
+ in the calling function. */
|
||||
+ if (call_count == 1
|
||||
+ && (!TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)
|
||||
+ && elt_offs >= TYPE_LENGTH (array_type)))
|
||||
+ error (_("no such vector element"));
|
||||
|
||||
- if (lowbound < lowerbound || length < 0
|
||||
- || lowbound + length - 1 > upperbound)
|
||||
- error (_("slice out of range"));
|
||||
+ /* CALL_COUNT is 1 when we are dealing either with the highest dimension
|
||||
+ of the array, or a one dimensional array. Set RANGE_TYPE accordingly.
|
||||
+ In both cases we calculate how many rows/elements will be in the output
|
||||
+ array by setting slice_range_size. */
|
||||
+ if (call_count == 1)
|
||||
+ {
|
||||
+ range_type = TYPE_INDEX_TYPE (array_type);
|
||||
+ slice_range_size = elem_count;
|
||||
+
|
||||
+ /* Check if the array bounds are valid. */
|
||||
+ if (get_discrete_bounds (range_type, &ary_low_bound, &ary_high_bound) < 0)
|
||||
+ error (_("slice from bad array or bitstring"));
|
||||
+ }
|
||||
+ /* When CALL_COUNT is greater than 1, we are dealing with an array of arrays.
|
||||
+ So we need to get the type below the current one and set the RANGE_TYPE
|
||||
+ accordingly. */
|
||||
+ else
|
||||
+ {
|
||||
+ range_type = TYPE_INDEX_TYPE (TYPE_TARGET_TYPE (array_type));
|
||||
+ slice_range_size = (ary_low_bound + row_count - 1) * (elem_count);
|
||||
+ ary_low_bound = TYPE_LOW_BOUND (range_type);
|
||||
+ }
|
||||
|
||||
/* FIXME-type-allocation: need a way to free this type when we are
|
||||
- done with it. */
|
||||
- slice_range_type = create_static_range_type ((struct type *) NULL,
|
||||
- TYPE_TARGET_TYPE (range_type),
|
||||
- lowbound,
|
||||
- lowbound + length - 1);
|
||||
+ done with it. */
|
||||
|
||||
+ slice_range_type = create_static_range_type (NULL, TYPE_TARGET_TYPE (range_type),
|
||||
+ ary_low_bound, slice_range_size);
|
||||
{
|
||||
- struct type *element_type = TYPE_TARGET_TYPE (array_type);
|
||||
- LONGEST offset
|
||||
- = (lowbound - lowerbound) * TYPE_LENGTH (check_typedef (element_type));
|
||||
+ struct type *element_type;
|
||||
+
|
||||
+ /* When CALL_COUNT equals 1 we can use the legacy code for subarrays. */
|
||||
+ if (call_count == 1)
|
||||
+ {
|
||||
+ element_type = TYPE_TARGET_TYPE (array_type);
|
||||
|
||||
- slice_type = create_array_type ((struct type *) NULL,
|
||||
- element_type,
|
||||
- slice_range_type);
|
||||
- TYPE_CODE (slice_type) = TYPE_CODE (array_type);
|
||||
+ slice_type = create_array_type (NULL, element_type, slice_range_type);
|
||||
+
|
||||
+ TYPE_CODE (slice_type) = TYPE_CODE (array_type);
|
||||
+
|
||||
+ if (VALUE_LVAL (array) == lval_memory && value_lazy (array))
|
||||
+ v = allocate_value_lazy (slice_type);
|
||||
+ else
|
||||
+ {
|
||||
+ v = allocate_value (slice_type);
|
||||
+ value_contents_copy (v,
|
||||
+ value_embedded_offset (v),
|
||||
+ array,
|
||||
+ value_embedded_offset (array) + elt_offs,
|
||||
+ elt_size * longest_to_int (length));
|
||||
+ }
|
||||
|
||||
- if (VALUE_LVAL (array) == lval_memory && value_lazy (array))
|
||||
- slice = allocate_value_lazy (slice_type);
|
||||
+ }
|
||||
+ /* When CALL_COUNT is larger than 1 we are working on a range of ranges.
|
||||
+ So we copy the relevant elements into the new array we return. */
|
||||
else
|
||||
{
|
||||
- slice = allocate_value (slice_type);
|
||||
- value_contents_copy (slice, 0, array, offset,
|
||||
- type_length_units (slice_type));
|
||||
+ LONGEST dst_offset = 0;
|
||||
+ LONGEST src_row_length = TYPE_LENGTH (TYPE_TARGET_TYPE (array_type));
|
||||
+
|
||||
+ element_type = TYPE_TARGET_TYPE (TYPE_TARGET_TYPE (array_type));
|
||||
+ slice_type = create_array_type (NULL, element_type, slice_range_type);
|
||||
+
|
||||
+ TYPE_CODE (slice_type) = TYPE_CODE (TYPE_TARGET_TYPE (array_type));
|
||||
+
|
||||
+ v = allocate_value (slice_type);
|
||||
+ for (i = 0; i < longest_to_int (row_count); i++)
|
||||
+ {
|
||||
+ /* Fetches the contents of ARRAY and copies them into V. */
|
||||
+ value_contents_copy (v,
|
||||
+ dst_offset,
|
||||
+ array,
|
||||
+ elt_offs,
|
||||
+ elt_size * elem_count);
|
||||
+ elt_offs += src_row_length;
|
||||
+ dst_offset += elt_size * elem_count;
|
||||
+ }
|
||||
}
|
||||
|
||||
- set_value_component_location (slice, array);
|
||||
- VALUE_FRAME_ID (slice) = VALUE_FRAME_ID (array);
|
||||
- set_value_offset (slice, value_offset (array) + offset);
|
||||
+ set_value_component_location (v, array);
|
||||
+ VALUE_REGNUM (v) = VALUE_REGNUM (array);
|
||||
+ VALUE_FRAME_ID (v) = VALUE_FRAME_ID (array);
|
||||
+ set_value_offset (v, value_offset (array) + elt_offs);
|
||||
}
|
||||
|
||||
- return slice;
|
||||
+ return v;
|
||||
}
|
||||
|
||||
/* Create a value for a FORTRAN complex number. Currently most of the
|
||||
diff --git a/gdb/value.h b/gdb/value.h
|
||||
index 2eac5ef..3400460 100644
|
||||
--- a/gdb/value.h
|
||||
+++ b/gdb/value.h
|
||||
@@ -1056,6 +1056,8 @@ extern struct value *varying_to_slice (struct value *);
|
||||
|
||||
extern struct value *value_slice (struct value *, int, int);
|
||||
|
||||
+extern struct value *value_slice_1 (struct value *, int, int, int);
|
||||
+
|
||||
extern struct value *value_literal_complex (struct value *, struct value *,
|
||||
struct type *);
|
||||
|
||||
--
|
||||
2.5.0
|
||||
|
45
gdb-fortran-stride-intel-2of6.patch
Normal file
45
gdb-fortran-stride-intel-2of6.patch
Normal file
@ -0,0 +1,45 @@
|
||||
http://sourceware.org/ml/gdb-patches/2016-02/msg00841.html
|
||||
Subject: [PATCH v2 2/6] fortran: combine subarray and string computation
|
||||
|
||||
From: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
Strings only have one dimension, but the element computation is
|
||||
identical to the subarray computation for ranges and indices.
|
||||
|
||||
2013-11-26 Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
* eval.c (evaluate_subexp_standard): Call
|
||||
value_f90_subarray for print expressions on array and
|
||||
string types.
|
||||
|
||||
|
||||
Signed-off-by: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
---
|
||||
gdb/eval.c | 10 +---------
|
||||
1 file changed, 1 insertion(+), 9 deletions(-)
|
||||
|
||||
diff --git a/gdb/eval.c b/gdb/eval.c
|
||||
index c9f325f..164d7ab 100644
|
||||
--- a/gdb/eval.c
|
||||
+++ b/gdb/eval.c
|
||||
@@ -2034,16 +2034,8 @@ evaluate_subexp_standard (struct type *expect_type,
|
||||
switch (code)
|
||||
{
|
||||
case TYPE_CODE_ARRAY:
|
||||
- return value_f90_subarray (arg1, exp, pos, nargs, noside);
|
||||
-
|
||||
case TYPE_CODE_STRING:
|
||||
- if (exp->elts[*pos].opcode == OP_F90_RANGE)
|
||||
- return value_f90_subarray (arg1, exp, pos, 1, noside);
|
||||
- else
|
||||
- {
|
||||
- arg2 = evaluate_subexp_with_coercion (exp, pos, noside);
|
||||
- return value_subscript (arg1, value_as_long (arg2));
|
||||
- }
|
||||
+ return value_f90_subarray (arg1, exp, pos, nargs, noside);
|
||||
|
||||
case TYPE_CODE_PTR:
|
||||
case TYPE_CODE_FUNC:
|
||||
--
|
||||
2.5.0
|
||||
|
162
gdb-fortran-stride-intel-3of6.patch
Normal file
162
gdb-fortran-stride-intel-3of6.patch
Normal file
@ -0,0 +1,162 @@
|
||||
http://sourceware.org/ml/gdb-patches/2016-02/msg00845.html
|
||||
Subject: [PATCH v2 3/6] fortran: change subrange enum to bit field
|
||||
|
||||
From: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
Change Fortran subrange enum for subrange expressions to
|
||||
represent a bitfield for easier manipulation. Consequently
|
||||
also change occurences and evaluation of said enum. The
|
||||
behaviour of GDB is unchanged.
|
||||
|
||||
2013-11-27 Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
* eval.c (value_f90_subarray): Change evaluation of the
|
||||
subarray boundaries. Set boundaries to be either user
|
||||
provided (bit in f90_range_type was set) or take the
|
||||
default value if the boundary was not provided by the user.
|
||||
* f-exp.y (subrange): Change rules for subrange expressions
|
||||
to write the relevant bit sequence onto the elt stack.
|
||||
* f-lang.h (f90_range_type): Change the enum to use bit
|
||||
values for each boundary, if set by the user.
|
||||
* parse.c (operator_length_standard): In case of
|
||||
OP_F90_RANGE change the calculation of the number of
|
||||
arguments on the elt stack, depending on the number of
|
||||
boundaries provided by the user.
|
||||
|
||||
|
||||
Signed-off-by: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
---
|
||||
gdb/eval.c | 14 ++++++--------
|
||||
gdb/f-exp.y | 11 ++++++-----
|
||||
gdb/f-lang.h | 6 ++----
|
||||
gdb/parse.c | 21 ++++++++-------------
|
||||
4 files changed, 22 insertions(+), 30 deletions(-)
|
||||
|
||||
diff --git a/gdb/eval.c b/gdb/eval.c
|
||||
index 164d7ab..9b8b051 100644
|
||||
--- a/gdb/eval.c
|
||||
+++ b/gdb/eval.c
|
||||
@@ -480,12 +480,12 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
/* If a lower bound was provided by the user, the bit has been
|
||||
set and we can assign the value from the elt stack. Same for
|
||||
upper bound. */
|
||||
- if ((range->f90_range_type == HIGH_BOUND_DEFAULT)
|
||||
- || range->f90_range_type == NONE_BOUND_DEFAULT)
|
||||
+ if ((range->f90_range_type & SUBARRAY_LOW_BOUND)
|
||||
+ == SUBARRAY_LOW_BOUND)
|
||||
range->low = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
pos, noside));
|
||||
- if ((range->f90_range_type == LOW_BOUND_DEFAULT)
|
||||
- || range->f90_range_type == NONE_BOUND_DEFAULT)
|
||||
+ if ((range->f90_range_type & SUBARRAY_HIGH_BOUND)
|
||||
+ == SUBARRAY_HIGH_BOUND)
|
||||
range->high = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
pos, noside));
|
||||
}
|
||||
@@ -526,12 +526,10 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
|
||||
/* If no lower bound was provided by the user, we take the
|
||||
default boundary. Same for the high bound. */
|
||||
- if ((range->f90_range_type == LOW_BOUND_DEFAULT)
|
||||
- || (range->f90_range_type == BOTH_BOUND_DEFAULT))
|
||||
+ if ((range->f90_range_type & SUBARRAY_LOW_BOUND) == 0)
|
||||
range->low = TYPE_LOW_BOUND (index_type);
|
||||
|
||||
- if ((range->f90_range_type == HIGH_BOUND_DEFAULT)
|
||||
- || (range->f90_range_type == BOTH_BOUND_DEFAULT))
|
||||
+ if ((range->f90_range_type & SUBARRAY_HIGH_BOUND) == 0)
|
||||
range->high = TYPE_HIGH_BOUND (index_type);
|
||||
|
||||
/* Both user provided low and high bound have to be inside the
|
||||
diff --git a/gdb/f-exp.y b/gdb/f-exp.y
|
||||
index 9343abb..b1206de 100644
|
||||
--- a/gdb/f-exp.y
|
||||
+++ b/gdb/f-exp.y
|
||||
@@ -315,26 +315,27 @@ arglist : arglist ',' exp %prec ABOVE_COMMA
|
||||
/* There are four sorts of subrange types in F90. */
|
||||
|
||||
subrange: exp ':' exp %prec ABOVE_COMMA
|
||||
- { write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
- write_exp_elt_longcst (pstate, NONE_BOUND_DEFAULT);
|
||||
+ { write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
+ write_exp_elt_longcst (pstate,
|
||||
+ SUBARRAY_LOW_BOUND | SUBARRAY_HIGH_BOUND);
|
||||
write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
;
|
||||
|
||||
subrange: exp ':' %prec ABOVE_COMMA
|
||||
{ write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
- write_exp_elt_longcst (pstate, HIGH_BOUND_DEFAULT);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_LOW_BOUND);
|
||||
write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
;
|
||||
|
||||
subrange: ':' exp %prec ABOVE_COMMA
|
||||
{ write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
- write_exp_elt_longcst (pstate, LOW_BOUND_DEFAULT);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_HIGH_BOUND);
|
||||
write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
;
|
||||
|
||||
subrange: ':' %prec ABOVE_COMMA
|
||||
{ write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
- write_exp_elt_longcst (pstate, BOTH_BOUND_DEFAULT);
|
||||
+ write_exp_elt_longcst (pstate, 0);
|
||||
write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
;
|
||||
|
||||
diff --git a/gdb/f-lang.h b/gdb/f-lang.h
|
||||
index eeca107..4d56bf7 100644
|
||||
--- a/gdb/f-lang.h
|
||||
+++ b/gdb/f-lang.h
|
||||
@@ -44,10 +44,8 @@ extern void f_val_print (struct type *, const gdb_byte *, int, CORE_ADDR,
|
||||
|
||||
enum f90_range_type
|
||||
{
|
||||
- BOTH_BOUND_DEFAULT, /* "(:)" */
|
||||
- LOW_BOUND_DEFAULT, /* "(:high)" */
|
||||
- HIGH_BOUND_DEFAULT, /* "(low:)" */
|
||||
- NONE_BOUND_DEFAULT /* "(low:high)" */
|
||||
+ SUBARRAY_LOW_BOUND = 0x1, /* "(low:)" */
|
||||
+ SUBARRAY_HIGH_BOUND = 0x2 /* "(:high)" */
|
||||
};
|
||||
|
||||
/* A common block. */
|
||||
diff --git a/gdb/parse.c b/gdb/parse.c
|
||||
index 4191fc6..d500279 100644
|
||||
--- a/gdb/parse.c
|
||||
+++ b/gdb/parse.c
|
||||
@@ -1006,22 +1006,17 @@ operator_length_standard (const struct expression *expr, int endpos,
|
||||
|
||||
case OP_F90_RANGE:
|
||||
oplen = 3;
|
||||
+ args = 0;
|
||||
range_type = (enum f90_range_type)
|
||||
longest_to_int (expr->elts[endpos - 2].longconst);
|
||||
|
||||
- switch (range_type)
|
||||
- {
|
||||
- case LOW_BOUND_DEFAULT:
|
||||
- case HIGH_BOUND_DEFAULT:
|
||||
- args = 1;
|
||||
- break;
|
||||
- case BOTH_BOUND_DEFAULT:
|
||||
- args = 0;
|
||||
- break;
|
||||
- case NONE_BOUND_DEFAULT:
|
||||
- args = 2;
|
||||
- break;
|
||||
- }
|
||||
+ /* Increment the argument counter for each argument
|
||||
+ provided by the user. */
|
||||
+ if ((range_type & SUBARRAY_LOW_BOUND) == SUBARRAY_LOW_BOUND)
|
||||
+ args++;
|
||||
+
|
||||
+ if ((range_type & SUBARRAY_HIGH_BOUND) == SUBARRAY_HIGH_BOUND)
|
||||
+ args++;
|
||||
|
||||
break;
|
||||
|
||||
--
|
||||
2.5.0
|
||||
|
142
gdb-fortran-stride-intel-4of6.patch
Normal file
142
gdb-fortran-stride-intel-4of6.patch
Normal file
@ -0,0 +1,142 @@
|
||||
http://sourceware.org/ml/gdb-patches/2016-02/msg00842.html
|
||||
Subject: [PATCH v2 4/6] fortran: enable parsing of stride parameter for subranges
|
||||
|
||||
From: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
Allow the user to provide a stride parameter for Fortran
|
||||
subarrays. The stride parameter can be any integer except
|
||||
'0'. The default stride value is '1'.
|
||||
|
||||
2013-11-27 Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
* eval.c (value_f90_subarray): Add expression evaluation
|
||||
for a stride parameter in a Fortran range expression.
|
||||
* f-exp.y: Add yacc rules for writing info on the elt stack
|
||||
when the user provided a stride argument.
|
||||
* f-lang.h (F90_RANGE): Add field to enum to show when a
|
||||
stride was provided by the user.
|
||||
* parse.c (operator_length_standard): Check if a stride
|
||||
value was provided, and increment argument counter
|
||||
accordingly.
|
||||
|
||||
|
||||
Signed-off-by: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
---
|
||||
gdb/eval.c | 10 +++++++++-
|
||||
gdb/f-exp.y | 33 +++++++++++++++++++++++++++++++--
|
||||
gdb/f-lang.h | 5 +++--
|
||||
gdb/parse.c | 3 +++
|
||||
4 files changed, 46 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/gdb/eval.c b/gdb/eval.c
|
||||
index 9b8b051..308ada3 100644
|
||||
--- a/gdb/eval.c
|
||||
+++ b/gdb/eval.c
|
||||
@@ -438,7 +438,7 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
struct subscript_range
|
||||
{
|
||||
enum f90_range_type f90_range_type;
|
||||
- LONGEST low, high;
|
||||
+ LONGEST low, high, stride;
|
||||
}
|
||||
range;
|
||||
LONGEST number;
|
||||
@@ -488,6 +488,14 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
== SUBARRAY_HIGH_BOUND)
|
||||
range->high = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
pos, noside));
|
||||
+
|
||||
+ /* Assign the user's stride value if provided. */
|
||||
+ if ((range->f90_range_type & SUBARRAY_STRIDE) == SUBARRAY_STRIDE)
|
||||
+ range->stride = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
+ pos, noside));
|
||||
+ /* Assign the default stride value '1'. */
|
||||
+ else
|
||||
+ range->stride = 1;
|
||||
}
|
||||
/* User input is an index. E.g.: "p arry(5)". */
|
||||
else
|
||||
diff --git a/gdb/f-exp.y b/gdb/f-exp.y
|
||||
index b1206de..5151fee 100644
|
||||
--- a/gdb/f-exp.y
|
||||
+++ b/gdb/f-exp.y
|
||||
@@ -316,8 +316,8 @@ arglist : arglist ',' exp %prec ABOVE_COMMA
|
||||
|
||||
subrange: exp ':' exp %prec ABOVE_COMMA
|
||||
{ write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
- write_exp_elt_longcst (pstate,
|
||||
- SUBARRAY_LOW_BOUND | SUBARRAY_HIGH_BOUND);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_LOW_BOUND
|
||||
+ | SUBARRAY_HIGH_BOUND);
|
||||
write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
;
|
||||
|
||||
@@ -339,6 +339,35 @@ subrange: ':' %prec ABOVE_COMMA
|
||||
write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
;
|
||||
|
||||
+/* Each subrange type can have a stride argument. */
|
||||
+subrange: exp ':' exp ':' exp %prec ABOVE_COMMA
|
||||
+ { write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_LOW_BOUND
|
||||
+ | SUBARRAY_HIGH_BOUND
|
||||
+ | SUBARRAY_STRIDE);
|
||||
+ write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
+ ;
|
||||
+
|
||||
+subrange: exp ':' ':' exp %prec ABOVE_COMMA
|
||||
+ { write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_LOW_BOUND
|
||||
+ | SUBARRAY_STRIDE);
|
||||
+ write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
+ ;
|
||||
+
|
||||
+subrange: ':' exp ':' exp %prec ABOVE_COMMA
|
||||
+ { write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_HIGH_BOUND
|
||||
+ | SUBARRAY_STRIDE);
|
||||
+ write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
+ ;
|
||||
+
|
||||
+subrange: ':' ':' exp %prec ABOVE_COMMA
|
||||
+ { write_exp_elt_opcode (pstate, OP_F90_RANGE);
|
||||
+ write_exp_elt_longcst (pstate, SUBARRAY_STRIDE);
|
||||
+ write_exp_elt_opcode (pstate, OP_F90_RANGE); }
|
||||
+ ;
|
||||
+
|
||||
complexnum: exp ',' exp
|
||||
{ }
|
||||
;
|
||||
diff --git a/gdb/f-lang.h b/gdb/f-lang.h
|
||||
index 4d56bf7..0ad57af 100644
|
||||
--- a/gdb/f-lang.h
|
||||
+++ b/gdb/f-lang.h
|
||||
@@ -44,8 +44,9 @@ extern void f_val_print (struct type *, const gdb_byte *, int, CORE_ADDR,
|
||||
|
||||
enum f90_range_type
|
||||
{
|
||||
- SUBARRAY_LOW_BOUND = 0x1, /* "(low:)" */
|
||||
- SUBARRAY_HIGH_BOUND = 0x2 /* "(:high)" */
|
||||
+ SUBARRAY_LOW_BOUND = 0x1, /* "(low:)" or "(low::)" */
|
||||
+ SUBARRAY_HIGH_BOUND = 0x2, /* "(:high)" or "(:high:)" */
|
||||
+ SUBARRAY_STRIDE = 0x4 /* "(::stride)" */
|
||||
};
|
||||
|
||||
/* A common block. */
|
||||
diff --git a/gdb/parse.c b/gdb/parse.c
|
||||
index d500279..07248c3 100644
|
||||
--- a/gdb/parse.c
|
||||
+++ b/gdb/parse.c
|
||||
@@ -1018,6 +1018,9 @@ operator_length_standard (const struct expression *expr, int endpos,
|
||||
if ((range_type & SUBARRAY_HIGH_BOUND) == SUBARRAY_HIGH_BOUND)
|
||||
args++;
|
||||
|
||||
+ if ((range_type & SUBARRAY_STRIDE) == SUBARRAY_STRIDE)
|
||||
+ args++;
|
||||
+
|
||||
break;
|
||||
|
||||
default:
|
||||
--
|
||||
2.5.0
|
||||
|
412
gdb-fortran-stride-intel-5of6.patch
Normal file
412
gdb-fortran-stride-intel-5of6.patch
Normal file
@ -0,0 +1,412 @@
|
||||
http://sourceware.org/ml/gdb-patches/2016-02/msg00844.html
|
||||
Subject: [PATCH v2 5/6] fortran: calculate subarray with stride values.
|
||||
|
||||
From: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
Calculate elements of a subarray using a provided stride value
|
||||
The stride value can be a positive or negative integer, but may
|
||||
not be zero. If no stride is provided, use the default value
|
||||
1 to print all elements inside the range.
|
||||
|
||||
1| program prog
|
||||
2| integer :: ary(10) = (/ (i, i=1, 10) /)
|
||||
3| end program prog
|
||||
|
||||
(gdb) print ary(1:10:2)
|
||||
$3 = (1, 3, 5, 7, 9)
|
||||
|
||||
2013-11-27 Christoph Weinmann <christoph.t.weinmann>
|
||||
|
||||
* eval.c (value_f90_subarray): Add range size calculation
|
||||
for stride based ranges, and evaluation of user stride
|
||||
parameters. Add check for matching user input to array
|
||||
bounds.
|
||||
* valops.c (value_slice): Add call parameter with default
|
||||
stride value for calling value_slice_1.
|
||||
* valops.c (value_slice_1): Add function parameter for
|
||||
stride length in the return subarray. Calculate array
|
||||
elements based on stride value.
|
||||
* value.h: Add stride parameter to declaration of
|
||||
value_slice_1.
|
||||
|
||||
|
||||
Signed-off-by: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
---
|
||||
gdb/eval.c | 111 ++++++++++++++++++++++++++++++++++++++++++++++-------------
|
||||
gdb/valops.c | 87 +++++++++++++++++++++++++++++++++-------------
|
||||
gdb/value.h | 2 +-
|
||||
3 files changed, 152 insertions(+), 48 deletions(-)
|
||||
|
||||
diff --git a/gdb/eval.c b/gdb/eval.c
|
||||
index 308ada3..d01b579 100644
|
||||
--- a/gdb/eval.c
|
||||
+++ b/gdb/eval.c
|
||||
@@ -437,8 +437,8 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
{
|
||||
struct subscript_range
|
||||
{
|
||||
- enum f90_range_type f90_range_type;
|
||||
- LONGEST low, high, stride;
|
||||
+ enum f90_range_type f90_range_type;
|
||||
+ LONGEST low, high, stride;
|
||||
}
|
||||
range;
|
||||
LONGEST number;
|
||||
@@ -475,7 +475,7 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
range = &index->range;
|
||||
|
||||
*pos += 3;
|
||||
- range->f90_range_type = longest_to_int (exp->elts[pc].longconst);
|
||||
+ range->f90_range_type = exp->elts[pc].longconst;
|
||||
|
||||
/* If a lower bound was provided by the user, the bit has been
|
||||
set and we can assign the value from the elt stack. Same for
|
||||
@@ -484,6 +484,7 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
== SUBARRAY_LOW_BOUND)
|
||||
range->low = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
pos, noside));
|
||||
+
|
||||
if ((range->f90_range_type & SUBARRAY_HIGH_BOUND)
|
||||
== SUBARRAY_HIGH_BOUND)
|
||||
range->high = value_as_long (evaluate_subexp (NULL_TYPE, exp,
|
||||
@@ -496,6 +497,10 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
/* Assign the default stride value '1'. */
|
||||
else
|
||||
range->stride = 1;
|
||||
+
|
||||
+ /* Check the provided stride value is illegal, aka '0'. */
|
||||
+ if (range->stride == 0)
|
||||
+ error (_("Stride must not be 0"));
|
||||
}
|
||||
/* User input is an index. E.g.: "p arry(5)". */
|
||||
else
|
||||
@@ -512,10 +517,8 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
|
||||
}
|
||||
|
||||
- /* Traverse the array from right to left and evaluate each corresponding
|
||||
- user input. VALUE_SUBSCRIPT is called for every index, until a range
|
||||
- expression is evaluated. After a range expression has been evaluated,
|
||||
- every subsequent expression is also treated as a range. */
|
||||
+ /* Traverse the array from right to left and set the high and low bounds
|
||||
+ for later use. */
|
||||
for (i = nargs - 1; i >= 0; i--)
|
||||
{
|
||||
struct subscript_store *index = &subscript_array[i];
|
||||
@@ -548,6 +551,48 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
|| range->high > TYPE_HIGH_BOUND (index_type))
|
||||
error (_("provided bound(s) outside array bound(s)"));
|
||||
|
||||
+ /* For a negative stride the lower boundary must be larger than the
|
||||
+ upper boundary.
|
||||
+ For a positive stride the lower boundary must be smaller than the
|
||||
+ upper boundary. */
|
||||
+ if ((range->stride < 0 && range->low < range->high)
|
||||
+ || (range->stride > 0 && range->low > range->high))
|
||||
+ error (_("Wrong value provided for stride and boundaries"));
|
||||
+
|
||||
+ }
|
||||
+ break;
|
||||
+
|
||||
+ case SUBSCRIPT_INDEX:
|
||||
+ break;
|
||||
+
|
||||
+ }
|
||||
+
|
||||
+ array_type = TYPE_TARGET_TYPE (array_type);
|
||||
+ }
|
||||
+
|
||||
+ /* Reset ARRAY_TYPE before slicing.*/
|
||||
+ array_type = check_typedef (value_type (new_array));
|
||||
+
|
||||
+ /* Traverse the array from right to left and evaluate each corresponding
|
||||
+ user input. VALUE_SUBSCRIPT is called for every index, until a range
|
||||
+ expression is evaluated. After a range expression has been evaluated,
|
||||
+ every subsequent expression is also treated as a range. */
|
||||
+ for (i = nargs - 1; i >= 0; i--)
|
||||
+ {
|
||||
+ struct subscript_store *index = &subscript_array[i];
|
||||
+ struct type *index_type = TYPE_INDEX_TYPE (array_type);
|
||||
+
|
||||
+ switch (index->kind)
|
||||
+ {
|
||||
+ case SUBSCRIPT_RANGE:
|
||||
+ {
|
||||
+
|
||||
+ /* When we hit the first range specified by the user, we must
|
||||
+ treat any subsequent user entry as a range. We simply
|
||||
+ increment DIM_COUNT which tells us how many times we are
|
||||
+ calling VALUE_SLICE_1. */
|
||||
+ struct subscript_range *range = &index->range;
|
||||
+
|
||||
/* DIM_COUNT counts every user argument that is treated as a range.
|
||||
This is necessary for expressions like 'print array(7, 8:9).
|
||||
Here the first argument is a literal, but must be treated as a
|
||||
@@ -555,10 +600,9 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
dim_count++;
|
||||
|
||||
new_array
|
||||
- = value_slice_1 (new_array,
|
||||
- longest_to_int (range->low),
|
||||
- longest_to_int (range->high - range->low + 1),
|
||||
- dim_count);
|
||||
+ = value_slice_1 (new_array, range->low,
|
||||
+ range->high - range->low + 1,
|
||||
+ range->stride, dim_count);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -572,27 +616,38 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
to get the value offset right. */
|
||||
if (dim_count == 0)
|
||||
new_array
|
||||
- = value_subscripted_rvalue (new_array, index->number,
|
||||
+ = value_subscripted_rvalue (new_array, index->number,
|
||||
f77_get_lowerbound (value_type
|
||||
(new_array)));
|
||||
else
|
||||
{
|
||||
- /* Check for valid index input. */
|
||||
+ dim_count++;
|
||||
+
|
||||
+ /* We might end up here, because we have to treat the provided
|
||||
+ index like a range. But now VALUE_SUBSCRIPTED_RVALUE
|
||||
+ cannot do the range checks for us. So we have to make sure
|
||||
+ ourselves that the user provided index is inside the
|
||||
+ array bounds. Throw an error if not. */
|
||||
if (index->number < TYPE_LOW_BOUND (index_type)
|
||||
- || index->number > TYPE_HIGH_BOUND (index_type))
|
||||
- error (_("error no such vector element"));
|
||||
+ && index->number < TYPE_HIGH_BOUND (index_type))
|
||||
+ error (_("provided bound(s) outside array bound(s)"));
|
||||
+
|
||||
+ if (index->number > TYPE_LOW_BOUND (index_type)
|
||||
+ && index->number > TYPE_HIGH_BOUND (index_type))
|
||||
+ error (_("provided bound(s) outside array bound(s)"));
|
||||
|
||||
- dim_count++;
|
||||
new_array = value_slice_1 (new_array,
|
||||
- longest_to_int (index->number),
|
||||
- 1, /* length is '1' element */
|
||||
+ index->number,
|
||||
+ 1, /* COUNT is '1' element */
|
||||
+ 1, /* STRIDE set to '1' */
|
||||
dim_count);
|
||||
}
|
||||
|
||||
}
|
||||
break;
|
||||
}
|
||||
- }
|
||||
+ array_type = TYPE_TARGET_TYPE (array_type);
|
||||
+ }
|
||||
|
||||
/* With DIM_COUNT > 1 we currently have a one dimensional array, but expect
|
||||
an array of arrays, depending on how many ranges have been provided by
|
||||
@@ -617,7 +672,9 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
the output array. So we traverse the SUBSCRIPT_ARRAY again, looking
|
||||
for a range entry. When we find one, we use the range info to create
|
||||
an additional range_type to set the correct bounds and dimensions for
|
||||
- the output array. */
|
||||
+ the output array. In addition, we may have a stride value that is not
|
||||
+ '1', forcing us to adjust the number of elements in a range, according
|
||||
+ to the stride value. */
|
||||
for (i = 0; i < nargs; i++)
|
||||
{
|
||||
struct subscript_store *index = &subscript_array[i];
|
||||
@@ -625,12 +682,20 @@ value_f90_subarray (struct value *array, struct expression *exp,
|
||||
if (index->kind == SUBSCRIPT_RANGE)
|
||||
{
|
||||
struct type *range_type, *interim_array_type;
|
||||
+ int new_length;
|
||||
+
|
||||
+ /* The length of a sub-dimension with all elements between the
|
||||
+ bounds plus the start element itself. It may be modified by
|
||||
+ a user provided stride value. */
|
||||
+ new_length = index->range.high - index->range.low;
|
||||
+
|
||||
+ new_length /= index->range.stride;
|
||||
|
||||
range_type
|
||||
= create_static_range_type (NULL,
|
||||
- temp_type,
|
||||
- 1,
|
||||
- index->range.high - index->range.low + 1);
|
||||
+ temp_type,
|
||||
+ index->range.low,
|
||||
+ index->range.low + new_length);
|
||||
|
||||
interim_array_type = create_array_type (NULL,
|
||||
temp_type,
|
||||
diff --git a/gdb/valops.c b/gdb/valops.c
|
||||
index 09ea877..83c8462 100644
|
||||
--- a/gdb/valops.c
|
||||
+++ b/gdb/valops.c
|
||||
@@ -3759,10 +3759,13 @@ value_of_this_silent (const struct language_defn *lang)
|
||||
struct value *
|
||||
value_slice (struct value *array, int lowbound, int length)
|
||||
{
|
||||
- /* Pass unaltered arguments to VALUE_SLICE_1, plus a CALL_COUNT of '1' as we
|
||||
- are only considering the highest dimension, or we are working on a one
|
||||
- dimensional array. So we call VALUE_SLICE_1 exactly once. */
|
||||
- return value_slice_1 (array, lowbound, length, 1);
|
||||
+ /* Pass unaltered arguments to VALUE_SLICE_1, plus a default stride
|
||||
+ value of '1', which returns every element between LOWBOUND and
|
||||
+ (LOWBOUND + LENGTH). We also provide a default CALL_COUNT of '1'
|
||||
+ as we are only considering the highest dimension, or we are
|
||||
+ working on a one dimensional array. So we call VALUE_SLICE_1
|
||||
+ exactly once. */
|
||||
+ return value_slice_1 (array, lowbound, length, 1, 1);
|
||||
}
|
||||
|
||||
/* CALL_COUNT is used to determine if we are calling the function once, e.g.
|
||||
@@ -3776,7 +3779,8 @@ value_slice (struct value *array, int lowbound, int length)
|
||||
ranges in the calling function. */
|
||||
|
||||
struct value *
|
||||
-value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
+value_slice_1 (struct value *array, int lowbound, int length,
|
||||
+ int stride_length, int call_count)
|
||||
{
|
||||
struct type *slice_range_type, *slice_type, *range_type;
|
||||
struct type *array_type = check_typedef (value_type (array));
|
||||
@@ -3799,14 +3803,24 @@ value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
attributes of the underlying type. */
|
||||
if (call_count > 1)
|
||||
{
|
||||
+ ary_low_bound = TYPE_LOW_BOUND (TYPE_INDEX_TYPE (elt_type));
|
||||
+ ary_high_bound = TYPE_HIGH_BOUND (TYPE_INDEX_TYPE (elt_type));
|
||||
elt_type = check_typedef (TYPE_TARGET_TYPE (elt_type));
|
||||
row_count = TYPE_LENGTH (array_type)
|
||||
/ TYPE_LENGTH (TYPE_TARGET_TYPE (array_type));
|
||||
}
|
||||
|
||||
- elem_count = length;
|
||||
+ /* With a stride of '1', the number of elements per result row is equal to
|
||||
+ the LENGTH of the subarray. With non-default stride values, we skip
|
||||
+ elements, but have to add the start element to the total number of
|
||||
+ elements per row. */
|
||||
+ if (stride_length == 1)
|
||||
+ elem_count = length;
|
||||
+ else
|
||||
+ elem_count = ((length - 1) / stride_length) + 1;
|
||||
+
|
||||
elt_size = TYPE_LENGTH (elt_type);
|
||||
- elt_offs = longest_to_int (lowbound - ary_low_bound);
|
||||
+ elt_offs = lowbound - ary_low_bound;
|
||||
elt_stride = TYPE_LENGTH (TYPE_INDEX_TYPE (array_type));
|
||||
|
||||
elt_offs *= elt_size;
|
||||
@@ -3825,7 +3839,7 @@ value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
if (call_count == 1)
|
||||
{
|
||||
range_type = TYPE_INDEX_TYPE (array_type);
|
||||
- slice_range_size = elem_count;
|
||||
+ slice_range_size = ary_low_bound + elem_count - 1;
|
||||
|
||||
/* Check if the array bounds are valid. */
|
||||
if (get_discrete_bounds (range_type, &ary_low_bound, &ary_high_bound) < 0)
|
||||
@@ -3837,7 +3851,7 @@ value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
else
|
||||
{
|
||||
range_type = TYPE_INDEX_TYPE (TYPE_TARGET_TYPE (array_type));
|
||||
- slice_range_size = (ary_low_bound + row_count - 1) * (elem_count);
|
||||
+ slice_range_size = ary_low_bound + (row_count * elem_count) - 1;
|
||||
ary_low_bound = TYPE_LOW_BOUND (range_type);
|
||||
}
|
||||
|
||||
@@ -3849,8 +3863,9 @@ value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
{
|
||||
struct type *element_type;
|
||||
|
||||
- /* When CALL_COUNT equals 1 we can use the legacy code for subarrays. */
|
||||
- if (call_count == 1)
|
||||
+ /* When both CALL_COUNT and STRIDE_LENGTH equal 1, we can use the legacy
|
||||
+ code for subarrays. */
|
||||
+ if (call_count == 1 && stride_length == 1)
|
||||
{
|
||||
element_type = TYPE_TARGET_TYPE (array_type);
|
||||
|
||||
@@ -3871,29 +3886,53 @@ value_slice_1 (struct value *array, int lowbound, int length, int call_count)
|
||||
}
|
||||
|
||||
}
|
||||
- /* When CALL_COUNT is larger than 1 we are working on a range of ranges.
|
||||
- So we copy the relevant elements into the new array we return. */
|
||||
+ /* With a CALL_COUNT or STRIDE_LENGTH are greater than 1 we are working
|
||||
+ on a range of ranges. So we copy the relevant elements into the
|
||||
+ new array we return. */
|
||||
else
|
||||
{
|
||||
+ int j, offs_store = elt_offs;
|
||||
LONGEST dst_offset = 0;
|
||||
LONGEST src_row_length = TYPE_LENGTH (TYPE_TARGET_TYPE (array_type));
|
||||
|
||||
- element_type = TYPE_TARGET_TYPE (TYPE_TARGET_TYPE (array_type));
|
||||
+ if (call_count == 1)
|
||||
+ {
|
||||
+ /* When CALL_COUNT is equal to 1 we are working on the current range
|
||||
+ and use these elements directly. */
|
||||
+ element_type = TYPE_TARGET_TYPE (array_type);
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ /* Working on an array of arrays, the type of the elements is the type
|
||||
+ of the subarrays' type. */
|
||||
+ element_type = TYPE_TARGET_TYPE (TYPE_TARGET_TYPE (array_type));
|
||||
+ }
|
||||
+
|
||||
slice_type = create_array_type (NULL, element_type, slice_range_type);
|
||||
|
||||
- TYPE_CODE (slice_type) = TYPE_CODE (TYPE_TARGET_TYPE (array_type));
|
||||
+ /* If we have a one dimensional array, we copy its TYPE_CODE. For a
|
||||
+ multi dimensional array we copy the embedded type's TYPE_CODE. */
|
||||
+ if (call_count == 1)
|
||||
+ TYPE_CODE (slice_type) = TYPE_CODE (array_type);
|
||||
+ else
|
||||
+ TYPE_CODE (slice_type) = TYPE_CODE (TYPE_TARGET_TYPE (array_type));
|
||||
|
||||
v = allocate_value (slice_type);
|
||||
- for (i = 0; i < longest_to_int (row_count); i++)
|
||||
+
|
||||
+ /* Iterate through the rows of the outer array and set the new offset
|
||||
+ for each row. */
|
||||
+ for (i = 0; i < row_count; i++)
|
||||
{
|
||||
- /* Fetches the contents of ARRAY and copies them into V. */
|
||||
- value_contents_copy (v,
|
||||
- dst_offset,
|
||||
- array,
|
||||
- elt_offs,
|
||||
- elt_size * elem_count);
|
||||
- elt_offs += src_row_length;
|
||||
- dst_offset += elt_size * elem_count;
|
||||
+ elt_offs = offs_store + i * src_row_length;
|
||||
+
|
||||
+ /* Iterate through the elements in each row to copy only those. */
|
||||
+ for (j = 1; j <= elem_count; j++)
|
||||
+ {
|
||||
+ /* Fetches the contents of ARRAY and copies them into V. */
|
||||
+ value_contents_copy (v, dst_offset, array, elt_offs, elt_size);
|
||||
+ elt_offs += elt_size * stride_length;
|
||||
+ dst_offset += elt_size;
|
||||
+ }
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/gdb/value.h b/gdb/value.h
|
||||
index 3400460..c18ef2e 100644
|
||||
--- a/gdb/value.h
|
||||
+++ b/gdb/value.h
|
||||
@@ -1056,7 +1056,7 @@ extern struct value *varying_to_slice (struct value *);
|
||||
|
||||
extern struct value *value_slice (struct value *, int, int);
|
||||
|
||||
-extern struct value *value_slice_1 (struct value *, int, int, int);
|
||||
+extern struct value *value_slice_1 (struct value *, int, int, int, int);
|
||||
|
||||
extern struct value *value_literal_complex (struct value *, struct value *,
|
||||
struct type *);
|
||||
--
|
||||
2.5.0
|
||||
|
36
gdb-fortran-stride-intel-6of6-nokfail.patch
Normal file
36
gdb-fortran-stride-intel-6of6-nokfail.patch
Normal file
@ -0,0 +1,36 @@
|
||||
--- gdb-7.10.50.20160106/gdb/testsuite/gdb.fortran/subrange.exp-orig 2016-01-08 22:45:44.956842553 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/gdb.fortran/subrange.exp 2016-01-08 23:26:05.078554629 +0100
|
||||
@@ -39,27 +39,16 @@ foreach var {a alloc ptr} {
|
||||
set old_prefix $pf_prefix
|
||||
lappend pf_prefix "$var:"
|
||||
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (2, 2:3)" { = \(22, 32\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (2:3, 3)" { = \(32, 33\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (1, 2:)" { = \(21, 31\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (2, :2)" { = \(12, 22\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (3, 2:2)" { = \(23\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "ptype $var (3, 2:2)" " = $int4 \\(2:2\\)"
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (4, :)" { = \(14, 24, 34\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (:, :)" { = \(\( *11, 12, 13, 14\) \( *21, 22, 23, 24\) \( *31, 32, 33, 34\) *\)}
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "ptype $var (:, :)" " = $int4 \\(4,3\\)"
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (:)" "Wrong number of subscripts"
|
||||
- setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test "p $var (:, :, :)" "Wrong number of subscripts"
|
||||
|
||||
set pf_prefix $old_prefix
|
||||
@@ -68,5 +57,4 @@ foreach var {a alloc ptr} {
|
||||
gdb_test_no_output {set $a=a}
|
||||
delete_breakpoints
|
||||
gdb_unload
|
||||
-setup_kfail "*-*-*" "vlaregression/9999"
|
||||
gdb_test {p $a (3, 2:2)} { = \(23\)}
|
515
gdb-fortran-stride-intel-6of6.patch
Normal file
515
gdb-fortran-stride-intel-6of6.patch
Normal file
@ -0,0 +1,515 @@
|
||||
http://sourceware.org/ml/gdb-patches/2016-02/msg00847.html
|
||||
Subject: [PATCH v2 6/6] fortran: test cases for subarray strides and slices
|
||||
|
||||
From: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
Add test cases for subarray creation with range, literal and
|
||||
stride value permutations for one, two, and three dimensional
|
||||
arrays.
|
||||
|
||||
2013-12-04 Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
|
||||
testsuite/gdb.fortran/
|
||||
* static-arrays.exp: New test.
|
||||
* static-arrays.f90: New file.
|
||||
|
||||
|
||||
Signed-off-by: Christoph Weinmann <christoph.t.weinmann@intel.com>
|
||||
---
|
||||
gdb/testsuite/gdb.fortran/static-arrays.exp | 421 ++++++++++++++++++++++++++++
|
||||
gdb/testsuite/gdb.fortran/static-arrays.f90 | 55 ++++
|
||||
2 files changed, 476 insertions(+)
|
||||
create mode 100644 gdb/testsuite/gdb.fortran/static-arrays.exp
|
||||
create mode 100644 gdb/testsuite/gdb.fortran/static-arrays.f90
|
||||
|
||||
diff --git a/gdb/testsuite/gdb.fortran/static-arrays.exp b/gdb/testsuite/gdb.fortran/static-arrays.exp
|
||||
new file mode 100644
|
||||
index 0000000..cc9ecc0
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.fortran/static-arrays.exp
|
||||
@@ -0,0 +1,421 @@
|
||||
+# Copyright 2015 Free Software Foundation, Inc.
|
||||
+#
|
||||
+# Contributed by Intel Corp. <christoph.t.weinmann@intel.com>
|
||||
+#
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
+# it under the terms of the GNU General Public License as published by
|
||||
+# the Free Software Foundation; either version 3 of the License, or
|
||||
+# (at your option) any later version.
|
||||
+#
|
||||
+# This program is distributed in the hope that it will be useful,
|
||||
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+# GNU General Public License for more details.
|
||||
+#
|
||||
+# You should have received a copy of the GNU General Public License
|
||||
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
+
|
||||
+standard_testfile static-arrays.f90
|
||||
+
|
||||
+if { [prepare_for_testing $testfile.exp $testfile $srcfile {debug f90}] } {
|
||||
+ return -1
|
||||
+}
|
||||
+
|
||||
+if ![runto MAIN__] then {
|
||||
+ perror "couldn't run to breakpoint MAIN__"
|
||||
+ continue
|
||||
+}
|
||||
+
|
||||
+gdb_breakpoint [gdb_get_line_number "BP1"]
|
||||
+gdb_continue_to_breakpoint "BP1" ".*BP1.*"
|
||||
+
|
||||
+# Tests subarrays of one dimensional arrays with subrange variations
|
||||
+gdb_test "print ar1" "\\$\[0-9\]+ = \\(1, 2, 3, 4, 5, 6, 7, 8, 9\\)" \
|
||||
+ "print ar1."
|
||||
+gdb_test "print ar1\(4:7\)" "\\$\[0-9\]+ = \\(4, 5, 6, 7\\)" \
|
||||
+ "print ar1\(4:7\)"
|
||||
+gdb_test "print ar1\(8:\)" "\\$\[0-9\]+ = \\(8, 9\\).*" \
|
||||
+ "print ar1\(8:\)"
|
||||
+gdb_test "print ar1\(:3\)" "\\$\[0-9\]+ = \\(1, 2, 3\\).*" \
|
||||
+ "print ar1\(:3\)"
|
||||
+gdb_test "print ar1\(:\)" "\\$\[0-9\]+ = \\(1, 2, 3, 4, 5, 6, 7, 8, 9\\)" \
|
||||
+ "print ar1\(:\)"
|
||||
+
|
||||
+# Check assignment
|
||||
+gdb_test_no_output "set \$my_ary = ar1\(3:8\)"
|
||||
+gdb_test "print \$my_ary" \
|
||||
+ "\\$\[0-9\]+ = \\(3, 4, 5, 6, 7, 8\\)" \
|
||||
+ "Assignment of subarray to variable"
|
||||
+gdb_test_no_output "set ar1\(5\) = 42"
|
||||
+ gdb_test "print ar1\(3:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(3, 4, 42, 6, 7, 8\\)" \
|
||||
+ "print ar1\(3:8\) after assignment"
|
||||
+gdb_test "print \$my_ary" \
|
||||
+ "\\$\[0-9\]+ = \\(3, 4, 5, 6, 7, 8\\)" \
|
||||
+ "Assignment of subarray to variable after original array changed"
|
||||
+
|
||||
+# Test for subarrays of one dimensional arrays with literals
|
||||
+ gdb_test "print ar1\(3\)" "\\$\[0-9\]+ = 3" \
|
||||
+ "print ar1\(3\)"
|
||||
+
|
||||
+# Tests for subranges of 2 dimensional arrays with subrange variations
|
||||
+gdb_test "print ar2\(2:3, 3:4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 23, 33\\) \\( 24, 34\\) \\)" \
|
||||
+ "print ar2\(2:3, 3:4\)."
|
||||
+gdb_test "print ar2\(8:9,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 88, 98\\) \\( 89, 99\\) \\)" \
|
||||
+ "print ar2\(8:9,8:\)"
|
||||
+gdb_test "print ar2\(8:9,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 81, 91\\) \\( 82, 92\\) \\)" \
|
||||
+ "print ar2\(8:9,:2\)"
|
||||
+
|
||||
+gdb_test "print ar2\(8:,8:9\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 88, 98\\) \\( 89, 99\\) \\)" \
|
||||
+ "print ar2\(8:,8:9\)"
|
||||
+gdb_test "print ar2\(8:,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 88, 98\\) \\( 89, 99\\) \\)" \
|
||||
+ "print ar2\(8:,8:\)"
|
||||
+gdb_test "print ar2\(8:,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 81, 91\\) \\( 82, 92\\) \\)" \
|
||||
+ "print ar2\(8:,:2\)"
|
||||
+
|
||||
+gdb_test "print ar2\(:2,2:3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 12, 22\\) \\( 13, 23\\) \\)" \
|
||||
+ "print ar2\(:2,2:3\)"
|
||||
+gdb_test "print ar2\(:2,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 18, 28\\) \\( 19, 29\\) \\)" \
|
||||
+ "print ar2\(:2,8:\)"
|
||||
+gdb_test "print ar2\(:2,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 11, 21\\) \\( 12, 22\\) \\)" \
|
||||
+ "print ar2\(:2,:2\)"
|
||||
+
|
||||
+# Test subranges of 2 dimensional arrays with literals and subrange variations
|
||||
+gdb_test "print ar2\(7, 3:6\)" \
|
||||
+ "\\$\[0-9\]+ = \\(73, 74, 75, 76\\)" \
|
||||
+ "print ar2\(7, 3:6\)"
|
||||
+gdb_test "print ar2\(7,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(78, 79\\)" \
|
||||
+ "print ar2\(7,8:\)"
|
||||
+gdb_test "print ar2\(7,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(71, 72\\)" \
|
||||
+ "print ar2\(7,:2\)"
|
||||
+
|
||||
+gdb_test "print ar2\(7:8,4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(74, 84\\)" \
|
||||
+ "print ar2(7:8,4\)"
|
||||
+gdb_test "print ar2\(8:,4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(84, 94\\)" \
|
||||
+ "print ar2\(8:,4\)"
|
||||
+gdb_test "print ar2\(:2,4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(14, 24\\)" \
|
||||
+ "print ar2\(:2,4\)"
|
||||
+gdb_test "print ar2\(3,4\)" \
|
||||
+ "\\$\[0-9\]+ = 34" \
|
||||
+ "print ar2\(3,4\)"
|
||||
+
|
||||
+# Test subarrays of 3 dimensional arrays with literals and subrange variations
|
||||
+gdb_test "print ar3\(2:4,3:4,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 237, 337, 437\\) \\( 247, 347, 447\\)\
|
||||
+ \\) \\( \\( 238, 338, 438\\) \\( 248, 348, 448\\) \\) \\)" \
|
||||
+ "print ar3\(2:4,3:4,7:8\)"
|
||||
+gdb_test "print ar3\(2:3,4:5,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 248, 348\\) \\( 258, 358\\) \\) \\(\
|
||||
+ \\( 249, 349\\) \\( 259, 359\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,4:5,8:\)"
|
||||
+gdb_test "print ar3\(2:3,4:5,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 241, 341\\) \\( 251, 351\\) \\) \\(\
|
||||
+ \\( 242, 342\\) \\( 252, 352\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,4:5,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(2:3,8:,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 287, 387\\) \\( 297, 397\\) \\) \\(\
|
||||
+ \\( 288, 388\\) \\( 298, 398\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,8:,7:8\)"
|
||||
+gdb_test "print ar3\(2:3,8:,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 288, 388\\) \\( 298, 398\\) \\) \\(\
|
||||
+ \\( 289, 389\\) \\( 299, 399\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,8:,8:\)"
|
||||
+gdb_test "print ar3\(2:3,8:,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 281, 381\\) \\( 291, 391\\) \\) \\(\
|
||||
+ \\( 282, 382\\) \\( 292, 392\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,8:,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(2:3,:2,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 217, 317\\) \\( 227, 327\\) \\) \\(\
|
||||
+ \\( 218, 318\\) \\( 228, 328\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,:2,7:8\)"
|
||||
+gdb_test "print ar3\(2:3,:2,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 218, 318\\) \\( 228, 328\\) \\) \\(\
|
||||
+ \\( 219, 319\\) \\( 229, 329\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,:2,8:\)"
|
||||
+gdb_test "print ar3\(2:3,:2,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 211, 311\\) \\( 221, 321\\) \\) \\(\
|
||||
+ \\( 212, 312\\) \\( 222, 322\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,:2,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(8:,3:4,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 837, 937\\) \\( 847, 947\\) \\) \\(\
|
||||
+ \\( 838, 938\\) \\( 848, 948\\) \\) \\)" \
|
||||
+ "print ar3\(8:,3:4,7:8\)"
|
||||
+gdb_test "print ar3\(8:,4:5,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 848, 948\\) \\( 858, 958\\) \\) \\(\
|
||||
+ \\( 849, 949\\) \\( 859, 959\\) \\) \\)" \
|
||||
+ "print ar3\(8:,4:5,8:\)"
|
||||
+gdb_test "print ar3\(8:,4:5,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 841, 941\\) \\( 851, 951\\) \\) \\(\
|
||||
+ \\( 842, 942\\) \\( 852, 952\\) \\) \\)" \
|
||||
+ "print ar3\(8:,4:5,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(8:,8:,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 887, 987\\) \\( 897, 997\\) \\) \\(\
|
||||
+ \\( 888, 988\\) \\( 898, 998\\) \\) \\)" \
|
||||
+ "print ar3\(8:,8:,7:8\)"
|
||||
+gdb_test "print ar3\(8:,8:,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 888, 988\\) \\( 898, 998\\) \\) \\(\
|
||||
+ \\( 889, 989\\) \\( 899, 999\\) \\) \\)" \
|
||||
+ "print ar3\(8:,8:,8:\)"
|
||||
+gdb_test "print ar3\(8:,8:,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 881, 981\\) \\( 891, 991\\) \\) \\(\
|
||||
+ \\( 882, 982\\) \\( 892, 992\\) \\) \\)" \
|
||||
+ "print ar3\(8:,8:,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(8:,:2,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 817, 917\\) \\( 827, 927\\) \\) \\(\
|
||||
+ \\( 818, 918\\) \\( 828, 928\\) \\) \\)" \
|
||||
+ "print ar3\(8:,:2,7:8\)"
|
||||
+gdb_test "print ar3\(8:,:2,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 818, 918\\) \\( 828, 928\\) \\) \\(\
|
||||
+ \\( 819, 919\\) \\( 829, 929\\) \\) \\)" \
|
||||
+ "print ar3\(8:,:2,8:\)"
|
||||
+gdb_test "print ar3\(8:,:2,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 811, 911\\) \\( 821, 921\\) \\) \\(\
|
||||
+ \\( 812, 912\\) \\( 822, 922\\) \\) \\)" \
|
||||
+ "print ar3\(8:,:2,:2\)"
|
||||
+
|
||||
+
|
||||
+gdb_test "print ar3\(:2,3:4,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 137, 237\\) \\( 147, 247\\) \\) \\(\
|
||||
+ \\( 138, 238\\) \\( 148, 248\\) \\) \\)" \
|
||||
+ "print ar3 \(:2,3:4,7:8\)."
|
||||
+gdb_test "print ar3\(:2,3:4,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 138, 238\\) \\( 148, 248\\) \\) \\(\
|
||||
+ \\( 139, 239\\) \\( 149, 249\\) \\) \\)" \
|
||||
+ "print ar3\(:2,3:4,8:\)"
|
||||
+gdb_test "print ar3\(:2,3:4,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 131, 231\\) \\( 141, 241\\) \\) \\(\
|
||||
+ \\( 132, 232\\) \\( 142, 242\\) \\) \\)" \
|
||||
+ "print ar3\(:2,3:4,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(:2,8:,7:8\)" "\\$\[0-9\]+ = \\(\\( \\( 187, 287\\) \\(\
|
||||
+ 197, 297\\) \\) \\( \\( 188, 288\\) \\( 198, 298\\) \\) \\)" \
|
||||
+ "print ar3\(:2,8:,7:8\)"
|
||||
+gdb_test "print ar3\(:2,8:,8:\)" "\\$\[0-9\]+ = \\(\\( \\( 188, 288\\) \\( 198,\
|
||||
+ 298\\) \\) \\( \\( 189, 289\\) \\( 199, 299\\) \\) \\)" \
|
||||
+ "print ar3\(:2,8:,8:\)"
|
||||
+gdb_test "print ar3\(:2,8:,:2\)" "\\$\[0-9\]+ = \\(\\( \\( 181, 281\\) \\( 191,\
|
||||
+ 291\\) \\) \\( \\( 182, 282\\) \\( 192, 292\\) \\) \\)" \
|
||||
+ "print ar3\(:2,8:,:2\)"
|
||||
+
|
||||
+gdb_test "print ar3\(:2,:2,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 117, 217\\) \\( 127, 227\\) \\) \\(\
|
||||
+ \\( 118, 218\\) \\( 128, 228\\) \\) \\)" \
|
||||
+ "print ar3\(:2,:2,7:8\)"
|
||||
+gdb_test "print ar3\(:2,:2,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 118, 218\\) \\( 128, 228\\) \\) \\(\
|
||||
+ \\( 119, 219\\) \\( 129, 229\\) \\) \\)" \
|
||||
+ "print ar3\(:2,:2,8:\)"
|
||||
+gdb_test "print ar3\(:2,:2,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 111, 211\\) \\( 121, 221\\) \\) \\(\
|
||||
+ \\( 112, 212\\) \\( 122, 222\\) \\) \\)" \
|
||||
+ "print ar3\(:2,:2,:2\)"
|
||||
+
|
||||
+#Tests for subarrays of 3 dimensional arrays with literals and subranges
|
||||
+gdb_test "print ar3\(3,3:4,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 337, 347\\) \\( 338, 348\\) \\)" \
|
||||
+ "print ar3\(3,3:4,7:8\)"
|
||||
+gdb_test "print ar3\(3,4:5,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 348, 358\\) \\( 349, 359\\) \\)" \
|
||||
+ "print ar3\(3,4:5,8:\)"
|
||||
+gdb_test "print ar3\(3,4:5,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 341, 351\\) \\( 342, 352\\) \\)" \
|
||||
+ "print ar3\(3,4:5,:2\)"
|
||||
+gdb_test "print ar3\(3,4:5,3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(343, 353\\)" \
|
||||
+ "print ar3\(3,4:5,3\)"
|
||||
+
|
||||
+gdb_test "print ar3\(2,8:,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 287, 297\\) \\( 288, 298\\) \\)" \
|
||||
+ "print ar3\(2,8:,7:8\)"
|
||||
+gdb_test "print ar3\(2,8:,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 288, 298\\) \\( 289, 299\\) \\)" \
|
||||
+ "print ar3\(2,8:,8:\)"
|
||||
+gdb_test "print ar3\(2,8:,:2\)"\
|
||||
+ "\\$\[0-9\]+ = \\(\\( 281, 291\\) \\( 282, 292\\) \\)" \
|
||||
+ "print ar3\(2,8:,:2\)"
|
||||
+gdb_test "print ar3\(2,8:,3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(283, 293\\)" \
|
||||
+ "print ar3\(2,8:,3\)"
|
||||
+
|
||||
+gdb_test "print ar3\(2,:2,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 217, 227\\) \\( 218, 228\\) \\)" \
|
||||
+ "print ar3\(2,:2,7:8\)"
|
||||
+gdb_test "print ar3\(2,:2,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 218, 228\\) \\( 219, 229\\) \\)" \
|
||||
+ "print ar3\(2,:2,8:\)"
|
||||
+gdb_test "print ar3\(2,:2,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 211, 221\\) \\( 212, 222\\) \\)" \
|
||||
+ "print ar3\(2,:2,:2\)"
|
||||
+gdb_test "print ar3\(2,:2,3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(213, 223\\)" \
|
||||
+ "print ar3\(2,:2,3\)"
|
||||
+
|
||||
+gdb_test "print ar3\(3,4,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(347, 348\\)" \
|
||||
+ "print ar3\(3,4,7:8\)"
|
||||
+gdb_test "print ar3\(3,4,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(348, 349\\)" \
|
||||
+i "print ar3\(3,4,8:\)"
|
||||
+gdb_test "print ar3\(3,4,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(341, 342\\)" \
|
||||
+ "print ar3\(3,4,:2\)"
|
||||
+gdb_test "print ar3\(5,6,7\)" \
|
||||
+ "\\$\[0-9\]+ = 567" \
|
||||
+ "print ar3\(5,6,7\)"
|
||||
+
|
||||
+gdb_test "print ar3\(3:4,6,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 367, 467\\) \\( 368, 468\\) \\)" \
|
||||
+ "print ar3\(3:4,6,7:8\)"
|
||||
+gdb_test "print ar3\(3:4,6,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 368, 468\\) \\( 369, 469\\) \\)" \
|
||||
+ "print ar3\(3:4,6,8:\)"
|
||||
+gdb_test "print ar3\(3:4,6,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 361, 461\\) \\( 362, 462\\) \\)" \
|
||||
+ "print ar3\(3:4,6,:2\)"
|
||||
+gdb_test "print ar3\(3:4,6,5\)" \
|
||||
+ "\\$\[0-9\]+ = \\(365, 465\\)" \
|
||||
+ "print ar3\(3:4,6,5\)"
|
||||
+
|
||||
+gdb_test "print ar3\(8:,6,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 867, 967\\) \\( 868, 968\\) \\)" \
|
||||
+ "print ar3\(8:,6,7:8\)"
|
||||
+gdb_test "print ar3\(8:,6,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 868, 968\\) \\( 869, 969\\) \\)" \
|
||||
+ "print ar3\(8:,6,8:\)"
|
||||
+gdb_test "print ar3\(8:,6,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 861, 961\\) \\( 862, 962\\) \\)" \
|
||||
+ "print ar3\(8:,6,:2\)"
|
||||
+gdb_test "print ar3\(8:,6,5\)" \
|
||||
+ "\\$\[0-9\]+ = \\(865, 965\\)" \
|
||||
+ "print ar3\(8:,6,5\)"
|
||||
+
|
||||
+gdb_test "print ar3\(:2,6,7:8\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 167, 267\\) \\( 168, 268\\) \\)" \
|
||||
+ "print ar3\(:2,6,7:8\)"
|
||||
+gdb_test "print ar3\(:2,6,8:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 168, 268\\) \\( 169, 269\\) \\)" \
|
||||
+ "print ar3\(:2,6,8:\)"
|
||||
+gdb_test "print ar3\(:2,6,:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 161, 261\\) \\( 162, 262\\) \\)" \
|
||||
+ "print ar3\(:2,6,:2\)"
|
||||
+gdb_test "print ar3\(:2,6,5\)" \
|
||||
+ "\\$\[0-9\]+ = \\(165, 265\\)" \
|
||||
+ "print ar3\(:2,6,5\)"
|
||||
+
|
||||
+gdb_test "print ar3\(3:4,5:6,4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 354, 454\\) \\( 364, 464\\) \\)" \
|
||||
+ "print ar2\(3:4,5:6,4\)"
|
||||
+gdb_test "print ar3\(8:,5:6,4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 854, 954\\) \\( 864, 964\\) \\)" \
|
||||
+ "print ar2\(8:,5:6,4\)"
|
||||
+gdb_test "print ar3\(:2,5:6,4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 154, 254\\) \\( 164, 264\\) \\)" \
|
||||
+ "print ar2\(:2,5:6,4\)"
|
||||
+
|
||||
+# Stride > 1
|
||||
+gdb_test "print ar1\(2:6:2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(2, 4, 6\\)" \
|
||||
+ "print ar1\(2:6:2\)"
|
||||
+gdb_test "print ar2\(2:6:2,3:4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 23, 43, 63\\) \\( 24, 44, 64\\) \\)" \
|
||||
+ "print ar2\(2:6:2,3:4\)"
|
||||
+gdb_test "print ar2\(2:6:2,3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(23, 43, 63\\)" \
|
||||
+ "print ar2\(2:6:2,3\)"
|
||||
+gdb_test "print ar3\(2:6:2,3:5:2,4:7:3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 234, 434, 634\\) \\( 254, 454, 654\\)\
|
||||
+ \\) \\( \\( 237, 437, 637\\) \\( 257, 457, 657\\) \\) \\)" \
|
||||
+ "print ar3\(2:6:2,3:5:2,4:7:3\)"
|
||||
+gdb_test "print ar3\(2:6:2,5,4:7:3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 254, 454, 654\\) \\( 257, 457, 657\\)\
|
||||
+ \\)" \
|
||||
+ "print ar3\(2:6:2,5,4:7:3\)"
|
||||
+
|
||||
+# Stride < 0
|
||||
+gdb_test "print ar1\(8:2:-2\)" \
|
||||
+ "\\$\[0-9\]+ = \\(8, 6, 4, 2\\)" \
|
||||
+ "print ar1\(8:2:-2\)"
|
||||
+gdb_test "print ar2\(8:2:-2,3:4\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 83, 63, 43, 23\\) \\( 84, 64, 44, 24\\)\
|
||||
+ \\)" \
|
||||
+ "print ar2\(8:2:-2,3:4\)"
|
||||
+gdb_test "print ar2\(2:6:2,3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(23, 43, 63\\)" \
|
||||
+ "print ar2\(2:6:2,3\)"
|
||||
+gdb_test "print ar3\(2:3,7:3:-4,4:7:3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 274, 374\\) \\( 234, 334\\) \\) \\(\
|
||||
+ \\( 277, 377\\) \\( 237, 337\\) \\) \\)" \
|
||||
+ "print ar3\(2:3,7:3:-4,4:7:3\)"
|
||||
+gdb_test "print ar3\(2:6:2,5,7:4:-3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( 257, 457, 657\\) \\( 254, 454, 654\\)\
|
||||
+ \\)" \
|
||||
+ "print ar3\(2:6:2,5,7:4:-3\)"
|
||||
+
|
||||
+# Tests with negative and mixed indices
|
||||
+gdb_test "p ar4\(2:4, -2:1, -15:-14\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 261, 361, 461\\) \\( 271, 371, 471\\)\
|
||||
+ \\( 281, 381, 481\\) \\( 291, 391, 491\\) \\) \\( \\( 262,\
|
||||
+ 362, 462\\) \\( 272, 372, 472\\) \\( 282, 382, 482\\) \\( 292,\
|
||||
+ 392, 492\\) \\) \\)" \
|
||||
+ "print ar4(2:4, -2:1, -15:-14)"
|
||||
+
|
||||
+gdb_test "p ar4\(7,-6:2:3,-7\)" \
|
||||
+ "\\$\[0-9\]+ = \\(729, 759, 789\\)" \
|
||||
+ "print ar4(7,-6:2:3,-7)"
|
||||
+
|
||||
+gdb_test "p ar4\(9:2:-2, -6:2:3, -6:-15:-3\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 930, 730, 530, 330\\) \\( 960, 760,\
|
||||
+ 560, 360\\) \\( 990, 790, 590, 390\\) \\) \\( \\( 927, 727,\
|
||||
+ 527, 327\\) \\( 957, 757, 557, 357\\) \\( 987, 787, 587,\
|
||||
+ 387\\) \\) \\( \\( 924, 724, 524, 324\\) \\( 954, 754, 554,\
|
||||
+ 354\\) \\( 984, 784, 584, 384\\) \\) \\( \\( 921, 721, 521,\
|
||||
+ 321\\) \\( 951, 751, 551, 351\\) \\( 981, 781, 581, 381\\) \\)\
|
||||
+ \\)" \
|
||||
+ "print ar4(9:2:-2, -6:2:3, -6:-15:-3)"
|
||||
+
|
||||
+gdb_test "p ar4\(:,:,:\)" \
|
||||
+ "\\$\[0-9\]+ = \\(\\( \\( 111, 211, 311, 411, 511, 611, 711,\
|
||||
+ 811, .*" \
|
||||
+ "print ar4(:,:,:)"
|
||||
+
|
||||
+# Provoke error messages for bad user input
|
||||
+gdb_test "print ar1\(0:4\)" \
|
||||
+ "provided bound\\(s\\) outside array bound\\(s\\)" \
|
||||
+ "print ar1\(0:4\)"
|
||||
+gdb_test "print ar1\(8:12\)" \
|
||||
+ "provided bound\\(s\\) outside array bound\\(s\\)" \
|
||||
+ "print ar1\(8:12\)"
|
||||
+gdb_test "print ar1\(8:2:\)" \
|
||||
+ "A syntax error in expression, near `\\)'." \
|
||||
+ "print ar1\(8:2:\)"
|
||||
+gdb_test "print ar1\(8:2:2\)" \
|
||||
+ "Wrong value provided for stride and boundaries" \
|
||||
+ "print ar1\(8:2:2\)"
|
||||
+gdb_test "print ar1\(2:8:-2\)" \
|
||||
+ "Wrong value provided for stride and boundaries" \
|
||||
+ "print ar1\(2:8:-2\)"
|
||||
+gdb_test "print ar1\(2:7:0\)" \
|
||||
+ "Stride must not be 0" \
|
||||
+ "print ar1\(2:7:0\)"
|
||||
+gdb_test "print ar1\(3:7\) = 42" \
|
||||
+ "Invalid cast." \
|
||||
+ "Assignment of value to subarray"
|
||||
diff --git a/gdb/testsuite/gdb.fortran/static-arrays.f90 b/gdb/testsuite/gdb.fortran/static-arrays.f90
|
||||
new file mode 100644
|
||||
index 0000000..f22fcbe
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.fortran/static-arrays.f90
|
||||
@@ -0,0 +1,55 @@
|
||||
+! Copyright 2015 Free Software Foundation, Inc.
|
||||
+!
|
||||
+! Contributed by Intel Corp. <christoph.t.weinmann@intel.com>
|
||||
+!
|
||||
+! This program is free software; you can redistribute it and/or modify
|
||||
+! it under the terms of the GNU General Public License as published by
|
||||
+! the Free Software Foundation; either version 3 of the License, or
|
||||
+! (at your option) any later version.
|
||||
+!
|
||||
+! This program is distributed in the hope that it will be useful,
|
||||
+! but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+! GNU General Public License for more details.
|
||||
+!
|
||||
+! You should have received a copy of the GNU General Public License
|
||||
+! along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
+
|
||||
+subroutine sub
|
||||
+ integer, dimension(9) :: ar1
|
||||
+ integer, dimension(9,9) :: ar2
|
||||
+ integer, dimension(9,9,9) :: ar3
|
||||
+ integer, dimension(10,-7:3, -15:-5) :: ar4
|
||||
+ integer :: i,j,k
|
||||
+
|
||||
+ ar1 = 1
|
||||
+ ar2 = 1
|
||||
+ ar3 = 1
|
||||
+ ar4 = 4
|
||||
+
|
||||
+ ! Resulting array ar3 looks like ((( 111, 112, 113, 114,...)))
|
||||
+ do i = 1, 9, 1
|
||||
+ ar1(i) = i
|
||||
+ do j = 1, 9, 1
|
||||
+ ar2(i,j) = i*10 + j
|
||||
+ do k = 1, 9, 1
|
||||
+ ar3(i,j,k) = i*100 + j*10 + k
|
||||
+ end do
|
||||
+ end do
|
||||
+ end do
|
||||
+
|
||||
+ do i = 1, 10, 1
|
||||
+ do j = -7, 3, 1
|
||||
+ do k = -15, -5, 1
|
||||
+ ar4(i,j,k) = i*100 + (j+8)*10 + (k+16)
|
||||
+ end do
|
||||
+ end do
|
||||
+ end do
|
||||
+
|
||||
+ ar1(1) = 11 !BP1
|
||||
+ return
|
||||
+end
|
||||
+
|
||||
+program testprog
|
||||
+ call sub
|
||||
+end
|
||||
--
|
||||
2.5.0
|
||||
|
@ -6,8 +6,10 @@ http://sourceware.org/ml/gdb-patches/2006-11/msg00253.html
|
||||
[rfc] Do not make up line information
|
||||
http://sourceware.org/ml/gdb-cvs/2006-11/msg00127.html
|
||||
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.base/lineno-makeup-func.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/lineno-makeup-func.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/lineno-makeup-func.c 2016-02-15 23:29:16.595161971 +0100
|
||||
@@ -0,0 +1,21 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -30,8 +32,10 @@ http://sourceware.org/ml/gdb-cvs/2006-11/msg00127.html
|
||||
+func (void)
|
||||
+{
|
||||
+}
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.base/lineno-makeup.c
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/lineno-makeup.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/lineno-makeup.c 2016-02-15 23:29:23.873213646 +0100
|
||||
@@ -0,0 +1,35 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -60,7 +64,7 @@ http://sourceware.org/ml/gdb-cvs/2006-11/msg00127.html
|
||||
+ (s390_analyze_prologue) would skip the whole body till reaching `main'. */
|
||||
+
|
||||
+extern void func (void);
|
||||
+asm ("func: .incbin \"gdb.base/lineno-makeup-func.bin\"");
|
||||
+asm ("func: .incbin \"" BINFILENAME "\"");
|
||||
+
|
||||
+int
|
||||
+main (void)
|
||||
@ -68,8 +72,10 @@ http://sourceware.org/ml/gdb-cvs/2006-11/msg00127.html
|
||||
+ func ();
|
||||
+ return 0;
|
||||
+}
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.base/lineno-makeup.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.base/lineno-makeup.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.base/lineno-makeup.exp 2016-02-15 23:29:23.873213646 +0100
|
||||
@@ -0,0 +1,78 @@
|
||||
+# Copyright 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -89,9 +95,9 @@ http://sourceware.org/ml/gdb-cvs/2006-11/msg00127.html
|
||||
+set testfile "lineno-makeup"
|
||||
+set srcfuncfile ${testfile}-func.c
|
||||
+set srcfile ${testfile}.c
|
||||
+set objfuncfile ${objdir}/${subdir}/${testfile}-func.o
|
||||
+set binfuncfile ${objdir}/${subdir}/${testfile}-func.bin
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set objfuncfile [standard_output_file ${testfile}-func.o]
|
||||
+set binfuncfile [standard_output_file ${testfile}-func.bin]
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfuncfile}" "${objfuncfile}" object {}] != "" } {
|
||||
+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
|
||||
@ -105,7 +111,7 @@ http://sourceware.org/ml/gdb-cvs/2006-11/msg00127.html
|
||||
+set binfuncfilesize [file size $binfuncfile]
|
||||
+verbose -log "file size $binfuncfile = $binfuncfilesize"
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug additional_flags=-DBINFILENAME=\"$binfuncfile\"]] != "" } {
|
||||
+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
|
||||
+}
|
||||
+
|
||||
|
50
gdb-opcodes-clflushopt-test.patch
Normal file
50
gdb-opcodes-clflushopt-test.patch
Normal file
@ -0,0 +1,50 @@
|
||||
--- /dev/null 2016-01-16 21:50:55.732812229 +0100
|
||||
+++ gdb-7.6.1/gdb/testsuite/gdb.arch/amd64-clflushopt.exp 2016-01-16 22:49:19.950683918 +0100
|
||||
@@ -0,0 +1,25 @@
|
||||
+# Copyright 2016 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
+# it under the terms of the GNU General Public License as published by
|
||||
+# the Free Software Foundation; either version 3 of the License, or
|
||||
+# (at your option) any later version.
|
||||
+#
|
||||
+# This program is distributed in the hope that it will be useful,
|
||||
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+# GNU General Public License for more details.
|
||||
+#
|
||||
+# You should have received a copy of the GNU General Public License
|
||||
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
+
|
||||
+if { ![istarget "x86_64-*-*"] && ![istarget "i?86-*-*"] } then {
|
||||
+ verbose "Skipping amd64 clflushopt test."
|
||||
+ return
|
||||
+}
|
||||
+
|
||||
+if [prepare_for_testing amd64-clflushopt.exp amd64-clflushopt amd64-clflushopt.S [list debug "additional_flags=-nostdlib"]] {
|
||||
+ return -1
|
||||
+}
|
||||
+
|
||||
+gdb_test "disas _start" "Dump of assembler code for function _start:\r\n *0x\[0-9a-f\]+ <\[+\]0>:\tclflushopt \\(%edi\\)\r\nEnd of assembler dump\\." "clflushopt"
|
||||
--- /dev/null 2016-01-16 21:50:55.732812229 +0100
|
||||
+++ gdb-7.6.1/gdb/testsuite/gdb.arch/amd64-clflushopt.S 2016-01-16 22:49:26.398725209 +0100
|
||||
@@ -0,0 +1,19 @@
|
||||
+/* Copyright 2016 Free Software Foundation, Inc.
|
||||
+
|
||||
+ This program is free software; you can redistribute it and/or modify
|
||||
+ it under the terms of the GNU General Public License as published by
|
||||
+ the Free Software Foundation; either version 3 of the License, or
|
||||
+ (at your option) any later version.
|
||||
+
|
||||
+ This program is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+ GNU General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU General Public License
|
||||
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
+
|
||||
+ This file is part of the gdb testsuite. */
|
||||
+
|
||||
+_start: .globl _start
|
||||
+ clflushopt (%edi)
|
@ -1,36 +0,0 @@
|
||||
diff --git a/gdb/python/lib/gdb/command/pahole.py b/gdb/python/lib/gdb/command/pahole.py
|
||||
index e08eaf5..56c1737 100644
|
||||
--- a/gdb/python/lib/gdb/command/pahole.py
|
||||
+++ b/gdb/python/lib/gdb/command/pahole.py
|
||||
@@ -55,19 +55,19 @@ It prints the type and displays comments showing where holes are."""
|
||||
fieldsize = 8 * ftype.sizeof
|
||||
|
||||
# TARGET_CHAR_BIT
|
||||
- print (' /* %3d %3d */' % (int (bitpos / 8), int (fieldsize / 8)), end = "")
|
||||
+ print (' /* %3d %3d */' % (int (bitpos / 8), int (fieldsize / 8))),
|
||||
bitpos = bitpos + fieldsize
|
||||
|
||||
if ftype.code == gdb.TYPE_CODE_STRUCT:
|
||||
self.pahole (ftype, level + 1, field.name)
|
||||
else:
|
||||
- print (' ' * (2 + 2 * level), end = "")
|
||||
+ print (' ' * (2 + 2 * level)),
|
||||
print ('%s %s' % (str (ftype), field.name))
|
||||
|
||||
if level == 0:
|
||||
self.maybe_print_hole(bitpos, 8 * type.sizeof)
|
||||
|
||||
- print (' ' * (14 + 2 * level), end = "")
|
||||
+ print (' ' * (14 + 2 * level)),
|
||||
print ('} %s' % name)
|
||||
|
||||
def invoke (self, arg, from_tty):
|
||||
@@ -75,7 +75,7 @@ It prints the type and displays comments showing where holes are."""
|
||||
type = type.strip_typedefs ()
|
||||
if type.code != gdb.TYPE_CODE_STRUCT:
|
||||
raise (TypeError, '%s is not a struct type' % arg)
|
||||
- print (' ' * 14, end = "")
|
||||
+ print (' ' * 14),
|
||||
self.pahole (type, 0, '')
|
||||
|
||||
Pahole()
|
@ -1,193 +0,0 @@
|
||||
From f469e8ce11672e26feb5ba6f9a134275fcfd5b4f Mon Sep 17 00:00:00 2001
|
||||
From: Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
Date: Fri, 21 Aug 2015 18:13:46 -0400
|
||||
Subject: [PATCH 1/4] Improve error reporting when handling SystemTap SDT
|
||||
probes
|
||||
|
||||
This patch improves the error reporting when handling SystemTap SDT
|
||||
probes. "Handling", in this case, mostly means "parsing".
|
||||
|
||||
On gdb/probe.h, only trivial changes on functions' comments in order
|
||||
to explicitly mention that some of them can throw exceptions. This is
|
||||
just to make the API a bit more clear.
|
||||
|
||||
On gdb/stap-probe.c, I have s/internal_error/error/ on two functions
|
||||
that are responsible for parsing specific bits of the probes'
|
||||
arguments: stap_get_opcode and stap_get_expected_argument_type. It is
|
||||
not correct to call internal_error on such situations because it is
|
||||
not really GDB's fault if the probes have malformed arguments. I also
|
||||
improved the error reported on stap_get_expected_argument_type by also
|
||||
including the probe name on it.
|
||||
|
||||
Aside from that, and perhaps most importantly, I added a check on
|
||||
stap_get_arg to make sure that we don't try to extract an argument
|
||||
from a probe that has no arguments. This check issues an
|
||||
internal_error, because it really means that GDB is doing something it
|
||||
shouldn't.
|
||||
|
||||
Although it can be considered almost trivial, and despite the fact
|
||||
that I am the maintainer for this part of the code, I am posting this
|
||||
patch for review. I will wait a few days, and if nobody has anything
|
||||
to say, I will go ahead and push it.
|
||||
|
||||
gdb/ChangeLog:
|
||||
2015-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
|
||||
* probe.h (struct probe_ops) <get_probe_argument_count,
|
||||
evaluate_probe_argument, enable_probe, disable_probe>: Mention in
|
||||
the comment that the function can throw an exception.
|
||||
(get_probe_argument_count): Likewise.
|
||||
(evaluate_probe_argument): Likewise.
|
||||
* stap-probe.c (stap_get_opcode): Call error instead of
|
||||
internal_error.
|
||||
(stap_get_expected_argument_type): Likewise. Add argument
|
||||
'probe'. Improve error message by mentioning the probe's name.
|
||||
(stap_parse_probe_arguments): Adjust call to
|
||||
stap_get_expected_argument_type.
|
||||
(stap_get_arg): Add comment. Assert that 'probe->args_parsed' is
|
||||
not zero. Call internal_error if GDB requests an argument but the
|
||||
probe has no arguments.
|
||||
---
|
||||
gdb/ChangeLog | 17 +++++++++++++++++
|
||||
gdb/probe.h | 20 ++++++++++++++------
|
||||
gdb/stap-probe.c | 29 ++++++++++++++++++++++-------
|
||||
3 files changed, 53 insertions(+), 13 deletions(-)
|
||||
|
||||
Index: gdb-7.10/gdb/probe.h
|
||||
===================================================================
|
||||
--- gdb-7.10.orig/gdb/probe.h
|
||||
+++ gdb-7.10/gdb/probe.h
|
||||
@@ -70,7 +70,8 @@ struct probe_ops
|
||||
CORE_ADDR (*get_probe_address) (struct probe *probe,
|
||||
struct objfile *objfile);
|
||||
|
||||
- /* Return the number of arguments of PROBE. */
|
||||
+ /* Return the number of arguments of PROBE. This function can
|
||||
+ throw an exception. */
|
||||
|
||||
unsigned (*get_probe_argument_count) (struct probe *probe,
|
||||
struct frame_info *frame);
|
||||
@@ -82,7 +83,8 @@ struct probe_ops
|
||||
int (*can_evaluate_probe_arguments) (struct probe *probe);
|
||||
|
||||
/* Evaluate the Nth argument from the PROBE, returning a value
|
||||
- corresponding to it. The argument number is represented N. */
|
||||
+ corresponding to it. The argument number is represented N.
|
||||
+ This function can throw an exception. */
|
||||
|
||||
struct value *(*evaluate_probe_argument) (struct probe *probe,
|
||||
unsigned n,
|
||||
@@ -141,13 +143,15 @@ struct probe_ops
|
||||
|
||||
/* Enable a probe. The semantics of "enabling" a probe depend on
|
||||
the specific backend and the field can be NULL in case enabling
|
||||
- probes is not supported. */
|
||||
+ probes is not supported. This function can throw an
|
||||
+ exception. */
|
||||
|
||||
void (*enable_probe) (struct probe *probe);
|
||||
|
||||
/* Disable a probe. The semantics of "disabling" a probe depend
|
||||
on the specific backend and the field can be NULL in case
|
||||
- disabling probes is not supported. */
|
||||
+ disabling probes is not supported. This function can throw an
|
||||
+ exception. */
|
||||
|
||||
void (*disable_probe) (struct probe *probe);
|
||||
};
|
||||
@@ -264,7 +268,9 @@ extern struct cmd_list_element **info_pr
|
||||
extern CORE_ADDR get_probe_address (struct probe *probe,
|
||||
struct objfile *objfile);
|
||||
|
||||
-/* Return the argument count of the specified probe. */
|
||||
+/* Return the argument count of the specified probe.
|
||||
+
|
||||
+ This function can throw an exception. */
|
||||
|
||||
extern unsigned get_probe_argument_count (struct probe *probe,
|
||||
struct frame_info *frame);
|
||||
@@ -276,7 +282,9 @@ extern unsigned get_probe_argument_count
|
||||
extern int can_evaluate_probe_arguments (struct probe *probe);
|
||||
|
||||
/* Evaluate argument N of the specified probe. N must be between 0
|
||||
- inclusive and get_probe_argument_count exclusive. */
|
||||
+ inclusive and get_probe_argument_count exclusive.
|
||||
+
|
||||
+ This function can throw an exception. */
|
||||
|
||||
extern struct value *evaluate_probe_argument (struct probe *probe,
|
||||
unsigned n,
|
||||
Index: gdb-7.10/gdb/stap-probe.c
|
||||
===================================================================
|
||||
--- gdb-7.10.orig/gdb/stap-probe.c
|
||||
+++ gdb-7.10/gdb/stap-probe.c
|
||||
@@ -313,9 +313,8 @@ stap_get_opcode (const char **s)
|
||||
break;
|
||||
|
||||
default:
|
||||
- internal_error (__FILE__, __LINE__,
|
||||
- _("Invalid opcode in expression `%s' for SystemTap"
|
||||
- "probe"), *s);
|
||||
+ error (_("Invalid opcode in expression `%s' for SystemTap"
|
||||
+ "probe"), *s);
|
||||
}
|
||||
|
||||
return op;
|
||||
@@ -326,7 +325,8 @@ stap_get_opcode (const char **s)
|
||||
|
||||
static struct type *
|
||||
stap_get_expected_argument_type (struct gdbarch *gdbarch,
|
||||
- enum stap_arg_bitness b)
|
||||
+ enum stap_arg_bitness b,
|
||||
+ const struct stap_probe *probe)
|
||||
{
|
||||
switch (b)
|
||||
{
|
||||
@@ -361,8 +361,8 @@ stap_get_expected_argument_type (struct
|
||||
return builtin_type (gdbarch)->builtin_uint64;
|
||||
|
||||
default:
|
||||
- internal_error (__FILE__, __LINE__,
|
||||
- _("Undefined bitness for probe."));
|
||||
+ error (_("Undefined bitness for probe '%s'."),
|
||||
+ probe->p.name);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -1172,7 +1172,8 @@ stap_parse_probe_arguments (struct stap_
|
||||
else
|
||||
arg.bitness = STAP_ARG_BITNESS_UNDEFINED;
|
||||
|
||||
- arg.atype = stap_get_expected_argument_type (gdbarch, arg.bitness);
|
||||
+ arg.atype = stap_get_expected_argument_type (gdbarch, arg.bitness,
|
||||
+ probe);
|
||||
|
||||
expr = stap_parse_argument (&cur, arg.atype, gdbarch);
|
||||
|
||||
@@ -1278,12 +1279,26 @@ stap_is_operator (const char *op)
|
||||
return ret;
|
||||
}
|
||||
|
||||
+/* Return argument N of probe PROBE.
|
||||
+
|
||||
+ If the probe's arguments have not been parsed yet, parse them. If
|
||||
+ there are no arguments, throw an exception (error). Otherwise,
|
||||
+ return the requested argument. */
|
||||
+
|
||||
static struct stap_probe_arg *
|
||||
stap_get_arg (struct stap_probe *probe, unsigned n, struct gdbarch *gdbarch)
|
||||
{
|
||||
if (!probe->args_parsed)
|
||||
stap_parse_probe_arguments (probe, gdbarch);
|
||||
|
||||
+ gdb_assert (probe->args_parsed);
|
||||
+ if (probe->args_u.vec == NULL)
|
||||
+ internal_error (__FILE__, __LINE__,
|
||||
+ _("Probe '%s' apparently does not have arguments, but \n"
|
||||
+ "GDB is requesting its argument number %u anyway. "
|
||||
+ "This should not happen. Please report this bug."),
|
||||
+ probe->p.name, n);
|
||||
+
|
||||
return VEC_index (stap_probe_arg_s, probe->args_u.vec, n);
|
||||
}
|
||||
|
@ -1,194 +0,0 @@
|
||||
From 3bd7e5b7ee5ea0b3bbb4030ca841f66faad74f0f Mon Sep 17 00:00:00 2001
|
||||
From: Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
Date: Fri, 21 Aug 2015 18:28:07 -0400
|
||||
Subject: [PATCH 2/4] Catching errors on probes-based dynamic linker interface
|
||||
|
||||
This patch is intended to make the interaction between the
|
||||
probes-based dynamic linker interface and the SystemTap SDT probe code
|
||||
on GDB more robust. It does that by wrapping the calls to the probe
|
||||
API with TRY...CATCH'es, so that any exception thrown will be caught
|
||||
and handled properly.
|
||||
|
||||
The idea for this patch came from
|
||||
<https://bugzilla.redhat.com/show_bug.cgi?id=1196181>, which is a bug
|
||||
initially filed against Fedora GDB (but now under Fedora GLIBC). This
|
||||
bug happens on armhfp (although it could happen on other targets as
|
||||
well), and is triggered because GCC generates a strange argument for
|
||||
one of the probes used by GDB in the dynamic linker interface. As can
|
||||
be seen in the bug, this argument is "-4@.L1052".
|
||||
|
||||
I don't want to discuss the reasons for this argument to be there
|
||||
(this discussion belongs to the bug, or to another thread), but GDB
|
||||
could definitely do a better error handling here. Currently, one sees
|
||||
the following message when there is an error in the probes-based
|
||||
dynamic linker interface:
|
||||
|
||||
(gdb) run
|
||||
Starting program: /bin/inferior
|
||||
warning: Probes-based dynamic linker interface failed.
|
||||
Reverting to original interface.
|
||||
|
||||
Cannot parse expression `.L976 4@r4'.
|
||||
(gdb)
|
||||
|
||||
Which means that one needs to explicitly issue a "continue" command to
|
||||
make GDB continue running the inferior, even though this error is not
|
||||
fatal and GDB will fallback to the old interface automatically.
|
||||
|
||||
This is where this patch helps: it makes GDB still print the necessary
|
||||
warnings or error messages, but it *also* does not stop the inferior
|
||||
unnecessarily.
|
||||
|
||||
I have tested this patch on the systems where this error happens, but
|
||||
I could not come up with a way to create a testcase for it.
|
||||
Nevertheless, it should be straightforward to see that this patch does
|
||||
improve the current situation.
|
||||
|
||||
gdb/ChangeLog:
|
||||
2015-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
|
||||
* solib-svr4.c (solib_event_probe_action): Call
|
||||
get_probe_argument_count using TRY...CATCH.
|
||||
(svr4_handle_solib_event): Likewise, for evaluate_probe_argument.
|
||||
---
|
||||
gdb/ChangeLog | 6 ++++++
|
||||
gdb/solib-svr4.c | 43 ++++++++++++++++++++++++++++++++++++++++---
|
||||
2 files changed, 46 insertions(+), 3 deletions(-)
|
||||
|
||||
Index: gdb-7.10/gdb/solib-svr4.c
|
||||
===================================================================
|
||||
--- gdb-7.10.orig/gdb/solib-svr4.c
|
||||
+++ gdb-7.10/gdb/solib-svr4.c
|
||||
@@ -1796,7 +1796,23 @@ solib_event_probe_action (struct probe_a
|
||||
arg0: Lmid_t lmid (mandatory)
|
||||
arg1: struct r_debug *debug_base (mandatory)
|
||||
arg2: struct link_map *new (optional, for incremental updates) */
|
||||
- probe_argc = get_probe_argument_count (pa->probe, frame);
|
||||
+ TRY
|
||||
+ {
|
||||
+ probe_argc = get_probe_argument_count (pa->probe, frame);
|
||||
+ }
|
||||
+ CATCH (ex, RETURN_MASK_ERROR)
|
||||
+ {
|
||||
+ exception_print (gdb_stderr, ex);
|
||||
+ probe_argc = 0;
|
||||
+ }
|
||||
+ END_CATCH
|
||||
+
|
||||
+ /* If get_probe_argument_count throws an exception, probe_argc will
|
||||
+ be set to zero. However, if pa->probe does not have arguments,
|
||||
+ then get_probe_argument_count will succeed but probe_argc will
|
||||
+ also be zero. Both cases happen because of different things, but
|
||||
+ they are treated equally here: action will be set to
|
||||
+ PROBES_INTERFACE_FAILED. */
|
||||
if (probe_argc == 2)
|
||||
action = FULL_RELOAD;
|
||||
else if (probe_argc < 2)
|
||||
@@ -1950,7 +1966,17 @@ svr4_handle_solib_event (void)
|
||||
usm_chain = make_cleanup (resume_section_map_updates_cleanup,
|
||||
current_program_space);
|
||||
|
||||
- val = evaluate_probe_argument (pa->probe, 1, frame);
|
||||
+ TRY
|
||||
+ {
|
||||
+ val = evaluate_probe_argument (pa->probe, 1, frame);
|
||||
+ }
|
||||
+ CATCH (ex, RETURN_MASK_ERROR)
|
||||
+ {
|
||||
+ exception_print (gdb_stderr, ex);
|
||||
+ val = NULL;
|
||||
+ }
|
||||
+ END_CATCH
|
||||
+
|
||||
if (val == NULL)
|
||||
{
|
||||
do_cleanups (old_chain);
|
||||
@@ -1981,7 +2007,18 @@ svr4_handle_solib_event (void)
|
||||
|
||||
if (action == UPDATE_OR_RELOAD)
|
||||
{
|
||||
- val = evaluate_probe_argument (pa->probe, 2, frame);
|
||||
+ TRY
|
||||
+ {
|
||||
+ val = evaluate_probe_argument (pa->probe, 2, frame);
|
||||
+ }
|
||||
+ CATCH (ex, RETURN_MASK_ERROR)
|
||||
+ {
|
||||
+ exception_print (gdb_stderr, ex);
|
||||
+ do_cleanups (old_chain);
|
||||
+ return;
|
||||
+ }
|
||||
+ END_CATCH
|
||||
+
|
||||
if (val != NULL)
|
||||
lm = value_as_address (val);
|
||||
|
||||
From ad1c917a79e8c5aa67657f148415c1bee01b240f Mon Sep 17 00:00:00 2001
|
||||
From: Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
Date: Wed, 2 Sep 2015 00:34:22 -0400
|
||||
Subject: [PATCH 3/4] Initialize variable and silence GCC warning from last
|
||||
commit
|
||||
|
||||
BuildBot e-mailed me to let me know that my last commit broke GDB on
|
||||
RHEL-7.1 s390x. On solib-svr4.c:svr4_handle_solib_event, 'val' now
|
||||
needs to be initialized as NULL because it is inside a TRY..CATCH
|
||||
block. This patch does that. Pushed as obvious.
|
||||
|
||||
gdb/ChangeLog:
|
||||
2015-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
|
||||
* solib-svr4.c (svr4_handle_solib_event): Initialize 'val' as NULL
|
||||
---
|
||||
gdb/ChangeLog | 4 ++++
|
||||
gdb/solib-svr4.c | 2 +-
|
||||
2 files changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
Index: gdb-7.10/gdb/solib-svr4.c
|
||||
===================================================================
|
||||
--- gdb-7.10.orig/gdb/solib-svr4.c
|
||||
+++ gdb-7.10/gdb/solib-svr4.c
|
||||
@@ -1918,7 +1918,7 @@ svr4_handle_solib_event (void)
|
||||
struct probe_and_action *pa;
|
||||
enum probe_action action;
|
||||
struct cleanup *old_chain, *usm_chain;
|
||||
- struct value *val;
|
||||
+ struct value *val = NULL;
|
||||
CORE_ADDR pc, debug_base, lm = 0;
|
||||
int is_initial_ns;
|
||||
struct frame_info *frame = get_current_frame ();
|
||||
From 73c6b4756a7cee53c274ed05fddcd079b8b7e57c Mon Sep 17 00:00:00 2001
|
||||
From: Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
Date: Wed, 2 Sep 2015 00:46:43 -0400
|
||||
Subject: [PATCH 4/4] Initialize yet another variable to silence GCC warning
|
||||
from last-but-one commit
|
||||
|
||||
Yet another BuildBot e-mail, yet another breakage on RHEL-7.1 s390x
|
||||
(which uses an older GCC). This time,
|
||||
solib-svr4.c:solib_event_probe_action has the probe_argc variable,
|
||||
which is now inside a TRY..CATCH and therefore needs to be
|
||||
initialized. Pushed as obvious.
|
||||
|
||||
gdb/ChangeLog:
|
||||
2015-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
|
||||
* solib-svr4.c (solib_event_probe_action): Initialize 'probe_argc'
|
||||
as zero.
|
||||
---
|
||||
gdb/ChangeLog | 5 +++++
|
||||
gdb/solib-svr4.c | 2 +-
|
||||
2 files changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
2015-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
|
||||
Index: gdb-7.10/gdb/solib-svr4.c
|
||||
===================================================================
|
||||
--- gdb-7.10.orig/gdb/solib-svr4.c
|
||||
+++ gdb-7.10/gdb/solib-svr4.c
|
||||
@@ -1782,7 +1782,7 @@ static enum probe_action
|
||||
solib_event_probe_action (struct probe_and_action *pa)
|
||||
{
|
||||
enum probe_action action;
|
||||
- unsigned probe_argc;
|
||||
+ unsigned probe_argc = 0;
|
||||
struct frame_info *frame = get_current_frame ();
|
||||
|
||||
action = pa->action;
|
@ -1,14 +1,17 @@
|
||||
--- gdb-7.4.50.20120103-orig/gdb/event-top.c 2012-01-11 15:14:01.426206439 +0100
|
||||
+++ gdb-7.4.50.20120103/gdb/event-top.c 2012-01-11 15:18:29.766577551 +0100
|
||||
@@ -982,6 +982,11 @@ set_async_editing_command (char *args, i
|
||||
diff -dup -rup gdb-7.10.50.20160106-orig/gdb/event-top.c gdb-7.10.50.20160106/gdb/event-top.c
|
||||
--- gdb-7.10.50.20160106-orig/gdb/event-top.c 2016-01-09 14:51:02.324243506 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/event-top.c 2016-01-09 14:51:33.029434121 +0100
|
||||
@@ -1033,6 +1033,13 @@ set_async_editing_command (char *args, i
|
||||
void
|
||||
gdb_setup_readline (void)
|
||||
{
|
||||
+#ifdef NEED_RL_STATE_FEDORA_GDB
|
||||
+ /* 6.2 regression: no longed asks for --more--
|
||||
+ gdb.base/readline-ask.exp
|
||||
+ https://bugzilla.redhat.com/show_bug.cgi?id=701131 */
|
||||
+ RL_SETSTATE (RL_STATE_FEDORA_GDB);
|
||||
+
|
||||
+#endif
|
||||
/* This function is a noop for the sync case. The assumption is
|
||||
that the sync setup is ALL done in gdb_init, and we would only
|
||||
mess it up here. The sync stuff should really go away over
|
||||
|
@ -1,257 +0,0 @@
|
||||
http://sourceware.org/ml/gdb-patches/2015-09/msg00183.html
|
||||
Subject: [ppc64le patch v3] Use skip_entrypoint for skip_trampoline_code
|
||||
|
||||
|
||||
--mYCpIKhGyMATD0i+
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: inline
|
||||
|
||||
An update to PASS the testcase on non-ppc64le archs.
|
||||
|
||||
--mYCpIKhGyMATD0i+
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: inline; filename=4
|
||||
|
||||
gdb/ChangeLog
|
||||
2015-09-07 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||
|
||||
* linespec.c (minsym_found): Call gdbarch_skip_entrypoint.
|
||||
* ppc64-tdep.c (ppc64_skip_trampoline_code): Rename to ...
|
||||
(ppc64_skip_trampoline_code_1): ... here.
|
||||
(ppc64_skip_trampoline_code): New wrapper function.
|
||||
* symtab.c (find_function_start_sal): Call gdbarch_skip_entrypoint.
|
||||
|
||||
gdb/testsuite/ChangeLog
|
||||
2015-09-07 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||
|
||||
* gdb.opt/solib-intra-step-lib.c: New file.
|
||||
* gdb.opt/solib-intra-step-main.c: New file.
|
||||
* gdb.opt/solib-intra-step.exp: New file.
|
||||
|
||||
diff --git a/gdb/linespec.c b/gdb/linespec.c
|
||||
index 8f102fa..4c29c12 100644
|
||||
--- a/gdb/linespec.c
|
||||
+++ b/gdb/linespec.c
|
||||
@@ -3570,6 +3570,8 @@ minsym_found (struct linespec_state *self, struct objfile *objfile,
|
||||
sal.pc = MSYMBOL_VALUE_ADDRESS (objfile, msymbol);
|
||||
sal.pc = gdbarch_convert_from_func_ptr_addr (gdbarch, sal.pc,
|
||||
¤t_target);
|
||||
+ if (gdbarch_skip_entrypoint_p (gdbarch))
|
||||
+ sal.pc = gdbarch_skip_entrypoint (gdbarch, sal.pc);
|
||||
}
|
||||
else
|
||||
skip_prologue_sal (&sal);
|
||||
diff --git a/gdb/ppc64-tdep.c b/gdb/ppc64-tdep.c
|
||||
index bb23b6a..4a0b93a 100644
|
||||
--- a/gdb/ppc64-tdep.c
|
||||
+++ b/gdb/ppc64-tdep.c
|
||||
@@ -454,8 +454,8 @@ ppc64_standard_linkage4_target (struct frame_info *frame,
|
||||
When the execution direction is EXEC_REVERSE, scan backward to
|
||||
check whether we are in the middle of a PLT stub. */
|
||||
|
||||
-CORE_ADDR
|
||||
-ppc64_skip_trampoline_code (struct frame_info *frame, CORE_ADDR pc)
|
||||
+static CORE_ADDR
|
||||
+ppc64_skip_trampoline_code_1 (struct frame_info *frame, CORE_ADDR pc)
|
||||
{
|
||||
#define MAX(a,b) ((a) > (b) ? (a) : (b))
|
||||
unsigned int insns[MAX (MAX (MAX (ARRAY_SIZE (ppc64_standard_linkage1),
|
||||
@@ -530,6 +530,20 @@ ppc64_skip_trampoline_code (struct frame_info *frame, CORE_ADDR pc)
|
||||
return 0;
|
||||
}
|
||||
|
||||
+/* Wrapper of ppc64_skip_trampoline_code_1 checking also
|
||||
+ ppc_elfv2_skip_entrypoint. */
|
||||
+
|
||||
+CORE_ADDR
|
||||
+ppc64_skip_trampoline_code (struct frame_info *frame, CORE_ADDR pc)
|
||||
+{
|
||||
+ struct gdbarch *gdbarch = get_frame_arch (frame);
|
||||
+
|
||||
+ pc = ppc64_skip_trampoline_code_1 (frame, pc);
|
||||
+ if (pc != 0 && gdbarch_skip_entrypoint_p (gdbarch))
|
||||
+ pc = gdbarch_skip_entrypoint (gdbarch, pc);
|
||||
+ return pc;
|
||||
+}
|
||||
+
|
||||
/* Support for convert_from_func_ptr_addr (ARCH, ADDR, TARG) on PPC64
|
||||
GNU/Linux.
|
||||
|
||||
diff --git a/gdb/symtab.c b/gdb/symtab.c
|
||||
index 1ba691e..f65e809 100644
|
||||
--- a/gdb/symtab.c
|
||||
+++ b/gdb/symtab.c
|
||||
@@ -3629,7 +3629,11 @@ find_function_start_sal (struct symbol *sym, int funfirstline)
|
||||
&& (COMPUNIT_LOCATIONS_VALID (SYMTAB_COMPUNIT (sal.symtab))
|
||||
|| SYMTAB_LANGUAGE (sal.symtab) == language_asm))
|
||||
{
|
||||
+ struct gdbarch *gdbarch = symbol_arch (sym);
|
||||
+
|
||||
sal.pc = BLOCK_START (SYMBOL_BLOCK_VALUE (sym));
|
||||
+ if (gdbarch_skip_entrypoint_p (gdbarch))
|
||||
+ sal.pc = gdbarch_skip_entrypoint (gdbarch, sal.pc);
|
||||
return sal;
|
||||
}
|
||||
|
||||
diff --git a/gdb/testsuite/gdb.opt/solib-intra-step-lib.c b/gdb/testsuite/gdb.opt/solib-intra-step-lib.c
|
||||
new file mode 100644
|
||||
index 0000000..9ab1211
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.opt/solib-intra-step-lib.c
|
||||
@@ -0,0 +1,30 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
+ Copyright 2015 Free Software Foundation, Inc.
|
||||
+
|
||||
+ This program is free software; you can redistribute it and/or modify
|
||||
+ it under the terms of the GNU General Public License as published by
|
||||
+ the Free Software Foundation; either version 3 of the License, or
|
||||
+ (at your option) any later version.
|
||||
+
|
||||
+ This program is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+ GNU General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU General Public License
|
||||
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
||||
+
|
||||
+#include <stdlib.h>
|
||||
+
|
||||
+void
|
||||
+shlib_second (int dummy)
|
||||
+{ /* second-retry */
|
||||
+ abort (); /* second-hit */
|
||||
+}
|
||||
+
|
||||
+void
|
||||
+shlib_first (void)
|
||||
+{ /* first-retry */
|
||||
+ shlib_second (0); /* first-hit */
|
||||
+}
|
||||
diff --git a/gdb/testsuite/gdb.opt/solib-intra-step-main.c b/gdb/testsuite/gdb.opt/solib-intra-step-main.c
|
||||
new file mode 100644
|
||||
index 0000000..186bd5f
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.opt/solib-intra-step-main.c
|
||||
@@ -0,0 +1,25 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
+ Copyright 2015 Free Software Foundation, Inc.
|
||||
+
|
||||
+ This program is free software; you can redistribute it and/or modify
|
||||
+ it under the terms of the GNU General Public License as published by
|
||||
+ the Free Software Foundation; either version 3 of the License, or
|
||||
+ (at your option) any later version.
|
||||
+
|
||||
+ This program is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+ GNU General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU General Public License
|
||||
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
||||
+
|
||||
+extern void shlib_first (void);
|
||||
+
|
||||
+int
|
||||
+main (void)
|
||||
+{
|
||||
+ shlib_first ();
|
||||
+ return 0;
|
||||
+}
|
||||
diff --git a/gdb/testsuite/gdb.opt/solib-intra-step.exp b/gdb/testsuite/gdb.opt/solib-intra-step.exp
|
||||
new file mode 100644
|
||||
index 0000000..044c4bd
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.opt/solib-intra-step.exp
|
||||
@@ -0,0 +1,86 @@
|
||||
+# Copyright 2015 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
+# it under the terms of the GNU General Public License as published by
|
||||
+# the Free Software Foundation; either version 3 of the License, or
|
||||
+# (at your option) any later version.
|
||||
+#
|
||||
+# This program is distributed in the hope that it will be useful,
|
||||
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+# GNU General Public License for more details.
|
||||
+#
|
||||
+# You should have received a copy of the GNU General Public License
|
||||
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
+
|
||||
+standard_testfile
|
||||
+
|
||||
+if {[skip_shlib_tests]} {
|
||||
+ return 0
|
||||
+}
|
||||
+
|
||||
+# Library file.
|
||||
+set libname "${testfile}-lib"
|
||||
+set srcfile_lib ${srcdir}/${subdir}/${libname}.c
|
||||
+set binfile_lib [standard_output_file ${libname}.so]
|
||||
+set lib_flags [list debug optimize=-O2]
|
||||
+# Binary file.
|
||||
+set testfile "${testfile}-main"
|
||||
+set srcfile ${srcdir}/${subdir}/${testfile}.c
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+set bin_flags [list debug shlib=${binfile_lib}]
|
||||
+
|
||||
+if [get_compiler_info] {
|
||||
+ return -1
|
||||
+}
|
||||
+
|
||||
+if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib} $lib_flags] != ""
|
||||
+ || [gdb_compile ${srcfile} ${binfile} executable $bin_flags] != "" } {
|
||||
+ untested "Could not compile $binfile_lib or $binfile."
|
||||
+ return -1
|
||||
+}
|
||||
+
|
||||
+clean_restart ${binfile}
|
||||
+gdb_load_shlibs $binfile_lib
|
||||
+
|
||||
+if ![runto_main] then {
|
||||
+ return 0
|
||||
+}
|
||||
+
|
||||
+set test "first-hit"
|
||||
+gdb_test_multiple "step" $test {
|
||||
+ -re " first-hit .*\r\n$gdb_prompt $" {
|
||||
+ pass $test
|
||||
+ }
|
||||
+ -re " first-retry .*\r\n$gdb_prompt $" {
|
||||
+ gdb_test "step" " first-hit .*" "first-hit (optimized)"
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+set test "second-hit"
|
||||
+gdb_test_multiple "step" $test {
|
||||
+ -re " second-hit .*\r\n$gdb_prompt $" {
|
||||
+ pass $test
|
||||
+ }
|
||||
+ -re " first-retry .*\r\n$gdb_prompt $" {
|
||||
+ set test "second-hit (optimized 1)"
|
||||
+ gdb_test_multiple "step" $test {
|
||||
+ -re " second-hit .*\r\n$gdb_prompt $" {
|
||||
+ pass $test
|
||||
+ }
|
||||
+ -re " first-hit .*\r\n$gdb_prompt $" {
|
||||
+ gdb_test "step" " second-hit .*" "second-hit (optimized 2)"
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+ -re " second-retry .*\r\n$gdb_prompt $" {
|
||||
+ gdb_test "step" " second-hit .*" "second-hit (optimized 3)"
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+if ![runto_main] then {
|
||||
+ return 0
|
||||
+}
|
||||
+
|
||||
+gdb_breakpoint "shlib_second"
|
||||
+gdb_continue_to_breakpoint "second-hit" ".* (second-hit|second-retry) .*"
|
||||
|
||||
--mYCpIKhGyMATD0i+--
|
||||
|
@ -1,220 +0,0 @@
|
||||
http://sourceware.org/ml/gdb-patches/2015-10/msg00166.html
|
||||
Subject: [patch] Fix internal error on DW_OP_bregx(-1)
|
||||
|
||||
|
||||
--ibTvN161/egqYuK8
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: inline
|
||||
|
||||
Hi,
|
||||
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=1270564#c15
|
||||
https://bugzilla.redhat.com/attachment.cgi?id=1081772
|
||||
|
||||
clang-3.5.0-9.fc22.x86_64
|
||||
<3><22b2>: Abbrev Number: 69 (DW_TAG_variable)
|
||||
<22b3> DW_AT_location : 7 byte block: 92 ff ff ff ff f 0 (DW_OP_bregx: 4294967295 (r-1) 0)
|
||||
<22bb> DW_AT_name : (indirect string, offset: 0x2a36): texture_data
|
||||
<22c1> DW_AT_type : <0x1d3>
|
||||
|
||||
(gdb) p variable
|
||||
warning: Unmapped DWARF Register #-1 encountered.
|
||||
regcache.c:177: internal-error: register_size: Assertion `regnum >= 0 && regnum < (gdbarch_num_regs (gdbarch) + gdbarch_num_pseudo_regs (gdbarch))' failed.
|
||||
[...]
|
||||
Quit this debugging session? (y or n) FAIL: gdb.dwarf2/dw2-regno-invalid.exp: p variable (GDB internal error)
|
||||
|
||||
-> (x86_64)
|
||||
(gdb) p variable
|
||||
warning: Unmapped DWARF Register #-1 encountered.
|
||||
Invalid register #-1, expecting 0 <= # < 220
|
||||
(gdb) PASS: gdb.dwarf2/dw2-regno-invalid.exp: p variable
|
||||
-> (i386)
|
||||
(gdb) p variable
|
||||
Invalid register #104, expecting 0 <= # < 104
|
||||
(gdb) PASS: gdb.dwarf2/dw2-regno-invalid.exp: p variable
|
||||
|
||||
GDB calls gdbarch_dwarf2_reg_to_regnum() first which returns -1 in the x86_64
|
||||
case
|
||||
if (regnum == -1)
|
||||
warning (_("Unmapped DWARF Register #%d encountered."), reg);
|
||||
but in i386 case it does:
|
||||
/* This will hopefully provoke a warning. */
|
||||
return gdbarch_num_regs (gdbarch) + gdbarch_num_pseudo_regs (gdbarch);
|
||||
and the default implementation is a nop, leaving whatever register number
|
||||
the DWARF specified.
|
||||
|
||||
No regressions on {x86_64,x86_64-m32,i686}-fedorarawhide-linux-gnu.
|
||||
|
||||
|
||||
Jan
|
||||
|
||||
--ibTvN161/egqYuK8
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: inline; filename="undefreg.patch"
|
||||
|
||||
gdb/ChangeLog
|
||||
2015-10-12 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||
|
||||
* findvar.c (address_from_register): Check REGNUM validity.
|
||||
|
||||
gdb/testsuite/ChangeLog
|
||||
2015-10-12 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||
|
||||
* gdb.dwarf2/dw2-regno-invalid.S: New file.
|
||||
* gdb.dwarf2/dw2-regno-invalid.exp: New file.
|
||||
|
||||
diff --git a/gdb/findvar.c b/gdb/findvar.c
|
||||
index 0f46e53..855947d 100644
|
||||
--- a/gdb/findvar.c
|
||||
+++ b/gdb/findvar.c
|
||||
@@ -927,6 +927,12 @@ address_from_register (int regnum, struct frame_info *frame)
|
||||
struct type *type = builtin_type (gdbarch)->builtin_data_ptr;
|
||||
struct value *value;
|
||||
CORE_ADDR result;
|
||||
+ int regnum_max_excl = (gdbarch_num_regs (gdbarch)
|
||||
+ + gdbarch_num_pseudo_regs (gdbarch));
|
||||
+
|
||||
+ if (regnum < 0 || regnum >= regnum_max_excl)
|
||||
+ error (_("Invalid register #%d, expecting 0 <= # < %d"), regnum,
|
||||
+ regnum_max_excl);
|
||||
|
||||
/* This routine may be called during early unwinding, at a time
|
||||
where the ID of FRAME is not yet known. Calling value_from_register
|
||||
diff --git a/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.S b/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.S
|
||||
new file mode 100644
|
||||
index 0000000..075bfd6
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.S
|
||||
@@ -0,0 +1,91 @@
|
||||
+/* Copyright 2015 Free Software Foundation, Inc.
|
||||
+
|
||||
+ This program is free software; you can redistribute it and/or modify
|
||||
+ it under the terms of the GNU General Public License as published by
|
||||
+ the Free Software Foundation; either version 3 of the License, or
|
||||
+ (at your option) any later version.
|
||||
+
|
||||
+ This program is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+ GNU General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU General Public License
|
||||
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
||||
+
|
||||
+ .section .debug_info
|
||||
+debug_start:
|
||||
+ .4byte debug_end - 1f /* Length of Compilation Unit Info */
|
||||
+1:
|
||||
+ .2byte 0x3 /* DWARF version number */
|
||||
+ .4byte .Ldebug_abbrev0 /* Offset Into Abbrev. Section */
|
||||
+ .byte 0x4 /* Pointer Size (in bytes) */
|
||||
+ .uleb128 0x1 /* (DIE (0xb) DW_TAG_compile_unit) */
|
||||
+ .ascii "clang-3.5.0-9.fc22.x86_64\0" /* DW_AT_producer */
|
||||
+ .byte 0x1 /* DW_AT_language */
|
||||
+ .ascii "1.c\0" /* DW_AT_name */
|
||||
+ .4byte main_label /* DW_AT_low_pc */
|
||||
+ .4byte main_label+0x10000 /* DW_AT_high_pc */
|
||||
+
|
||||
+ .uleb128 2 /* Abbrev: DW_TAG_subprogram */
|
||||
+ .byte 1 /* DW_AT_external */
|
||||
+ .ascii "main\0" /* DW_AT_name */
|
||||
+ .4byte main_label /* DW_AT_low_pc */
|
||||
+ .4byte main_label+0x10000 /* DW_AT_high_pc */
|
||||
+
|
||||
+ .uleb128 0x4 /* (DW_TAG_variable) */
|
||||
+ .ascii "variable\0" /* DW_AT_name */
|
||||
+ .2byte 2f - 1f /* DW_AT_location: DW_FORM_block2 */
|
||||
+1:
|
||||
+ .byte 0x92 /* DW_OP_bregx */
|
||||
+ .uleb128 0xffffffff
|
||||
+ .sleb128 0
|
||||
+2:
|
||||
+
|
||||
+ .byte 0x0 /* end of children of main */
|
||||
+ .byte 0x0 /* end of children of CU */
|
||||
+debug_end:
|
||||
+
|
||||
+ .section .debug_abbrev
|
||||
+.Ldebug_abbrev0:
|
||||
+ .uleb128 0x1 /* (abbrev code) */
|
||||
+ .uleb128 0x11 /* (TAG: DW_TAG_compile_unit) */
|
||||
+ .byte 0x1 /* DW_children_yes */
|
||||
+ .uleb128 0x25 /* (DW_AT_producer) */
|
||||
+ .uleb128 0x8 /* (DW_FORM_string) */
|
||||
+ .uleb128 0x13 /* (DW_AT_language) */
|
||||
+ .uleb128 0xb /* (DW_FORM_data1) */
|
||||
+ .uleb128 0x3 /* (DW_AT_name) */
|
||||
+ .uleb128 0x8 /* (DW_FORM_string) */
|
||||
+ .uleb128 0x11 /* DW_AT_low_pc */
|
||||
+ .uleb128 0x1 /* DW_FORM_addr */
|
||||
+ .uleb128 0x12 /* DW_AT_high_pc */
|
||||
+ .uleb128 0x1 /* DW_FORM_addr */
|
||||
+ .byte 0x0
|
||||
+ .byte 0x0
|
||||
+
|
||||
+ .uleb128 2 /* Abbrev code */
|
||||
+ .uleb128 0x2e /* DW_TAG_subprogram */
|
||||
+ .byte 1 /* has_children */
|
||||
+ .uleb128 0x3f /* DW_AT_external */
|
||||
+ .uleb128 0xc /* DW_FORM_flag */
|
||||
+ .uleb128 0x3 /* DW_AT_name */
|
||||
+ .uleb128 0x8 /* DW_FORM_string */
|
||||
+ .uleb128 0x11 /* DW_AT_low_pc */
|
||||
+ .uleb128 0x1 /* DW_FORM_addr */
|
||||
+ .uleb128 0x12 /* DW_AT_high_pc */
|
||||
+ .uleb128 0x1 /* DW_FORM_addr */
|
||||
+ .byte 0x0 /* Terminator */
|
||||
+ .byte 0x0 /* Terminator */
|
||||
+
|
||||
+
|
||||
+ .uleb128 0x4 /* (abbrev code) */
|
||||
+ .uleb128 0x34 /* (TAG: DW_TAG_variable) */
|
||||
+ .byte 0x0 /* DW_children_yes */
|
||||
+ .uleb128 0x3 /* (DW_AT_name) */
|
||||
+ .uleb128 0x8 /* (DW_FORM_string) */
|
||||
+ .uleb128 0x02 /* (DW_AT_location) */
|
||||
+ .uleb128 0x3 /* (DW_FORM_block2) */
|
||||
+ .byte 0x0
|
||||
+ .byte 0x0
|
||||
+ .byte 0x0
|
||||
diff --git a/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp b/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp
|
||||
new file mode 100644
|
||||
index 0000000..7c3a404
|
||||
--- /dev/null
|
||||
+++ b/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp
|
||||
@@ -0,0 +1,32 @@
|
||||
+# Copyright 2015 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
+# it under the terms of the GNU General Public License as published by
|
||||
+# the Free Software Foundation; either version 3 of the License, or
|
||||
+# (at your option) any later version.
|
||||
+#
|
||||
+# This program is distributed in the hope that it will be useful,
|
||||
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+# GNU General Public License for more details.
|
||||
+#
|
||||
+# You should have received a copy of the GNU General Public License
|
||||
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
+load_lib dwarf.exp
|
||||
+
|
||||
+# This test can only be run on targets which support DWARF-2 and use gas.
|
||||
+if {![dwarf2_support]} {
|
||||
+ return 0
|
||||
+}
|
||||
+
|
||||
+standard_testfile .S main.c
|
||||
+
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile} ${srcdir}/${subdir}/${srcfile2}" \
|
||||
+ "${binfile}" executable {}] != "" } {
|
||||
+ return -1
|
||||
+}
|
||||
+
|
||||
+clean_restart ${binfile}
|
||||
+runto_main
|
||||
+
|
||||
+gdb_test "p variable"
|
||||
|
||||
--ibTvN161/egqYuK8--
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -52,11 +52,11 @@ Content-Type: text/x-patch
|
||||
Content-Transfer-Encoding: 7bit
|
||||
Content-Disposition: attachment; filename=bitpos-ensure-size_t.patch
|
||||
|
||||
Index: gdb-7.7.90.20140613/gdb/alpha-tdep.c
|
||||
Index: gdb-7.10.90.20160211/gdb/alpha-tdep.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/alpha-tdep.c 2014-06-13 22:14:49.725846383 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/alpha-tdep.c 2014-06-13 22:14:53.163850081 +0200
|
||||
@@ -414,6 +414,13 @@ alpha_push_dummy_call (struct gdbarch *g
|
||||
--- gdb-7.10.90.20160211.orig/gdb/alpha-tdep.c 2016-02-11 20:56:59.224850729 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/alpha-tdep.c 2016-02-11 20:57:05.385891225 +0100
|
||||
@@ -413,6 +413,13 @@
|
||||
accumulate_size = 0;
|
||||
else
|
||||
accumulate_size -= sizeof(arg_reg_buffer);
|
||||
@ -70,24 +70,24 @@ Index: gdb-7.7.90.20140613/gdb/alpha-tdep.c
|
||||
sp -= accumulate_size;
|
||||
|
||||
/* Keep sp aligned to a multiple of 16 as the ABI requires. */
|
||||
Index: gdb-7.7.90.20140613/gdb/cp-valprint.c
|
||||
Index: gdb-7.10.90.20160211/gdb/cp-valprint.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/cp-valprint.c 2014-06-13 22:14:49.725846383 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/cp-valprint.c 2014-06-13 22:14:53.164850081 +0200
|
||||
@@ -538,6 +538,8 @@ cp_print_value (struct type *type, struc
|
||||
--- gdb-7.10.90.20160211.orig/gdb/cp-valprint.c 2016-02-11 20:56:59.224850729 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/cp-valprint.c 2016-02-11 20:57:05.385891225 +0100
|
||||
@@ -536,6 +536,8 @@
|
||||
gdb_byte *buf;
|
||||
struct cleanup *back_to;
|
||||
|
||||
+ ulongest_fits_host_or_error (TYPE_LENGTH (baseclass));
|
||||
+
|
||||
buf = xmalloc (TYPE_LENGTH (baseclass));
|
||||
buf = (gdb_byte *) xmalloc (TYPE_LENGTH (baseclass));
|
||||
back_to = make_cleanup (xfree, buf);
|
||||
|
||||
Index: gdb-7.7.90.20140613/gdb/dwarf2loc.c
|
||||
Index: gdb-7.10.90.20160211/gdb/dwarf2loc.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/dwarf2loc.c 2014-06-13 22:14:49.726846384 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/dwarf2loc.c 2014-06-13 22:14:53.166850084 +0200
|
||||
@@ -1666,6 +1666,8 @@ read_pieced_value (struct value *v)
|
||||
--- gdb-7.10.90.20160211.orig/gdb/dwarf2loc.c 2016-02-11 20:56:59.225850736 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/dwarf2loc.c 2016-02-11 20:57:05.386891231 +0100
|
||||
@@ -1744,6 +1744,8 @@
|
||||
|
||||
this_size = (this_size_bits + source_offset_bits % 8 + 7) / 8;
|
||||
source_offset = source_offset_bits / 8;
|
||||
@ -96,7 +96,7 @@ Index: gdb-7.7.90.20140613/gdb/dwarf2loc.c
|
||||
if (buffer_size < this_size)
|
||||
{
|
||||
buffer_size = this_size;
|
||||
@@ -1857,6 +1859,7 @@ write_pieced_value (struct value *to, st
|
||||
@@ -1926,6 +1928,7 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -104,35 +104,35 @@ Index: gdb-7.7.90.20140613/gdb/dwarf2loc.c
|
||||
if (buffer_size < this_size)
|
||||
{
|
||||
buffer_size = this_size;
|
||||
Index: gdb-7.7.90.20140613/gdb/findcmd.c
|
||||
Index: gdb-7.10.90.20160211/gdb/findcmd.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/findcmd.c 2014-06-13 22:14:49.726846384 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/findcmd.c 2014-06-13 22:14:53.166850084 +0200
|
||||
@@ -185,6 +185,7 @@ parse_find_args (char *args, ULONGEST *m
|
||||
--- gdb-7.10.90.20160211.orig/gdb/findcmd.c 2016-02-11 20:56:59.226850742 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/findcmd.c 2016-02-11 20:57:05.387891238 +0100
|
||||
@@ -184,6 +184,7 @@
|
||||
size_t current_offset = pattern_buf_end - pattern_buf;
|
||||
|
||||
pattern_buf_size = pattern_buf_size_need * 2;
|
||||
+ ulongest_fits_host_or_error (pattern_buf_size);
|
||||
pattern_buf = xrealloc (pattern_buf, pattern_buf_size);
|
||||
pattern_buf = (gdb_byte *) xrealloc (pattern_buf, pattern_buf_size);
|
||||
pattern_buf_end = pattern_buf + current_offset;
|
||||
}
|
||||
Index: gdb-7.7.90.20140613/gdb/p-valprint.c
|
||||
Index: gdb-7.10.90.20160211/gdb/p-valprint.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/p-valprint.c 2014-06-13 22:14:49.728846387 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/p-valprint.c 2014-06-13 22:14:53.166850084 +0200
|
||||
@@ -772,6 +772,7 @@ pascal_object_print_value (struct type *
|
||||
--- gdb-7.10.90.20160211.orig/gdb/p-valprint.c 2016-02-11 20:56:59.226850742 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/p-valprint.c 2016-02-11 20:57:05.387891238 +0100
|
||||
@@ -769,6 +769,7 @@
|
||||
gdb_byte *buf;
|
||||
struct cleanup *back_to;
|
||||
|
||||
+ ulongest_fits_host_or_error (TYPE_LENGTH (baseclass));
|
||||
buf = xmalloc (TYPE_LENGTH (baseclass));
|
||||
buf = (gdb_byte *) xmalloc (TYPE_LENGTH (baseclass));
|
||||
back_to = make_cleanup (xfree, buf);
|
||||
|
||||
Index: gdb-7.7.90.20140613/gdb/utils.c
|
||||
Index: gdb-7.10.90.20160211/gdb/utils.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/utils.c 2014-06-13 22:14:53.166850084 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/utils.c 2014-06-13 22:15:16.839875341 +0200
|
||||
@@ -2838,6 +2838,18 @@ string_to_core_addr (const char *my_stri
|
||||
--- gdb-7.10.90.20160211.orig/gdb/utils.c 2016-02-11 20:56:59.227850749 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/utils.c 2016-02-11 20:57:05.388891244 +0100
|
||||
@@ -2837,6 +2837,18 @@
|
||||
return addr;
|
||||
}
|
||||
|
||||
@ -151,59 +151,52 @@ Index: gdb-7.7.90.20140613/gdb/utils.c
|
||||
char *
|
||||
gdb_realpath (const char *filename)
|
||||
{
|
||||
Index: gdb-7.7.90.20140613/gdb/valops.c
|
||||
Index: gdb-7.10.90.20160211/gdb/valops.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/valops.c 2014-06-13 22:14:49.730846389 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/valops.c 2014-06-13 22:14:53.169850088 +0200
|
||||
@@ -2074,6 +2074,7 @@ search_struct_method (const char *name,
|
||||
--- gdb-7.10.90.20160211.orig/gdb/valops.c 2016-02-11 20:56:59.228850755 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/valops.c 2016-02-11 20:57:05.389891251 +0100
|
||||
@@ -2057,6 +2057,7 @@
|
||||
struct cleanup *back_to;
|
||||
CORE_ADDR address;
|
||||
|
||||
+ ulongest_fits_host_or_error (TYPE_LENGTH (baseclass));
|
||||
tmp = xmalloc (TYPE_LENGTH (baseclass));
|
||||
tmp = (gdb_byte *) xmalloc (TYPE_LENGTH (baseclass));
|
||||
back_to = make_cleanup (xfree, tmp);
|
||||
address = value_address (*arg1p);
|
||||
Index: gdb-7.7.90.20140613/gdb/value.c
|
||||
Index: gdb-7.10.90.20160211/gdb/value.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/value.c 2014-06-13 22:14:49.732846391 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/value.c 2014-06-13 22:14:53.169850088 +0200
|
||||
@@ -824,6 +824,7 @@ allocate_value_lazy (struct type *type)
|
||||
--- gdb-7.10.90.20160211.orig/gdb/value.c 2016-02-11 20:56:59.229850762 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/value.c 2016-02-11 20:58:35.095480877 +0100
|
||||
@@ -935,6 +935,7 @@
|
||||
description correctly. */
|
||||
check_typedef (type);
|
||||
|
||||
+ ulongest_fits_host_or_error (TYPE_LENGTH (type));
|
||||
val = (struct value *) xzalloc (sizeof (struct value));
|
||||
val = XCNEW (struct value);
|
||||
val->contents = NULL;
|
||||
val->next = all_values;
|
||||
@@ -855,6 +856,8 @@ allocate_value_lazy (struct type *type)
|
||||
@@ -1034,6 +1035,8 @@
|
||||
static void
|
||||
allocate_value_contents (struct value *val)
|
||||
{
|
||||
+ ulongest_fits_host_or_error (TYPE_LENGTH (val->enclosing_type));
|
||||
+
|
||||
if (!val->contents)
|
||||
val->contents = (gdb_byte *) xzalloc (TYPE_LENGTH (val->enclosing_type));
|
||||
}
|
||||
@@ -2831,8 +2834,12 @@ void
|
||||
set_value_enclosing_type (struct value *val, struct type *new_encl_type)
|
||||
{
|
||||
if (TYPE_LENGTH (new_encl_type) > TYPE_LENGTH (value_enclosing_type (val)))
|
||||
- val->contents =
|
||||
- (gdb_byte *) xrealloc (val->contents, TYPE_LENGTH (new_encl_type));
|
||||
+ {
|
||||
{
|
||||
check_type_length_before_alloc (val->enclosing_type);
|
||||
@@ -3090,6 +3093,7 @@
|
||||
if (TYPE_LENGTH (new_encl_type) > TYPE_LENGTH (value_enclosing_type (val)))
|
||||
{
|
||||
check_type_length_before_alloc (new_encl_type);
|
||||
+ ulongest_fits_host_or_error (TYPE_LENGTH (new_encl_type));
|
||||
+
|
||||
+ val->contents =
|
||||
+ (gdb_byte *) xrealloc (val->contents, TYPE_LENGTH (new_encl_type));
|
||||
+ }
|
||||
|
||||
val->enclosing_type = new_encl_type;
|
||||
}
|
||||
Index: gdb-7.7.90.20140613/gdb/vax-tdep.c
|
||||
val->contents
|
||||
= (gdb_byte *) xrealloc (val->contents, TYPE_LENGTH (new_encl_type));
|
||||
}
|
||||
Index: gdb-7.10.90.20160211/gdb/vax-tdep.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/vax-tdep.c 2014-06-13 22:14:49.732846391 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/vax-tdep.c 2014-06-13 22:14:53.169850088 +0200
|
||||
@@ -223,6 +223,7 @@ vax_return_value (struct gdbarch *gdbarc
|
||||
--- gdb-7.10.90.20160211.orig/gdb/vax-tdep.c 2016-02-11 20:56:59.229850762 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/vax-tdep.c 2016-02-11 20:57:05.391891264 +0100
|
||||
@@ -219,6 +219,7 @@
|
||||
ULONGEST addr;
|
||||
|
||||
regcache_raw_read_unsigned (regcache, VAX_R0_REGNUM, &addr);
|
||||
@ -211,11 +204,11 @@ Index: gdb-7.7.90.20140613/gdb/vax-tdep.c
|
||||
read_memory (addr, readbuf, len);
|
||||
}
|
||||
|
||||
Index: gdb-7.7.90.20140613/gdb/defs.h
|
||||
Index: gdb-7.10.90.20160211/gdb/defs.h
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140613.orig/gdb/defs.h 2014-06-13 22:14:49.732846391 +0200
|
||||
+++ gdb-7.7.90.20140613/gdb/defs.h 2014-06-13 22:14:53.169850088 +0200
|
||||
@@ -756,4 +756,6 @@ enum block_enum
|
||||
--- gdb-7.10.90.20160211.orig/gdb/defs.h 2016-02-11 20:56:59.229850762 +0100
|
||||
+++ gdb-7.10.90.20160211/gdb/defs.h 2016-02-11 20:57:05.391891264 +0100
|
||||
@@ -690,4 +690,6 @@
|
||||
|
||||
#include "utils.h"
|
||||
|
||||
|
@ -96,11 +96,11 @@ Content-Type: text/x-patch
|
||||
Content-Transfer-Encoding: 7bit
|
||||
Content-Disposition: attachment; filename=bitpos-wp.patch
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/arm-linux-nat.c
|
||||
Index: gdb-7.10.50.20151027/gdb/arm-linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/arm-linux-nat.c 2015-01-05 22:10:30.170726774 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/arm-linux-nat.c 2015-01-05 22:10:35.571751324 +0100
|
||||
@@ -1295,7 +1295,7 @@ arm_linux_stopped_by_watchpoint (struct
|
||||
--- gdb-7.10.50.20151027.orig/gdb/arm-linux-nat.c 2015-11-08 10:36:33.050071812 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/arm-linux-nat.c 2015-11-08 10:36:33.094072110 +0100
|
||||
@@ -1209,7 +1209,7 @@ arm_linux_stopped_by_watchpoint (struct
|
||||
static int
|
||||
arm_linux_watchpoint_addr_within_range (struct target_ops *target,
|
||||
CORE_ADDR addr,
|
||||
@ -109,11 +109,11 @@ Index: gdb-7.8.50.20141228/gdb/arm-linux-nat.c
|
||||
{
|
||||
return start <= addr && start + length - 1 >= addr;
|
||||
}
|
||||
Index: gdb-7.8.50.20141228/gdb/ppc-linux-nat.c
|
||||
Index: gdb-7.10.50.20151027/gdb/ppc-linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/ppc-linux-nat.c 2015-01-05 22:10:30.171726779 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/ppc-linux-nat.c 2015-01-05 22:10:35.572751329 +0100
|
||||
@@ -1860,11 +1860,11 @@ can_use_watchpoint_cond_accel (void)
|
||||
--- gdb-7.10.50.20151027.orig/gdb/ppc-linux-nat.c 2015-11-08 10:36:33.064071907 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/ppc-linux-nat.c 2015-11-08 10:36:33.095072117 +0100
|
||||
@@ -1807,11 +1807,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.8.50.20141228/gdb/ppc-linux-nat.c
|
||||
CORE_ADDR addr_end_data, addr_end_dvc;
|
||||
|
||||
/* The DVC register compares bytes within fixed-length windows which
|
||||
@@ -1951,7 +1951,7 @@ num_memory_accesses (struct value *v)
|
||||
@@ -1898,7 +1898,7 @@ num_memory_accesses (struct value *v)
|
||||
of the constant. */
|
||||
static int
|
||||
check_condition (CORE_ADDR watch_addr, struct expression *cond,
|
||||
@ -137,7 +137,7 @@ Index: gdb-7.8.50.20141228/gdb/ppc-linux-nat.c
|
||||
{
|
||||
int pc = 1, num_accesses_left, num_accesses_right;
|
||||
struct value *left_val, *right_val, *left_chain, *right_chain;
|
||||
@@ -2019,7 +2019,7 @@ check_condition (CORE_ADDR watch_addr, s
|
||||
@@ -1966,7 +1966,7 @@ check_condition (CORE_ADDR watch_addr, s
|
||||
true. */
|
||||
static int
|
||||
ppc_linux_can_accel_watchpoint_condition (struct target_ops *self,
|
||||
@ -146,16 +146,16 @@ Index: gdb-7.8.50.20141228/gdb/ppc-linux-nat.c
|
||||
struct expression *cond)
|
||||
{
|
||||
CORE_ADDR data_value;
|
||||
@@ -2036,7 +2036,7 @@ ppc_linux_can_accel_watchpoint_condition
|
||||
@@ -1983,7 +1983,7 @@ ppc_linux_can_accel_watchpoint_condition
|
||||
|
||||
static void
|
||||
create_watchpoint_request (struct ppc_hw_breakpoint *p, CORE_ADDR addr,
|
||||
- int len, int rw, struct expression *cond,
|
||||
+ LONGEST len, int rw, struct expression *cond,
|
||||
int insert)
|
||||
- int len, enum target_hw_bp_type type,
|
||||
+ LONGEST len, enum target_hw_bp_type type,
|
||||
struct expression *cond, int insert)
|
||||
{
|
||||
if (len == 1
|
||||
@@ -2302,7 +2302,7 @@ ppc_linux_stopped_by_watchpoint (struct
|
||||
@@ -2249,7 +2249,7 @@ ppc_linux_stopped_by_watchpoint (struct
|
||||
static int
|
||||
ppc_linux_watchpoint_addr_within_range (struct target_ops *target,
|
||||
CORE_ADDR addr,
|
||||
@ -164,11 +164,11 @@ Index: gdb-7.8.50.20141228/gdb/ppc-linux-nat.c
|
||||
{
|
||||
int mask;
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/procfs.c
|
||||
Index: gdb-7.10.50.20151027/gdb/procfs.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/procfs.c 2015-01-05 22:10:30.172726783 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/procfs.c 2015-01-05 22:10:35.573751333 +0100
|
||||
@@ -2426,7 +2426,7 @@ procfs_address_to_host_pointer (CORE_ADD
|
||||
--- gdb-7.10.50.20151027.orig/gdb/procfs.c 2015-11-08 10:36:33.065071913 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/procfs.c 2015-11-08 10:36:33.096072123 +0100
|
||||
@@ -2427,7 +2427,7 @@ procfs_address_to_host_pointer (CORE_ADD
|
||||
#endif
|
||||
|
||||
static int
|
||||
@ -177,7 +177,7 @@ Index: gdb-7.8.50.20141228/gdb/procfs.c
|
||||
{
|
||||
#if !defined (PCWATCH) && !defined (PIOCSWATCH)
|
||||
/* If neither or these is defined, we can't support watchpoints.
|
||||
@@ -4705,7 +4705,7 @@ procfs_pid_to_str (struct target_ops *op
|
||||
@@ -4706,7 +4706,7 @@ procfs_pid_to_str (struct target_ops *op
|
||||
/* Insert a watchpoint. */
|
||||
|
||||
static int
|
||||
@ -186,11 +186,11 @@ Index: gdb-7.8.50.20141228/gdb/procfs.c
|
||||
int after)
|
||||
{
|
||||
#ifndef AIX5
|
||||
Index: gdb-7.8.50.20141228/gdb/remote.c
|
||||
Index: gdb-7.10.50.20151027/gdb/remote.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/remote.c 2015-01-05 22:10:30.174726792 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/remote.c 2015-01-05 22:10:35.574751338 +0100
|
||||
@@ -8298,7 +8298,7 @@ remote_insert_watchpoint (struct target_
|
||||
--- gdb-7.10.50.20151027.orig/gdb/remote.c 2015-11-08 10:36:33.067071927 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/remote.c 2015-11-08 10:36:33.097072130 +0100
|
||||
@@ -9085,7 +9085,7 @@ remote_insert_watchpoint (struct target_
|
||||
p = strchr (rs->buf, '\0');
|
||||
addr = remote_address_masked (addr);
|
||||
p += hexnumstr (p, (ULONGEST) addr);
|
||||
@ -199,7 +199,7 @@ Index: gdb-7.8.50.20141228/gdb/remote.c
|
||||
|
||||
putpkt (rs->buf);
|
||||
getpkt (&rs->buf, &rs->buf_size, 0);
|
||||
@@ -8318,7 +8318,7 @@ remote_insert_watchpoint (struct target_
|
||||
@@ -9105,7 +9105,7 @@ remote_insert_watchpoint (struct target_
|
||||
|
||||
static int
|
||||
remote_watchpoint_addr_within_range (struct target_ops *target, CORE_ADDR addr,
|
||||
@ -208,7 +208,7 @@ Index: gdb-7.8.50.20141228/gdb/remote.c
|
||||
{
|
||||
CORE_ADDR diff = remote_address_masked (addr - start);
|
||||
|
||||
@@ -8348,7 +8348,7 @@ remote_remove_watchpoint (struct target_
|
||||
@@ -9134,7 +9134,7 @@ remote_remove_watchpoint (struct target_
|
||||
p = strchr (rs->buf, '\0');
|
||||
addr = remote_address_masked (addr);
|
||||
p += hexnumstr (p, (ULONGEST) addr);
|
||||
@ -217,10 +217,10 @@ Index: gdb-7.8.50.20141228/gdb/remote.c
|
||||
putpkt (rs->buf);
|
||||
getpkt (&rs->buf, &rs->buf_size, 0);
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/target.c
|
||||
Index: gdb-7.10.50.20151027/gdb/target.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/target.c 2015-01-05 22:10:30.175726797 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/target.c 2015-01-05 22:10:35.575751342 +0100
|
||||
--- gdb-7.10.50.20151027.orig/gdb/target.c 2015-11-08 10:36:33.069071941 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/target.c 2015-11-08 10:36:33.098072137 +0100
|
||||
@@ -51,7 +51,7 @@ static void generic_tls_error (void) ATT
|
||||
static void default_terminal_info (struct target_ops *, const char *, int);
|
||||
|
||||
@ -230,7 +230,7 @@ Index: gdb-7.8.50.20141228/gdb/target.c
|
||||
|
||||
static int default_region_ok_for_hw_watchpoint (struct target_ops *,
|
||||
CORE_ADDR, LONGEST);
|
||||
@@ -2983,7 +2983,7 @@ default_region_ok_for_hw_watchpoint (str
|
||||
@@ -3140,7 +3140,7 @@ default_region_ok_for_hw_watchpoint (str
|
||||
static int
|
||||
default_watchpoint_addr_within_range (struct target_ops *target,
|
||||
CORE_ADDR addr,
|
||||
@ -239,11 +239,11 @@ Index: gdb-7.8.50.20141228/gdb/target.c
|
||||
{
|
||||
return addr >= start && addr < start + length;
|
||||
}
|
||||
Index: gdb-7.8.50.20141228/gdb/target.h
|
||||
Index: gdb-7.10.50.20151027/gdb/target.h
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/target.h 2015-01-05 22:10:30.176726802 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/target.h 2015-01-05 22:10:35.575751342 +0100
|
||||
@@ -483,7 +483,7 @@ struct target_ops
|
||||
--- gdb-7.10.50.20151027.orig/gdb/target.h 2015-11-08 10:36:33.069071941 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/target.h 2015-11-08 10:36:33.098072137 +0100
|
||||
@@ -543,7 +543,7 @@ struct target_ops
|
||||
int (*to_stopped_data_address) (struct target_ops *, CORE_ADDR *)
|
||||
TARGET_DEFAULT_RETURN (0);
|
||||
int (*to_watchpoint_addr_within_range) (struct target_ops *,
|
||||
@ -252,7 +252,7 @@ Index: gdb-7.8.50.20141228/gdb/target.h
|
||||
TARGET_DEFAULT_FUNC (default_watchpoint_addr_within_range);
|
||||
|
||||
/* Documentation of this routine is provided with the corresponding
|
||||
@@ -493,7 +493,7 @@ struct target_ops
|
||||
@@ -553,7 +553,7 @@ struct target_ops
|
||||
TARGET_DEFAULT_FUNC (default_region_ok_for_hw_watchpoint);
|
||||
|
||||
int (*to_can_accel_watchpoint_condition) (struct target_ops *,
|
||||
@ -261,80 +261,11 @@ Index: gdb-7.8.50.20141228/gdb/target.h
|
||||
struct expression *)
|
||||
TARGET_DEFAULT_RETURN (0);
|
||||
int (*to_masked_watch_num_registers) (struct target_ops *,
|
||||
Index: gdb-7.8.50.20141228/gdb/aarch64-linux-nat.c
|
||||
Index: gdb-7.10.50.20151027/gdb/aarch64-linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/aarch64-linux-nat.c 2015-01-05 22:10:30.176726802 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/aarch64-linux-nat.c 2015-01-05 22:10:35.575751342 +0100
|
||||
@@ -424,14 +424,14 @@ aarch64_notify_debug_reg_change (const s
|
||||
static void
|
||||
aarch64_show_debug_reg_state (struct aarch64_debug_reg_state *state,
|
||||
const char *func, CORE_ADDR addr,
|
||||
- int len, int type)
|
||||
+ LONGEST len, int type)
|
||||
{
|
||||
int i;
|
||||
|
||||
fprintf_unfiltered (gdb_stdlog, "%s", func);
|
||||
if (addr || len)
|
||||
- fprintf_unfiltered (gdb_stdlog, " (addr=0x%08lx, len=%d, type=%s)",
|
||||
- (unsigned long) addr, len,
|
||||
+ fprintf_unfiltered (gdb_stdlog, " (addr=0x%08lx, len=%s, type=%s)",
|
||||
+ (unsigned long) addr, plongest (len),
|
||||
type == hw_write ? "hw-write-watchpoint"
|
||||
: (type == hw_read ? "hw-read-watchpoint"
|
||||
: (type == hw_access ? "hw-access-watchpoint"
|
||||
@@ -851,9 +851,10 @@ aarch64_linux_read_description (struct t
|
||||
gdbserver/linux-aarch64-low.c for more information. */
|
||||
|
||||
static void
|
||||
-aarch64_align_watchpoint (CORE_ADDR addr, int len, CORE_ADDR *aligned_addr_p,
|
||||
+aarch64_align_watchpoint (CORE_ADDR addr, LONGEST len,
|
||||
+ CORE_ADDR *aligned_addr_p,
|
||||
int *aligned_len_p, CORE_ADDR *next_addr_p,
|
||||
- int *next_len_p)
|
||||
+ LONGEST *next_len_p)
|
||||
{
|
||||
int aligned_len;
|
||||
unsigned int offset;
|
||||
@@ -1020,7 +1021,7 @@ aarch64_point_encode_ctrl_reg (int type,
|
||||
Return 0 for any non-compliant ADDR and/or LEN; return 1 otherwise. */
|
||||
|
||||
static int
|
||||
-aarch64_point_is_aligned (int is_watchpoint, CORE_ADDR addr, int len)
|
||||
+aarch64_point_is_aligned (int is_watchpoint, CORE_ADDR addr, LONGEST len)
|
||||
{
|
||||
unsigned int alignment = is_watchpoint ? AARCH64_HWP_ALIGNMENT
|
||||
: AARCH64_HBP_ALIGNMENT;
|
||||
@@ -1272,7 +1273,7 @@ aarch64_handle_aligned_watchpoint (int t
|
||||
Return 0 if succeed. */
|
||||
|
||||
static int
|
||||
-aarch64_handle_unaligned_watchpoint (int type, CORE_ADDR addr, int len,
|
||||
+aarch64_handle_unaligned_watchpoint (int type, CORE_ADDR addr, LONGEST len,
|
||||
int is_insert)
|
||||
{
|
||||
struct aarch64_debug_reg_state *state
|
||||
@@ -1297,8 +1298,8 @@ aarch64_handle_unaligned_watchpoint (int
|
||||
fprintf_unfiltered (gdb_stdlog,
|
||||
"handle_unaligned_watchpoint: is_insert: %d\n"
|
||||
" aligned_addr: 0x%08lx, aligned_len: %d\n"
|
||||
-" next_addr: 0x%08lx, next_len: %d\n",
|
||||
- is_insert, aligned_addr, aligned_len, addr, len);
|
||||
+" next_addr: 0x%08lx, next_len: %s\n",
|
||||
+ is_insert, aligned_addr, aligned_len, addr, plongest (len));
|
||||
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
@@ -1310,7 +1311,7 @@ aarch64_handle_unaligned_watchpoint (int
|
||||
/* Implements insertion and removal of a single watchpoint. */
|
||||
|
||||
static int
|
||||
-aarch64_handle_watchpoint (int type, CORE_ADDR addr, int len, int is_insert)
|
||||
+aarch64_handle_watchpoint (int type, CORE_ADDR addr, LONGEST len, int is_insert)
|
||||
{
|
||||
if (aarch64_point_is_aligned (1 /* is_watchpoint */ , addr, len))
|
||||
return aarch64_handle_aligned_watchpoint (type, addr, len, is_insert);
|
||||
@@ -1479,7 +1480,7 @@ aarch64_linux_stopped_by_watchpoint (str
|
||||
--- gdb-7.10.50.20151027.orig/gdb/aarch64-linux-nat.c 2015-11-08 10:36:33.074071975 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/aarch64-linux-nat.c 2015-11-08 10:36:33.098072137 +0100
|
||||
@@ -795,7 +795,7 @@ aarch64_linux_stopped_by_watchpoint (str
|
||||
static int
|
||||
aarch64_linux_watchpoint_addr_within_range (struct target_ops *target,
|
||||
CORE_ADDR addr,
|
||||
@ -343,11 +274,11 @@ Index: gdb-7.8.50.20141228/gdb/aarch64-linux-nat.c
|
||||
{
|
||||
return start <= addr && start + length - 1 >= addr;
|
||||
}
|
||||
Index: gdb-7.8.50.20141228/gdb/target-delegates.c
|
||||
Index: gdb-7.10.50.20151027/gdb/target-delegates.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/target-delegates.c 2015-01-05 22:10:30.177726806 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/target-delegates.c 2015-01-05 22:12:11.071185408 +0100
|
||||
@@ -607,14 +607,14 @@ debug_stopped_data_address (struct targe
|
||||
--- gdb-7.10.50.20151027.orig/gdb/target-delegates.c 2015-11-08 10:36:33.073071968 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/target-delegates.c 2015-11-08 10:36:33.099072144 +0100
|
||||
@@ -709,14 +709,14 @@ debug_stopped_data_address (struct targe
|
||||
}
|
||||
|
||||
static int
|
||||
@ -364,7 +295,7 @@ Index: gdb-7.8.50.20141228/gdb/target-delegates.c
|
||||
{
|
||||
int result;
|
||||
fprintf_unfiltered (gdb_stdlog, "-> %s->to_watchpoint_addr_within_range (...)\n", debug_target.to_shortname);
|
||||
@@ -626,7 +626,7 @@ debug_watchpoint_addr_within_range (stru
|
||||
@@ -728,7 +728,7 @@ debug_watchpoint_addr_within_range (stru
|
||||
fputs_unfiltered (", ", gdb_stdlog);
|
||||
target_debug_print_CORE_ADDR (arg2);
|
||||
fputs_unfiltered (", ", gdb_stdlog);
|
||||
@ -373,7 +304,7 @@ Index: gdb-7.8.50.20141228/gdb/target-delegates.c
|
||||
fputs_unfiltered (") = ", gdb_stdlog);
|
||||
target_debug_print_int (result);
|
||||
fputs_unfiltered ("\n", gdb_stdlog);
|
||||
@@ -659,20 +659,20 @@ debug_region_ok_for_hw_watchpoint (struc
|
||||
@@ -761,20 +761,20 @@ debug_region_ok_for_hw_watchpoint (struc
|
||||
}
|
||||
|
||||
static int
|
||||
@ -397,7 +328,7 @@ Index: gdb-7.8.50.20141228/gdb/target-delegates.c
|
||||
{
|
||||
int result;
|
||||
fprintf_unfiltered (gdb_stdlog, "-> %s->to_can_accel_watchpoint_condition (...)\n", debug_target.to_shortname);
|
||||
@@ -682,7 +682,7 @@ debug_can_accel_watchpoint_condition (st
|
||||
@@ -784,7 +784,7 @@ debug_can_accel_watchpoint_condition (st
|
||||
fputs_unfiltered (", ", gdb_stdlog);
|
||||
target_debug_print_CORE_ADDR (arg1);
|
||||
fputs_unfiltered (", ", gdb_stdlog);
|
||||
@ -406,3 +337,99 @@ Index: gdb-7.8.50.20141228/gdb/target-delegates.c
|
||||
fputs_unfiltered (", ", gdb_stdlog);
|
||||
target_debug_print_int (arg3);
|
||||
fputs_unfiltered (", ", gdb_stdlog);
|
||||
Index: gdb-7.10.50.20151027/gdb/nat/aarch64-linux-hw-point.c
|
||||
===================================================================
|
||||
--- gdb-7.10.50.20151027.orig/gdb/nat/aarch64-linux-hw-point.c 2015-10-27 02:48:31.000000000 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/nat/aarch64-linux-hw-point.c 2015-11-08 10:36:33.099072144 +0100
|
||||
@@ -111,7 +111,7 @@ aarch64_point_encode_ctrl_reg (enum targ
|
||||
Return 0 for any non-compliant ADDR and/or LEN; return 1 otherwise. */
|
||||
|
||||
static int
|
||||
-aarch64_point_is_aligned (int is_watchpoint, CORE_ADDR addr, int len)
|
||||
+aarch64_point_is_aligned (int is_watchpoint, CORE_ADDR addr, LONGEST len)
|
||||
{
|
||||
unsigned int alignment = 0;
|
||||
|
||||
@@ -180,9 +180,10 @@ aarch64_point_is_aligned (int is_watchpo
|
||||
limitations can be largely relaxed with some further work. */
|
||||
|
||||
static void
|
||||
-aarch64_align_watchpoint (CORE_ADDR addr, int len, CORE_ADDR *aligned_addr_p,
|
||||
+aarch64_align_watchpoint (CORE_ADDR addr, LONGEST len,
|
||||
+ CORE_ADDR *aligned_addr_p,
|
||||
int *aligned_len_p, CORE_ADDR *next_addr_p,
|
||||
- int *next_len_p)
|
||||
+ LONGEST *next_len_p)
|
||||
{
|
||||
int aligned_len;
|
||||
unsigned int offset;
|
||||
@@ -494,7 +495,7 @@ aarch64_handle_aligned_watchpoint (enum
|
||||
|
||||
static int
|
||||
aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type,
|
||||
- CORE_ADDR addr, int len, int is_insert,
|
||||
+ CORE_ADDR addr, LONGEST len, int is_insert,
|
||||
struct aarch64_debug_reg_state *state)
|
||||
{
|
||||
while (len > 0)
|
||||
@@ -517,9 +518,9 @@ aarch64_handle_unaligned_watchpoint (enu
|
||||
" "
|
||||
"aligned_addr: %s, aligned_len: %d\n"
|
||||
" "
|
||||
- "next_addr: %s, next_len: %d\n",
|
||||
+ "next_addr: %s, next_len: %s\n",
|
||||
is_insert, core_addr_to_string_nz (aligned_addr),
|
||||
- aligned_len, core_addr_to_string_nz (addr), len);
|
||||
+ aligned_len, core_addr_to_string_nz (addr), plongest (len));
|
||||
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
@@ -530,7 +531,7 @@ aarch64_handle_unaligned_watchpoint (enu
|
||||
|
||||
int
|
||||
aarch64_handle_watchpoint (enum target_hw_bp_type type, CORE_ADDR addr,
|
||||
- int len, int is_insert,
|
||||
+ LONGEST len, int is_insert,
|
||||
struct aarch64_debug_reg_state *state)
|
||||
{
|
||||
if (aarch64_point_is_aligned (1 /* is_watchpoint */ , addr, len))
|
||||
@@ -581,14 +582,14 @@ aarch64_linux_set_debug_regs (const stru
|
||||
void
|
||||
aarch64_show_debug_reg_state (struct aarch64_debug_reg_state *state,
|
||||
const char *func, CORE_ADDR addr,
|
||||
- int len, enum target_hw_bp_type type)
|
||||
+ LONGEST len, enum target_hw_bp_type type)
|
||||
{
|
||||
int i;
|
||||
|
||||
debug_printf ("%s", func);
|
||||
if (addr || len)
|
||||
- debug_printf (" (addr=0x%08lx, len=%d, type=%s)",
|
||||
- (unsigned long) addr, len,
|
||||
+ debug_printf (" (addr=0x%08lx, len=%s, type=%s)",
|
||||
+ (unsigned long) addr, plongest (len),
|
||||
type == hw_write ? "hw-write-watchpoint"
|
||||
: (type == hw_read ? "hw-read-watchpoint"
|
||||
: (type == hw_access ? "hw-access-watchpoint"
|
||||
Index: gdb-7.10.50.20151027/gdb/nat/aarch64-linux-hw-point.h
|
||||
===================================================================
|
||||
--- gdb-7.10.50.20151027.orig/gdb/nat/aarch64-linux-hw-point.h 2015-10-27 02:48:31.000000000 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/nat/aarch64-linux-hw-point.h 2015-11-08 10:36:47.656170839 +0100
|
||||
@@ -168,7 +168,7 @@ int aarch64_handle_breakpoint (enum targ
|
||||
int len, int is_insert,
|
||||
struct aarch64_debug_reg_state *state);
|
||||
int aarch64_handle_watchpoint (enum target_hw_bp_type type, CORE_ADDR addr,
|
||||
- int len, int is_insert,
|
||||
+ LONGEST len, int is_insert,
|
||||
struct aarch64_debug_reg_state *state);
|
||||
|
||||
void aarch64_linux_set_debug_regs (const struct aarch64_debug_reg_state *state,
|
||||
@@ -176,7 +176,7 @@ void aarch64_linux_set_debug_regs (const
|
||||
|
||||
void aarch64_show_debug_reg_state (struct aarch64_debug_reg_state *state,
|
||||
const char *func, CORE_ADDR addr,
|
||||
- int len, enum target_hw_bp_type type);
|
||||
+ LONGEST len, enum target_hw_bp_type type);
|
||||
|
||||
void aarch64_linux_get_debug_reg_capacity (int tid);
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -47,10 +47,10 @@ Content-Type: text/x-patch
|
||||
Content-Transfer-Encoding: 7bit
|
||||
Content-Disposition: attachment; filename=f77-bounds.patch
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/f-lang.h
|
||||
Index: gdb-7.10.50.20151027/gdb/f-lang.h
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/f-lang.h 2015-01-06 22:46:31.620852996 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/f-lang.h 2015-01-06 22:46:34.190865466 +0100
|
||||
--- gdb-7.10.50.20151027.orig/gdb/f-lang.h 2015-11-02 21:25:14.233161097 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/f-lang.h 2015-11-02 21:25:22.404214860 +0100
|
||||
@@ -62,9 +62,9 @@ struct common_block
|
||||
struct symbol *contents[1];
|
||||
};
|
||||
@ -63,11 +63,11 @@ Index: gdb-7.8.50.20141228/gdb/f-lang.h
|
||||
|
||||
extern void f77_get_dynamic_array_length (struct type *);
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/f-typeprint.c
|
||||
Index: gdb-7.10.50.20151027/gdb/f-typeprint.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/f-typeprint.c 2015-01-06 22:46:31.621853001 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/f-typeprint.c 2015-01-06 22:47:03.731008798 +0100
|
||||
@@ -158,7 +158,7 @@ f_type_print_varspec_suffix (struct type
|
||||
--- gdb-7.10.50.20151027.orig/gdb/f-typeprint.c 2015-11-02 21:25:14.234161104 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/f-typeprint.c 2015-11-02 21:25:22.404214860 +0100
|
||||
@@ -171,7 +171,7 @@ f_type_print_varspec_suffix (struct type
|
||||
int show, int passed_a_ptr, int demangled_args,
|
||||
int arrayprint_recurse_level)
|
||||
{
|
||||
@ -76,7 +76,7 @@ Index: gdb-7.8.50.20141228/gdb/f-typeprint.c
|
||||
|
||||
/* No static variables are permitted as an error call may occur during
|
||||
execution of this function. */
|
||||
@@ -192,7 +192,7 @@ f_type_print_varspec_suffix (struct type
|
||||
@@ -204,7 +204,7 @@ f_type_print_varspec_suffix (struct type
|
||||
|
||||
lower_bound = f77_get_lowerbound (type);
|
||||
if (lower_bound != 1) /* Not the default. */
|
||||
@ -85,7 +85,7 @@ Index: gdb-7.8.50.20141228/gdb/f-typeprint.c
|
||||
|
||||
/* Make sure that, if we have an assumed size array, we
|
||||
print out a warning and print the upperbound as '*'. */
|
||||
@@ -202,7 +202,7 @@ f_type_print_varspec_suffix (struct type
|
||||
@@ -214,7 +214,7 @@ f_type_print_varspec_suffix (struct type
|
||||
else
|
||||
{
|
||||
upper_bound = f77_get_upperbound (type);
|
||||
@ -94,7 +94,7 @@ Index: gdb-7.8.50.20141228/gdb/f-typeprint.c
|
||||
}
|
||||
|
||||
if (TYPE_CODE (TYPE_TARGET_TYPE (type)) != TYPE_CODE_ARRAY)
|
||||
@@ -271,7 +271,7 @@ void
|
||||
@@ -283,7 +283,7 @@ void
|
||||
f_type_print_base (struct type *type, struct ui_file *stream, int show,
|
||||
int level)
|
||||
{
|
||||
@ -103,7 +103,7 @@ Index: gdb-7.8.50.20141228/gdb/f-typeprint.c
|
||||
int index;
|
||||
|
||||
QUIT;
|
||||
@@ -353,7 +353,7 @@ f_type_print_base (struct type *type, st
|
||||
@@ -365,7 +365,7 @@ f_type_print_base (struct type *type, st
|
||||
else
|
||||
{
|
||||
upper_bound = f77_get_upperbound (type);
|
||||
@ -112,10 +112,10 @@ Index: gdb-7.8.50.20141228/gdb/f-typeprint.c
|
||||
}
|
||||
break;
|
||||
|
||||
Index: gdb-7.8.50.20141228/gdb/f-valprint.c
|
||||
Index: gdb-7.10.50.20151027/gdb/f-valprint.c
|
||||
===================================================================
|
||||
--- gdb-7.8.50.20141228.orig/gdb/f-valprint.c 2015-01-06 22:46:31.621853001 +0100
|
||||
+++ gdb-7.8.50.20141228/gdb/f-valprint.c 2015-01-06 22:46:34.191865471 +0100
|
||||
--- gdb-7.10.50.20151027.orig/gdb/f-valprint.c 2015-11-02 21:25:14.234161104 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/f-valprint.c 2015-11-02 21:25:22.405214867 +0100
|
||||
@@ -43,7 +43,7 @@ LONGEST f77_array_offset_tbl[MAX_FORTRAN
|
||||
/* Array which holds offsets to be applied to get a row's elements
|
||||
for a given array. Array also holds the size of each subarray. */
|
||||
|
@ -1,15 +1,19 @@
|
||||
--- gdb-7.5.0.20120926-m64/gdb/value.c-orig 2012-11-09 17:08:52.137406118 +0100
|
||||
+++ gdb-7.5.0.20120926-m64/gdb/value.c 2012-11-09 17:32:38.324199230 +0100
|
||||
@@ -663,7 +663,6 @@ allocate_value_lazy (struct type *type)
|
||||
Index: gdb-7.10.50.20151022/gdb/value.c
|
||||
===================================================================
|
||||
--- gdb-7.10.50.20151022.orig/gdb/value.c 2015-10-24 23:17:04.042143628 +0200
|
||||
+++ gdb-7.10.50.20151022/gdb/value.c 2015-10-24 23:17:27.687300689 +0200
|
||||
@@ -934,7 +934,6 @@ allocate_value_lazy (struct type *type)
|
||||
description correctly. */
|
||||
check_typedef (type);
|
||||
|
||||
- ulongest_fits_host_or_error (TYPE_LENGTH (type));
|
||||
val = (struct value *) xzalloc (sizeof (struct value));
|
||||
val = XCNEW (struct value);
|
||||
val->contents = NULL;
|
||||
val->next = all_values;
|
||||
--- /dev/null 2012-10-18 11:08:13.202328239 +0200
|
||||
+++ gdb-7.5.0.20120926-m64-test/gdb/testsuite/gdb.base/longest-types-64bit.exp 2012-11-09 18:13:56.286587994 +0100
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.exp 2015-10-24 23:17:04.042143628 +0200
|
||||
@@ -0,0 +1,59 @@
|
||||
+# This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -70,8 +74,10 @@
|
||||
+}
|
||||
+
|
||||
+test "native"
|
||||
--- /dev/null 2012-10-18 11:08:13.202328239 +0200
|
||||
+++ ./gdb/testsuite/gdb.base/longest-types-64bit.c 2012-11-09 17:08:51.374406344 +0100
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.c 2015-10-24 23:17:04.042143628 +0200
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -101,8 +107,10 @@
|
||||
+{
|
||||
+ return 0;
|
||||
+}
|
||||
--- /dev/null 2012-10-18 11:08:13.202328239 +0200
|
||||
+++ ./gdb/testsuite/gdb.base/longest-types-64bit.S 2012-11-09 17:51:37.597846130 +0100
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.S
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.S 2015-10-24 23:17:04.042143628 +0200
|
||||
@@ -0,0 +1,249 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -353,8 +361,10 @@
|
||||
+ .string "char"
|
||||
+ .ident "GCC: (GNU) 4.7.3 20121109 (prerelease)"
|
||||
+ .section .note.GNU-stack,"",@progbits
|
||||
--- /dev/null 2012-10-18 11:08:13.202328239 +0200
|
||||
+++ gdb-7.5.0.20120926-m64-test/gdb/testsuite/gdb.base/longest-types-64bit.bz2.uu 2012-11-09 18:04:52.995692771 +0100
|
||||
Index: gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.bz2.uu
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.50.20151022/gdb/testsuite/gdb.base/longest-types-64bit.bz2.uu 2015-10-24 23:17:04.042143628 +0200
|
||||
@@ -0,0 +1,67 @@
|
||||
+begin 755 gdb.base/longest-types-64bit.bz2
|
||||
+M0EIH.3%!62936<'N#OH`"G/________^______?_Y______//]7SQD5'^/_%
|
||||
|
@ -1,7 +1,7 @@
|
||||
Index: gdb-7.5.91.20130407/gdb/testsuite/gdb.threads/tls-rhbz947564.cc
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-rhbz947564.cc
|
||||
===================================================================
|
||||
--- /dev/null
|
||||
+++ gdb-7.5.91.20130407/gdb/testsuite/gdb.threads/tls-rhbz947564.cc
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-rhbz947564.cc 2016-02-15 23:39:21.791458927 +0100
|
||||
@@ -0,0 +1,53 @@
|
||||
+#include <iostream>
|
||||
+#include <pthread.h>
|
||||
@ -56,10 +56,10 @@ Index: gdb-7.5.91.20130407/gdb/testsuite/gdb.threads/tls-rhbz947564.cc
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
Index: gdb-7.5.91.20130407/gdb/testsuite/gdb.threads/tls-rhbz947564.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-rhbz947564.exp
|
||||
===================================================================
|
||||
--- /dev/null
|
||||
+++ gdb-7.5.91.20130407/gdb/testsuite/gdb.threads/tls-rhbz947564.exp
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/tls-rhbz947564.exp 2016-02-15 23:39:30.029517418 +0100
|
||||
@@ -0,0 +1,75 @@
|
||||
+# Copyright (C) 2013 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -78,7 +78,7 @@ Index: gdb-7.5.91.20130407/gdb/testsuite/gdb.threads/tls-rhbz947564.exp
|
||||
+
|
||||
+set testfile tls-rhbz947564
|
||||
+set srcfile ${testfile}.cc
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if [istarget "*-*-linux"] then {
|
||||
+ set target_cflags "-D_MIT_POSIX_THREADS"
|
||||
|
@ -1,29 +0,0 @@
|
||||
Index: gdb-7.7/gdb/linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-7.7.orig/gdb/linux-nat.c 2014-02-09 19:18:24.048554459 +0100
|
||||
+++ gdb-7.7/gdb/linux-nat.c 2014-02-09 19:19:22.210622806 +0100
|
||||
@@ -1529,8 +1529,22 @@ get_pending_status (struct lwp_info *lp,
|
||||
gdb_signal_to_string (signo));
|
||||
}
|
||||
|
||||
- if (*status == 0 && ptid_get_pid (lp->ptid) == pid_was_stopped)
|
||||
- *status = W_STOPCODE (SIGSTOP);
|
||||
+ /* Workaround RHEL-5 kernel which has unreliable PTRACE_DETACH, SIGSTOP (that
|
||||
+ many TIDs are left unstopped). See RH Bug 496732. */
|
||||
+ if (ptid_get_pid (lp->ptid) == pid_was_stopped)
|
||||
+ {
|
||||
+ int err;
|
||||
+
|
||||
+ errno = 0;
|
||||
+ err = kill_lwp (ptid_get_lwp (lp->ptid), SIGSTOP);
|
||||
+ if (debug_linux_nat)
|
||||
+ {
|
||||
+ fprintf_unfiltered (gdb_stdlog,
|
||||
+ "SC: lwp kill %d %s\n",
|
||||
+ err,
|
||||
+ errno ? safe_strerror (errno) : "ERRNO-OK");
|
||||
+ }
|
||||
+ }
|
||||
|
||||
return 0;
|
||||
}
|
@ -1,5 +1,7 @@
|
||||
--- /dev/null 2009-09-25 12:44:54.497650251 +0200
|
||||
+++ ./gdb/testsuite/gdb.threads/simultaneous-step-resume-breakpoint.exp 2009-09-25 17:27:12.000000000 +0200
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/simultaneous-step-resume-breakpoint.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/simultaneous-step-resume-breakpoint.exp 2016-02-15 23:38:23.366044101 +0100
|
||||
@@ -0,0 +1,65 @@
|
||||
+# Copyright (C) 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -21,7 +23,7 @@
|
||||
+
|
||||
+set testfile simultaneous-step-resume-breakpoint
|
||||
+set srcfile ${testfile}.c
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+
|
||||
+if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
|
||||
+ return -1
|
||||
@ -66,8 +68,10 @@
|
||||
+
|
||||
+gdb_test "continue" "sleep-after.*" "second continue"
|
||||
+gdb_test "continue" "final-exit.*" "third continue"
|
||||
--- /dev/null 2009-09-25 12:44:54.497650251 +0200
|
||||
+++ ./gdb/testsuite/gdb.threads/simultaneous-step-resume-breakpoint.c 2009-09-25 17:29:42.000000000 +0200
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/simultaneous-step-resume-breakpoint.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.threads/simultaneous-step-resume-breakpoint.c 2016-02-15 23:38:18.257007826 +0100
|
||||
@@ -0,0 +1,79 @@
|
||||
+/* Copyright 2009 Free Software Foundation, Inc.
|
||||
+
|
||||
|
@ -70,10 +70,10 @@ gdb/testsuite/
|
||||
create mode 100644 gdb/testsuite/gdb.base/cfi-without-die-main.c
|
||||
create mode 100644 gdb/testsuite/gdb.base/cfi-without-die.exp
|
||||
|
||||
Index: gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die-caller.c
|
||||
Index: gdb-7.10.50.20160106/gdb/testsuite/gdb.base/cfi-without-die-caller.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die-caller.c 2014-02-06 19:35:23.485863819 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/gdb.base/cfi-without-die-caller.c 2016-01-08 21:10:15.498079587 +0100
|
||||
@@ -0,0 +1,28 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -103,10 +103,10 @@ Index: gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die-caller.c
|
||||
+ /* Modify the return value to prevent any tail-call optimization. */
|
||||
+ return (*callback) () - one;
|
||||
+}
|
||||
Index: gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die-main.c
|
||||
Index: gdb-7.10.50.20160106/gdb/testsuite/gdb.base/cfi-without-die-main.c
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die-main.c 2014-02-06 19:35:23.485863819 +0100
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/gdb.base/cfi-without-die-main.c 2016-01-08 21:10:15.498079587 +0100
|
||||
@@ -0,0 +1,32 @@
|
||||
+/* This testcase is part of GDB, the GNU debugger.
|
||||
+
|
||||
@ -140,11 +140,11 @@ Index: gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die-main.c
|
||||
+{
|
||||
+ return caller (callback);
|
||||
+}
|
||||
Index: gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die.exp
|
||||
Index: gdb-7.10.50.20160106/gdb/testsuite/gdb.base/cfi-without-die.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die.exp 2014-02-06 20:26:00.775208847 +0100
|
||||
@@ -0,0 +1,67 @@
|
||||
+++ gdb-7.10.50.20160106/gdb/testsuite/gdb.base/cfi-without-die.exp 2016-01-08 21:13:04.529998009 +0100
|
||||
@@ -0,0 +1,71 @@
|
||||
+# Copyright 2010 Free Software Foundation, Inc.
|
||||
+
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
@ -186,6 +186,10 @@ Index: gdb-7.7/gdb/testsuite/gdb.base/cfi-without-die.exp
|
||||
+}
|
||||
+set test "verify unwinding breaks without CFI"
|
||||
+gdb_test_multiple "bt" $test {
|
||||
+ -re " in \[?\]\[?\] .*\r\n$gdb_prompt $" {
|
||||
+ # It may backtrace through some random frames even to main().
|
||||
+ pass $test
|
||||
+ }
|
||||
+ -re " in main .*\r\n$gdb_prompt $" {
|
||||
+ fail $test
|
||||
+ }
|
||||
|
@ -1,8 +1,10 @@
|
||||
archer archer-keiths-expr-cumulative
|
||||
b5a7497340b24199f0c7ba7fdf0d54d4df44d6bc
|
||||
|
||||
--- /dev/null 2011-01-12 06:28:36.282000001 +0100
|
||||
+++ ./gdb/testsuite/gdb.cp/namespace-nested-imports.cc 2009-09-25 06:50:38.000000000 +0200
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-nested-imports.cc
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-nested-imports.cc 2016-02-15 23:34:32.196402773 +0100
|
||||
@@ -0,0 +1,36 @@
|
||||
+namespace A
|
||||
+{
|
||||
@ -40,8 +42,10 @@ b5a7497340b24199f0c7ba7fdf0d54d4df44d6bc
|
||||
+ //ab;
|
||||
+ return C::first();
|
||||
+}
|
||||
--- /dev/null 2011-01-12 06:28:36.282000001 +0100
|
||||
+++ ./gdb/testsuite/gdb.cp/namespace-nested-imports.exp 2009-09-25 06:50:38.000000000 +0200
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-nested-imports.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-nested-imports.exp 2016-02-15 23:34:51.926542859 +0100
|
||||
@@ -0,0 +1,50 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -60,7 +64,7 @@ b5a7497340b24199f0c7ba7fdf0d54d4df44d6bc
|
||||
+
|
||||
+set testfile namespace-nested-imports
|
||||
+set srcfile ${testfile}.cc
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
@ -93,8 +97,10 @@ b5a7497340b24199f0c7ba7fdf0d54d4df44d6bc
|
||||
+gdb_continue_to_breakpoint "C::D::second"
|
||||
+
|
||||
+gdb_test "print ab" "= 11"
|
||||
--- /dev/null 2011-01-12 06:28:36.282000001 +0100
|
||||
+++ ./gdb/testsuite/gdb.cp/namespace-no-imports.cc 2009-09-25 06:50:38.000000000 +0200
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-no-imports.cc
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-no-imports.cc 2016-02-15 23:34:32.196402773 +0100
|
||||
@@ -0,0 +1,37 @@
|
||||
+
|
||||
+namespace A
|
||||
@ -133,8 +139,10 @@ b5a7497340b24199f0c7ba7fdf0d54d4df44d6bc
|
||||
+ A::B::C::abc;
|
||||
+ return A::B::first();
|
||||
+}
|
||||
--- /dev/null 2011-01-12 06:28:36.282000001 +0100
|
||||
+++ ./gdb/testsuite/gdb.cp/namespace-no-imports.exp 2009-09-25 06:50:38.000000000 +0200
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-no-imports.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.cp/namespace-no-imports.exp 2016-02-15 23:34:51.926542859 +0100
|
||||
@@ -0,0 +1,69 @@
|
||||
+# Copyright 2008 Free Software Foundation, Inc.
|
||||
+
|
||||
@ -153,7 +161,7 @@ b5a7497340b24199f0c7ba7fdf0d54d4df44d6bc
|
||||
+
|
||||
+set testfile namespace-no-imports
|
||||
+set srcfile ${testfile}.cc
|
||||
+set binfile ${objdir}/${subdir}/${testfile}
|
||||
+set binfile [standard_output_file ${testfile}]
|
||||
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}] != "" } {
|
||||
+ untested "Couldn't compile test program"
|
||||
+ return -1
|
||||
|
@ -6,10 +6,10 @@ http://sourceware.org/ml/gdb-patches/2010-08/msg00085.html
|
||||
http://sourceware.org/ml/gdb-cvs/2010-08/msg00026.html
|
||||
2e5bcfdef1ec3883d48c3f87a4be5c0dff25e17e
|
||||
|
||||
Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.arch/x86_64-pid0-core.core.bz2.uu
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-pid0-core.core.bz2.uu
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.arch/x86_64-pid0-core.core.bz2.uu 2013-08-02 22:14:50.748990883 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-pid0-core.core.bz2.uu 2016-02-15 23:23:40.772772165 +0100
|
||||
@@ -0,0 +1,20 @@
|
||||
+begin 600 x86_64-pid0-core.core.bz2
|
||||
+M0EIH.3%!629362,CA>P!$/'_____^*#EZ-A!SP36P&_:G0#=14``04A&8,'U
|
||||
@ -31,10 +31,10 @@ Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.arch/x86_64-pid0-core.core.bz2.
|
||||
+4B.Z!/,0-IZ^W_Q=R13A0D",CA>P`
|
||||
+`
|
||||
+end
|
||||
Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.arch/x86_64-pid0-core.exp
|
||||
Index: gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-pid0-core.exp
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.arch/x86_64-pid0-core.exp 2013-08-02 22:17:30.575209385 +0200
|
||||
+++ gdb-7.10.90.20160211/gdb/testsuite/gdb.arch/x86_64-pid0-core.exp 2016-02-15 23:23:55.145875704 +0100
|
||||
@@ -0,0 +1,46 @@
|
||||
+# This testcase is part of GDB, the GNU debugger.
|
||||
+#
|
||||
@ -63,7 +63,7 @@ Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.arch/x86_64-pid0-core.exp
|
||||
+
|
||||
+set testfile "x86_64-pid0-core"
|
||||
+set corebz2uufile ${srcdir}/${subdir}/${testfile}.core.bz2.uu
|
||||
+set corefile ${objdir}/${subdir}/${testfile}.core
|
||||
+set corefile [standard_output_file ${testfile}.core]
|
||||
+
|
||||
+if {[catch "system \"uudecode -o - ${corebz2uufile} | bzip2 -dc >${corefile}\""] != 0} {
|
||||
+ untested "failed uudecode or bzip2"
|
||||
|
39
gdb-testsuite-readline63-sigint.patch
Normal file
39
gdb-testsuite-readline63-sigint.patch
Normal file
@ -0,0 +1,39 @@
|
||||
gdb/users/ppalka/readline-7.0-update
|
||||
commit 379059215e823555a37a8dc7e02cef8fd86566e4
|
||||
https://sourceware.org/ml/gdb-patches/2015-07/msg00422.html
|
||||
Message-Id: <1436927724-4059-1-git-send-email-patrick@parcs.ath.cx>
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=1301175
|
||||
|
||||
Index: gdb-7.10.50.20160131/gdb/testsuite/gdb.gdb/selftest.exp
|
||||
===================================================================
|
||||
--- gdb-7.10.50.20160131.orig/gdb/testsuite/gdb.gdb/selftest.exp 2016-01-31 19:44:47.156963419 +0100
|
||||
+++ gdb-7.10.50.20160131/gdb/testsuite/gdb.gdb/selftest.exp 2016-01-31 19:45:11.245135173 +0100
|
||||
@@ -458,9 +458,25 @@
|
||||
}
|
||||
|
||||
set description "send SIGINT signal to child process"
|
||||
- gdb_test "signal SIGINT" \
|
||||
- "Continuing with signal SIGINT.*" \
|
||||
- "$description"
|
||||
+ gdb_test_multiple "signal SIGINT" "$description" {
|
||||
+ -re "^signal SIGINT\r\nContinuing with signal SIGINT.\r\nQuit\r\n" {
|
||||
+ pass "$description"
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ set description "send ^C to child process again"
|
||||
+ send_gdb "\003"
|
||||
+ gdb_expect {
|
||||
+ -re "(Thread .*|Program) received signal SIGINT.*$gdb_prompt $" {
|
||||
+ pass "$description"
|
||||
+ }
|
||||
+ -re ".*$gdb_prompt $" {
|
||||
+ fail "$description"
|
||||
+ }
|
||||
+ timeout {
|
||||
+ fail "$description (timeout)"
|
||||
+ }
|
||||
+ }
|
||||
|
||||
# Switch back to the GDB thread if Guile support is linked in.
|
||||
# "signal SIGINT" could also switch the current thread.
|
@ -1,38 +1,38 @@
|
||||
Re: [PATCH 04/23] vla: make dynamic fortran arrays functional.
|
||||
https://sourceware.org/ml/gdb-patches/2014-06/msg00570.html
|
||||
|
||||
Index: gdb-7.7.90.20140627/gdb/valarith.c
|
||||
Index: gdb-7.10.50.20151027/gdb/valarith.c
|
||||
===================================================================
|
||||
--- gdb-7.7.90.20140627.orig/gdb/valarith.c 2014-07-07 20:44:03.136394525 +0200
|
||||
+++ gdb-7.7.90.20140627/gdb/valarith.c 2014-07-07 20:45:41.588536459 +0200
|
||||
@@ -195,10 +195,17 @@ value_subscripted_rvalue (struct value *
|
||||
--- gdb-7.10.50.20151027.orig/gdb/valarith.c 2015-11-03 20:41:48.543504999 +0100
|
||||
+++ gdb-7.10.50.20151027/gdb/valarith.c 2015-11-03 20:46:36.995238888 +0100
|
||||
@@ -193,10 +193,17 @@ value_subscripted_rvalue (struct value *
|
||||
struct type *array_type = check_typedef (value_type (array));
|
||||
struct type *elt_type = check_typedef (TYPE_TARGET_TYPE (array_type));
|
||||
unsigned int elt_size = TYPE_LENGTH (elt_type);
|
||||
unsigned int elt_size = type_length_units (elt_type);
|
||||
- unsigned int elt_offs = longest_to_int (index - lowerbound);
|
||||
+ unsigned int elt_offs;
|
||||
LONGEST elt_stride = TYPE_BYTE_STRIDE (TYPE_INDEX_TYPE (array_type));
|
||||
struct value *v;
|
||||
|
||||
+ if (TYPE_NOT_ASSOCIATED (array_type))
|
||||
+ error (_("no such vector element because not associated"));
|
||||
+ error (_("no such vector element (vector not associated)"));
|
||||
+ if (TYPE_NOT_ALLOCATED (array_type))
|
||||
+ error (_("no such vector element because not allocated"));
|
||||
+ error (_("no such vector element (vector not allocated)"));
|
||||
+
|
||||
+ elt_offs = longest_to_int (index - lowerbound);
|
||||
+
|
||||
if (elt_stride > 0)
|
||||
elt_offs *= elt_stride;
|
||||
else if (elt_stride < 0)
|
||||
@@ -212,14 +219,7 @@ value_subscripted_rvalue (struct value *
|
||||
@@ -210,14 +217,7 @@ value_subscripted_rvalue (struct value *
|
||||
|
||||
if (index < lowerbound || (!TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)
|
||||
&& elt_offs >= TYPE_LENGTH (array_type)))
|
||||
&& elt_offs >= type_length_units (array_type)))
|
||||
- {
|
||||
- if (TYPE_NOT_ASSOCIATED (array_type))
|
||||
- error (_("no such vector element because not associated"));
|
||||
- else if (TYPE_NOT_ALLOCATED (array_type))
|
||||
- error (_("no such vector element because not allocated"));
|
||||
- if (type_not_associated (array_type))
|
||||
- error (_("no such vector element (vector not associated)"));
|
||||
- else if (type_not_allocated (array_type))
|
||||
- error (_("no such vector element (vector not allocated)"));
|
||||
- else
|
||||
- error (_("no such vector element"));
|
||||
- }
|
||||
|
@ -165,17 +165,3 @@ Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.fortran/dynamic-other-frame.f90
|
||||
+ end interface
|
||||
+ call foo ('hello')
|
||||
+end
|
||||
Index: gdb-7.9.50.20150520/gdb/testsuite/gdb.fortran/vla-strings.exp
|
||||
===================================================================
|
||||
--- gdb-7.9.50.20150520.orig/gdb/testsuite/gdb.fortran/vla-strings.exp 2015-05-31 16:14:04.167533854 +0200
|
||||
+++ gdb-7.9.50.20150520/gdb/testsuite/gdb.fortran/vla-strings.exp 2015-05-31 16:14:31.073718201 +0200
|
||||
@@ -33,9 +33,6 @@ gdb_continue_to_breakpoint "var_char-all
|
||||
gdb_test "print var_char" \
|
||||
" = \\(PTR TO -> \\( character\\*10 \\)\\) ${hex}" \
|
||||
"print var_char after allocated first time"
|
||||
-gdb_test "print *var_char" \
|
||||
- " = '\\\\000\\\\000\\\\000\\\\000\\\\000\\\\000\\\\000\\\\000\\\\000\\\\000'" \
|
||||
- "print *var_char after allocated first time"
|
||||
gdb_test "whatis var_char" "type = PTR TO -> \\( character\\*10 \\)" \
|
||||
"whatis var_char first time"
|
||||
gdb_test "ptype var_char" "type = PTR TO -> \\( character\\*10 \\)" \
|
||||
|
1803
gdb-vla-intel.patch
1803
gdb-vla-intel.patch
File diff suppressed because it is too large
Load Diff
39
gdb.changes
39
gdb.changes
@ -1,3 +1,42 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Feb 29 18:50:39 UTC 2016 - matz@suse.de
|
||||
|
||||
- Rebase to gdb version 7.11 as of version in Fedora 24:
|
||||
* Per-inferior thread numbers.
|
||||
* Breakpoint "explicit locations" (via CLI and GDB/MI).
|
||||
* New convenience variables ($_gthread, $_inferior).
|
||||
* Record btrace now supports non-stop mode.
|
||||
* Various improvements on AArch64 GNU/Linux:
|
||||
- Multi-architecture debugging support.
|
||||
- displaced stepping.
|
||||
- tracepoint support added in GDBserver.
|
||||
* In Ada, the overloads selection menu provides the parameter
|
||||
types and return types for the matching overloaded subprograms.
|
||||
* Various remote protocol improvements, including several
|
||||
new packets which can be used to support features such as
|
||||
follow-exec-mode, exec catchpoints, syscall catchpoints, etc.
|
||||
* Some minor improvements in the Python API for extending GDB.
|
||||
- Added new patches from Fedora:
|
||||
gdb-fedora-libncursesw.patch
|
||||
gdb-fortran-stride-intel-1of6.patch
|
||||
gdb-fortran-stride-intel-2of6.patch
|
||||
gdb-fortran-stride-intel-3of6.patch
|
||||
gdb-fortran-stride-intel-4of6.patch
|
||||
gdb-fortran-stride-intel-5of6.patch
|
||||
gdb-fortran-stride-intel-6of6-nokfail.patch
|
||||
gdb-fortran-stride-intel-6of6.patch
|
||||
gdb-opcodes-clflushopt-test.patch
|
||||
gdb-testsuite-readline63-sigint.patch
|
||||
- Removed obsolete patches:
|
||||
gdb-6.3-bz231832-obstack-2gb.patch
|
||||
gdb-pahole-python2.patch
|
||||
gdb-probes-based-interface-robust-1of2.patch
|
||||
gdb-probes-based-interface-robust-2of2.patch
|
||||
gdb-rhbz1260558-ppc64le-skip_trampoline_code.patch
|
||||
gdb-rhbz1270564-invalid-dwarf-regno.patch
|
||||
gdb-rhel5-compat.patch
|
||||
- Really disable problematic testcases.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Jan 18 14:49:12 UTC 2016 - matz@suse.de
|
||||
|
||||
|
244
gdb.spec
244
gdb.spec
@ -27,7 +27,7 @@ Name: gdb
|
||||
%global snap 20130731
|
||||
# See timestamp of source gnulib installed into gdb/gnulib/ .
|
||||
%global snapgnulib 20121213
|
||||
Version: 7.10.1
|
||||
Version: 7.11
|
||||
Release: 0
|
||||
|
||||
# The release always contains a leading reserved number, start it at 1.
|
||||
@ -93,118 +93,121 @@ Source13: gdb-rpmlintrc
|
||||
#Fedora Packages begin
|
||||
Patch1: gdb-6.3-rh-testversion-20041202.patch
|
||||
Patch2: gdb-archer.patch
|
||||
Patch3: gdb-vla-intel.patch
|
||||
Patch4: gdb-vla-intel-logical-not.patch
|
||||
Patch5: gdb-vla-intel-stringbt-fix.patch
|
||||
Patch6: gdb-vla-intel-04of23-fix.patch
|
||||
Patch7: gdb-6.3-rh-dummykfail-20041202.patch
|
||||
Patch8: gdb-6.3-ppc64syscall-20040622.patch
|
||||
Patch9: gdb-6.3-ppc64displaysymbol-20041124.patch
|
||||
Patch10: gdb-6.3-gstack-20050411.patch
|
||||
Patch11: gdb-6.3-test-pie-20050107.patch
|
||||
Patch12: gdb-6.3-test-self-20050110.patch
|
||||
Patch13: gdb-6.3-test-dtorfix-20050121.patch
|
||||
Patch14: gdb-6.3-test-movedir-20050125.patch
|
||||
Patch15: gdb-6.3-threaded-watchpoints2-20050225.patch
|
||||
Patch16: gdb-6.3-inferior-notification-20050721.patch
|
||||
Patch17: gdb-6.3-inheritancetest-20050726.patch
|
||||
Patch18: gdb-6.3-readnever-20050907.patch
|
||||
Patch19: gdb-6.5-bz203661-emit-relocs.patch
|
||||
Patch20: gdb-6.5-bz185337-resolve-tls-without-debuginfo-v2.patch
|
||||
Patch21: gdb-6.5-sharedlibrary-path.patch
|
||||
Patch22: gdb-6.5-BEA-testsuite.patch
|
||||
Patch23: gdb-6.5-last-address-space-byte-test.patch
|
||||
Patch24: gdb-6.5-readline-long-line-crash-test.patch
|
||||
Patch25: gdb-6.5-bz216711-clone-is-outermost.patch
|
||||
Patch26: gdb-6.5-bz218379-ppc-solib-trampoline-test.patch
|
||||
Patch27: gdb-6.5-bz218379-solib-trampoline-lookup-lock-fix.patch
|
||||
Patch28: gdb-6.5-bz109921-DW_AT_decl_file-test.patch
|
||||
Patch29: gdb-6.3-bz140532-ppc-unwinding-test.patch
|
||||
Patch30: gdb-6.3-bz202689-exec-from-pthread-test.patch
|
||||
Patch31: gdb-6.6-bz230000-power6-disassembly-test.patch
|
||||
Patch32: gdb-6.3-bz231832-obstack-2gb.patch
|
||||
Patch33: gdb-6.6-bz229517-gcore-without-terminal.patch
|
||||
Patch34: gdb-6.6-bz235197-fork-detach-info.patch
|
||||
Patch35: gdb-6.6-testsuite-timeouts.patch
|
||||
Patch36: gdb-6.6-bz237572-ppc-atomic-sequence-test.patch
|
||||
Patch37: gdb-6.6-scheduler_locking-step-is-default.patch
|
||||
Patch38: gdb-6.3-attach-see-vdso-test.patch
|
||||
Patch39: gdb-6.5-bz243845-stale-testing-zombie-test.patch
|
||||
Patch40: gdb-6.6-buildid-locate.patch
|
||||
Patch41: gdb-6.6-buildid-locate-solib-missing-ids.patch
|
||||
Patch42: gdb-6.6-buildid-locate-rpm.patch
|
||||
Patch43: gdb-6.7-charsign-test.patch
|
||||
Patch44: gdb-6.7-ppc-clobbered-registers-O2-test.patch
|
||||
Patch45: gdb-6.5-ia64-libunwind-leak-test.patch
|
||||
Patch46: gdb-6.5-missed-trap-on-step-test.patch
|
||||
Patch47: gdb-6.7-bz426600-DW_TAG_interface_type-test.patch
|
||||
Patch48: gdb-6.5-gcore-buffer-limit-test.patch
|
||||
Patch49: gdb-6.6-threads-static-test.patch
|
||||
Patch50: gdb-6.3-mapping-zero-inode-test.patch
|
||||
Patch51: gdb-6.3-focus-cmd-prev-test.patch
|
||||
Patch52: gdb-6.8-bz442765-threaded-exec-test.patch
|
||||
Patch53: gdb-6.8-sparc64-silence-memcpy-check.patch
|
||||
Patch54: gdb-6.5-section-num-fixup-test.patch
|
||||
Patch55: gdb-6.8-bz436037-reg-no-longer-active.patch
|
||||
Patch56: gdb-6.8-watchpoint-conditionals-test.patch
|
||||
Patch57: gdb-6.8-bz466901-backtrace-full-prelinked.patch
|
||||
Patch58: gdb-simultaneous-step-resume-breakpoint-test.patch
|
||||
Patch59: gdb-core-open-vdso-warning.patch
|
||||
Patch60: gdb-x86_64-i386-syscall-restart.patch
|
||||
Patch61: gdb-bz533176-fortran-omp-step.patch
|
||||
Patch62: gdb-follow-child-stale-parent.patch
|
||||
Patch63: gdb-ccache-workaround.patch
|
||||
Patch64: gdb-archer-pie-addons.patch
|
||||
Patch65: gdb-archer-pie-addons-keep-disabled.patch
|
||||
Patch66: gdb-lineno-makeup-test.patch
|
||||
Patch67: gdb-ppc-power7-test.patch
|
||||
Patch68: gdb-bz541866-rwatch-before-run.patch
|
||||
Patch69: gdb-moribund-utrace-workaround.patch
|
||||
Patch70: gdb-archer-next-over-throw-cxx-exec.patch
|
||||
Patch71: gdb-bz601887-dwarf4-rh-test.patch
|
||||
Patch72: gdb-6.6-buildid-locate-core-as-arg.patch
|
||||
Patch73: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch
|
||||
Patch74: gdb-test-bt-cfi-without-die.patch
|
||||
Patch75: gdb-gdb-add-index-script.patch
|
||||
Patch76: gdb-bz568248-oom-is-error.patch
|
||||
Patch77: gdb-bz634108-solib_address.patch
|
||||
Patch78: gdb-test-pid0-core.patch
|
||||
Patch79: gdb-test-dw2-aranges.patch
|
||||
Patch80: gdb-test-expr-cumulative-archer.patch
|
||||
Patch81: gdb-7.2.50-sparc-add-workaround-to-broken-debug-files.patch
|
||||
Patch82: gdb-glibc-vdso-workaround.patch
|
||||
Patch83: gdb-runtest-pie-override.patch
|
||||
Patch84: gdb-attach-fail-reasons-5of5.patch
|
||||
Patch85: gdb-stale-frame_info.patch
|
||||
Patch86: gdb-glibc-strstr-workaround.patch
|
||||
Patch87: gdb-rhel5.9-testcase-xlf-var-inside-mod.patch
|
||||
Patch88: gdb-rhbz-818343-set-solib-absolute-prefix-testcase.patch
|
||||
Patch89: gdb-rhbz795424-bitpos-20of25.patch
|
||||
Patch90: gdb-rhbz795424-bitpos-21of25.patch
|
||||
Patch91: gdb-rhbz795424-bitpos-22of25.patch
|
||||
Patch92: gdb-rhbz795424-bitpos-23of25.patch
|
||||
Patch93: gdb-rhbz795424-bitpos-25of25.patch
|
||||
Patch94: gdb-rhbz795424-bitpos-25of25-test.patch
|
||||
Patch95: gdb-rhbz795424-bitpos-lazyvalue.patch
|
||||
Patch96: gdb-rhbz947564-findvar-assertion-frame-failed-testcase.patch
|
||||
Patch97: gdb-gnat-dwarf-crash-3of3.patch
|
||||
Patch98: gdb-6.6-buildid-locate-misleading-warning-missing-debuginfo-rhbz981154.patch
|
||||
Patch99: gdb-archer-vla-tests.patch
|
||||
Patch100: gdb-btrobust.patch
|
||||
Patch101: gdb-fortran-frame-string.patch
|
||||
Patch102: gdb-python-gil.patch
|
||||
Patch103: gdb-jit-reader-multilib.patch
|
||||
Patch104: gdb-probes-based-interface-robust-1of2.patch
|
||||
Patch105: gdb-probes-based-interface-robust-2of2.patch
|
||||
Patch106: gdb-rhbz1260558-ppc64le-skip_trampoline_code.patch
|
||||
Patch107: gdb-rhbz1270564-invalid-dwarf-regno.patch
|
||||
Patch108: gdb-dts-rhel6-python-compat.patch
|
||||
Patch109: gdb-6.6-buildid-locate-rpm-scl.patch
|
||||
Patch110: gdb-readline62-ask-more-rh.patch
|
||||
Patch111: gdb-6.8-attach-signalled-detach-stopped.patch
|
||||
Patch112: gdb-6.8-quit-never-aborts.patch
|
||||
Patch113: gdb-rhel5-compat.patch
|
||||
Patch114: gdb-pahole-python2.patch
|
||||
Patch3: gdb-fortran-stride-intel-1of6.patch
|
||||
Patch4: gdb-fortran-stride-intel-2of6.patch
|
||||
Patch5: gdb-fortran-stride-intel-3of6.patch
|
||||
Patch6: gdb-fortran-stride-intel-4of6.patch
|
||||
Patch7: gdb-fortran-stride-intel-5of6.patch
|
||||
Patch8: gdb-fortran-stride-intel-6of6.patch
|
||||
Patch9: gdb-vla-intel.patch
|
||||
Patch10: gdb-vla-intel-logical-not.patch
|
||||
Patch11: gdb-vla-intel-stringbt-fix.patch
|
||||
Patch12: gdb-vla-intel-04of23-fix.patch
|
||||
Patch13: gdb-6.3-rh-dummykfail-20041202.patch
|
||||
Patch14: gdb-6.3-ppc64syscall-20040622.patch
|
||||
Patch15: gdb-6.3-ppc64displaysymbol-20041124.patch
|
||||
Patch16: gdb-6.3-gstack-20050411.patch
|
||||
Patch17: gdb-6.3-test-pie-20050107.patch
|
||||
Patch18: gdb-6.3-test-self-20050110.patch
|
||||
Patch19: gdb-6.3-test-dtorfix-20050121.patch
|
||||
Patch20: gdb-6.3-test-movedir-20050125.patch
|
||||
Patch21: gdb-6.3-threaded-watchpoints2-20050225.patch
|
||||
Patch22: gdb-6.3-inferior-notification-20050721.patch
|
||||
Patch23: gdb-6.3-inheritancetest-20050726.patch
|
||||
Patch24: gdb-6.3-readnever-20050907.patch
|
||||
Patch25: gdb-6.5-bz203661-emit-relocs.patch
|
||||
Patch26: gdb-6.5-bz185337-resolve-tls-without-debuginfo-v2.patch
|
||||
Patch27: gdb-6.5-sharedlibrary-path.patch
|
||||
Patch28: gdb-6.5-BEA-testsuite.patch
|
||||
Patch29: gdb-6.5-last-address-space-byte-test.patch
|
||||
Patch30: gdb-6.5-readline-long-line-crash-test.patch
|
||||
Patch31: gdb-6.5-bz216711-clone-is-outermost.patch
|
||||
Patch32: gdb-6.5-bz218379-ppc-solib-trampoline-test.patch
|
||||
Patch33: gdb-6.5-bz218379-solib-trampoline-lookup-lock-fix.patch
|
||||
Patch34: gdb-6.5-bz109921-DW_AT_decl_file-test.patch
|
||||
Patch35: gdb-6.3-bz140532-ppc-unwinding-test.patch
|
||||
Patch36: gdb-6.3-bz202689-exec-from-pthread-test.patch
|
||||
Patch37: gdb-6.6-bz230000-power6-disassembly-test.patch
|
||||
Patch38: gdb-6.6-bz229517-gcore-without-terminal.patch
|
||||
Patch39: gdb-6.6-bz235197-fork-detach-info.patch
|
||||
Patch40: gdb-6.6-testsuite-timeouts.patch
|
||||
Patch41: gdb-6.6-bz237572-ppc-atomic-sequence-test.patch
|
||||
Patch42: gdb-6.6-scheduler_locking-step-is-default.patch
|
||||
Patch43: gdb-6.3-attach-see-vdso-test.patch
|
||||
Patch44: gdb-6.5-bz243845-stale-testing-zombie-test.patch
|
||||
Patch45: gdb-6.6-buildid-locate.patch
|
||||
Patch46: gdb-6.6-buildid-locate-solib-missing-ids.patch
|
||||
Patch47: gdb-6.6-buildid-locate-rpm.patch
|
||||
Patch48: gdb-6.7-charsign-test.patch
|
||||
Patch49: gdb-6.7-ppc-clobbered-registers-O2-test.patch
|
||||
Patch50: gdb-6.5-ia64-libunwind-leak-test.patch
|
||||
Patch51: gdb-6.5-missed-trap-on-step-test.patch
|
||||
Patch52: gdb-6.7-bz426600-DW_TAG_interface_type-test.patch
|
||||
Patch53: gdb-6.5-gcore-buffer-limit-test.patch
|
||||
Patch54: gdb-6.6-threads-static-test.patch
|
||||
Patch55: gdb-6.3-mapping-zero-inode-test.patch
|
||||
Patch56: gdb-6.3-focus-cmd-prev-test.patch
|
||||
Patch57: gdb-6.8-bz442765-threaded-exec-test.patch
|
||||
Patch58: gdb-6.8-sparc64-silence-memcpy-check.patch
|
||||
Patch59: gdb-6.5-section-num-fixup-test.patch
|
||||
Patch60: gdb-6.8-bz436037-reg-no-longer-active.patch
|
||||
Patch61: gdb-6.8-watchpoint-conditionals-test.patch
|
||||
Patch62: gdb-6.8-bz466901-backtrace-full-prelinked.patch
|
||||
Patch63: gdb-simultaneous-step-resume-breakpoint-test.patch
|
||||
Patch64: gdb-core-open-vdso-warning.patch
|
||||
Patch65: gdb-x86_64-i386-syscall-restart.patch
|
||||
Patch66: gdb-bz533176-fortran-omp-step.patch
|
||||
Patch67: gdb-follow-child-stale-parent.patch
|
||||
Patch68: gdb-ccache-workaround.patch
|
||||
Patch69: gdb-archer-pie-addons.patch
|
||||
Patch70: gdb-archer-pie-addons-keep-disabled.patch
|
||||
Patch71: gdb-lineno-makeup-test.patch
|
||||
Patch72: gdb-ppc-power7-test.patch
|
||||
Patch73: gdb-bz541866-rwatch-before-run.patch
|
||||
Patch74: gdb-moribund-utrace-workaround.patch
|
||||
Patch75: gdb-archer-next-over-throw-cxx-exec.patch
|
||||
Patch76: gdb-bz601887-dwarf4-rh-test.patch
|
||||
Patch77: gdb-6.6-buildid-locate-core-as-arg.patch
|
||||
Patch78: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch
|
||||
Patch79: gdb-test-bt-cfi-without-die.patch
|
||||
Patch80: gdb-gdb-add-index-script.patch
|
||||
Patch81: gdb-bz568248-oom-is-error.patch
|
||||
Patch82: gdb-bz634108-solib_address.patch
|
||||
Patch83: gdb-test-pid0-core.patch
|
||||
Patch84: gdb-test-dw2-aranges.patch
|
||||
Patch85: gdb-test-expr-cumulative-archer.patch
|
||||
Patch86: gdb-7.2.50-sparc-add-workaround-to-broken-debug-files.patch
|
||||
Patch87: gdb-glibc-vdso-workaround.patch
|
||||
Patch88: gdb-runtest-pie-override.patch
|
||||
Patch89: gdb-attach-fail-reasons-5of5.patch
|
||||
Patch90: gdb-stale-frame_info.patch
|
||||
Patch91: gdb-glibc-strstr-workaround.patch
|
||||
Patch92: gdb-rhel5.9-testcase-xlf-var-inside-mod.patch
|
||||
Patch93: gdb-rhbz-818343-set-solib-absolute-prefix-testcase.patch
|
||||
Patch94: gdb-rhbz795424-bitpos-20of25.patch
|
||||
Patch95: gdb-rhbz795424-bitpos-21of25.patch
|
||||
Patch96: gdb-rhbz795424-bitpos-22of25.patch
|
||||
Patch97: gdb-rhbz795424-bitpos-23of25.patch
|
||||
Patch98: gdb-rhbz795424-bitpos-25of25.patch
|
||||
Patch99: gdb-rhbz795424-bitpos-25of25-test.patch
|
||||
Patch100: gdb-rhbz795424-bitpos-lazyvalue.patch
|
||||
Patch101: gdb-rhbz947564-findvar-assertion-frame-failed-testcase.patch
|
||||
Patch102: gdb-gnat-dwarf-crash-3of3.patch
|
||||
Patch103: gdb-6.6-buildid-locate-misleading-warning-missing-debuginfo-rhbz981154.patch
|
||||
Patch104: gdb-archer-vla-tests.patch
|
||||
Patch105: gdb-fortran-stride-intel-6of6-nokfail.patch
|
||||
Patch106: gdb-btrobust.patch
|
||||
Patch107: gdb-fortran-frame-string.patch
|
||||
Patch108: gdb-python-gil.patch
|
||||
Patch109: gdb-jit-reader-multilib.patch
|
||||
Patch110: gdb-fedora-libncursesw.patch
|
||||
Patch111: gdb-opcodes-clflushopt-test.patch
|
||||
Patch112: gdb-dts-rhel6-python-compat.patch
|
||||
Patch113: gdb-6.6-buildid-locate-rpm-scl.patch
|
||||
Patch114: gdb-readline62-ask-more-rh.patch
|
||||
Patch115: gdb-6.8-attach-signalled-detach-stopped.patch
|
||||
Patch116: gdb-6.8-quit-never-aborts.patch
|
||||
Patch117: gdb-testsuite-readline63-sigint.patch
|
||||
#Fedora Packages end
|
||||
|
||||
# Upstream patch to fix gcc -Werror
|
||||
@ -459,18 +462,18 @@ find -name "*.info*"|xargs rm -f
|
||||
%patch106 -p1
|
||||
%patch107 -p1
|
||||
%patch108 -p1
|
||||
%patch108 -p1 -R
|
||||
%patch109 -p1
|
||||
%patch109 -p1 -R
|
||||
%if 0
|
||||
# disable, openSUSE doesn't need it
|
||||
%patch110 -p1
|
||||
%patch110 -p1 -R
|
||||
%endif
|
||||
%patch111 -p1
|
||||
%patch112 -p1
|
||||
%patch113 -p1
|
||||
%patch113 -p1 -R
|
||||
%patch112 -p1 -R
|
||||
%patch111 -p1 -R
|
||||
%patch114 -p1
|
||||
%patch115 -p1
|
||||
%patch116 -p1
|
||||
%patch117 -p1
|
||||
#Fedora patching end
|
||||
|
||||
%patch1002 -p1
|
||||
@ -714,8 +717,9 @@ gcc -o ./orphanripper %{SOURCE2} -Wall -lutil -ggdb2
|
||||
for test in \
|
||||
gdb.base/readline-overflow.exp \
|
||||
gdb.base/bigcore.exp \
|
||||
gdb.threads/attach-many-short-lived-threads.exp \
|
||||
; do
|
||||
mv -f ../../gdb/testsuite/$test ../gdb/testsuite/$test-DISABLED || :
|
||||
mv -f ../../gdb/testsuite/$test ../../gdb/testsuite/$test-DISABLED || :
|
||||
done
|
||||
|
||||
# Run all the scheduled testsuite runs also in the PIE mode.
|
||||
|
Loading…
x
Reference in New Issue
Block a user