diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2008-05-02 16:53:40 +0000 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2008-05-02 16:53:40 +0000 |
commit | f1f8f695c0b509617985d96559c940664c01334b (patch) | |
tree | 71b024e8640775137ee73a9d6979dc70f4649c6b /gas | |
parent | 237fc4c9cdd1a1df1e53a8321dfd7b147da722fd (diff) | |
download | gdb-f1f8f695c0b509617985d96559c940664c01334b.zip gdb-f1f8f695c0b509617985d96559c940664c01334b.tar.gz gdb-f1f8f695c0b509617985d96559c940664c01334b.tar.bz2 |
gas/
2008-05-02 H.J. Lu <hongjiu.lu@intel.com>
* NEWS: Mention XSAVE, EPT and MOVBE.
* config/tc-i386.c (cpu_arch): Add .movbe and .ept.
(md_show_usage): Add .movbe and .ept.
* doc/c-i386.texi: Add movbe and ept to -march=. Document
.movbe and .ept.
gas/testsuite/
2008-05-02 H.J. Lu <hongjiu.lu@intel.com>
* gas/i386/i386.exp: Run movbe, movbe-intel, inval-movbe, ept,
ept-intel, inval-ept, x86-64-movbe, x86-64-movbe-intel,
x86-64-inval-movbe. x86-64-ept, x86-64-ept-intel and
x86-64-inval-ept.
* gas/i386/arch-10.s: Add movbe and invept.
* gas/i386/x86-64-arch-2.s: Likewise.
* gas/i386/ept.d: New file
* gas/i386/ept-intel.d: Likewise.
* gas/i386/ept.s: Likewise.
* gas/i386/inval-ept.l: Likewise.
* gas/i386/inval-ept.s: Likewise.
* gas/i386/inval-movbe.l: Likewise.
* gas/i386/inval-movbe.s: Likewise.
* gas/i386/movbe.d: Likewise.
* gas/i386/movbe-intel.d: Likewise.
* gas/i386/movbe.s: Likewise.
* gas/i386/x86-64-inval-ept.l: Likewise.
* gas/i386/x86-64-inval-ept.s: Likewise.
* gas/i386/x86-64-inval-movbe.l: Likewise.
* gas/i386/x86-64-inval-movbe.s: Likewise.
* gas/i386/x86-64-ept.d: Likewise.
* gas/i386/x86-64-ept-intel.d: Likewise.
* gas/i386/x86-64-ept.s: Likewise.
* gas/i386/x86-64-movbe.d: Likewise.
* gas/i386/x86-64-movbe-intel.d: Likewise.
* gas/i386/x86-64-movbe.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/
2008-05-02 H.J. Lu <hongjiu.lu@intel.com>
* i386-dis.c (MOVBE_Fixup): New.
(Mo): Likewise.
(PREFIX_0F3880): Likewise.
(PREFIX_0F3881): Likewise.
(PREFIX_0F38F0): Updated.
(prefix_table): Add PREFIX_0F3880 and PREFIX_0F3881. Update
PREFIX_0F38F0 and PREFIX_0F38F1 for movbe.
(three_byte_table): Use PREFIX_0F3880 and PREFIX_0F3881.
* i386-gen.c (cpu_flag_init): Add CPU_MOVBE_FLAGS and
CPU_EPT_FLAGS.
(cpu_flags): Add CpuMovbe and CpuEPT.
* i386-opc.h (CpuMovbe): New.
(CpuEPT): Likewise.
(CpuLM): Updated.
(i386_cpu_flags): Add cpumovbe and cpuept.
* i386-opc.tbl: Add entries for movbe and EPT instructions.
* i386-init.h: Regenerated.
* i386-tbl.h: Likewise.
Diffstat (limited to 'gas')
34 files changed, 581 insertions, 62 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index aa2f83c..a27a0c9 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,13 @@ +2008-05-02 H.J. Lu <hongjiu.lu@intel.com> + + * NEWS: Mention XSAVE, EPT and MOVBE. + + * config/tc-i386.c (cpu_arch): Add .movbe and .ept. + (md_show_usage): Add .movbe and .ept. + + * doc/c-i386.texi: Add movbe and ept to -march=. Document + .movbe and .ept. + 2008-04-29 David S. Miller <davem@davemloft.net> * config/tc-sparc.c (v9a_asr_table): Fix order of softint entries. @@ -10,7 +10,7 @@ * New command line option -msse2avx for x86 target to encode SSE instructions with VEX prefix. -* Add Intel XSAVE, AES, PCLMUL, AVX/FMA support for x86 target. +* Add Intel XSAVE, EPT, MOVBE, AES, PCLMUL, AVX/FMA support for x86 target. * New command line options, -march=CPU[,+EXTENSION...], -mtune=CPU, -mmnemonic=[att|intel], -msyntax=[att|intel], -mindex-reg, diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c index fde9acd..16f3742 100644 --- a/gas/config/tc-i386.c +++ b/gas/config/tc-i386.c @@ -661,6 +661,10 @@ static const arch_entry cpu_arch[] = CPU_PCLMUL_FLAGS }, { ".fma", PROCESSOR_UNKNOWN, CPU_FMA_FLAGS }, + { ".movbe", PROCESSOR_UNKNOWN, + CPU_MOVBE_FLAGS }, + { ".ept", PROCESSOR_UNKNOWN, + CPU_EPT_FLAGS }, { ".3dnow", PROCESSOR_UNKNOWN, CPU_3DNOW_FLAGS }, { ".3dnowa", PROCESSOR_UNKNOWN, @@ -8096,8 +8100,8 @@ md_show_usage (stream) generic32, generic64\n\ EXTENSION is combination of:\n\ mmx, sse, sse2, sse3, ssse3, sse4.1, sse4.2, sse4,\n\ - avx, vmx, smx, xsave, aes, pclmul, fma, 3dnow,\n\ - 3dnowa, sse4a, sse5, svme, abm, padlock\n")); + avx, vmx, smx, xsave, movbe, ept, aes, pclmul, fma,\n\ + 3dnow, 3dnowa, sse4a, 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\ diff --git a/gas/doc/c-i386.texi b/gas/doc/c-i386.texi index 1fd3476..55cab7e 100644 --- a/gas/doc/c-i386.texi +++ b/gas/doc/c-i386.texi @@ -127,6 +127,8 @@ accept various extension mnemonics. For example, @code{aes}, @code{pclmul}, @code{fma}, +@code{movbe}, +@code{ept}, @code{3dnow}, @code{3dnowa}, @code{sse4a}, @@ -844,7 +846,8 @@ supported on the CPU specified. The choices for @var{cpu_type} are: @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} +@item @samp{.aes} @tab @samp{.pclmul} @tab @samp{.fma} @tab @samp{.movbe} +@item @samp{.ept} @item @samp{.3dnow} @tab @samp{.3dnowa} @tab @samp{.sse4a} @tab @samp{.sse5} @item @samp{.svme} @tab @samp{.abm} @item @samp{.padlock} diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index e31417c..17a4b31 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,41 @@ +2008-05-02 H.J. Lu <hongjiu.lu@intel.com> + + * gas/i386/i386.exp: Run movbe, movbe-intel, inval-movbe, ept, + ept-intel, inval-ept, x86-64-movbe, x86-64-movbe-intel, + x86-64-inval-movbe. x86-64-ept, x86-64-ept-intel and + x86-64-inval-ept. + + * gas/i386/arch-10.s: Add movbe and invept. + * gas/i386/x86-64-arch-2.s: Likewise. + + * gas/i386/ept.d: New file + * gas/i386/ept-intel.d: Likewise. + * gas/i386/ept.s: Likewise. + * gas/i386/inval-ept.l: Likewise. + * gas/i386/inval-ept.s: Likewise. + * gas/i386/inval-movbe.l: Likewise. + * gas/i386/inval-movbe.s: Likewise. + * gas/i386/movbe.d: Likewise. + * gas/i386/movbe-intel.d: Likewise. + * gas/i386/movbe.s: Likewise. + * gas/i386/x86-64-inval-ept.l: Likewise. + * gas/i386/x86-64-inval-ept.s: Likewise. + * gas/i386/x86-64-inval-movbe.l: Likewise. + * gas/i386/x86-64-inval-movbe.s: Likewise. + * gas/i386/x86-64-ept.d: Likewise. + * gas/i386/x86-64-ept-intel.d: Likewise. + * gas/i386/x86-64-ept.s: Likewise. + * gas/i386/x86-64-movbe.d: Likewise. + * gas/i386/x86-64-movbe-intel.d: Likewise. + * gas/i386/x86-64-movbe.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. + 2008-04-28 Adam Nemet <anemet@caviumnetworks.com> * gas/mips/mips4.s: Split out fp instruction from here ... diff --git a/gas/testsuite/gas/i386/arch-10-1.l b/gas/testsuite/gas/i386/arch-10-1.l index 325e827..00ce939 100644 --- a/gas/testsuite/gas/i386/arch-10-1.l +++ b/gas/testsuite/gas/i386/arch-10-1.l @@ -21,6 +21,8 @@ .*:42: Error: .* .*:44: Error: .* .*:46: Error: .* +.*:48: Error: .* +.*:50: Error: .* GAS LISTING .* @@ -57,17 +59,21 @@ GAS LISTING .* [ ]*30[ ]+pclmulqdq \$8,%xmm1,%xmm0 [ ]*31[ ]+\# FMA [ ]*32[ ]+vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 -[ ]*33[ ]+\# 3DNow -[ ]*34[ ]+pmulhrw %mm4,%mm3 -[ ]*35[ ]+\# 3DNow Extensions -[ ]*36[ ]+pswapd %mm4,%mm3 -[ ]*37[ ]+\# SSE4a -[ ]*38[ ]+insertq %xmm2,%xmm1 -[ ]*39[ ]+\# SVME -[ ]*40[ ]+vmload -[ ]*41[ ]+\# ABM -[ ]*42[ ]+lzcnt %ecx,%ebx -[ ]*43[ ]+\# SSE5 -[ ]*44[ ]+frczss %xmm2, %xmm1 -[ ]*45[ ]+\# PadLock -[ ]*46[ ]+xstorerng +[ ]*33[ ]+\# MOVBE +[ ]*34[ ]+movbe \(%ecx\),%ebx +[ ]*35[ ]+\# EPT +[ ]*36[ ]+invept \(%ecx\),%ebx +[ ]*37[ ]+\# 3DNow +[ ]*38[ ]+pmulhrw %mm4,%mm3 +[ ]*39[ ]+\# 3DNow Extensions +[ ]*40[ ]+pswapd %mm4,%mm3 +[ ]*41[ ]+\# SSE4a +[ ]*42[ ]+insertq %xmm2,%xmm1 +[ ]*43[ ]+\# SVME +[ ]*44[ ]+vmload +[ ]*45[ ]+\# ABM +[ ]*46[ ]+lzcnt %ecx,%ebx +[ ]*47[ ]+\# SSE5 +[ ]*48[ ]+frczss %xmm2, %xmm1 +[ ]*49[ ]+\# PadLock +[ ]*50[ ]+xstorerng diff --git a/gas/testsuite/gas/i386/arch-10-2.l b/gas/testsuite/gas/i386/arch-10-2.l index cac7448..dd8650f 100644 --- a/gas/testsuite/gas/i386/arch-10-2.l +++ b/gas/testsuite/gas/i386/arch-10-2.l @@ -20,6 +20,8 @@ .*:42: Error: .* .*:44: Error: .* .*:46: Error: .* +.*:48: Error: .* +.*:50: Error: .* GAS LISTING .* @@ -56,17 +58,21 @@ GAS LISTING .* [ ]*30[ ]+pclmulqdq \$8,%xmm1,%xmm0 [ ]*31[ ]+\# FMA [ ]*32[ ]+vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 -[ ]*33[ ]+\# 3DNow -[ ]*34[ ]+pmulhrw %mm4,%mm3 -[ ]*35[ ]+\# 3DNow Extensions -[ ]*36[ ]+pswapd %mm4,%mm3 -[ ]*37[ ]+\# SSE4a -[ ]*38[ ]+insertq %xmm2,%xmm1 -[ ]*39[ ]+\# SVME -[ ]*40[ ]+vmload -[ ]*41[ ]+\# ABM -[ ]*42[ ]+lzcnt %ecx,%ebx -[ ]*43[ ]+\# SSE5 -[ ]*44[ ]+frczss %xmm2, %xmm1 -[ ]*45[ ]+\# PadLock -[ ]*46[ ]+xstorerng +[ ]*33[ ]+\# MOVBE +[ ]*34[ ]+movbe \(%ecx\),%ebx +[ ]*35[ ]+\# EPT +[ ]*36[ ]+invept \(%ecx\),%ebx +[ ]*37[ ]+\# 3DNow +[ ]*38[ ]+pmulhrw %mm4,%mm3 +[ ]*39[ ]+\# 3DNow Extensions +[ ]*40[ ]+pswapd %mm4,%mm3 +[ ]*41[ ]+\# SSE4a +[ ]*42[ ]+insertq %xmm2,%xmm1 +[ ]*43[ ]+\# SVME +[ ]*44[ ]+vmload +[ ]*45[ ]+\# ABM +[ ]*46[ ]+lzcnt %ecx,%ebx +[ ]*47[ ]+\# SSE5 +[ ]*48[ ]+frczss %xmm2, %xmm1 +[ ]*49[ ]+\# PadLock +[ ]*50[ ]+xstorerng diff --git a/gas/testsuite/gas/i386/arch-10-3.l b/gas/testsuite/gas/i386/arch-10-3.l index db521b3..ec53735 100644 --- a/gas/testsuite/gas/i386/arch-10-3.l +++ b/gas/testsuite/gas/i386/arch-10-3.l @@ -13,6 +13,8 @@ .*:42: Error: .* .*:44: Error: .* .*:46: Error: .* +.*:48: Error: .* +.*:50: Error: .* GAS LISTING .* @@ -52,17 +54,21 @@ GAS LISTING .* [ ]*30[ ]+pclmulqdq \$8,%xmm1,%xmm0 [ ]*31[ ]+\# FMA [ ]*32[ ]+vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 -[ ]*33[ ]+\# 3DNow -[ ]*34[ ]+pmulhrw %mm4,%mm3 -[ ]*35[ ]+\# 3DNow Extensions -[ ]*36[ ]+pswapd %mm4,%mm3 -[ ]*37[ ]+\# SSE4a -[ ]*38[ ]+insertq %xmm2,%xmm1 -[ ]*39[ ]+\# SVME -[ ]*40[ ]+vmload -[ ]*41[ ]+\# ABM -[ ]*42[ ]+lzcnt %ecx,%ebx -[ ]*43[ ]+\# SSE5 -[ ]*44[ ]+frczss %xmm2, %xmm1 -[ ]*45[ ]+\# PadLock -[ ]*46[ ]+xstorerng +[ ]*33[ ]+\# MOVBE +[ ]*34[ ]+movbe \(%ecx\),%ebx +[ ]*35[ ]+\# EPT +[ ]*36[ ]+invept \(%ecx\),%ebx +[ ]*37[ ]+\# 3DNow +[ ]*38[ ]+pmulhrw %mm4,%mm3 +[ ]*39[ ]+\# 3DNow Extensions +[ ]*40[ ]+pswapd %mm4,%mm3 +[ ]*41[ ]+\# SSE4a +[ ]*42[ ]+insertq %xmm2,%xmm1 +[ ]*43[ ]+\# SVME +[ ]*44[ ]+vmload +[ ]*45[ ]+\# ABM +[ ]*46[ ]+lzcnt %ecx,%ebx +[ ]*47[ ]+\# SSE5 +[ ]*48[ ]+frczss %xmm2, %xmm1 +[ ]*49[ ]+\# PadLock +[ ]*50[ ]+xstorerng diff --git a/gas/testsuite/gas/i386/arch-10-4.l b/gas/testsuite/gas/i386/arch-10-4.l index f60e80b..10e7db3 100644 --- a/gas/testsuite/gas/i386/arch-10-4.l +++ b/gas/testsuite/gas/i386/arch-10-4.l @@ -11,6 +11,8 @@ .*:42: Error: .* .*:44: Error: .* .*:46: Error: .* +.*:48: Error: .* +.*:50: Error: .* GAS LISTING .* @@ -50,17 +52,21 @@ GAS LISTING .* [ ]*30[ ]+pclmulqdq \$8,%xmm1,%xmm0 [ ]*31[ ]+\# FMA [ ]*32[ ]+vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 -[ ]*33[ ]+\# 3DNow -[ ]*34[ ]+pmulhrw %mm4,%mm3 -[ ]*35[ ]+\# 3DNow Extensions -[ ]*36[ ]+pswapd %mm4,%mm3 -[ ]*37[ ]+\# SSE4a -[ ]*38[ ]+insertq %xmm2,%xmm1 -[ ]*39[ ]+\# SVME -[ ]*40[ ]+vmload -[ ]*41[ ]+\# ABM -[ ]*42[ ]+lzcnt %ecx,%ebx -[ ]*43[ ]+\# SSE5 -[ ]*44[ ]+frczss %xmm2, %xmm1 -[ ]*45[ ]+\# PadLock -[ ]*46[ ]+xstorerng +[ ]*33[ ]+\# MOVBE +[ ]*34[ ]+movbe \(%ecx\),%ebx +[ ]*35[ ]+\# EPT +[ ]*36[ ]+invept \(%ecx\),%ebx +[ ]*37[ ]+\# 3DNow +[ ]*38[ ]+pmulhrw %mm4,%mm3 +[ ]*39[ ]+\# 3DNow Extensions +[ ]*40[ ]+pswapd %mm4,%mm3 +[ ]*41[ ]+\# SSE4a +[ ]*42[ ]+insertq %xmm2,%xmm1 +[ ]*43[ ]+\# SVME +[ ]*44[ ]+vmload +[ ]*45[ ]+\# ABM +[ ]*46[ ]+lzcnt %ecx,%ebx +[ ]*47[ ]+\# SSE5 +[ ]*48[ ]+frczss %xmm2, %xmm1 +[ ]*49[ ]+\# PadLock +[ ]*50[ ]+xstorerng diff --git a/gas/testsuite/gas/i386/arch-10.d b/gas/testsuite/gas/i386/arch-10.d index 4a5e0ab..50f046a 100644 --- a/gas/testsuite/gas/i386/arch-10.d +++ b/gas/testsuite/gas/i386/arch-10.d @@ -1,4 +1,4 @@ -#as: -march=i686+avx+vmx+smx+xsave+aes+pclmul+fma+sse5+3dnowa+svme+padlock +#as: -march=i686+avx+vmx+smx+xsave+aes+pclmul+fma+movbe+ept+sse5+3dnowa+svme+padlock #objdump: -dw #name: i386 arch 10 @@ -22,6 +22,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 66 0f 38 dc 01 aesenc \(%ecx\),%xmm0 [ ]*[a-f0-9]+: 66 0f 3a 44 c1 08 pclmulqdq \$0x8,%xmm1,%xmm0 [ ]*[a-f0-9]+: c4 e3 cd 69 fc 20 vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept \(%ecx\),%ebx [ ]*[a-f0-9]+: 0f 0f dc b7 pmulhrw %mm4,%mm3 [ ]*[a-f0-9]+: 0f 0f dc bb pswapd %mm4,%mm3 [ ]*[a-f0-9]+: f2 0f 79 ca insertq %xmm2,%xmm1 diff --git a/gas/testsuite/gas/i386/arch-10.s b/gas/testsuite/gas/i386/arch-10.s index 27f9f90..08fe0a5 100644 --- a/gas/testsuite/gas/i386/arch-10.s +++ b/gas/testsuite/gas/i386/arch-10.s @@ -30,6 +30,10 @@ aesenc (%ecx),%xmm0 pclmulqdq $8,%xmm1,%xmm0 # FMA vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 +# MOVBE +movbe (%ecx),%ebx +# EPT +invept (%ecx),%ebx # 3DNow pmulhrw %mm4,%mm3 # 3DNow Extensions diff --git a/gas/testsuite/gas/i386/ept-intel.d b/gas/testsuite/gas/i386/ept-intel.d new file mode 100644 index 0000000..7ee26b6 --- /dev/null +++ b/gas/testsuite/gas/i386/ept-intel.d @@ -0,0 +1,14 @@ +#objdump: -dwMintel +#name: i386 EPT (Intel disassembly) +#source: ept.s + +.*: +file format .* + +Disassembly of section .text: + +0+ <_start>: +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept ebx,OWORD PTR \[ecx\] +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid ebx,OWORD PTR \[ecx\] +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept ebx,OWORD PTR \[ecx\] +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid ebx,OWORD PTR \[ecx\] +#pass diff --git a/gas/testsuite/gas/i386/ept.d b/gas/testsuite/gas/i386/ept.d new file mode 100644 index 0000000..7321a69 --- /dev/null +++ b/gas/testsuite/gas/i386/ept.d @@ -0,0 +1,13 @@ +#objdump: -dw +#name: i386 EPT + +.*: file format .* + +Disassembly of section .text: + +0+ <_start>: +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid \(%ecx\),%ebx +#pass diff --git a/gas/testsuite/gas/i386/ept.s b/gas/testsuite/gas/i386/ept.s new file mode 100644 index 0000000..70ecacd --- /dev/null +++ b/gas/testsuite/gas/i386/ept.s @@ -0,0 +1,9 @@ +# Check EPT instructions + .text +_start: + invept (%ecx), %ebx + invvpid (%ecx), %ebx + + .intel_syntax noprefix + invept ebx, oword ptr [ecx] + invvpid ebx, oword ptr [ecx] diff --git a/gas/testsuite/gas/i386/i386.exp b/gas/testsuite/gas/i386/i386.exp index f1e9779..9805db7 100644 --- a/gas/testsuite/gas/i386/i386.exp +++ b/gas/testsuite/gas/i386/i386.exp @@ -128,6 +128,12 @@ if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_32_check]] run_dump_test "sse-check-warn" run_list_test "sse-check-error" "-msse-check=error -I${srcdir}/$subdir -al" run_dump_test "sse-noavx" + run_dump_test "movbe" + run_dump_test "movbe-intel" + run_list_test "inval-movbe" "-al" + run_dump_test "ept" + run_dump_test "ept-intel" + run_list_test "inval-ept" "-al" # These tests require support for 8 and 16 bit relocs, # so we only run them for ELF and COFF targets. @@ -258,6 +264,12 @@ if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_64_check]] t run_dump_test "x86-64-sse-check-warn" run_list_test "x86-64-sse-check-error" "-msse-check=error -I${srcdir}/$subdir -al" run_dump_test "x86-64-sse-noavx" + run_dump_test "x86-64-movbe" + run_dump_test "x86-64-movbe-intel" + run_list_test "x86-64-inval-movbe" "-al" + run_dump_test "x86-64-ept" + run_dump_test "x86-64-ept-intel" + run_list_test "x86-64-inval-ept" "-al" if { ![istarget "*-*-aix*"] && ![istarget "*-*-beos*"] diff --git a/gas/testsuite/gas/i386/inval-ept.l b/gas/testsuite/gas/i386/inval-ept.l new file mode 100644 index 0000000..8361841 --- /dev/null +++ b/gas/testsuite/gas/i386/inval-ept.l @@ -0,0 +1,33 @@ +.*: Assembler messages: +.*:4: Error: .* +.*:5: Error: .* +.*:6: Error: .* +.*:7: Error: .* +.*:8: Error: .* +.*:9: Error: .* +.*:12: Error: .* +.*:13: Error: .* +.*:14: Error: .* +.*:15: Error: .* +.*:16: Error: .* +.*:17: Error: .* +GAS LISTING .* + + +[ ]*1[ ]+\# Check illegal EPT instructions +[ ]*2[ ]+\.text +[ ]*3[ ]+_start: +[ ]*4[ ]+invept \(%ecx\), %bx +[ ]*5[ ]+invept %ebx, \(%ecx\) +[ ]*6[ ]+invept %ebx, %ecx +[ ]*7[ ]+invvpid \(%ecx\), %bx +[ ]*8[ ]+invvpid %ebx, \(%ecx\) +[ ]*9[ ]+invvpid %ebx, %ecx +[ ]*10[ ]+ +[ ]*11[ ]+\.intel_syntax noprefix +[ ]*12[ ]+invept bx, oword ptr \[ecx\] +[ ]*13[ ]+invept oword ptr \[ecx\], ebx +[ ]*14[ ]+invept ecx, ebx +[ ]*15[ ]+invvpid bx, oword ptr \[ecx\] +[ ]*16[ ]+invvpid oword ptr \[ecx\], ebx +[ ]*17[ ]+invvpid ecx, ebx diff --git a/gas/testsuite/gas/i386/inval-ept.s b/gas/testsuite/gas/i386/inval-ept.s new file mode 100644 index 0000000..6152c95 --- /dev/null +++ b/gas/testsuite/gas/i386/inval-ept.s @@ -0,0 +1,17 @@ +# Check illegal EPT instructions + .text +_start: + invept (%ecx), %bx + invept %ebx, (%ecx) + invept %ebx, %ecx + invvpid (%ecx), %bx + invvpid %ebx, (%ecx) + invvpid %ebx, %ecx + + .intel_syntax noprefix + invept bx, oword ptr [ecx] + invept oword ptr [ecx], ebx + invept ecx, ebx + invvpid bx, oword ptr [ecx] + invvpid oword ptr [ecx], ebx + invvpid ecx, ebx diff --git a/gas/testsuite/gas/i386/inval-movbe.l b/gas/testsuite/gas/i386/inval-movbe.l new file mode 100644 index 0000000..981bca8 --- /dev/null +++ b/gas/testsuite/gas/i386/inval-movbe.l @@ -0,0 +1,25 @@ +.*: Assembler messages: +.*:4: Error: .* +.*:5: Error: .* +.*:6: Error: .* +.*:7: Error: .* +.*:10: Error: .* +.*:11: Error: .* +.*:12: Error: .* +.*:13: Error: .* +GAS LISTING .* + + +[ ]*1[ ]+\# Check illegal movbe +[ ]*2[ ]+\.text +[ ]*3[ ]+foo: +[ ]*4[ ]+movbe \(%ecx\),%bl +[ ]*5[ ]+movbe %ecx,%ebx +[ ]*6[ ]+movbe %bx,%ecx +[ ]*7[ ]+movbe %bl,\(%ecx\) +[ ]*8[ ]+ +[ ]*9[ ]+\.intel_syntax noprefix +[ ]*10[ ]+movbe bl, byte ptr \[ecx\] +[ ]*11[ ]+movbe ebx, ecx +[ ]*12[ ]+movbe ecx, bx +[ ]*13[ ]+movbe byte ptr \[ecx\], bl diff --git a/gas/testsuite/gas/i386/inval-movbe.s b/gas/testsuite/gas/i386/inval-movbe.s new file mode 100644 index 0000000..9b11b4c --- /dev/null +++ b/gas/testsuite/gas/i386/inval-movbe.s @@ -0,0 +1,13 @@ +# Check illegal movbe + .text +foo: + movbe (%ecx),%bl + movbe %ecx,%ebx + movbe %bx,%ecx + movbe %bl,(%ecx) + + .intel_syntax noprefix + movbe bl, byte ptr [ecx] + movbe ebx, ecx + movbe ecx, bx + movbe byte ptr [ecx], bl diff --git a/gas/testsuite/gas/i386/movbe-intel.d b/gas/testsuite/gas/i386/movbe-intel.d new file mode 100644 index 0000000..9306bb1 --- /dev/null +++ b/gas/testsuite/gas/i386/movbe-intel.d @@ -0,0 +1,22 @@ +#objdump: -dwMintel +#name: i386 movbe (Intel disassembly) +#source: movbe.s + +.*: +file format .* + +Disassembly of section .text: + +0+ <foo>: +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe bx,WORD PTR \[ecx\] +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe ebx,DWORD PTR \[ecx\] +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe WORD PTR \[ecx\],bx +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe DWORD PTR \[ecx\],ebx +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe bx,WORD PTR \[ecx\] +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe ebx,DWORD PTR \[ecx\] +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe WORD PTR \[ecx\],bx +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe DWORD PTR \[ecx\],ebx +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe bx,WORD PTR \[ecx\] +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe ebx,DWORD PTR \[ecx\] +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe WORD PTR \[ecx\],bx +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe DWORD PTR \[ecx\],ebx +#pass diff --git a/gas/testsuite/gas/i386/movbe.d b/gas/testsuite/gas/i386/movbe.d new file mode 100644 index 0000000..9ee583e --- /dev/null +++ b/gas/testsuite/gas/i386/movbe.d @@ -0,0 +1,21 @@ +#objdump: -dw +#name: i386 movbe + +.*: file format .* + +Disassembly of section .text: + +0+ <foo>: +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe \(%ecx\),%bx +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe %bx,\(%ecx\) +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe %ebx,\(%ecx\) +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe \(%ecx\),%bx +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe %bx,\(%ecx\) +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe %ebx,\(%ecx\) +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe \(%ecx\),%bx +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe \(%ecx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe %bx,\(%ecx\) +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe %ebx,\(%ecx\) +#pass diff --git a/gas/testsuite/gas/i386/movbe.s b/gas/testsuite/gas/i386/movbe.s new file mode 100644 index 0000000..40f8bab --- /dev/null +++ b/gas/testsuite/gas/i386/movbe.s @@ -0,0 +1,17 @@ +# Check movbe + .text +foo: + movbe (%ecx),%bx + movbe (%ecx),%ebx + movbe %bx,(%ecx) + movbe %ebx,(%ecx) + movbew (%ecx),%bx + movbel (%ecx),%ebx + movbew %bx,(%ecx) + movbel %ebx,(%ecx) + + .intel_syntax noprefix + movbe bx, word ptr [ecx] + movbe ebx, dword ptr [ecx] + movbe word ptr [ecx], bx + movbe dword ptr [ecx], ebx diff --git a/gas/testsuite/gas/i386/x86-64-arch-2.d b/gas/testsuite/gas/i386/x86-64-arch-2.d index bb7a2c9..9bdd5bb 100644 --- a/gas/testsuite/gas/i386/x86-64-arch-2.d +++ b/gas/testsuite/gas/i386/x86-64-arch-2.d @@ -1,4 +1,4 @@ -#as: -march=generic64+avx+vmx+smx+xsave+aes+pclmul+fma+sse5+3dnowa+svme+padlock +#as: -march=generic64+avx+vmx+smx+xsave+aes+pclmul+fma+movbe+ept+sse5+3dnowa+svme+padlock #objdump: -dw #name: x86-64 arch 2 @@ -22,6 +22,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 66 0f 38 dc 01 aesenc \(%rcx\),%xmm0 [ ]*[a-f0-9]+: 66 0f 3a 44 c1 08 pclmulqdq \$0x8,%xmm1,%xmm0 [ ]*[a-f0-9]+: c4 e3 cd 69 fc 20 vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe \(%rcx\),%ebx +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept \(%rcx\),%rbx [ ]*[a-f0-9]+: 0f 0f dc b7 pmulhrw %mm4,%mm3 [ ]*[a-f0-9]+: 0f 0f dc bb pswapd %mm4,%mm3 [ ]*[a-f0-9]+: f2 0f 79 ca insertq %xmm2,%xmm1 diff --git a/gas/testsuite/gas/i386/x86-64-arch-2.s b/gas/testsuite/gas/i386/x86-64-arch-2.s index 11f5ebf..0cabf724 100644 --- a/gas/testsuite/gas/i386/x86-64-arch-2.s +++ b/gas/testsuite/gas/i386/x86-64-arch-2.s @@ -30,6 +30,10 @@ aesenc (%rcx),%xmm0 pclmulqdq $8,%xmm1,%xmm0 # FMA vfmaddpd %ymm4,%ymm6,%ymm2,%ymm7 +# MOVBE +movbe (%rcx),%ebx +# EPT +invept (%rcx),%rbx # 3DNow pmulhrw %mm4,%mm3 # 3DNow Extensions diff --git a/gas/testsuite/gas/i386/x86-64-ept-intel.d b/gas/testsuite/gas/i386/x86-64-ept-intel.d new file mode 100644 index 0000000..8ec1af4 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-ept-intel.d @@ -0,0 +1,18 @@ +#objdump: -drwMintel +#name: x86-64 EPT (Intel mode) +#source: x86-64-ept.s + +.*: +file format .* + +Disassembly of section .text: + +0+ <_start>: +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept rbx,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 44 0f 38 80 19 invept r11,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid rbx,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 44 0f 38 81 19 invvpid r11,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept rbx,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 44 0f 38 80 19 invept r11,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid rbx,OWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 44 0f 38 81 19 invvpid r11,OWORD PTR \[rcx\] +#pass diff --git a/gas/testsuite/gas/i386/x86-64-ept.d b/gas/testsuite/gas/i386/x86-64-ept.d new file mode 100644 index 0000000..e928f23 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-ept.d @@ -0,0 +1,17 @@ +#objdump: -dw +#name: x86-64 EPT + +.*: file format .* + +Disassembly of section .text: + +0+ <_start>: +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept \(%rcx\),%rbx +[ ]*[a-f0-9]+: 66 44 0f 38 80 19 invept \(%rcx\),%r11 +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid \(%rcx\),%rbx +[ ]*[a-f0-9]+: 66 44 0f 38 81 19 invvpid \(%rcx\),%r11 +[ ]*[a-f0-9]+: 66 0f 38 80 19 invept \(%rcx\),%rbx +[ ]*[a-f0-9]+: 66 44 0f 38 80 19 invept \(%rcx\),%r11 +[ ]*[a-f0-9]+: 66 0f 38 81 19 invvpid \(%rcx\),%rbx +[ ]*[a-f0-9]+: 66 44 0f 38 81 19 invvpid \(%rcx\),%r11 +#pass diff --git a/gas/testsuite/gas/i386/x86-64-ept.s b/gas/testsuite/gas/i386/x86-64-ept.s new file mode 100644 index 0000000..adc9226 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-ept.s @@ -0,0 +1,13 @@ +# Check 64bit EPT instructions + .text +_start: + invept (%rcx), %rbx + invept (%rcx), %r11 + invvpid (%rcx), %rbx + invvpid (%rcx), %r11 + + .intel_syntax noprefix + invept rbx, oword ptr [rcx] + invept r11, oword ptr [rcx] + invvpid rbx, oword ptr [rcx] + invvpid r11, oword ptr [rcx] diff --git a/gas/testsuite/gas/i386/x86-64-inval-ept.l b/gas/testsuite/gas/i386/x86-64-inval-ept.l new file mode 100644 index 0000000..4cfdda5 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-inval-ept.l @@ -0,0 +1,41 @@ +.*: Assembler messages: +.*:4: Error: .* +.*:5: Error: .* +.*:6: Error: .* +.*:7: Error: .* +.*:8: Error: .* +.*:9: Error: .* +.*:10: Error: .* +.*:11: Error: .* +.*:14: Error: .* +.*:15: Error: .* +.*:16: Error: .* +.*:17: Error: .* +.*:18: Error: .* +.*:19: Error: .* +.*:20: Error: .* +.*:21: Error: .* +GAS LISTING .* + + +[ ]*1[ ]+\# Check illegal EPT instructions in 64bit mode\. +[ ]*2[ ]+\.text +[ ]*3[ ]+_start: +[ ]*4[ ]+invept \(%rcx\), %bx +[ ]*5[ ]+invept \(%rcx\), %ebx +[ ]*6[ ]+invept %rbx, \(%rcx\) +[ ]*7[ ]+invept %rbx, %rcx +[ ]*8[ ]+invvpid \(%rcx\), %bx +[ ]*9[ ]+invvpid \(%rcx\), %ebx +[ ]*10[ ]+invvpid %rbx, \(%rcx\) +[ ]*11[ ]+invvpid %rbx, %rcx +[ ]*12[ ]+ +[ ]*13[ ]+\.intel_syntax noprefix +[ ]*14[ ]+invept bx, oword ptr \[rcx\] +[ ]*15[ ]+invept ebx, oword ptr \[rcx\] +[ ]*16[ ]+invept oword ptr \[rcx\], rbx +[ ]*17[ ]+invept rcx, rbx +[ ]*18[ ]+invvpid bx, oword ptr \[rcx\] +[ ]*19[ ]+invvpid ebx, oword ptr \[rcx\] +[ ]*20[ ]+invvpid oword ptr \[rcx\], rbx +[ ]*21[ ]+invvpid rcx, rbx diff --git a/gas/testsuite/gas/i386/x86-64-inval-ept.s b/gas/testsuite/gas/i386/x86-64-inval-ept.s new file mode 100644 index 0000000..89d6948 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-inval-ept.s @@ -0,0 +1,21 @@ +# Check illegal EPT instructions in 64bit mode. + .text +_start: + invept (%rcx), %bx + invept (%rcx), %ebx + invept %rbx, (%rcx) + invept %rbx, %rcx + invvpid (%rcx), %bx + invvpid (%rcx), %ebx + invvpid %rbx, (%rcx) + invvpid %rbx, %rcx + + .intel_syntax noprefix + invept bx, oword ptr [rcx] + invept ebx, oword ptr [rcx] + invept oword ptr [rcx], rbx + invept rcx, rbx + invvpid bx, oword ptr [rcx] + invvpid ebx, oword ptr [rcx] + invvpid oword ptr [rcx], rbx + invvpid rcx, rbx diff --git a/gas/testsuite/gas/i386/x86-64-inval-movbe.l b/gas/testsuite/gas/i386/x86-64-inval-movbe.l new file mode 100644 index 0000000..1c8ceb55 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-inval-movbe.l @@ -0,0 +1,29 @@ +.*: Assembler messages: +.*:4: Error: .* +.*:5: Error: .* +.*:6: Error: .* +.*:7: Error: .* +.*:8: Error: .* +.*:11: Error: .* +.*:12: Error: .* +.*:13: Error: .* +.*:14: Error: .* +.*:15: Error: .* +GAS LISTING .* + + +[ ]*1[ ]+\# Check illegal movbe in 64bit mode\. +[ ]*2[ ]+\.text +[ ]*3[ ]+foo: +[ ]*4[ ]+movbe \(%rcx\),%bl +[ ]*5[ ]+movbe %ecx,%ebx +[ ]*6[ ]+movbe %bx,%rcx +[ ]*7[ ]+movbe %rbx,%rcx +[ ]*8[ ]+movbe %bl,\(%rcx\) +[ ]*9[ ]+ +[ ]*10[ ]+\.intel_syntax noprefix +[ ]*11[ ]+movbe bl, byte ptr \[rcx\] +[ ]*12[ ]+movbe ebx, ecx +[ ]*13[ ]+movbe rcx, bx +[ ]*14[ ]+movbe rcx, rbx +[ ]*15[ ]+movbe byte ptr \[rcx\], bl diff --git a/gas/testsuite/gas/i386/x86-64-inval-movbe.s b/gas/testsuite/gas/i386/x86-64-inval-movbe.s new file mode 100644 index 0000000..38f09b1 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-inval-movbe.s @@ -0,0 +1,15 @@ +# Check illegal movbe in 64bit mode. + .text +foo: + movbe (%rcx),%bl + movbe %ecx,%ebx + movbe %bx,%rcx + movbe %rbx,%rcx + movbe %bl,(%rcx) + + .intel_syntax noprefix + movbe bl, byte ptr [rcx] + movbe ebx, ecx + movbe rcx, bx + movbe rcx, rbx + movbe byte ptr [rcx], bl diff --git a/gas/testsuite/gas/i386/x86-64-movbe-intel.d b/gas/testsuite/gas/i386/x86-64-movbe-intel.d new file mode 100644 index 0000000..9028477 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-movbe-intel.d @@ -0,0 +1,28 @@ +#objdump: -drwMintel +#name: x86-64 movbe (Intel mode) +#source: x86-64-movbe.s + +.*: +file format .* + +Disassembly of section .text: + +0+ <foo>: +[ ]*[a-f0-9]+: 66 45 0f 38 f0 29 movbe r13w,WORD PTR \[r9\] +[ ]*[a-f0-9]+: 45 0f 38 f0 29 movbe r13d,DWORD PTR \[r9\] +[ ]*[a-f0-9]+: 4d 0f 38 f0 29 movbe r13,QWORD PTR \[r9\] +[ ]*[a-f0-9]+: 66 45 0f 38 f1 29 movbe WORD PTR \[r9\],r13w +[ ]*[a-f0-9]+: 45 0f 38 f1 29 movbe DWORD PTR \[r9\],r13d +[ ]*[a-f0-9]+: 4d 0f 38 f1 29 movbe QWORD PTR \[r9\],r13 +[ ]*[a-f0-9]+: 66 45 0f 38 f0 29 movbe r13w,WORD PTR \[r9\] +[ ]*[a-f0-9]+: 45 0f 38 f0 29 movbe r13d,DWORD PTR \[r9\] +[ ]*[a-f0-9]+: 4d 0f 38 f0 29 movbe r13,QWORD PTR \[r9\] +[ ]*[a-f0-9]+: 66 45 0f 38 f1 29 movbe WORD PTR \[r9\],r13w +[ ]*[a-f0-9]+: 45 0f 38 f1 29 movbe DWORD PTR \[r9\],r13d +[ ]*[a-f0-9]+: 4d 0f 38 f1 29 movbe QWORD PTR \[r9\],r13 +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe bx,WORD PTR \[rcx\] +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe ebx,DWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 48 0f 38 f0 19 movbe rbx,QWORD PTR \[rcx\] +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe WORD PTR \[rcx\],bx +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe DWORD PTR \[rcx\],ebx +[ ]*[a-f0-9]+: 48 0f 38 f1 19 movbe QWORD PTR \[rcx\],rbx +#pass diff --git a/gas/testsuite/gas/i386/x86-64-movbe.d b/gas/testsuite/gas/i386/x86-64-movbe.d new file mode 100644 index 0000000..e8bce3f --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-movbe.d @@ -0,0 +1,27 @@ +#objdump: -dw +#name: x86-64 movbe + +.*: file format .* + +Disassembly of section .text: + +0+ <foo>: +[ ]*[a-f0-9]+: 66 45 0f 38 f0 29 movbe \(%r9\),%r13w +[ ]*[a-f0-9]+: 45 0f 38 f0 29 movbe \(%r9\),%r13d +[ ]*[a-f0-9]+: 4d 0f 38 f0 29 movbe \(%r9\),%r13 +[ ]*[a-f0-9]+: 66 45 0f 38 f1 29 movbe %r13w,\(%r9\) +[ ]*[a-f0-9]+: 45 0f 38 f1 29 movbe %r13d,\(%r9\) +[ ]*[a-f0-9]+: 4d 0f 38 f1 29 movbe %r13,\(%r9\) +[ ]*[a-f0-9]+: 66 45 0f 38 f0 29 movbe \(%r9\),%r13w +[ ]*[a-f0-9]+: 45 0f 38 f0 29 movbe \(%r9\),%r13d +[ ]*[a-f0-9]+: 4d 0f 38 f0 29 movbe \(%r9\),%r13 +[ ]*[a-f0-9]+: 66 45 0f 38 f1 29 movbe %r13w,\(%r9\) +[ ]*[a-f0-9]+: 45 0f 38 f1 29 movbe %r13d,\(%r9\) +[ ]*[a-f0-9]+: 4d 0f 38 f1 29 movbe %r13,\(%r9\) +[ ]*[a-f0-9]+: 66 0f 38 f0 19 movbe \(%rcx\),%bx +[ ]*[a-f0-9]+: 0f 38 f0 19 movbe \(%rcx\),%ebx +[ ]*[a-f0-9]+: 48 0f 38 f0 19 movbe \(%rcx\),%rbx +[ ]*[a-f0-9]+: 66 0f 38 f1 19 movbe %bx,\(%rcx\) +[ ]*[a-f0-9]+: 0f 38 f1 19 movbe %ebx,\(%rcx\) +[ ]*[a-f0-9]+: 48 0f 38 f1 19 movbe %rbx,\(%rcx\) +#pass diff --git a/gas/testsuite/gas/i386/x86-64-movbe.s b/gas/testsuite/gas/i386/x86-64-movbe.s new file mode 100644 index 0000000..5857ef7 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-movbe.s @@ -0,0 +1,23 @@ +# Check 64bit movbe + .text +foo: + movbe (%r9),%r13w + movbe (%r9),%r13d + movbe (%r9),%r13 + movbe %r13w,(%r9) + movbe %r13d,(%r9) + movbe %r13,(%r9) + movbew (%r9),%r13w + movbel (%r9),%r13d + movbeq (%r9),%r13 + movbew %r13w,(%r9) + movbel %r13d,(%r9) + movbeq %r13,(%r9) + + .intel_syntax noprefix + movbe bx, word ptr [rcx] + movbe ebx, dword ptr [rcx] + movbe rbx, qword ptr [rcx] + movbe word ptr [rcx], bx + movbe dword ptr [rcx], ebx + movbe qword ptr [rcx], rbx |