diff options
author | Jan Beulich <jbeulich@suse.com> | 2020-01-09 11:38:01 +0100 |
---|---|---|
committer | Jan Beulich <jbeulich@suse.com> | 2020-01-09 11:38:01 +0100 |
commit | d835a58baae720abe909795cb68763040d1750a8 (patch) | |
tree | f4a188a3fcfdc20e2f9bbfee761037dca16a39d7 /gas | |
parent | 482556efed3529d76baca0c61f7fb72221e6dc9a (diff) | |
download | fsf-binutils-gdb-d835a58baae720abe909795cb68763040d1750a8.zip fsf-binutils-gdb-d835a58baae720abe909795cb68763040d1750a8.tar.gz fsf-binutils-gdb-d835a58baae720abe909795cb68763040d1750a8.tar.bz2 |
x86: SYSENTER/SYSEXIT are unavailable in 64-bit mode on AMD
The disassembler change is such that in default mode we'd disassemble
the insns (for there not ebing any conflicts), but when AMD64 mode was
explicitly requested, we'd show them as "(bad)".
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 9 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/i386.exp | 4 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-sysenter-amd.d | 14 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-sysenter-amd.l | 5 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-sysenter-amd.s | 7 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-sysenter-intel.d | 15 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-sysenter-mixed.d | 6 |
7 files changed, 60 insertions, 0 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index bed8292..116617a 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,12 @@ +2020-01-09 Jan Beulich <jbeulich@suse.com> + + * testsuite/gas/i386/x86-64-sysenter-amd.s, + testsuite/gas/i386/x86-64-sysenter-amd.d, + testsuite/gas/i386/x86-64-sysenter-amd.l, + testsuite/gas/i386/x86-64-sysenter-intel.d, + testsuite/gas/i386/x86-64-sysenter-mixed.d: New. + * testsuite/gas/i386/i386.exp: Run new tests. + 2020-01-08 Nick Clifton <nickc@redhat.com> PR 25284 diff --git a/gas/testsuite/gas/i386/i386.exp b/gas/testsuite/gas/i386/i386.exp index 6ee486f..4c886d5 100644 --- a/gas/testsuite/gas/i386/i386.exp +++ b/gas/testsuite/gas/i386/i386.exp @@ -724,6 +724,10 @@ if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_64_check]] t run_dump_test "x86-64-nops-5" run_dump_test "x86-64-nops-5-k8" run_dump_test "x86-64-nops-7" + run_dump_test "x86-64-sysenter-intel" + run_dump_test "x86-64-sysenter-mixed" + run_dump_test "x86-64-sysenter-amd" + run_list_test "x86-64-sysenter-amd" run_dump_test "noreg64" run_list_test "cvtsi2sX" run_dump_test "x86-64-sse4_1" diff --git a/gas/testsuite/gas/i386/x86-64-sysenter-amd.d b/gas/testsuite/gas/i386/x86-64-sysenter-amd.d new file mode 100644 index 0000000..5b2fc37 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-sysenter-amd.d @@ -0,0 +1,14 @@ +#as: -mintel64 +#objdump: -dw -Mamd64 +#name: x86-64 sysenter (Intel64/AMD64) + +.*: +file format .* + +Disassembly of section .text: + +0+ <.text>: +[ ]*[a-f0-9]+:[ ]+0f 34[ ]+\(bad\)[ ]* +[ ]*[a-f0-9]+:[ ]+0f 35[ ]+\(bad\)[ ]* +[ ]*[a-f0-9]+:[ ]+0f 34[ ]+\(bad\)[ ]* +[ ]*[a-f0-9]+:[ ]+0f 35[ ]+\(bad\)[ ]* +#pass diff --git a/gas/testsuite/gas/i386/x86-64-sysenter-amd.l b/gas/testsuite/gas/i386/x86-64-sysenter-amd.l new file mode 100644 index 0000000..faa2562 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-sysenter-amd.l @@ -0,0 +1,5 @@ +.*: Assembler messages: +.*:2: Error: .* +.*:3: Error: .* +.*:6: Error: .* +.*:7: Error: .* diff --git a/gas/testsuite/gas/i386/x86-64-sysenter-amd.s b/gas/testsuite/gas/i386/x86-64-sysenter-amd.s new file mode 100644 index 0000000..b6d31f9 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-sysenter-amd.s @@ -0,0 +1,7 @@ + .text + sysenter + sysexit + + .intel_syntax noprefix + sysenter + sysexit diff --git a/gas/testsuite/gas/i386/x86-64-sysenter-intel.d b/gas/testsuite/gas/i386/x86-64-sysenter-intel.d new file mode 100644 index 0000000..ffd5e3e --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-sysenter-intel.d @@ -0,0 +1,15 @@ +#as: -mintel64 +#objdump: -dw -Mintel64 +#name: x86-64 sysenter (Intel64/Intel64) +#source: x86-64-sysenter-amd.s + +.*: +file format .* + +Disassembly of section .text: + +0+ <.text>: +[ ]*[a-f0-9]+: 0f 34 sysenter * +[ ]*[a-f0-9]+: 0f 35 sysexit * +[ ]*[a-f0-9]+: 0f 34 sysenter * +[ ]*[a-f0-9]+: 0f 35 sysexit * +#pass diff --git a/gas/testsuite/gas/i386/x86-64-sysenter-mixed.d b/gas/testsuite/gas/i386/x86-64-sysenter-mixed.d new file mode 100644 index 0000000..034f1cb --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-sysenter-mixed.d @@ -0,0 +1,6 @@ +#as: -mintel64 +#objdump: -dw +#name: x86-64 sysenter (Intel64/Default) +#source: x86-64-sysenter-amd.s +#dump: x86-64-sysenter-intel.d + |