[LLVMbugs] [Bug 19251] New: [x86 disassembler] prefix ordering may ignores opsize and rep[n]e prefixes

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Mar 25 16:20:50 PDT 2014


http://llvm.org/bugs/show_bug.cgi?id=19251

            Bug ID: 19251
           Summary: [x86 disassembler] prefix ordering may ignores opsize
                    and rep[n]e prefixes
           Product: libraries
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Backend: X86
          Assignee: unassignedbugs at nondot.org
          Reporter: aaron at lintile.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

echo "0x66 0xF2 0xAF 0xF2 0x66 0xAF" | ./llvm-mc  --disassemble
--triple=x86_64-linux-none
    .text
    scasl    %es:(%rdi), %eax
    repne
    scasw    %es:(%rdi), %ax

The first instruction decoding has the wrong operand size and ignores the repne
prefix.  The second disassembly is what I would expect.

According to IDA (and a couple other disassemblers) they are equivalent.

seg000:00000000       66 F2 AF repne scasw
seg000:00000003       F2 66 AF repne scasw

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20140325/f537faf9/attachment.html>


More information about the llvm-bugs mailing list