Skip to content

Merge InstructionDefinition and BaseInstruction into a single type #51

@RealA10N

Description

@RealA10N

The idea is to make instructions very modifiable, so optimizations and other can just look at 'InstructionInfo', modify it, and it will work.

The current design allows the ISA implementation to store instruction specific information in the 'BaseInstruction' instance, which can get invalidated if the 'InstructionInfo' instance is modified. For example:

  • Almost all 'AArch64' instructions store the binary representation of the instruction in 'BaseInstruction', instead of computing it dynamically from the arguments in 'InstructionInfo' when required. This restricts the option to change arguments of instructions in optimizations.
  • In the 'usm' isa, certain instructions store information in 'BaseInstruction'. For example, the jump instructions directly store the label to jump to (to avoid parsing the arguments each time).

Metadata

Metadata

Assignees

Labels

coreA core feature or change

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions