CACAO
Public Types | Public Member Functions | Static Public Member Functions | Private Attributes | Static Private Attributes
cacao::jit::compiler2::x86_64::X86_64ModRMOperand Class Reference
Inheritance diagram for cacao::jit::compiler2::x86_64::X86_64ModRMOperand:
cacao::jit::compiler2::x86_64::NativeAddress cacao::jit::compiler2::MachineAddress cacao::jit::compiler2::Address cacao::jit::compiler2::MachineOperand cacao::jit::compiler2::memory::ManagerMixin< MachineOperand >

Public Types

enum  ScaleFactor { Scale1 = 0, Scale2 = 1, Scale4 = 2, Scale8 = 3 }
 
- Public Types inherited from cacao::jit::compiler2::MachineOperand
enum  OperandID {
  MachineOperandID, RegisterID, StackSlotID, ManagedStackSlotID,
  ImmediateID, AddressID, VoidOperandID
}
 
typedef const voidIdentifyTy
 
typedef std::size_t IdentifyOffsetTy
 
typedef std::size_t IdentifySizeTy
 
typedef alloc::vector
< EmbeddedMachineOperand >
::type 
embedded_operand_list
 
typedef
embedded_operand_list::iterator 
operand_iterator
 
typedef
embedded_operand_list::const_iterator 
const_operand_iterator
 

Public Member Functions

 X86_64ModRMOperand (const BaseOp &base)
 
 X86_64ModRMOperand (const BaseOp &base, s4 disp)
 
 X86_64ModRMOperand (const BaseOp &base, const IndexOp &index, ScaleFactor scale, s4 disp=0)
 
 X86_64ModRMOperand (const BaseOp &base, const IndexOp &index, Type::TypeID type, s4 disp=0)
 
 X86_64ModRMOperand (const BaseOp &base, const IndexOp &index, s4 disp)
 
virtual const char * get_name () const
 
virtual X86_64ModRMOperandto_X86_64ModRMOperand ()
 
virtual OStreamprint (OStream &OS) const
 
void prepareEmit ()
 
u1 getRex (const X86_64Register &reg, bool opsiz64)
 
bool useSIB ()
 
u1 getModRM (const X86_64Register &reg)
 
u1 getSIB (const X86_64Register &reg)
 
bool useDisp8 ()
 
bool useDisp32 ()
 
s1 getDisp8 ()
 
s1 getDisp32_1 ()
 
s1 getDisp32_2 ()
 
s1 getDisp32_3 ()
 
s1 getDisp32_4 ()
 
X86_64RegistergetBase ()
 
X86_64RegistergetIndex ()
 
s4 getDisp ()
 
u1 getScale ()
 
- Public Member Functions inherited from cacao::jit::compiler2::x86_64::NativeAddress
 NativeAddress ()
 
virtual NativeAddressto_NativeAddress ()
 
- Public Member Functions inherited from cacao::jit::compiler2::MachineAddress
 MachineAddress ()
 
virtual MachineAddressto_MachineAddress ()
 
virtual ~MachineAddress ()
 
- Public Member Functions inherited from cacao::jit::compiler2::Address
 Address ()
 
virtual Addressto_Address ()
 
- Public Member Functions inherited from cacao::jit::compiler2::MachineOperand
std::size_t get_id () const
 
 MachineOperand (OperandID op_id, Type::TypeID type)
 
OperandID get_OperandID () const
 
Type::TypeID get_type () const
 
virtual ~MachineOperand ()
 
virtual MachineOperandto_MachineOperand ()
 
virtual VoidOperandto_VoidOperand ()
 
virtual Registerto_Register ()
 
virtual StackSlotto_StackSlot ()
 
virtual ManagedStackSlotto_ManagedStackSlot ()
 
virtual Immediateto_Immediate ()
 
bool is_MachineOperand () const
 
bool is_VoidOperand () const
 
bool is_Register () const
 
bool is_StackSlot () const
 
bool is_ManagedStackSlot () const
 
bool is_Immediate () const
 
bool is_Address () const
 
bool is_stackslot () const
 
bool aquivalence_less (const MachineOperand &MO) const
 
bool aquivalent (const MachineOperand &MO) const
 
virtual bool is_virtual () const
 True if operand is virtual and must be assigned during register allocation. More...
 
