Various mostly testsuite compatibility and regression fixes.

This commit is contained in:
Jan Kratochvil 2016-09-12 22:56:27 +02:00
parent d258670d64
commit 235c57bc26
5 changed files with 90 additions and 85 deletions

View File

@ -108,7 +108,7 @@ Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.base/gcore-shmid0.c
=================================================================== ===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.base/gcore-shmid0.c 2013-08-02 22:22:17.573599496 +0200 +++ gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.base/gcore-shmid0.c 2013-08-02 22:22:17.573599496 +0200
@@ -0,0 +1,127 @@ @@ -0,0 +1,128 @@
+/* Copyright 2007, 2009 Free Software Foundation, Inc. +/* Copyright 2007, 2009 Free Software Foundation, Inc.
+ +
+ This file is part of GDB. + This file is part of GDB.
@ -139,6 +139,7 @@ Index: gdb-7.6.50.20130731-cvs/gdb/testsuite/gdb.base/gcore-shmid0.c
+#include <stdlib.h> +#include <stdlib.h>
+#include <unistd.h> +#include <unistd.h>
+#include <assert.h> +#include <assert.h>
+#include <time.h>
+ +
+/* The same test running in a parallel testsuite may steal us the zero SID, +/* The same test running in a parallel testsuite may steal us the zero SID,
+ even if we never get any EEXIST. Just try a while. */ + even if we never get any EEXIST. Just try a while. */

View File

@ -112,12 +112,11 @@ Index: gdb-7.11.50.20160630/gdb/python/python.c
} }
END_CATCH END_CATCH
Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.c --- /dev/null 2016-09-12 21:37:05.332693927 +0200
=================================================================== +++ gdb-7.11.90.20160907/gdb/testsuite/gdb.python/py-gil-mthread.c 2016-09-12 21:51:53.750317187 +0200
--- /dev/null 1970-01-01 00:00:00.000000000 +0000 @@ -0,0 +1,13 @@
+++ gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.c 2016-07-03 16:30:42.813387876 +0200
@@ -0,0 +1,12 @@
+#include <stdio.h> +#include <stdio.h>
+#include <unistd.h>
+ +
+int +int
+main (void) +main (void)
@ -129,10 +128,8 @@ Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.c
+ printf ("Sleeping %d\n", i); + printf ("Sleeping %d\n", i);
+ } + }
+} +}
Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.exp --- /dev/null 2016-09-12 21:37:05.332693927 +0200
=================================================================== +++ gdb-7.11.90.20160907/gdb/testsuite/gdb.python/py-gil-mthread.exp 2016-09-12 21:52:38.605750360 +0200
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.exp 2016-07-03 16:30:42.813387876 +0200
@@ -0,0 +1,69 @@ @@ -0,0 +1,69 @@
+# Copyright (C) 2014 Free Software Foundation, Inc. +# Copyright (C) 2014 Free Software Foundation, Inc.
+ +
@ -171,7 +168,7 @@ Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.exp
+set sleeping_last -1 +set sleeping_last -1
+set hello_last 0 +set hello_last 0
+set minimal 5 +set minimal 5
+gdb_test_multiple "python execfile('$srcdir/$subdir/$srcfile2')" $test { +gdb_test_multiple "python exec (open ('$srcdir/$subdir/$srcfile2').read ())" $test {
+ -re "Error: unable to start thread\r\n" { + -re "Error: unable to start thread\r\n" {
+ fail $test + fail $test
+ # Not $gdb_prompt-synced! + # Not $gdb_prompt-synced!
@ -203,12 +200,13 @@ Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.exp
+ } + }
+ } + }
+} +}
Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.py --- /dev/null 2016-09-12 21:37:05.332693927 +0200
=================================================================== +++ gdb-7.11.90.20160907/gdb/testsuite/gdb.python/py-gil-mthread.py 2016-09-12 21:59:02.668459286 +0200
--- /dev/null 1970-01-01 00:00:00.000000000 +0000 @@ -0,0 +1,28 @@
+++ gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.py 2016-07-03 16:30:42.814387884 +0200 +try:
@@ -0,0 +1,22 @@ + import thread
+import thread +except:
+ import _thread
+import time +import time
+import gdb +import gdb
+ +
@ -218,15 +216,18 @@ Index: gdb-7.11.50.20160630/gdb/testsuite/gdb.python/py-gil-mthread.py
+ while count < 10: + while count < 10:
+ time.sleep(1) + time.sleep(1)
+ count += 1 + count += 1
+ print "Hello (", count, ")" + print ("Hello (", count, ")")
+ +
+# Create a threads a continue +# Create a threads a continue
+try: +try:
+ thread.start_new_thread( print_thread_hello, ()) + thread.start_new_thread (print_thread_hello, ())
+ gdb.execute ("continue", release_gil=True) + gdb.execute ("continue", release_gil=True)
+
+except: +except:
+ print "Error: unable to start thread" + try:
+ _thread.start_new_thread (print_thread_hello, ())
+ gdb.execute ("continue", release_gil=True)
+ except:
+ print ("Error: unable to start thread")
+ +
+while 1: +while 1:
+ pass + pass

View File

