This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] x86/Intel: fix operand checking for MOVSD


On Thu, Jun 30, 2016 at 3:12 AM, Jan Beulich <JBeulich@suse.com> wrote:
> The dual purpose mnemonic (string move vs scalar double move) breaks
> the assumption that the isstring flag would be set on both the first
> and last entry in the current set of templates, which results in bogus
> or missing diagnostics for the string move variant of the mnemonic.
> Short of mostly rewriting i386_index_check() and its interaction with
> the rest of the code, simply shrink the template set to just string
> instructions when encountering the second memory operand, and run
> i386_index_check() a second time for the first memory operand after
> that reduction.
>
> gas/
> 2016-06-30  Jan Beulich  <jbeulich@suse.com>
>
>         * config/tc-i386.c (struct _i386_insn): New field memop1_string.
>         (md_assemble): Free first memory operand string.
>         (i386_index_check): Use repprefixok to distingush xlat from
>         other (real) string ops.
>         (maybe_adjust_templates): New.
>         (i386_att_operand). Call it. Store first memory operand string.
>         * config/tc-i386-intel.c (i386_intel_operand): Likewise.
>
> gas/testsuite/
> 2016-06-30  Jan Beulich  <jbeulich@suse.com>
>
>         * gas/i386/intel-movs.s: New.
>         * gas/i386/intel-movs32.d: New.
>         * gas/i386/intel-movs64.d: New.
>         * gas/i386/i386.exp: Run new tests. Invoke as for 64-bits tests
>         with "--defsym x86_64=1 --strip-local-absolute".
>
> opcodes/
> 2016-06-30  Jan Beulich  <jbeulich@suse.com>
>
>         * i386-opc.tbl (xlat): Remove RepPrefixOk.
>         * i386-tbl.h: Re-generate.
>

It is OK.

Thanks.


-- 
H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]