Skip to content

PC/eip is not updated within a basic block #27

@enlighten5

Description

@enlighten5

QEMU does not update the pc within a basic block at runtime. Specifically,

  1. Instructions in one basic block will have the same pc as the first instruction.

  2. Blocks that are patched together by a jump instruction will have the same pc, i.e., pc will be not updated by the jump.

QEMU might do this for a better performance. but the pc is used by the backend for branch filtering and basic block pruning, an accurate pc can lead to better pruning results.

I have a fix in this commit. Please let me know if it makes sense.

Thank you!

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