From 0e0d4b413a0aefbdb7b231651e3c3baa2b1a04bb Mon Sep 17 00:00:00 2001 From: Peter Johnson Date: Thu, 3 Jan 2008 04:13:18 +0000 Subject: [PATCH] Fix #129: Support no-operand form of movsd in GAS syntax. Reported and patch by: mm.beck@gmx.net svn path=/trunk/yasm/; revision=2026 --- modules/arch/x86/gen_x86_insn.py | 2 +- modules/arch/x86/tests/gas32/Makefile.inc | 2 + modules/arch/x86/tests/gas32/gas-movsd.asm | 3 + modules/arch/x86/tests/gas32/gas-movsd.hex | 360 +++++++++++++++++++++ 4 files changed, 366 insertions(+), 1 deletion(-) create mode 100644 modules/arch/x86/tests/gas32/gas-movsd.asm create mode 100644 modules/arch/x86/tests/gas32/gas-movsd.hex diff --git a/modules/arch/x86/gen_x86_insn.py b/modules/arch/x86/gen_x86_insn.py index 9213fe0c..fd923d4f 100755 --- a/modules/arch/x86/gen_x86_insn.py +++ b/modules/arch/x86/gen_x86_insn.py @@ -2679,7 +2679,7 @@ add_insn("movsw", "onebyte", modifiers=[0xA5, 16]) # movsd has to be non-onebyte for SSE2 forms below add_group("movsd", - parsers=["nasm"], + parsers=["nasm", "gas"], opersize=32, opcode=[0xA5], operands=[]) diff --git a/modules/arch/x86/tests/gas32/Makefile.inc b/modules/arch/x86/tests/gas32/Makefile.inc index fbb8ccf4..80f22a40 100644 --- a/modules/arch/x86/tests/gas32/Makefile.inc +++ b/modules/arch/x86/tests/gas32/Makefile.inc @@ -9,6 +9,8 @@ EXTRA_DIST += modules/arch/x86/tests/gas32/gas-farithr.asm EXTRA_DIST += modules/arch/x86/tests/gas32/gas-farithr.hex EXTRA_DIST += modules/arch/x86/tests/gas32/gas-movdq32.asm EXTRA_DIST += modules/arch/x86/tests/gas32/gas-movdq32.hex +EXTRA_DIST += modules/arch/x86/tests/gas32/gas-movsd.asm +EXTRA_DIST += modules/arch/x86/tests/gas32/gas-movsd.hex EXTRA_DIST += modules/arch/x86/tests/gas32/gas32-jmpcall.asm EXTRA_DIST += modules/arch/x86/tests/gas32/gas32-jmpcall.hex diff --git a/modules/arch/x86/tests/gas32/gas-movsd.asm b/modules/arch/x86/tests/gas32/gas-movsd.asm new file mode 100644 index 00000000..3d3c0c73 --- /dev/null +++ b/modules/arch/x86/tests/gas32/gas-movsd.asm @@ -0,0 +1,3 @@ +.text +movsd +movsl diff --git a/modules/arch/x86/tests/gas32/gas-movsd.hex b/modules/arch/x86/tests/gas32/gas-movsd.hex new file mode 100644 index 00000000..70701e6d --- /dev/null +++ b/modules/arch/x86/tests/gas32/gas-movsd.hex @@ -0,0 +1,360 @@ +7f +45 +4c +46 +01 +01 +01 +00 +00 +00 +00 +00 +00 +00 +00 +00 +01 +00 +03 +00 +01 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +a0 +00 +00 +00 +00 +00 +00 +00 +34 +00 +00 +00 +00 +00 +28 +00 +05 +00 +01 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +a5 +a5 +00 +00 +00 +2e +74 +65 +78 +74 +00 +2e +73 +74 +72 +74 +61 +62 +00 +2e +73 +79 +6d +74 +61 +62 +00 +2e +73 +68 +73 +74 +72 +74 +61 +62 +00 +00 +00 +00 +00 +2d +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +01 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +04 +00 +f1 +ff +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +03 +00 +04 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +17 +00 +00 +00 +03 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +44 +00 +00 +00 +21 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +07 +00 +00 +00 +03 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +68 +00 +00 +00 +03 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +0f +00 +00 +00 +02 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +6c +00 +00 +00 +30 +00 +00 +00 +02 +00 +00 +00 +03 +00 +00 +00 +04 +00 +00 +00 +10 +00 +00 +00 +01 +00 +00 +00 +01 +00 +00 +00 +06 +00 +00 +00 +00 +00 +00 +00 +40 +00 +00 +00 +02 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +00 +10 +00 +00 +00 +00 +00 +00 +00 -- 2.40.0