Otawa
0.10
|
Objects of this class are simple machine register, more accurately unbreakable atomic registers. More...
#include <otawa/hard/Register.h>
Public Types | |
enum | kind_t { NONE = 0, ADDR, INT, FLOAT, BITS } |
This enumeration represents the differents kind of value found in hardware registers. More... | |
typedef enum otawa::hard::Register::kind_t | kind_t |
Public Member Functions | |
Register (const elm::String &name, kind_t kind, int size) | |
Build a new register. More... | |
int | number (void) const |
Get the register number. More... | |
RegBank * | bank (void) const |
Get the owner bank of the register. More... | |
const elm::String & | name (void) const |
Get the name of the register. More... | |
kind_t | kind (void) const |
Get the kind of a register. More... | |
int | size (void) const |
int | platformNumber (void) const |
Gives a number which is unique for this platform. More... | |
Private Attributes | |
int | _number |
kind_t | _kind |
int | _size |
elm::String | _name |
RegBank * | _bank |
int | pfnum |
Friends | |
class | Platform |
class | RegBank |
Objects of this class are simple machine register, more accurately unbreakable atomic registers.
If you architecture provides register spanning on multiple atomic register, use the SpanReg class for representing them.
This enumeration represents the differents kind of value found in hardware registers.
otawa::hard::Register::Register | ( | const elm::String & | name, |
Register::kind_t | kind, | ||
int | size | ||
) |
|
inline |
|
inline |
Get the kind of a register.
References _kind.
|
inline |
Get the name of the register.
References _name.
Referenced by otawa::hard::operator<<(), and otawa::clp::State::print().
|
inline |
|
inline |
Gives a number which is unique for this platform.
Each register, in a platform, is associated with a unique number ranging from 0 to Platform::regCount()-1. This number may be used as index to table or to bit vectors matching the overall registers.
References pfnum.
Referenced by otawa::clp::Analysis::processWorkSpace().
|
inline |
References _size.
|
friend |
|
friend |
|
private |
Referenced by bank(), and otawa::hard::RegBank::set().
|
private |
Referenced by name().
|
private |
Referenced by number(), and otawa::hard::RegBank::set().
|
private |
Referenced by size().
|
private |
Referenced by platformNumber().