Skip to content

[AT&T] Size suffix is missing for certain instructions #625

Description

@mappzor

Originally found for call and jmp but more instructions could be affected.

ZydisFormatterATTPrintMnemonic fails to properly append size suffix because:

  1. Condition is too strict and filters out rel32 operands:
    if ((operand->type == ZYDIS_OPERAND_TYPE_MEMORY) &&
  2. ZydisFormatterHelperGetExplicitSize contains this condition which filters out jumps, calls and possibly some other instructions:
    if (context->instruction->operand_count_visible < 2)

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-formatterArea: FormatterC-bugCategory: This is a bug (or a fix for a bug, when applied to PRs)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions