|
|
0a406a |
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
|
|
|
0a406a |
From: Fedora GDB patches <invalid@email.com>
|
|
|
0a406a |
Date: Fri, 27 Oct 2017 21:07:50 +0200
|
|
|
0a406a |
Subject: gdb-rhbz1084404-ppc64-s390x-wrong-prologue-skip-O2-g-3of3.patch
|
|
|
0a406a |
|
|
|
0a406a |
;; Fix '[ppc64] and [s390x] wrong prologue skip on -O2 -g code' (Jan
|
|
|
0a406a |
;; Kratochvil, RH BZ 1084404).
|
|
|
0a406a |
;;=fedoratest
|
|
|
0a406a |
|
|
|
0a406a |
These testcases have been created by compiling glibc-2.17-78 on
|
|
|
0a406a |
RHEL-7.1 s390x/ppc64 boxes, and then taking the "select.o" file
|
|
|
0a406a |
present at $builddir/misc/select.o.
|
|
|
0a406a |
|
|
|
0a406a |
diff --git a/gdb/testsuite/gdb.arch/ppc64-prologue-skip.exp b/gdb/testsuite/gdb.arch/ppc64-prologue-skip.exp
|
|
|
0a406a |
new file mode 100644
|
|
|
0a406a |
--- /dev/null
|
|
|
0a406a |
+++ b/gdb/testsuite/gdb.arch/ppc64-prologue-skip.exp
|
|
|
0a406a |
@@ -0,0 +1,34 @@
|
|
|
0a406a |
+# Copyright 2015 Free Software Foundation, Inc.
|
|
|
0a406a |
+
|
|
|
0a406a |
+# This program is free software; you can redistribute it and/or modify
|
|
|
0a406a |
+# it under the terms of the GNU General Public License as published by
|
|
|
0a406a |
+# the Free Software Foundation; either version 3 of the License, or
|
|
|
0a406a |
+# (at your option) any later version.
|
|
|
0a406a |
+#
|
|
|
0a406a |
+# This program is distributed in the hope that it will be useful,
|
|
|
0a406a |
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
0a406a |
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
0a406a |
+# GNU General Public License for more details.
|
|
|
0a406a |
+#
|
|
|
0a406a |
+# You should have received a copy of the GNU General Public License
|
|
|
0a406a |
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
0a406a |
+
|
|
|
0a406a |
+if { ![istarget powerpc64-*linux-*] || ![is_lp64_target] } {
|
|
|
0a406a |
+ verbose "Skipping ppc64-prologue-skip.exp"
|
|
|
0a406a |
+ return
|
|
|
0a406a |
+}
|
|
|
0a406a |
+
|
|
|
0a406a |
+set testfile "ppc64-prologue-skip"
|
|
|
0a406a |
+set uufile "${srcdir}/${subdir}/${testfile}.o.uu"
|
|
|
0a406a |
+set ofile "${srcdir}/${subdir}/${testfile}.o"
|
|
|
0a406a |
+
|
|
|
0a406a |
+if { [catch "system \"uudecode -o ${ofile} ${uufile}\"" ] != 0 } {
|
|
|
0a406a |
+ untested "failed uudecode"
|
|
|
0a406a |
+ return -1
|
|
|
0a406a |
+}
|
|
|
0a406a |
+
|
|
|
0a406a |
+gdb_exit
|
|
|
0a406a |
+gdb_start
|
|
|
0a406a |
+gdb_load $ofile
|
|
|
0a406a |
+
|
|
|
0a406a |
+gdb_test "break ___newselect_nocancel" "Breakpoint $decimal at 0xc: file ../sysdeps/unix/syscall-template.S, line 81." "breakpoint on ___newselect_nocancel"
|
|
|
0a406a |
diff --git a/gdb/testsuite/gdb.arch/ppc64-prologue-skip.o.uu b/gdb/testsuite/gdb.arch/ppc64-prologue-skip.o.uu
|
|
|
0a406a |
new file mode 100644
|
|
|
0a406a |
--- /dev/null
|
|
|
0a406a |
+++ b/gdb/testsuite/gdb.arch/ppc64-prologue-skip.o.uu
|
|
|
0a406a |
@@ -0,0 +1,70 @@
|
|
|
0a406a |
+begin 644 ppc64-skip-prologue.o.uu
|
|
|
0a406a |
+M?T5,1@("`0`````````````!`!4````!````````````````````````````
|
|
|
0a406a |
+M``-(``````!```````!``!0`$8%-B-`L"@``0,(`-#@``(Y$```"3.,`('P(
|
|
|
0a406a |
+M`J;X`0`0^"'_D4@```%@````Z`$`@#@A`'!\"`.F3H``(/@A_X%]*`*F^2$`
|
|
|
0a406a |
+MD/CA`-#XP0#(^*$`P/B!`+CX80"P2````6````#X80!PZ.$`T.C!`,CHH0#`
|
|
|
0a406a |
+MZ($`N.AA`+`X``".1````GP``";X80!X^`$`B.AA`'!(```!8````.DA`)#H
|
|
|
0a406a |
+M`0"(Z&$`>'TH`Z9\#_$@."$`@$SC`"!+__]@```````,($``````````O``(
|
|
|
0a406a |
+M7U]S96QE8W0```````````````````````````!6``(````Y!`'[#@T``0$!
|
|
|
0a406a |
+M`0````$```$N+B]S>7-D97!S+W5N:7@``'-Y
|
|
|
0a406a |
+M``````D"```````````#T``!`BT3`@D``0$```"/``(`````"`$`````````
|
|
|
0a406a |
+M`````````````````"XN+W-Y<V1E<',O=6YI>"]S>7-C86QL+71E;7!L871E
|
|
|
0a406a |
+M+E,`+W)O;W0O9VQI8F,O9VQI8F,M,BXQ-RTW."YE;#
|
|
|
0a406a |
+M,3
|
|
|
0a406a |
+M$@$#"!L()0@3!0`````````````````L``(`````"```````````````````
|
|
|
0a406a |
+M````````V``````````````````````````0``````%Z4@`$>$$!&PP!````
|
|
|
0a406a |
+M`#`````8`````````+P`20YP$4%^1`X`009!0@Z``4(107Y2$49_20X`!D$&
|
|
|
0a406a |
+M1@``````+G-Y;71A8@`N
|
|
|
0a406a |
+M871A`"YB
|
|
|
0a406a |
+M9U]L:6YE`"YR96QA+F1E8G5G7VEN9F\`+F1E8G5G7V%B8G)E=@`N
|
|
|
0a406a |
+M96)U9U]A
|
|
|
0a406a |
+M````````````````````````````````````````````````````````````
|
|
|
0a406a |
+M`````````"`````!``````````8```````````````````!``````````-@`
|
|
|
0a406a |
+M```````````````````$```````````````;````!```````````````````
|
|
|
0a406a |
+M```````````*>`````````!(````$@````$`````````"``````````8````
|
|
|
0a406a |
+M)@````$``````````P```````````````````1@`````````````````````
|
|
|
0a406a |
+M``````````$``````````````"P````(``````````,`````````````````
|
|
|
0a406a |
+M``$8```````````````````````````````!```````````````V`````0``
|
|
|
0a406a |
+M```````#```````````````````!&``````````0````````````````````
|
|
|
0a406a |
+M"```````````````,0````0`````````````````````````````"L``````
|
|
|
0a406a |
+M````,````!(````%``````````@`````````&````#L````!````````````
|
|
|
0a406a |
+M``````````````````$H```````````````````````````````!````````
|
|
|
0a406a |
+M``````!0`````0`````````````````````````````!*`````````!:````
|
|
|
0a406a |
+M`````````````````0``````````````2P````0`````````````````````
|
|
|
0a406a |
+M````````"O``````````&````!(````(``````````@`````````&````&$`
|
|
|
0a406a |
+M```!``````````````````````````````&"`````````),`````````````
|
|
|
0a406a |
+M```````!``````````````!<````!``````````````````````````````+
|
|
|
0a406a |
+M"`````````!@````$@````H`````````"``````````8````;0````$`````
|
|
|
0a406a |
+M`````````````````````````A4`````````%`````````````````````$`
|
|
|
0a406a |
+M`````````````(`````!``````````````````````````````(P````````
|
|
|
0a406a |
+M`#`````````````````````0``````````````![````!```````````````
|
|
|
0a406a |
+M```````````````+:``````````P````$@````T`````````"``````````8
|
|
|
0a406a |
+M````E`````$``````````@```````````````````F``````````2```````
|
|
|
0a406a |
+M``````````````@``````````````(\````$````````````````````````
|
|
|
0a406a |
+M``````N8`````````!@````2````#P`````````(`````````!@````1````
|
|
|
0a406a |
+M`P`````````````````````````````"J`````````">````````````````
|
|
|
0a406a |
+M`````0```````````````0````(`````````````````````````````"$@`
|
|
|
0a406a |
+M```````!L````!,````+``````````@`````````&`````D````#````````
|
|
|
0a406a |
+M``````````````````````GX`````````'H````````````````````!````
|
|
|
0a406a |
+M`````````````````````````````````````````````P```0``````````
|
|
|
0a406a |
+M`````````````````P```P```````````````````````````P``!```````
|
|
|
0a406a |
+M`````````````````````P``!0```````````````````````````P``"@``
|
|
|
0a406a |
+M`````````````````````````P``#````````````````````````````P``
|
|
|
0a406a |
+M"````````````````````````````P``#0``````````````````````````
|
|
|
0a406a |
+M`P``#P```````````````````````````P``!P``````````````````````
|
|
|
0a406a |
+M```!$@``!0```````````````````-@````*$@```0`````````,````````
|
|
|
0a406a |
+M`#`````@$``````````````````````````````P$```````````````````
|
|
|
0a406a |
+M``````````!*$`````````````````````````````!E(@``!0``````````
|
|
|
0a406a |
+M`````````-@```!S(@``!0```````````````````-@`7U]S96QE8W0`7U]?
|
|
|
0a406a |
+M;F5W
|
|
|
0a406a |
+M8FQE7V%S>6YC8V%N8V5L`%]?;&EB8U]D:7-A8FQE7V%S>6YC8V%N8V5L`%]?
|
|
|
0a406a |
+M;&EB8U]S96QE8W0`
|
|
|
0a406a |
+M``````````````!<````#@````H```````````````````"4````#P````H`
|
|
|
0a406a |
+M`````````````````````````0```"8````````````````````(````````
|
|
|
0a406a |
+M`#,```````````````````!&`````0```"8````````````````````&````
|
|
|
0a406a |
+M!@````$````````````````````,````!P````$````````````````````0
|
|
|
0a406a |
+M`````0```"8````````````````````8`````0```"8`````````V```````
|
|
|
0a406a |
+M```&````!0````$````````````````````0`````0```"8`````````````
|
|
|
0a406a |
+6```````<`````0```!H`````````````
|
|
|
0a406a |
+`
|
|
|
0a406a |
+end
|
|
|
0a406a |
diff --git a/gdb/testsuite/gdb.arch/s390x-prologue-skip.exp b/gdb/testsuite/gdb.arch/s390x-prologue-skip.exp
|
|
|
0a406a |
new file mode 100644
|
|
|
0a406a |
--- /dev/null
|
|
|
0a406a |
+++ b/gdb/testsuite/gdb.arch/s390x-prologue-skip.exp
|
|
|
0a406a |
@@ -0,0 +1,34 @@
|
|
|
0a406a |
+# Copyright 2015 Free Software Foundation, Inc.
|
|
|
0a406a |
+
|
|
|
0a406a |
+# This program is free software; you can redistribute it and/or modify
|
|
|
0a406a |
+# it under the terms of the GNU General Public License as published by
|
|
|
0a406a |
+# the Free Software Foundation; either version 3 of the License, or
|
|
|
0a406a |
+# (at your option) any later version.
|
|
|
0a406a |
+#
|
|
|
0a406a |
+# This program is distributed in the hope that it will be useful,
|
|
|
0a406a |
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
0a406a |
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
0a406a |
+# GNU General Public License for more details.
|
|
|
0a406a |
+#
|
|
|
0a406a |
+# You should have received a copy of the GNU General Public License
|
|
|
0a406a |
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
0a406a |
+
|
|
|
0a406a |
+if { ![istarget s390x-*linux-*] || ![is_lp64_target] } {
|
|
|
0a406a |
+ verbose "Skipping s390x-prologue-skip.exp"
|
|
|
0a406a |
+ return
|
|
|
0a406a |
+}
|
|
|
0a406a |
+
|
|
|
0a406a |
+set testfile "s390x-prologue-skip"
|
|
|
0a406a |
+set uufile "${srcdir}/${subdir}/${testfile}.o.uu"
|
|
|
0a406a |
+set ofile "${srcdir}/${subdir}/${testfile}.o"
|
|
|
0a406a |
+
|
|
|
0a406a |
+if { [catch "system \"uudecode -o ${ofile} ${uufile}\"" ] != 0 } {
|
|
|
0a406a |
+ untested "failed uudecode"
|
|
|
0a406a |
+ return -1
|
|
|
0a406a |
+}
|
|
|
0a406a |
+
|
|
|
0a406a |
+gdb_exit
|
|
|
0a406a |
+gdb_start
|
|
|
0a406a |
+gdb_load $ofile
|
|
|
0a406a |
+
|
|
|
0a406a |
+gdb_test "break select" "Breakpoint $decimal at 0x48: file ../sysdeps/unix/syscall-template.S, line 81." "breakpoint on select"
|
|
|
0a406a |
diff --git a/gdb/testsuite/gdb.arch/s390x-prologue-skip.o.uu b/gdb/testsuite/gdb.arch/s390x-prologue-skip.o.uu
|
|
|
0a406a |
new file mode 100644
|
|
|
0a406a |
--- /dev/null
|
|
|
0a406a |
+++ b/gdb/testsuite/gdb.arch/s390x-prologue-skip.o.uu
|
|
|
0a406a |
@@ -0,0 +1,64 @@
|
|
|
0a406a |
+begin 644 s390x-prologue-skip.o.uu
|
|
|
0a406a |
+M?T5,1@("`0`````````````!`!8````!````````````````````````````
|
|
|
0a406a |
+M``+```````!```````!``!(`#^LE\!``).O?\&@`)+D$`.^G^_]@X^#P```D
|
|
|
0a406a |
+MP.4`````N00``NLE\+``!`J.N00`TKD$`"#`Y0````"Y!``MZ]_Q"``$I_0`
|
|
|
0a406a |
+M"L`0`````+\/$`"G=/_7"HZG2?`!N2$`),"T``````?^````5@`"````.0$!
|
|
|
0a406a |
+M^PX-``$!`0$````!```!+BXO<WES9&5P<R]U;FEX``!S>7-C86QL+71E;7!L
|
|
|
0a406a |
+M871E+E,``0`````)`@```````````]```0)F$P("``$!````CP`"``````@!
|
|
|
0a406a |
+M```````````````````````````N+B]S>7-D97!S+W5N:7@O
|
|
|
0a406a |
+M96UP;&%T92Y3`"]R;V]T+V=L:6)C+V=L:6)C+3(N,3
|
|
|
0a406a |
+M;&EB8RTR+C$W+6,W-3AA-C@V+VUI
|
|
|
0a406a |
+M`1$`$`81`1(!`P@;""4($P4`````````````````+``"``````@`````````
|
|
|
0a406a |
+M`````````````````&@`````````````````````````%``````!>E(``7@.
|
|
|
0a406a |
+M`1L,#Z`!````````&````!P`````````1`!,CP6.!HT'2`[``@```!`````X
|
|
|
0a406a |
+M`````````"```````"YS>6UT86(`+G-T
|
|
|
0a406a |
+M=&5X=``N9&%T80`N8G-S`"YN;W1E+D=.52US=&%C:P`N
|
|
|
0a406a |
+M:6YE`"YR96QA+F1E8G5G7VEN9F\`+F1E8G5G7V%B8G)E=@`N
|
|
|
0a406a |
+M9U]A
|
|
|
0a406a |
+M````````````````````````````````````````````````````````````
|
|
|
0a406a |
+M````````(`````$`````````!@```````````````````$``````````:```
|
|
|
0a406a |
+M``````````````````0``````````````!L````$````````````````````
|
|
|
0a406a |
+M``````````F``````````&`````0`````0`````````(`````````!@````F
|
|
|
0a406a |
+M`````0`````````#````````````````````J```````````````````````
|
|
|
0a406a |
+M````````!```````````````+`````@``````````P``````````````````
|
|
|
0a406a |
+M`*@```````````````````````````````0``````````````#$````!````
|
|
|
0a406a |
+M``````````````````````````"H```````````````````````````````!
|
|
|
0a406a |
+M``````````````!&`````0``````````````````````````````J```````
|
|
|
0a406a |
+M``!:`````````````````````0``````````````00````0`````````````
|
|
|
0a406a |
+M````````````````">``````````&````!`````&``````````@`````````
|
|
|
0a406a |
+M&````%<````!``````````````````````````````$"`````````),`````
|
|
|
0a406a |
+M```````````````!``````````````!2````!```````````````````````
|
|
|
0a406a |
+M```````)^`````````!@````$`````@`````````"``````````8````8P``
|
|
|
0a406a |
+M``$``````````````````````````````94`````````%```````````````
|
|
|
0a406a |
+M``````$``````````````'8````!``````````````````````````````&P
|
|
|
0a406a |
+M`````````#`````````````````````0``````````````!Q````!```````
|
|
|
0a406a |
+M```````````````````````*6``````````P````$`````L`````````"```
|
|
|
0a406a |
+M```````8````B@````$``````````@```````````````````>``````````
|
|
|
0a406a |
+M2`````````````````````@``````````````(4````$````````````````
|
|
|
0a406a |
+M``````````````J(`````````#`````0````#0`````````(`````````!@`
|
|
|
0a406a |
+M```1`````P`````````````````````````````"*`````````"4````````
|
|
|
0a406a |
+M`````````````0```````````````0````(`````````````````````````
|
|
|
0a406a |
+M````!T`````````!L````!$````*``````````@`````````&`````D````#
|
|
|
0a406a |
+M``````````````````````````````CP`````````(X`````````````````
|
|
|
0a406a |
+M```!`````````````````````````````````````````````````P```0``
|
|
|
0a406a |
+M`````````````````````````P```P```````````````````````````P``
|
|
|
0a406a |
+M!````````````````````````````P``"```````````````````````````
|
|
|
0a406a |
+M`P``"@```````````````````````````P``!@``````````````````````
|
|
|
0a406a |
+M`````P``"P```````````````````````````P``#0``````````````````
|
|
|
0a406a |
+M`````````P``!0`````````````````````````!$```````````````````
|
|
|
0a406a |
+M```````````;$``````````````````````````````V$@```0````````!(
|
|
|
0a406a |
+M`````````"`````_$`````````````````````````````!7$@```0``````
|
|
|
0a406a |
+M``!6`````````!````!I$`````````````````````````````!Y(@```0``
|
|
|
0a406a |
+M``````!(`````````"````"'(@```0````````!(`````````"``7U]L:6)C
|
|
|
0a406a |
+M7V5N86)L95]A
|
|
|
0a406a |
+M;`!?7W-E;&5C=`!?7VQI8F-?;75L=&EP;&5?=&AR96%D
|
|
|
0a406a |
+M;V-A;F-E;`!?7W-Y
|
|
|
0a406a |
+M````````````'`````H````3``````````(`````````-@````L````3````
|
|
|
0a406a |
+M``````(`````````2@````T````3``````````(`````````8@````\````3
|
|
|
0a406a |
+M``````````(`````````1@````$````6````````````````````!@````4`
|
|
|
0a406a |
+M```$````````````````````#`````8````$````````````````````$```
|
|
|
0a406a |
+M``$````6````````````````````&`````$````6`````````&@`````````
|
|
|
0a406a |
+M!@````0````$````````````````````$`````$````6````````````````
|
|
|
0a406a |
+L````(`````$````%````````````````````/`````$````%`````````$@`
|
|
|
0a406a |
+`
|
|
|
0a406a |
+end
|