From da98bb4c748be5cfc2c48de41ce71a6a47ac6268 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Sat, 16 Oct 2010 21:53:16 +0000 Subject: [PATCH] Add CpuNop to CPU_GENERIC64_FLAGS. gas/testsuite/ 2010-10-16 H.J. Lu * gas/i386/i386.exp: Run x86-64-nops-1-g64. * gas/i386/x86-64-nops-1.d: Remove -mtune=generic64. * gas/i386/x86-64-nops-1-g64.d: New. opcodes/ 2010-10-16 H.J. Lu * i386-gen.c (cpu_flag_init): Add CpuNop to CPU_GENERIC64_FLAGS. * i386-init.h: Regenerated. --- gas/testsuite/ChangeLog | 8 ++ gas/testsuite/gas/i386/i386.exp | 1 + gas/testsuite/gas/i386/x86-64-nops-1-g64.d | 157 +++++++++++++++++++++ gas/testsuite/gas/i386/x86-64-nops-1.d | 1 - opcodes/ChangeLog | 6 + opcodes/i386-gen.c | 2 +- opcodes/i386-init.h | 2 +- 7 files changed, 174 insertions(+), 3 deletions(-) create mode 100644 gas/testsuite/gas/i386/x86-64-nops-1-g64.d diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index 69f6fc0f57c..1ab14fd0e21 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2010-10-16 H.J. Lu + + * gas/i386/i386.exp: Run x86-64-nops-1-g64. + + * gas/i386/x86-64-nops-1.d: Remove -mtune=generic64. + + * gas/i386/x86-64-nops-1-g64.d: New. + 2010-10-15 David Gibson * gas/bfin/loop_label.s, gas/bfin/loop_label.d, diff --git a/gas/testsuite/gas/i386/i386.exp b/gas/testsuite/gas/i386/i386.exp index b89767ffe6a..f4465c2839d 100644 --- a/gas/testsuite/gas/i386/i386.exp +++ b/gas/testsuite/gas/i386/i386.exp @@ -295,6 +295,7 @@ if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_64_check]] t run_dump_test "x86-64-gidt" run_dump_test "x86-64-nops" run_dump_test "x86-64-nops-1" + run_dump_test "x86-64-nops-1-g64" run_dump_test "x86-64-nops-1-k8" run_dump_test "x86-64-nops-1-nocona" run_dump_test "x86-64-nops-1-core2" diff --git a/gas/testsuite/gas/i386/x86-64-nops-1-g64.d b/gas/testsuite/gas/i386/x86-64-nops-1-g64.d new file mode 100644 index 00000000000..427189de4bc --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-nops-1-g64.d @@ -0,0 +1,157 @@ +#source: nops-1.s +#as: -mtune=generic64 +#objdump: -drw +#name: x86-64 -mtune=generic64 nops 1 + +.*: +file format .* + + +Disassembly of section .text: + +0+ : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 66 66 66 66 66 2e 0f 1f 84 00 00 00 00 00 data32 data32 data32 data32 data32 nopw %cs:0x0\(%rax,%rax,1\) + +0+10 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 66 66 66 66 2e 0f 1f 84 00 00 00 00 00 data32 data32 data32 data32 nopw %cs:0x0\(%rax,%rax,1\) + +0+20 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 66 66 66 2e 0f 1f 84 00 00 00 00 00 data32 data32 data32 nopw %cs:0x0\(%rax,%rax,1\) + +0+30 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 66 66 2e 0f 1f 84 00 00 00 00 00 data32 data32 nopw %cs:0x0\(%rax,%rax,1\) + +0+40 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 66 2e 0f 1f 84 00 00 00 00 00 data32 nopw %cs:0x0\(%rax,%rax,1\) + +0+50 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 2e 0f 1f 84 00 00 00 00 00 nopw %cs:0x0\(%rax,%rax,1\) + +0+60 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 0f 1f 84 00 00 00 00 00 nopw 0x0\(%rax,%rax,1\) + +0+70 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 0f 1f 84 00 00 00 00 00 nopl 0x0\(%rax,%rax,1\) + +0+80 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 0f 1f 80 00 00 00 00 nopl 0x0\(%rax\) + +0+90 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 0f 1f 44 00 00 nopw 0x0\(%rax,%rax,1\) + +0+a0 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 0f 1f 44 00 00 nopl 0x0\(%rax,%rax,1\) + +0+b0 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 0f 1f 40 00 nopl 0x0\(%rax\) + +0+c0 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 0f 1f 00 nopl \(%rax\) + +0+d0 : +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 90 nop +[ ]*[a-f0-9]+: 66 90 xchg %ax,%ax +#pass diff --git a/gas/testsuite/gas/i386/x86-64-nops-1.d b/gas/testsuite/gas/i386/x86-64-nops-1.d index cb8cea5b041..b385ab5dfc1 100644 --- a/gas/testsuite/gas/i386/x86-64-nops-1.d +++ b/gas/testsuite/gas/i386/x86-64-nops-1.d @@ -1,5 +1,4 @@ #source: nops-1.s -#as: -mtune=generic64 #objdump: -drw #name: x86-64 nops 1 diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog index 98dedc3248a..ea0eeefca5a 100644 --- a/opcodes/ChangeLog +++ b/opcodes/ChangeLog @@ -1,3 +1,9 @@ +2010-10-16 H.J. Lu + + * i386-gen.c (cpu_flag_init): Add CpuNop to CPU_GENERIC64_FLAGS. + + * i386-init.h: Regenerated. + 2010-10-15 Mike Frysinger * bfin-dis.c (decode_dsp32alu_0): Call imm5d() for BYTEOP2M. diff --git a/opcodes/i386-gen.c b/opcodes/i386-gen.c index 79fe9ad8c1e..ee0633863d4 100644 --- a/opcodes/i386-gen.c +++ b/opcodes/i386-gen.c @@ -47,7 +47,7 @@ static initializer cpu_flag_init[] = { "CPU_GENERIC32_FLAGS", "Cpu186|Cpu286|Cpu386" }, { "CPU_GENERIC64_FLAGS", - "Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|Cpu387|Cpu687|CpuMMX|CpuSSE|CpuSSE2|CpuLM" }, + "Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|Cpu387|Cpu687|CpuNop|CpuMMX|CpuSSE|CpuSSE2|CpuLM" }, { "CPU_NONE_FLAGS", "0" }, { "CPU_I186_FLAGS", diff --git a/opcodes/i386-init.h b/opcodes/i386-init.h index 9a3a999c51c..fe546b60e14 100644 --- a/opcodes/i386-init.h +++ b/opcodes/i386-init.h @@ -30,7 +30,7 @@ 0, 0, 0, 0, 0, 0, 0, 0, 0 } } #define CPU_GENERIC64_FLAGS \ - { { 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, \ + { { 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, \ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, \ 0, 0, 0, 0, 0, 1, 0, 0, 0 } } -- 2.30.2