Skip to content

SHLD regression #1505

@Tiecoon

Description

@Tiecoon

The capstone next branch 05b3fbf is now disassembling improper opcode details for SHLD

With the following code

from capstone import *

CODE = b"\x0f\xa5\xc2\xd3"

md = Cs(CS_ARCH_X86, CS_MODE_64)
md.detail = True

for i in md.disasm(CODE, 0x1000):
    print("0x%x:\t%s\t%s\t\t%s" % (i.address, i.mnemonic, i.op_str, i.opcode))
    for j in i.opcode:
        print("\t" + hex(j))

4.0.1:

Name: capstone
Version: 4.0.1
Summary: Capstone disassembly engine
Home-page: http://www.capstone-engine.org
Author: Nguyen Anh Quynh
Author-email: aquynh@gmail.com
License: UNKNOWN
Location: /home/luke/.virtualenvs/...
Requires:
Required-by:

Produces:

0x1000: shld    edx, eax, cl            [15, 165, 0, 0]
        0xf
        0xa5
        0x0
        0x0

05b3fbf:

Name: capstone
Version: 5.0.0
Summary: Capstone disassembly engine
Home-page: http://www.capstone-engine.org
Author: Nguyen Anh Quynh
Author-email: aquynh@gmail.com
License: UNKNOWN
Location: /home/luke/.virtualenvs/...
Requires:
Required-by:

Produces

0x1000: shld    edx, eax, cl            [165, 0, 0, 0]
        0xa5
        0x0
        0x0
        0x0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions