Blame SOURCES/gdb-rhbz1553104-s390x-arch12-test.patch

93189d
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
93189d
From: Jan Kratochvil <jan.kratochvil@redhat.com>
93189d
Date: Fri, 23 Mar 2018 20:42:44 +0100
93189d
Subject: gdb-rhbz1553104-s390x-arch12-test.patch
93189d
93189d
;; [s390x] Backport arch12 instructions decoding (RH BZ 1553104).
93189d
;; =fedoratest
93189d
93189d
diff --git a/gdb/testsuite/gdb.arch/s390x-arch12.S b/gdb/testsuite/gdb.arch/s390x-arch12.S
93189d
new file mode 100644
93189d
--- /dev/null
93189d
+++ b/gdb/testsuite/gdb.arch/s390x-arch12.S
93189d
@@ -0,0 +1,4 @@
93189d
+.text
93189d
+.globl load_guarded
93189d
+load_guarded:
93189d
+.byte 0xeb,0xbf,0xf0,0x58,0x00,0x24,0xe3,0xf0,0xff,0x50,0xff,0x71,0xb9,0x04,0x00,0xbf,0xe3,0x20,0xb0,0xa0,0x00,0x24,0xe3,0x10,0xb0,0xa0,0x00,0x04,0xe3,0x10,0x10,0x00,0x00,0x4c,0xe3,0x10,0xb0,0xa8,0x00,0x24,0xe3,0x10,0xb0,0xa8,0x00,0x04,0xb9,0x04,0x00,0x21,0xe3,0x40,0xb1,0x20,0x00,0x04,0xeb,0xbf,0xb1,0x08,0x00,0x04,0x07,0xf4
93189d
diff --git a/gdb/testsuite/gdb.arch/s390x-arch12.exp b/gdb/testsuite/gdb.arch/s390x-arch12.exp
93189d
new file mode 100644
93189d
--- /dev/null
93189d
+++ b/gdb/testsuite/gdb.arch/s390x-arch12.exp
93189d
@@ -0,0 +1,34 @@
93189d
+# Copyright 2018 Free Software Foundation, Inc.
93189d
+
93189d
+# This program is free software; you can redistribute it and/or modify
93189d
+# it under the terms of the GNU General Public License as published by
93189d
+# the Free Software Foundation; either version 3 of the License, or
93189d
+# (at your option) any later version.
93189d
+#
93189d
+# This program is distributed in the hope that it will be useful,
93189d
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
93189d
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
93189d
+# GNU General Public License for more details.
93189d
+#
93189d
+# You should have received a copy of the GNU General Public License
93189d
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
93189d
+
93189d
+#if { ![istarget s390x-*linux-*] || ![is_lp64_target] } {
93189d
+#    verbose "Skipping s390x-prologue-skip.exp"
93189d
+#    return
93189d
+#}
93189d
+
93189d
+set testfile "s390x-arch12"
93189d
+set uufile "${srcdir}/${subdir}/${testfile}.o.uu"
93189d
+set ofile "${srcdir}/${subdir}/${testfile}.o"
93189d
+
93189d
+if { [catch "system \"uudecode -o ${ofile} ${uufile}\"" ] != 0 } {
93189d
+    untested "failed uudecode"
93189d
+    return -1
93189d
+}
93189d
+
93189d
+gdb_exit
93189d
+gdb_start
93189d
+gdb_load $ofile
93189d
+
93189d
+gdb_test "disas load_guarded" " <\\+28>:\tlgg\t%r1,0\\(%r1\\)\r\n\[^\r\n\]* <\\+34>:\tstg\t%r1,168\\(%r11\\)\r\n.*"
93189d
diff --git a/gdb/testsuite/gdb.arch/s390x-arch12.o.uu b/gdb/testsuite/gdb.arch/s390x-arch12.o.uu
93189d
new file mode 100644
93189d
--- /dev/null
93189d
+++ b/gdb/testsuite/gdb.arch/s390x-arch12.o.uu
93189d
@@ -0,0 +1,20 @@
93189d
+begin 644 s390x-arch12.o
93189d
+M?T5,1@("`0`````````````!`!8````!````````````````````````````
93189d
+M``$X``````!```````!```<`!.N_\%@`)./P_U#_<;D$`+_C(+"@`"3C$+"@
93189d
+M``3C$!```$SC$+"H`"3C$+"H``2Y!``AXT"Q(``$Z[^Q"``$!_0`+G-Y;71A
93189d
+M8@`N
93189d
+M`````````````````````````````````P```0``````````````````````
93189d
+M`````P```@```````````````````````````P```P``````````````````
93189d
+M```````!$````0``````````````````````;&]A9%]G=6%R9&5D````````
93189d
+M````````````````````````````````````````````````````````````
93189d
+M`````````````````````````!L````!``````````8`````````````````
93189d
+M``!``````````$`````````````````````$```````````````A`````0``
93189d
+M```````#````````````````````@```````````````````````````````
93189d
+M!```````````````)P````@``````````P```````````````````(``````
93189d
+M``````````````````````````0``````````````!$````#````````````
93189d
+M``````````````````"``````````"P````````````````````!````````
93189d
+M```````!`````@``````````````````````````````L`````````!X````
93189d
+M!@````0`````````"``````````8````"0````,`````````````````````
93189d
+H`````````2@`````````#@````````````````````$`````````````
93189d
+`
93189d
+end