@ -1,5 +1,47 @@
--- /dev/null 2016-04-19 22:52:19.405224269 +0200 --- /dev/null 2016-09-12 21:37:05.332693927 +0200
+++ gdb-7.6.1/gdb/testsuite/gdb.python/py-framefilter-thread.exp 2016-04-19 23:22:10.655271756 +0200 +++ gdb-7.11.90.20160907/gdb/testsuite/gdb.python/py-framefilter-thread.c 2016-09-12 21:43:56.448695513 +0200
@@ -0,0 +1,39 @@
+/* This testcase is part of GDB, the GNU debugger.
+
+ 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/>. */
+
+#include <pthread.h>
+#include <assert.h>
+
+static void *
+start (void *arg)
+{
+ return arg; /* Backtrace end breakpoint */
+}
+
+int
+main (void)
+{
+ pthread_t thread1;
+ int i;
+
+ i = pthread_create (&thread1, NULL, start, NULL);
+ assert (i == 0);
+ i = pthread_join (thread1, NULL);
+ assert (i == 0);
+
+ return 0;
+}
--- /dev/null 2016-09-12 21:37:05.332693927 +0200
+++ gdb-7.11.90.20160907/gdb/testsuite/gdb.python/py-framefilter-thread.exp 2016-09-12 21:46:54.623428493 +0200
@@ -0,0 +1,54 @@ @@ -0,0 +1,54 @@
+# Copyright (C) 2016 Free Software Foundation, Inc. +# Copyright (C) 2016 Free Software Foundation, Inc.
+ +
@ -35,7 +77,7 @@
+ +
+# Load global frame-filters +# Load global frame-filters
+set remote_python_file [remote_download host ${srcdir}/${subdir}/${testfile}.py] +set remote_python_file [remote_download host ${srcdir}/${subdir}/${testfile}.py]
+gdb_test_no_output "python execfile ('${remote_python_file}')" \ +gdb_test_no_output "python exec (open ('${remote_python_file}').read ())" \
+ "Load python file" + "Load python file"
+ +
+gdb_breakpoint [gdb_get_line_number "Backtrace end breakpoint"] +gdb_breakpoint [gdb_get_line_number "Backtrace end breakpoint"]
@ -55,51 +97,9 @@
+# block = self.frame.block() +# block = self.frame.block()
+# RuntimeError: Cannot locate object file for block. +# RuntimeError: Cannot locate object file for block.
+gdb_test "bt" " in \[0-9\]+ \[^\r\n\]*" "bt with filters" +gdb_test "bt" " in \[0-9\]+ \[^\r\n\]*" "bt with filters"
--- /dev/null 2016-04-19 22:52:19.405224269 +0200 --- /dev/null 2016-09-12 21:37:05.332693927 +0200
+++ gdb-7.6.1/gdb/testsuite/gdb.python/py-framefilter-thread.c 2016-04-18 22:44:07.096613437 +0200 +++ gdb-7.11.90.20160907/gdb/testsuite/gdb.python/py-framefilter-thread.py 2016-09-12 21:49:16.150795235 +0200
@@ -0,0 +1,39 @@ @@ -0,0 +1,60 @@
+/* This testcase is part of GDB, the GNU debugger.
+
+ 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/>. */
+
+#include <pthread.h>
+#include <assert.h>
+
+static void *
+start (void *arg)
+{
+ return; /* Backtrace end breakpoint */
+}
+
+int
+main (void)
+{
+ pthread_t thread1;
+ int i;
+
+ i = pthread_create (&thread1, NULL, start, NULL);
+ assert (i == 0);
+ i = pthread_join (thread1, NULL);
+ assert (i == 0);
+
+ return 0;
+}
--- /dev/null 2016-04-19 22:52:19.405224269 +0200
+++ gdb-7.6.1/gdb/testsuite/gdb.python/py-framefilter-thread.py 2016-04-19 23:14:03.273994063 +0200
@@ -0,0 +1,56 @@
+# Copyright (C) 2016 Free Software Foundation, Inc. +# Copyright (C) 2016 Free Software Foundation, Inc.
+ +
+# This program is free software; you can redistribute it and/or modify +# This program is free software; you can redistribute it and/or modify
@ -151,8 +151,12 @@
+ gdb.frame_filters [self.name] = self + gdb.frame_filters [self.name] = self
+ +
+ def filter (self, frame_iter): + def filter (self, frame_iter):
+ frame_iter = itertools.imap (Reverse_Function, + # Python 3.x moved the itertools.imap functionality to map(),
+ frame_iter) + # so check if it is available.
+ if hasattr(itertools, "imap"):
+ frame_iter = itertools.imap (Reverse_Function, frame_iter)
+ else:
+ frame_iter = map (Reverse_Function, frame_iter)
+ return frame_iter + return frame_iter
+ +
+FrameFilter() +FrameFilter()

View File

@ -112,7 +112,7 @@ Index: gdb-7.10.50.20160106/gdb/testsuite/gdb.fortran/vla-func.f90
+ implicit none + implicit none
+ interface + interface
+ logical function func1 (vla) + logical function func1 (vla)
+ integer :: vla (:, :) + integer, allocatable :: vla (:, :)
+ end function + end function
+ end interface + end interface
+ interface + interface

