class
ArchBase class representing an architecture.
Contents
It holds information such as the size of the registers, the number of registers, and available CPU modes for architectures that can have several modes (like ARMv7)
❱ Base classes
- class Serializable
- Virtual interface that serializable classes must implement.
❱ Derived classes
❱ Public types
❱ Constructors, destructors, conversion operators
-
Arch(Arch::
Type type, int bits, int nb_regs)
❱ Public functions
-
auto reg_name(reg_
t num) const -> const std::string& - Get name of register 'num'.
-
auto reg_num(const std::string& name) const -> reg_
t - Get num of register named 'name'.
-
auto reg_size(reg_
t reg) const -> size_t pure virtual - Get size in bits of register 'reg'.
-
auto sp() const -> reg_
t pure virtual - Stack pointer for this architecture.
-
auto pc() const -> reg_
t pure virtual - Program counter for this architecture.
-
auto tsc() const -> reg_
t pure virtual - Timestamp/Clock counter for this architecture.
- auto bits() const -> int
- Return the size of the architecture in bits.
- auto octets() const -> int
- Return the size of the architecture in bytes/octets.
-
auto class_uid() const -> serial::
uid_t virtual - Return the class uid (see ClassId enum)
-
void dump(serial::
Serializer&) const virtual - Dump the object contents in a serializer stream.
-
void load(serial::
Deserializer&) virtual - Restore an object from a deserializer stream.
❱ Public variables
-
const Arch::
Type type - Architecture identifier.
- const int nb_regs
- Number of registers in this architecture.
- std::vector<CPUMode> available_modes
- CPU modes available for the architecture.
❱ Protected variables
❱ Enum documentation
❱ Function documentation
maat:: Arch:: Arch(Arch:: Type type,
int bits,
int nb_regs)
Constructor