maat::ir::IRMap class

Contents

A simple class that maps addresses to lifted assembly instructions

❱   Public types

struct InstLocation
The location of a given IR instruction, it is made of an IR block and the id of the instruction within the block.

❱   Public functions

auto add(const AsmInst& inst) -> uint64_t
Add an AsmInst to the map and return the start address of this AsmInst.

auto add(AsmInst&& inst) -> uint64_t
Add an AsmInst to the map and return the start address of this AsmInst.

auto get_inst_at(uint64_t addr) -> AsmInst&
Returns AsmInst at address 'addr'. Raises an exception if the AsmInst is missing.

auto contains_inst_at(uint64_t addr) -> bool
Returns true if the map contains the AsmInst for address 'addr'.

void remove_insts_containing(uint64_t start, uint64_t end)
Remove the AsmInsts whose raw bytes location overlaps with ['start_addr','end_addr'] (included)

void remove_inst_at(uint64_t addr)
Remove instruction at address 'addr'.