2009-01-10  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/config/tc-i386.c (cpu_arch): Add corei7, .clflush and
	.syscall.
	(i386_align_code): Handle PROCESSOR_COREI7.
	(md_show_usage): Add corei7, clflush and syscall.
	(i386_target_format): Replace cpup4 with cpuclflush.

	* gas/config/tc-i386.h (processor_type): Add PROCESSOR_COREI7.

	* doc/c-i386.texi: Document corei7, clflush and syscall.

gas/testsuite/

2009-01-10  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/i386/arch-10.s: Add clflush and syscall.
	* gas/i386/x86-64-arch-2.s: Likewise.

	* gas/i386/arch-10.d: Updated.
	* gas/i386/arch-10-1.l: Likewise.
	* gas/i386/arch-10-2.l: Likewise.
	* gas/i386/arch-10-3.l: Likewise.
	* gas/i386/arch-10-4.l: Likewise.
	* gas/i386/x86-64-arch-2.d: Likewise.

opcodes/

2009-01-10  H.J. Lu  <hongjiu.lu@intel.com>

	* i386-gen.c (cpu_flag_init): Replace CpuP4 and CpuK6 with
	CpuClflush and CpuSYSCALL, respectively. Remove CpuK8.  Add
	CPU_COREI7_FLAGS, CPU_CLFLUSH_FLAGS and CPU_SYSCALL_FLAGS.
	(cpu_flags): Remove CpuP4, CpuK6 and CpuK8.  Add CpuClflush
	and CpuSYSCALL.
	(lineno): Removed.
	(set_bitfield): Take an argument, lineno.  Don't report lineno
	on error if it is -1.
	(process_i386_cpu_flag): Take an argument, lineno.
	(process_i386_opcode_modifier): Likewise.
	(process_i386_operand_type): Likewise.
	(output_i386_opcode): Likewise.
	(opcode_hash_entry): Add lineno.
	(process_i386_opcodes): Updated.
	(process_i386_registers): Likewise.
	(process_i386_initializers): Likewise.

	* i386-opc.h (CpuP4): Removed.
	(CpuK6): Likewise.
	(CpuK8): Likewise.
	(CpuClflush): New.
	(CpuSYSCALL): Likewise.
	(CpuMMX): Updated.
	(i386_cpu_flags): Remove cpup4, cpuk6 and cpuk8.  Add
	cpuclflush and cpusyscall.

	* i386-opc.tbl: Update movnti, clflush, lfence, mfence, pause,
	syscall and sysret.
	* i386-init.h: Regenerated.
	* i386-tbl.h: Likewise.
This commit is contained in:
H.J. Lu 2009-01-10 17:25:52 +00:00
parent 38788b66ed
commit bd5295b282
19 changed files with 3397 additions and 3262 deletions

View File

@ -1,3 +1,15 @@
2009-01-10 H.J. Lu <hongjiu.lu@intel.com>
* gas/config/tc-i386.c (cpu_arch): Add corei7, .clflush and
.syscall.
(i386_align_code): Handle PROCESSOR_COREI7.
(md_show_usage): Add corei7, clflush and syscall.
(i386_target_format): Replace cpup4 with cpuclflush.
* gas/config/tc-i386.h (processor_type): Add PROCESSOR_COREI7.
* doc/c-i386.texi: Document corei7, clflush and syscall.
2009-01-09 H.J. Lu <hongjiu.lu@intel.com>
* config/tc-i386.c (cpu_arch): Add .rdtscp.

View File