virtual bool needs_allocation () const
 Return true if operand is processed during register allocation. More...
 
bool has_embedded_operands ()
 
std::size_t op_size () const
 
EmbeddedMachineOperandoperator[] (std::size_t i)
 
const EmbeddedMachineOperandget (std::size_t i) const
 
EmbeddedMachineOperandget (std::size_t i)
 
operand_iterator begin ()
 
operand_iterator end ()
 
operand_iterator find (MachineOperand *op)
 
EmbeddedMachineOperandfront ()
 
EmbeddedMachineOperandback ()
 
const_operand_iterator begin () const
 
const_operand_iterator end () const
 

Static Public Member Functions

static ScaleFactor get_scale (Type::TypeID type)
 
static ScaleFactor get_scale (int32_t scale)
 
- Static Public Member Functions inherited from cacao::jit::compiler2::memory::ManagerMixin< MachineOperand >
static voidoperator new (std::size_t size) throw (std::bad_alloc)
 normal new More...
 
static voidoperator new (std::size_t size, void *ptr) throw ()
 placement new More...
 
static voidoperator new (std::size_t size, const std::nothrow_t &nt) throw ()
 nothrow new More...
 
static void operator delete (void *pMemory) throw ()
 normal delete More...
 
static void operator delete (void *pMemory, void *ptr) throw ()
 placement delete More...
 
static void operator delete (void *pMemory, const std::nothrow_t &) throw ()
 nothrow delete More...
 
static voidoperator new[] (std::size_t size) throw (std::bad_alloc)
 normal new[] More...
 
static voidoperator new[] (std::size_t size, void *ptr) throw ()
 placement new[] More...
 
static voidoperator new[] (std::size_t size, const std::nothrow_t &nt) throw ()
 nothrow new[] More...
 
static void operator delete[] (void *pMemory) throw ()
 normal delete[] More...
 
static void operator delete[] (void *pMemory, void *ptr) throw ()
 placement delete[] More...
 
static void operator delete[] (void *pMemory, const std::nothrow_t &) throw ()
 nothrow delete[] More...
 

Private Attributes

s4 disp
 
ScaleFactor scale
 
X86_64Registerbase86_64
 
X86_64Registerindex86_64
 

Static Private Attributes

static const unsigned base = 0
 
static const unsigned index = 1
 

Additional Inherited Members

- Protected Member Functions inherited from cacao::jit::compiler2::MachineOperand
virtual IdentifyTy id_base () const
 
virtual IdentifyOffsetTy id_offset () const
 
virtual IdentifySizeTy id_size () const
 
- Protected Attributes inherited from cacao::jit::compiler2::MachineOperand
embedded_operand_list embedded_operands
 TODO describe. More...
 

Detailed Description

Definition at line 61 of file X86_64ModRMOperand.hpp.

Member Enumeration Documentation

Enumerator
Scale1 
Scale2 
Scale4 
Scale8 

Definition at line 63 of file X86_64ModRMOperand.hpp.

Constructor & Destructor Documentation

cacao::jit::compiler2::x86_64::X86_64ModRMOperand::X86_64ModRMOperand ( const BaseOp base)
inline

Definition at line 70 of file X86_64ModRMOperand.hpp.

cacao::jit::compiler2::x86_64::X86_64ModRMOperand::X86_64ModRMOperand ( const BaseOp base,
s4  disp 
)
inline

Definition at line 77 of file X86_64ModRMOperand.hpp.

cacao::jit::compiler2::x86_64::X86_64ModRMOperand::X86_64ModRMOperand ( const BaseOp base,
const IndexOp index,
ScaleFactor  scale,
s4  disp = 0 
)
inline

Definition at line 84 of file X86_64ModRMOperand.hpp.

cacao::jit::compiler2::x86_64::X86_64ModRMOperand::X86_64ModRMOperand ( const BaseOp base,
const IndexOp index,
Type::TypeID  type,
s4  disp = 0 
)
inline

Definition at line 93 of file X86_64ModRMOperand.hpp.

cacao::jit::compiler2::x86_64::X86_64ModRMOperand::X86_64ModRMOperand ( const BaseOp base,
const IndexOp index,
s4  disp 
)
inline

Definition at line 102 of file X86_64ModRMOperand.hpp.

Member Function Documentation