View File

@ -28,7 +28,7 @@ Version: 7.12
# The release always contains a leading reserved number, start it at 1. # The release always contains a leading reserved number, start it at 1.
# `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing. # `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing.
Release: 0.13.%{tardate}%{?dist} Release: 0.14.%{tardate}%{?dist}
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ and GPLv2+ with exceptions and GPL+ and LGPLv2+ and BSD and Public Domain and GFDL License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ and GPLv2+ with exceptions and GPL+ and LGPLv2+ and BSD and Public Domain and GFDL
Group: Development/Debuggers Group: Development/Debuggers
@ -658,11 +658,8 @@ BuildRequires: gcc-java libgcj%{bits_local} libgcj%{bits_other}
BuildRequires: zlib-devel%{bits_local} zlib-devel%{bits_other} BuildRequires: zlib-devel%{bits_local} zlib-devel%{bits_other}
%endif %endif
%if 0%{!?rhel:1} || 0%{?rhel} > 6 %if 0%{!?rhel:1} || 0%{?rhel} > 6
# These Fedoras do not yet have gcc-go built.
%ifnarch ppc64le aarch64
BuildRequires: gcc-go BuildRequires: gcc-go
%endif %endif
%endif
# archer-sergiodj-stap-patch-split # archer-sergiodj-stap-patch-split
BuildRequires: systemtap-sdt-devel BuildRequires: systemtap-sdt-devel
%if 0%{?rhel:1} && 0%{?rhel} <= 7 %if 0%{?rhel:1} && 0%{?rhel} <= 7
@ -685,8 +682,8 @@ BuildRequires: opencl-headers ocl-icd-devel%{bits_local} ocl-icd-devel%{bits_oth
BuildRequires: fpc BuildRequires: fpc
%endif %endif
%endif %endif
# Copied from gcc-4.1.2-32. # Copied from: gcc-6.2.1-1.fc26
%ifarch %{ix86} x86_64 ppc alpha %ifarch %{ix86} x86_64 ia64 ppc %{power64} alpha s390x %{arm} aarch64
BuildRequires: gcc-gnat BuildRequires: gcc-gnat
BuildRequires: libgnat%{bits_local} libgnat%{bits_other} BuildRequires: libgnat%{bits_local} libgnat%{bits_other}
%endif %endif
@ -696,20 +693,19 @@ BuildRequires: libgfortran%{bits_local} libgfortran%{bits_other}
# libstdc++-devel of matching bits is required only for g++ -static. # libstdc++-devel of matching bits is required only for g++ -static.
BuildRequires: libstdc++%{bits_local} libstdc++%{bits_other} BuildRequires: libstdc++%{bits_local} libstdc++%{bits_other}
%if 0%{!?rhel:1} || 0%{?rhel} > 6 %if 0%{!?rhel:1} || 0%{?rhel} > 6
%if 0%{!?rhel:1} || 0%{?rhel} > 7
BuildRequires: libquadmath%{bits_local} libquadmath%{bits_other}
%else
%ifarch %{ix86} x86_64
BuildRequires: libquadmath%{bits_local} libquadmath%{bits_other} BuildRequires: libquadmath%{bits_local} libquadmath%{bits_other}
# These Fedoras do not yet have gcc-go built.
%ifnarch ppc64le aarch64
BuildRequires: libgo-devel%{bits_local} libgo-devel%{bits_other}
%endif %endif
%endif %endif
BuildRequires: libgo-devel%{bits_local} libgo-devel%{bits_other}
%endif
BuildRequires: glibc-static%{bits_local} BuildRequires: glibc-static%{bits_local}
# multilib glibc-static is open Bug 488472: # multilib glibc-static is open Bug 488472:
#BuildRequires: glibc-static%{bits_other} #BuildRequires: glibc-static%{bits_other}
# Copied from valgrind-3.5.0-1.
# Valgrind is not yet ported to ppc64le.
%ifarch %{ix86} x86_64 ppc ppc64
BuildRequires: valgrind%{bits_local} valgrind%{bits_other} BuildRequires: valgrind%{bits_local} valgrind%{bits_other}
%endif
%if 0%{!?rhel:1} || 0%{?rhel} > 6 %if 0%{!?rhel:1} || 0%{?rhel} > 6
BuildRequires: xz BuildRequires: xz
%endif %endif
@ -1452,6 +1448,9 @@ then
fi fi
%changelog %changelog
* Mon Sep 12 2016 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.12-0.14.20160907.fc25
- Various mostly testsuite compatibility and regression fixes.
* Wed Sep 7 2016 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.12-0.13.20160907.fc25 * Wed Sep 7 2016 Jan Kratochvil <jan.kratochvil@redhat.com> - 7.12-0.13.20160907.fc25
- Rebase to FSF GDB 7.11.90.20160907 (pre-7.12 branch snapshot). - Rebase to FSF GDB 7.11.90.20160907 (pre-7.12 branch snapshot).
- Rebase Intel VLA patchset. - Rebase Intel VLA patchset.