@ -600,6 +600,8 @@ static const arch_entry cpu_arch[] =
CPU_CORE2_FLAGS },
{ "core2", PROCESSOR_CORE2,
CPU_CORE2_FLAGS },
{ "corei7", PROCESSOR_COREI7,
CPU_COREI7_FLAGS },
{ "k6", PROCESSOR_K6,
CPU_K6_FLAGS },
{ "k6_2", PROCESSOR_K6,
@ -650,6 +652,10 @@ static const arch_entry cpu_arch[] =
CPU_MOVBE_FLAGS },
{ ".ept", PROCESSOR_UNKNOWN,
CPU_EPT_FLAGS },
{ ".clflush", PROCESSOR_UNKNOWN,
CPU_CLFLUSH_FLAGS },
{ ".syscall", PROCESSOR_UNKNOWN,
CPU_SYSCALL_FLAGS },
{ ".rdtscp", PROCESSOR_UNKNOWN,
CPU_RDTSCP_FLAGS },
{ ".3dnow", PROCESSOR_UNKNOWN,
@ -950,8 +956,8 @@ i386_align_code (fragS *fragP, int count)
1. For PROCESSOR_I386, PROCESSOR_I486, PROCESSOR_PENTIUM and
PROCESSOR_GENERIC32, f32_patt will be used.
2. For PROCESSOR_PENTIUMPRO, PROCESSOR_PENTIUM4, PROCESSOR_NOCONA,
PROCESSOR_CORE, PROCESSOR_CORE2, and PROCESSOR_GENERIC64,
alt_long_patt will be used.
PROCESSOR_CORE, PROCESSOR_CORE2, PROCESSOR_COREI7, and
PROCESSOR_GENERIC64, alt_long_patt will be used.
3. For PROCESSOR_ATHLON, PROCESSOR_K6, PROCESSOR_K8 and
PROCESSOR_AMDFAM10, alt_short_patt will be used.
@ -997,6 +1003,7 @@ i386_align_code (fragS *fragP, int count)
case PROCESSOR_NOCONA:
case PROCESSOR_CORE:
case PROCESSOR_CORE2:
case PROCESSOR_COREI7:
case PROCESSOR_GENERIC64:
patt = alt_long_patt;
break;
@ -1044,6 +1051,7 @@ i386_align_code (fragS *fragP, int count)
case PROCESSOR_NOCONA:
case PROCESSOR_CORE:
case PROCESSOR_CORE2:
case PROCESSOR_COREI7:
if (fragP->tc_frag_data.isa_flags.bitfield.cpui686)
patt = alt_long_patt;
else
@ -8232,18 +8240,18 @@ md_show_usage (stream)
generate code for CPU and EXTENSION, CPU is one of:\n\
i8086, i186, i286, i386, i486, pentium, pentiumpro,\n\
pentiumii, pentiumiii, pentium4, prescott, nocona,\n\
core, core2, k6, k6_2, athlon, k8, amdfam10,\n\
core, core2, corei7, k6, k6_2, athlon, k8, amdfam10,\n\
generic32, generic64\n\
EXTENSION is combination of:\n\
mmx, sse, sse2, sse3, ssse3, sse4.1, sse4.2, sse4,\n\
avx, vmx, smx, xsave, movbe, ept, aes, pclmul, fma,\n\
rdtscp, 3dnow, 3dnowa, sse4a, sse5, svme, abm,\n\
padlock\n"));
clflush, syscall, rdtscp, 3dnow, 3dnowa, sse4a,\n\
sse5, svme, abm, padlock\n"));
fprintf (stream, _("\
-mtune=CPU optimize for CPU, CPU is one of:\n\
i8086, i186, i286, i386, i486, pentium, pentiumpro,\n\
pentiumii, pentiumiii, pentium4, prescott, nocona,\n\
core, core2, k6, k6_2, athlon, k8, amdfam10,\n\
core, core2, corei7, k6, k6_2, athlon, k8, amdfam10,\n\
generic32, generic64\n"));
fprintf (stream, _("\
-msse2avx encode SSE instructions with VEX prefix\n"));
@ -8281,7 +8289,7 @@ i386_target_format (void)
cpu_arch_isa_flags.bitfield.cpui486 = 1;
cpu_arch_isa_flags.bitfield.cpui586 = 1;
cpu_arch_isa_flags.bitfield.cpui686 = 1;
cpu_arch_isa_flags.bitfield.cpup4 = 1;
cpu_arch_isa_flags.bitfield.cpuclflush = 1;
cpu_arch_isa_flags.bitfield.cpummx= 1;
cpu_arch_isa_flags.bitfield.cpusse = 1;
cpu_arch_isa_flags.bitfield.cpusse2 = 1;
@ -8294,7 +8302,7 @@ i386_target_format (void)
cpu_arch_tune_flags.bitfield.cpui486 = 1;
cpu_arch_tune_flags.bitfield.cpui586 = 1;
cpu_arch_tune_flags.bitfield.cpui686 = 1;
cpu_arch_tune_flags.bitfield.cpup4 = 1;
cpu_arch_tune_flags.bitfield.cpuclflush = 1;
cpu_arch_tune_flags.bitfield.cpummx= 1;
cpu_arch_tune_flags.bitfield.cpusse = 1;
cpu_arch_tune_flags.bitfield.cpusse2 = 1;

View File

@ -198,6 +198,7 @@ enum processor_type
PROCESSOR_NOCONA,
PROCESSOR_CORE,
PROCESSOR_CORE2,
PROCESSOR_COREI7,
PROCESSOR_K6,
PROCESSOR_ATHLON,
PROCESSOR_K8,

View File

@ -100,6 +100,7 @@ processor names are recognized:
@code{nocona},
@code{core},
@code{core2},
@code{corei7},
@code{k6},
@code{k6_2},
@code{athlon},
@ -130,6 +131,8 @@ accept various extension mnemonics. For example,
@code{fma},
@code{movbe},
@code{ept},
@code{clflush},
@code{syscall},
@code{rdtscp},
@code{3dnow},
@code{3dnowa},
@ -873,14 +876,14 @@ supported on the CPU specified. The choices for @var{cpu_type} are:
@item @samp{i486} @tab @samp{i586} @tab @samp{i686} @tab @samp{pentium}
@item @samp{pentiumpro} @tab @samp{pentiumii} @tab @samp{pentiumiii} @tab @samp{pentium4}
@item @samp{prescott} @tab @samp{nocona} @tab @samp{core} @tab @samp{core2}
@item @samp{k6} @tab @samp{k6_2} @tab @samp{athlon} @tab @samp{k8}
@item @samp{amdfam10}
@item @samp{corei7} @tab @samp{k6} @tab @samp{k6_2} @tab @samp{athlon}
@item @samp{k8} @tab @samp{amdfam10}
@item @samp{generic32} @tab @samp{generic64}
@item @samp{.mmx} @tab @samp{.sse} @tab @samp{.sse2} @tab @samp{.sse3}
@item @samp{.ssse3} @tab @samp{.sse4.1} @tab @samp{.sse4.2} @tab @samp{.sse4}
@item @samp{.avx} @tab @samp{.vmx} @tab @samp{.smx} @tab @samp{.xsave}
@item @samp{.aes} @tab @samp{.pclmul} @tab @samp{.fma} @tab @samp{.movbe}
@item @samp{.ept} @tab @samp{.rdtscp}
@item @samp{.ept} @tab @samp{.clflush} @tab @samp{.syscall} @tab @samp{.rdtscp}
@item @samp{.3dnow} @tab @samp{.3dnowa} @tab @samp{.sse4a} @tab @samp{.sse5}
@item @samp{.svme} @tab @samp{.abm}
@item @samp{.padlock}

View File

@ -1,3 +1,15 @@
2009-01-10 H.J. Lu <hongjiu.lu@intel.com>
* gas/i386/arch-10.s: Add clflush and syscall.
* gas/i386/x86-64-arch-2.s: Likewise.
* gas/i386/arch-10.d: Updated.
* gas/i386/arch-10-1.l: Likewise.
* gas/i386/arch-10-2.l: Likewise.
* gas/i386/arch-10-3.l: Likewise.
* gas/i386/arch-10-4.l: Likewise.
* gas/i386/x86-64-arch-2.d: Likewise.
2009-01-09 H.J. Lu <hongjiu.lu@intel.com>
* gas/i386/arch-10.s: Add rdtscp.

View File

@ -25,6 +25,8 @@
.*:50: Error: .*
.*:52: Error: .*
.*:54: Error: .*
.*:56: Error: .*
.*:58: Error: .*
GAS LISTING .*
@ -33,53 +35,60 @@ GAS LISTING .*
[ ]*2[ ]+\.text
[ ]*3[ ]+\# cmov feature
[ ]*4[ ]+cmove %eax,%ebx
[ ]*5[ ]+\# MMX
[ ]*6[ ]+paddb %mm4,%mm3
[ ]*7[ ]+\# SSE
[ ]*8[ ]+addss %xmm4,%xmm3
[ ]*9[ ]+\# SSE2
[ ]*10[ ]+addsd %xmm4,%xmm3
[ ]*11[ ]+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xmm2, %xmm1
GAS LISTING .*
[ ]*57[ ]+\# PadLock
[ ]*58[ ]+xstorerng

View File

@ -24,6 +24,8 @@
.*:50: Error: .*
.*:52: Error: .*
.*:54: Error: .*
.*:56: Error: .*
.*:58: Error: .*
GAS LISTING .*
@ -32,53 +34,60 @@ GAS LISTING .*
[ ]*2[ ]+\.text
[ ]*3[ ]+\# cmov feature
[ ]*4[ ]+\?\?\?\? 0F44D8 cmove %eax,%ebx
[ ]*5[ ]+\# MMX
[ ]*6[ ]+paddb %mm4,%mm3
[ ]*7[ ]+\# SSE
[ ]*8[ ]+addss %xmm4,%xmm3
[ ]*9[ ]+\# SSE2
[ ]*10[ ]+addsd %xmm4,%xmm3
[ ]*11[ ]+\# SSE3
[ ]*12[ ]+addsubpd %xmm4,%xmm3
[ ]*13[ ]+\# SSSE3
[ ]*14[ ]+phaddw %xmm4,%xmm3
[ ]*15[ ]+\# SSE4\.1
[ ]*16[ ]+phminposuw %xmm1,%xmm3
[ ]*17[ ]+\# SSE4\.2
[ ]*18[ ]+crc32 %ecx,%ebx
[ ]*19[ ]+\# AVX
[ ]*20[ ]+vzeroall
[ ]*21[ ]+\# VMX
[ ]*22[ ]+vmxoff
[ ]*23[ ]+\# SMX
[ ]*24[ ]+getsec
[ ]*25[ ]+\# Xsave
[ ]*26[ ]+xgetbv
[ ]*27[ ]+\# AES
[ ]*28[ ]+aesenc \(%ecx\),%xmm0
[ ]*29[ ]+\# PCLMUL
[ ]*30[ ]+pclmulqdq \$8,%xmm1,%xmm0
[ ]*31[ ]+\# AES \+ AVX
[ ]*32[ ]+vaesenc \(%ecx\),%xmm0,%xmm2
[ ]*33[ ]+\# FMA
[ ]*34[ ]+vfmadd132pd %xmm4,%xmm6,%xmm2
[ ]*35[ ]+\# MOVBE
[ ]*36[ ]+movbe \(%ecx\),%ebx
[ ]*37[ ]+\# EPT
[ ]*38[ ]+invept \(%ecx\),%ebx
[ ]*39[ ]+\# RDTSCP
[ ]*40[ ]+rdtscp
[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
[ ]*39[ ]+\# MOVBE
[ ]*40[ ]+movbe \(%ecx\),%ebx
[ ]*41[ ]+\# EPT
[ ]*42[ ]+invept \(%ecx\),%ebx
[ ]*43[ ]+\# RDTSCP
[ ]*44[ ]+rdtscp
[ ]*45[ ]+\# 3DNow
[ ]*46[ ]+pmulhrw %mm4,%mm3
[ ]*47[ ]+\# 3DNow Extensions
[ ]*48[ ]+pswapd %mm4,%mm3
[ ]*49[ ]+\# SSE4a
[ ]*50[ ]+insertq %xmm2,%xmm1
[ ]*51[ ]+\# SVME
[ ]*52[ ]+vmload
[ ]*53[ ]+\# ABM
[ ]*54[ ]+lzcnt %ecx,%ebx
[ ]*55[ ]+\# SSE5
[ ]*56[ ]+frczss %xmm2, %xmm1
GAS LISTING .*
[ ]*57[ ]+\# PadLock
[ ]*58[ ]+xstorerng

View File

@ -1,6 +1,6 @@
.*: Assembler messages:
.*:20: Error: .*
.*:22: Error: .*
.*:6: Error: .*
.*:8: Error: .*
.*:24: Error: .*
.*:26: Error: .*
.*:28: Error: .*
@ -17,6 +17,8 @@
.*:50: Error: .*
.*:52: Error: .*
.*:54: Error: .*
.*:56: Error: .*
.*:58: Error: .*
GAS LISTING .*
@ -25,59 +27,63 @@ GAS LISTING .*
[ ]*2[ ]+\.text
[ ]*3[ ]+\# cmov feature
[ ]*4[ ]+\?\?\?\? 0F44D8 cmove %eax,%ebx
[ ]*5[ ]+\# MMX
[ ]*6[ ]+\?\?\?\? 0FFCDC paddb %mm4,%mm3
[ ]*7[ ]+\# SSE
[ ]*8[ ]+\?\?\?\? F30F58DC addss %xmm4,%xmm3
[ ]*9[ ]+\# SSE2
[ ]*10[ ]+\?\?\?\? F20F58DC addsd %xmm4,%xmm3
[ ]*11[ ]+\# SSE3
[ ]*12[ ]+\?\?\?\? 660FD0DC addsubpd %xmm4,%xmm3
[ ]*13[ ]+\# SSSE3
[ ]*14[ ]+\?\?\?\? 660F3801 phaddw %xmm4,%xmm3
[ ]*14[ ]+DC
[ ]*15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# SVME
[ ]*52[ ]+vmload
[ ]*53[ ]+\# ABM
GAS LISTING .*
[ ]*54[ ]+xstorerng
[ ]*54[ ]+lzcnt %ecx,%ebx
[ ]*55[ ]+\# SSE5
[ ]*56[ ]+frczss %xmm2, %xmm1
[ ]*57[ ]+\# PadLock
[ ]*58[ ]+xstorerng

View File

@ -1,7 +1,7 @@
.*: Assembler messages:
.*:20: Error: .*
.*:26: Error: .*
.*:28: Error: .*
.*:6: Error: .*
.*:8: Error: .*
.*:24: Error: .*
.*:30: Error: .*
.*:32: Error: .*
.*:34: Error: .*
@ -15,6 +15,8 @@
.*:50: Error: .*
.*:52: Error: .*
.*:54: Error: .*
.*:56: Error: .*
.*:58: Error: .*
GAS LISTING .*
@ -23,59 +25,63 @@ GAS LISTING .*
[ ]*2[ ]+\.text
[ ]*3[ ]+\# cmov feature
[ ]*4[ ]+\?\?\?\? 0F44D8 cmove %eax,%ebx
[ ]*5[ ]+\# MMX
[ ]*6[ ]+\?\?\?\? 0FFCDC paddb %mm4,%mm3
[ ]*7[ ]+\# SSE
[ ]*8[ ]+\?\?\?\? F30F58DC addss %xmm4,%xmm3
[ ]*9[ ]+\# SSE2
[ ]*10[ ]+\?\?\?\? F20F58DC addsd %xmm4,%xmm3
[ ]*11[ ]+\# SSE3
[ ]*12[ ]+\?\?\?\? 660FD0DC addsubpd %xmm4,%xmm3
[ ]*13[ ]+\# SSSE3
[ ]*14[ ]+\?\?\?\? 660F3801 phaddw %xmm4,%xmm3
[ ]*14[ ]+DC
[ ]*15[ ]+\# SSE4\.1
[ ]*16[ ]+\?\?\?\? 660F3841 phminposuw %xmm1,%xmm3
[ ]*16[ ]+D9
[ ]*17[ ]+\# SSE4\.2
[ ]*18[ ]+\?\?\?\? F20F38F1 crc32 %ecx,%ebx
[ ]*18[ ]+D9
[ ]*19[ ]+\# AVX
[ ]*20[ ]+vzeroall
[ ]*21[ ]+\# VMX
[ ]*22[ ]+\?\?\?\? 0F01C4 vmxoff
[ ]*23[ ]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 @@
#as: -march=i686+avx+vmx+smx+xsave+aes+pclmul+fma+movbe+ept+rdtscp+sse5+3dnowa+svme+padlock
#as: -march=i686+avx+vmx+smx+xsave+aes+pclmul+fma+movbe+ept+clflush+syscall+rdtscp+sse5+3dnowa+svme+padlock
#objdump: -dw
#name: i386 arch 10
@ -8,6 +8,8 @@ Disassembly of section .text:
0+ <.text>:
[ ]*[a-f0-9]+: 0f 44 d8 cmove %eax,%ebx
[ ]*[a-f0-9]+: 0f ae 38 clflush \(%eax\)
[ ]*[a-f0-9]+: 0f 05 syscall
[ ]*[a-f0-9]+: 0f fc dc paddb %mm4,%mm3
[ ]*[a-f0-9]+: f3 0f 58 dc addss %xmm4,%xmm3
[ ]*[a-f0-9]+: f2 0f 58 dc addsd %xmm4,%xmm3

View File

@ -2,6 +2,10 @@
.text
# cmov feature
cmove %eax,%ebx
# clflush
clflush (%eax)
# SYSCALL
syscall
# MMX
paddb %mm4,%mm3
# SSE

View File

@ -1,4 +1,4 @@
#as: -march=generic64+avx+vmx+smx+xsave+aes+pclmul+fma+movbe+ept+rdtscp+sse5+3dnowa+svme+padlock
#as: -march=generic64+avx+vmx+smx+xsave+aes+pclmul+fma+movbe+ept+clflush+syscall+rdtscp+sse5+3dnowa+svme+padlock
#objdump: -dw
#name: x86-64 arch 2
@ -8,6 +8,8 @@ Disassembly of section .text:
0+ <.text>:
[ ]*[a-f0-9]+: 0f 44 d8 cmove %eax,%ebx
[ ]*[a-f0-9]+: 0f ae 38 clflush \(%rax\)
[ ]*[a-f0-9]+: 0f 05 syscall
[ ]*[a-f0-9]+: 0f fc dc paddb %mm4,%mm3
[ ]*[a-f0-9]+: f3 0f 58 dc addss %xmm4,%xmm3
[ ]*[a-f0-9]+: f2 0f 58 dc addsd %xmm4,%xmm3

View File

@ -2,6 +2,10 @@
.text
# cmov feature
cmove %eax,%ebx
# clflush
clflush (%rax)
# SYSCALL
syscall
# MMX
paddb %mm4,%mm3
# SSE

View File

@ -1,3 +1,36 @@
2009-01-10 H.J. Lu <hongjiu.lu@intel.com>
* i386-gen.c (cpu_flag_init): Replace CpuP4 and CpuK6 with
CpuClflush and CpuSYSCALL, respectively. Remove CpuK8. Add
CPU_COREI7_FLAGS, CPU_CLFLUSH_FLAGS and CPU_SYSCALL_FLAGS.
(cpu_flags): Remove CpuP4, CpuK6 and CpuK8. Add CpuClflush
and CpuSYSCALL.
(lineno): Removed.
(set_bitfield): Take an argument, lineno. Don't report lineno
on error if it is -1.
(process_i386_cpu_flag): Take an argument, lineno.
(process_i386_opcode_modifier): Likewise.
(process_i386_operand_type): Likewise.
(output_i386_opcode): Likewise.
(opcode_hash_entry): Add lineno.
(process_i386_opcodes): Updated.
(process_i386_registers): Likewise.
(process_i386_initializers): Likewise.
* i386-opc.h (CpuP4): Removed.
(CpuK6): Likewise.
(CpuK8): Likewise.
(CpuClflush): New.
(CpuSYSCALL): Likewise.
(CpuMMX): Updated.
(i386_cpu_flags): Remove cpup4, cpuk6 and cpuk8. Add
cpuclflush and cpusyscall.
* i386-opc.tbl: Update movnti, clflush, lfence, mfence, pause,
syscall and sysret.
* i386-init.h: Regenerated.
* i386-tbl.h: Likewise.
2009-01-09 H.J. Lu <hongjiu.lu@intel.com>
* i386-gen.c (cpu_flag_init): Add CpuRdtscp to CPU_K8_FLAGS

View File

@ -47,7 +47,7 @@ static initializer cpu_flag_init [] =
{ "CPU_GENERIC32_FLAGS",
"Cpu186|Cpu286|Cpu386" },
{ "CPU_GENERIC64_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuP4|CpuMMX|CpuSSE|CpuSSE2|CpuLM" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|CpuMMX|CpuSSE|CpuSSE2|CpuLM" },
{ "CPU_NONE_FLAGS",
"0" },
{ "CPU_I186_FLAGS",
@ -67,23 +67,29 @@ static initializer cpu_flag_init [] =
{ "CPU_P3_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuMMX|CpuSSE" },
{ "CPU_P4_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuP4|CpuMMX|CpuSSE|CpuSSE2" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|CpuMMX|CpuSSE|CpuSSE2" },
{ "CPU_NOCONA_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuP4|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3|CpuLM" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3|CpuLM" },
{ "CPU_CORE_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuP4|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3" },
{ "CPU_CORE2_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuP4|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3|CpuSSSE3|CpuLM" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3|CpuSSSE3|CpuLM" },
{ "CPU_COREI7_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuClflush|CpuMMX|CpuSSE|CpuSSE2|CpuSSE3|CpuSSSE3|CpuSSE4_1|CpuSSE4_2|CpuRdtscp|CpuLM" },
{ "CPU_K6_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|CpuK6|CpuMMX" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|CpuSYSCALL|CpuMMX" },
{ "CPU_K6_2_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|CpuK6|CpuMMX|Cpu3dnow" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|CpuSYSCALL|CpuMMX|Cpu3dnow" },
{ "CPU_ATHLON_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuK6|CpuMMX|Cpu3dnow|Cpu3dnowA" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuSYSCALL|CpuMMX|Cpu3dnow|Cpu3dnowA" },
{ "CPU_K8_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuK6|CpuK8|CpuMMX|Cpu3dnow|Cpu3dnowA|CpuSSE|CpuSSE2|CpuRdtscp|CpuLM" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuSYSCALL|CpuRdtscp|CpuMMX|Cpu3dnow|Cpu3dnowA|CpuSSE|CpuSSE2|CpuLM" },
{ "CPU_AMDFAM10_FLAGS",
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuK6|CpuK8|CpuMMX|Cpu3dnow|Cpu3dnowA|CpuSSE|CpuSSE2|CpuSSE3|CpuSSE4a|CpuABM|CpuRdtscp|CpuLM" },
"Cpu186|Cpu286|Cpu386|Cpu486|Cpu586|Cpu686|CpuSYSCALL|CpuRdtscp|CpuMMX|Cpu3dnow|Cpu3dnowA|CpuSSE|CpuSSE2|CpuSSE3|CpuSSE4a|CpuABM|CpuLM" },
{ "CPU_CLFLUSH_FLAGS",
"CpuClflush" },
{ "CPU_SYSCALL_FLAGS",
"CpuSYSCALL" },
{ "CPU_MMX_FLAGS",
"CpuMMX" },
{ "CPU_SSE_FLAGS",
@ -249,9 +255,8 @@ static bitfield cpu_flags[] =
BITFIELD (Cpu486),
BITFIELD (Cpu586),
BITFIELD (Cpu686),
BITFIELD (CpuP4),
BITFIELD (CpuK6),
BITFIELD (CpuK8),
BITFIELD (CpuClflush),
BITFIELD (CpuSYSCALL),
BITFIELD (CpuMMX),
BITFIELD (CpuSSE),
BITFIELD (CpuSSE2),
@ -397,7 +402,6 @@ static bitfield operand_types[] =
#endif
};
static int lineno;
static const char *filename;
static int
@ -499,7 +503,7 @@ next_field (char *str, char sep, char **next, char *last)
}
static void
set_bitfield (const char *f, bitfield *array, unsigned int size)
set_bitfield (const char *f, bitfield *array, unsigned int size, int lineno)
{
unsigned int i;
@ -515,7 +519,10 @@ set_bitfield (const char *f, bitfield *array, unsigned int size)
return;
}
fail (_("%s: %d: Unknown bitfield: %s\n"), filename, lineno, f);
if (lineno != -1)
fail (_("%s: %d: Unknown bitfield: %s\n"), filename, lineno, f);
else
fail (_("Unknown bitfield: %s\n"), f);
}
static void
@ -544,7 +551,8 @@ output_cpu_flags (FILE *table, bitfield *flags, unsigned int size,
static void
process_i386_cpu_flag (FILE *table, char *flag, int macro,
const char *comma, const char *indent)
const char *comma, const char *indent,
int lineno)
{
char *str, *next, *last;
bitfield flags [ARRAY_SIZE (cpu_flags)];
@ -569,7 +577,7 @@ process_i386_cpu_flag (FILE *table, char *flag, int macro,
{
str = next_field (next, '|', &next, last);
if (str)
set_bitfield (str, flags, ARRAY_SIZE (flags));
set_bitfield (str, flags, ARRAY_SIZE (flags), lineno);
}
}
@ -595,7 +603,7 @@ output_opcode_modifier (FILE *table, bitfield *modifier, unsigned int size)
}
static void
process_i386_opcode_modifier (FILE *table, char *mod)
process_i386_opcode_modifier (FILE *table, char *mod, int lineno)
{
char *str, *next, *last;
bitfield modifiers [ARRAY_SIZE (opcode_modifiers)];
@ -610,7 +618,7 @@ process_i386_opcode_modifier (FILE *table, char *mod)
{
str = next_field (next, '|', &next, last);
if (str)
set_bitfield (str, modifiers, ARRAY_SIZE (modifiers));
set_bitfield (str, modifiers, ARRAY_SIZE (modifiers), lineno);
}
}
output_opcode_modifier (table, modifiers, ARRAY_SIZE (modifiers));
@ -642,7 +650,7 @@ output_operand_type (FILE *table, bitfield *types, unsigned int size,
static void
process_i386_operand_type (FILE *table, char *op, int macro,
const char *indent)
const char *indent, int lineno)
{
char *str, *next, *last;
bitfield types [ARRAY_SIZE (operand_types)];
@ -657,7 +665,7 @@ process_i386_operand_type (FILE *table, char *op, int macro,
{
str = next_field (next, '|', &next, last);
if (str)
set_bitfield (str, types, ARRAY_SIZE (types));
set_bitfield (str, types, ARRAY_SIZE (types), lineno);
}
}
output_operand_type (table, types, ARRAY_SIZE (types), macro,
@ -666,7 +674,7 @@ process_i386_operand_type (FILE *table, char *op, int macro,
static void
output_i386_opcode (FILE *table, const char *name, char *str,
char *last)
char *last, int lineno)
{
unsigned int i;
char *operands, *base_opcode, *extension_opcode, *opcode_length;
@ -737,9 +745,9 @@ output_i386_opcode (FILE *table, const char *name, char *str,
name, operands, base_opcode, extension_opcode,
opcode_length);
process_i386_cpu_flag (table, cpu_flags, 0, ",", " ");
process_i386_cpu_flag (table, cpu_flags, 0, ",", " ", lineno);
process_i386_opcode_modifier (table, opcode_modifier);
process_i386_opcode_modifier (table, opcode_modifier, lineno);
fprintf (table, " { ");
@ -748,7 +756,7 @@ output_i386_opcode (FILE *table, const char *name, char *str,
if (operand_types[i] == NULL || *operand_types[i] == '0')
{
if (i == 0)
process_i386_operand_type (table, "0", 0, "\t ");
process_i386_operand_type (table, "0", 0, "\t ", lineno);
break;
}
@ -756,7 +764,7 @@ output_i386_opcode (FILE *table, const char *name, char *str,
fprintf (table, ",\n ");
process_i386_operand_type (table, operand_types[i], 0,
"\t ");
"\t ", lineno);
}
fprintf (table, " } },\n");
}
@ -766,6 +774,7 @@ struct opcode_hash_entry
struct opcode_hash_entry *next;
char *name;
char *opcode;
int lineno;
};
/* Calculate the hash value of an opcode hash entry P. */
@ -798,6 +807,7 @@ process_i386_opcodes (FILE *table)
htab_t opcode_hash_table;
struct opcode_hash_entry **opcode_array;
unsigned int opcode_array_size = 1024;
int lineno = 0;
filename = "i386-opc.tbl";
fp = fopen (filename, "r");
@ -874,6 +884,7 @@ process_i386_opcodes (FILE *table)
opcode_array[i]->next = NULL;
opcode_array[i]->name = xstrdup (name);
opcode_array[i]->opcode = xstrdup (str);
opcode_array[i]->lineno = lineno;
*hash_slot = opcode_array[i];
i++;
}
@ -888,6 +899,7 @@ process_i386_opcodes (FILE *table)
(*entry)->next = NULL;
(*entry)->name = (*hash_slot)->name;
(*entry)->opcode = xstrdup (str);
(*entry)->lineno = lineno;
}
}
@ -898,8 +910,9 @@ process_i386_opcodes (FILE *table)
{
name = next->name;
str = next->opcode;
lineno = next->lineno;
last = str + strlen (str);
output_i386_opcode (table, name, str, last);
output_i386_opcode (table, name, str, last, lineno);
}
}
@ -907,12 +920,12 @@ process_i386_opcodes (FILE *table)
fprintf (table, " { NULL, 0, 0, 0, 0,\n");
process_i386_cpu_flag (table, "0", 0, ",", " ");
process_i386_cpu_flag (table, "0", 0, ",", " ", -1);
process_i386_opcode_modifier (table, "0");
process_i386_opcode_modifier (table, "0", -1);
fprintf (table, " { ");
process_i386_operand_type (table, "0", 0, "\t ");
process_i386_operand_type (table, "0", 0, "\t ", -1);
fprintf (table, " } }\n");
fprintf (table, "};\n");
@ -926,6 +939,7 @@ process_i386_registers (FILE *table)
char *str, *p, *last;
char *reg_name, *reg_type, *reg_flags, *reg_num;
char *dw2_32_num, *dw2_64_num;
int lineno = 0;
filename = "i386-reg.tbl";
fp = fopen (filename, "r");
@ -980,7 +994,7 @@ process_i386_registers (FILE *table)
fprintf (table, " { \"%s\",\n ", reg_name);
process_i386_operand_type (table, reg_type, 0, "\t");
process_i386_operand_type (table, reg_type, 0, "\t", lineno);
/* Find 32-bit Dwarf2 register number. */
dw2_32_num = next_field (str, ',', &str, last);
@ -1016,7 +1030,7 @@ process_i386_initializers (void)
{
fprintf (fp, "\n#define %s \\\n", cpu_flag_init[i].name);
init = xstrdup (cpu_flag_init[i].init);
process_i386_cpu_flag (fp, init, 1, "", " ");
process_i386_cpu_flag (fp, init, 1, "", " ", -1);
free (init);
}
@ -1024,7 +1038,7 @@ process_i386_initializers (void)
{
fprintf (fp, "\n\n#define %s \\\n ", operand_type_init[i].name);
init = xstrdup (operand_type_init[i].init);
process_i386_operand_type (fp, init, 1, " ");
process_i386_operand_type (fp, init, 1, " ", -1);
free (init);
}
fprintf (fp, "\n");

View File

@ -21,183 +21,195 @@
#define CPU_UNKNOWN_FLAGS \
{ { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, \
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1 } }
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1 } }
#define CPU_GENERIC32_FLAGS \
{ { 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, 0, 0, 0, 0, 0, 0 } }
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
#define CPU_GENERIC64_FLAGS \
{ { 1, 1, 1, 1, 1, 1, 1, 0, 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, 1, 0, 0, 0 } }
{ { 1, 1, 1, 1, 1, 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, 1, 0, 0, 0 } }
#define CPU_NONE_FLAGS \
{ { 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, 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 } }
#define CPU_I186_FLAGS \
{ { 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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U_ABM_FLAGS \
{ { 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
#define CPU_SSE5_FLAGS \
{ { 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, \
1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
{ { 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, \
1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
#define CPU_AVX_FLAGS \
{ { 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, \
0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
{ { 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, \
0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
#define OPERAND_TYPE_NONE \

View File

@ -42,14 +42,12 @@
#define Cpu586 (Cpu486 + 1)
/* i686 or better required */
#define Cpu686 (Cpu586 + 1)
/* Pentium4 or better required */
#define CpuP4 (Cpu686 + 1)
/* AMD K6 or better required*/
#define CpuK6 (CpuP4 + 1)
/* AMD K8 or better required */
#define CpuK8 (CpuK6 + 1)
/* CLFLUSH Instuction support required */
#define CpuClflush (Cpu686 + 1)
/* SYSCALL Instuctions support required */
#define CpuSYSCALL (CpuClflush + 1)
/* MMX support required */
#define CpuMMX (CpuK8 + 1)
#define CpuMMX (CpuSYSCALL + 1)
/* SSE support required */
#define CpuSSE (CpuMMX + 1)
/* SSE2 support required */
@ -126,9 +124,8 @@ typedef union i386_cpu_flags
unsigned int cpui486:1;
unsigned int cpui586:1;
unsigned int cpui686:1;
unsigned int cpup4:1;
unsigned int cpuk6:1;
unsigned int cpuk8:1;
unsigned int cpuclflush:1;
unsigned int cpusyscall:1;
unsigned int cpummx:1;
unsigned int cpusse:1;
unsigned int cpusse2:1;

View File

@ -909,11 +909,12 @@ fucompi, 1, 0xdfe8, None, 2, Cpu686, ShortForm|No_bSuf|No_wSuf|No_lSuf|No_sSuf|N
// Pentium4 extensions.
movnti, 2, 0xfc3, None, 2, CpuP4, Modrm|No_bSuf|No_wSuf|No_sSuf|No_ldSuf, { Reg32|Reg64, Dword|Qword|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S }
clflush, 1, 0xfae, 0x7, 2, CpuP4, Modrm|IgnoreSize|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { Byte|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S }
lfence, 0, 0xfae, 0xe8, 2, CpuP4, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }
mfence, 0, 0xfae, 0xf0, 2, CpuP4, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }
pause, 0, 0xf390, None, 2, CpuP4, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { 0 }
movnti, 2, 0xfc3, None, 2, CpuSSE2, Modrm|No_bSuf|No_wSuf|No_sSuf|No_ldSuf, { Reg32|Reg64, Dword|Qword|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S }
clflush, 1, 0xfae, 0x7, 2, CpuClflush, Modrm|IgnoreSize|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { Byte|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S }
lfence, 0, 0xfae, 0xe8, 2, CpuSSE2, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }
mfence, 0, 0xfae, 0xf0, 2, CpuSSE2, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }
// Processors that do not support PAUSE treat this opcode as a NOP instruction.
pause, 0, 0xf390, None, 2, Cpu186, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { 0 }
// MMX/SSE2 instructions.
@ -2488,9 +2489,9 @@ pmulhrw, 2, 0xf0f, 0xb7, 2, Cpu3dnow, Modrm|IgnoreSize|No_bSuf|No_wSuf|No_lSuf|N
pswapd, 2, 0xf0f, 0xbb, 2, Cpu3dnowA, Modrm|IgnoreSize|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { Qword|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S|RegMMX, RegMMX }
// AMD extensions.
syscall, 0, 0xf05, None, 2, CpuK6, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { 0 }
syscall, 0, 0xf05, None, 2, CpuSYSCALL, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { 0 }
syscall, 0, 0xf05, None, 2, Cpu64, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { 0 }
sysret, 0, 0xf07, None, 2, CpuK6, DefaultSize|No_bSuf|No_wSuf|No_sSuf|No_ldSuf, { 0 }
sysret, 0, 0xf07, None, 2, CpuSYSCALL, DefaultSize|No_bSuf|No_wSuf|No_sSuf|No_ldSuf, { 0 }
sysret, 0, 0xf07, None, 2, Cpu64, DefaultSize|No_bSuf|No_wSuf|No_sSuf|No_ldSuf, { 0 }
swapgs, 0, 0xf01, 0xf8, 2, Cpu64, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }
rdtscp, 0, 0xf01, 0xf9, 2, CpuRdtscp, No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }

File diff suppressed because it is too large Load Diff