virtual const char* cacao::jit::compiler2::x86_64::X86_64ModRMOperand::get_name ( ) const
inlinevirtual

Reimplemented from cacao::jit::compiler2::MachineAddress.

Definition at line 112 of file X86_64ModRMOperand.hpp.

X86_64ModRMOperand::ScaleFactor cacao::jit::compiler2::x86_64::X86_64ModRMOperand::get_scale ( Type::TypeID  type)
static

Definition at line 166 of file X86_64ModRMOperand.cpp.

X86_64ModRMOperand::ScaleFactor cacao::jit::compiler2::x86_64::X86_64ModRMOperand::get_scale ( int32_t  scale)
static

Definition at line 186 of file X86_64ModRMOperand.cpp.

X86_64Register* cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getBase ( )
inline

Definition at line 152 of file X86_64ModRMOperand.hpp.

s4 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getDisp ( )
inline

Definition at line 166 of file X86_64ModRMOperand.hpp.

s1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getDisp32_1 ( )

Definition at line 150 of file X86_64ModRMOperand.cpp.

s1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getDisp32_2 ( )

Definition at line 154 of file X86_64ModRMOperand.cpp.

s1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getDisp32_3 ( )

Definition at line 158 of file X86_64ModRMOperand.cpp.

s1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getDisp32_4 ( )

Definition at line 162 of file X86_64ModRMOperand.cpp.

s1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getDisp8 ( )

Definition at line 146 of file X86_64ModRMOperand.cpp.

X86_64Register* cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getIndex ( )
inline

Definition at line 159 of file X86_64ModRMOperand.hpp.

u1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getModRM ( const X86_64Register reg)

Definition at line 77 of file X86_64ModRMOperand.cpp.

u1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getRex ( const X86_64Register reg,
bool  opsiz64 
)

Definition at line 46 of file X86_64ModRMOperand.cpp.

u1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getScale ( )
inline

Definition at line 170 of file X86_64ModRMOperand.hpp.

u1 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::getSIB ( const X86_64Register reg)

Definition at line 115 of file X86_64ModRMOperand.cpp.

void cacao::jit::compiler2::x86_64::X86_64ModRMOperand::prepareEmit ( )

Definition at line 40 of file X86_64ModRMOperand.cpp.

virtual OStream& cacao::jit::compiler2::x86_64::X86_64ModRMOperand::print ( OStream OS) const
inlinevirtual

Reimplemented from cacao::jit::compiler2::MachineOperand.

Definition at line 116 of file X86_64ModRMOperand.hpp.

X86_64ModRMOperand * cacao::jit::compiler2::x86_64::X86_64ModRMOperand::to_X86_64ModRMOperand ( )
virtual
bool cacao::jit::compiler2::x86_64::X86_64ModRMOperand::useDisp32 ( )

Definition at line 142 of file X86_64ModRMOperand.cpp.

bool cacao::jit::compiler2::x86_64::X86_64ModRMOperand::useDisp8 ( )

Definition at line 138 of file X86_64ModRMOperand.cpp.

bool cacao::jit::compiler2::x86_64::X86_64ModRMOperand::useSIB ( )

Definition at line 72 of file X86_64ModRMOperand.cpp.

Field Documentation

const unsigned cacao::jit::compiler2::x86_64::X86_64ModRMOperand::base = 0
staticprivate

Definition at line 175 of file X86_64ModRMOperand.hpp.

X86_64Register* cacao::jit::compiler2::x86_64::X86_64ModRMOperand::base86_64
private

Definition at line 179 of file X86_64ModRMOperand.hpp.

s4 cacao::jit::compiler2::x86_64::X86_64ModRMOperand::disp
private

Definition at line 177 of file X86_64ModRMOperand.hpp.

const unsigned cacao::jit::compiler2::x86_64::X86_64ModRMOperand::index = 1
staticprivate

Definition at line 176 of file X86_64ModRMOperand.hpp.

X86_64Register* cacao::jit::compiler2::x86_64::X86_64ModRMOperand::index86_64
private

Definition at line 180 of file X86_64ModRMOperand.hpp.

ScaleFactor cacao::jit::compiler2::x86_64::X86_64ModRMOperand::scale
private

Definition at line 178 of file X86_64ModRMOperand.hpp.


The documentation for this class was generated from the following files: