CACAO
Public Types | Public Member Functions | Protected Member Functions | Private Attributes | Friends
cacao::jit::compiler2::Value Class Reference
Inheritance diagram for cacao::jit::compiler2::Value:
cacao::jit::compiler2::memory::ManagerMixin< Value > cacao::jit::compiler2::Instruction cacao::jit::compiler2::ALOADInst cacao::jit::compiler2::ANEWARRAYInst cacao::jit::compiler2::AREFInst cacao::jit::compiler2::ASTOREInst cacao::jit::compiler2::BeginInst cacao::jit::compiler2::BinaryInst cacao::jit::compiler2::BUILTINInst cacao::jit::compiler2::CHECKCASTInst cacao::jit::compiler2::CHECKNULLInst cacao::jit::compiler2::CONSTInst cacao::jit::compiler2::ContainerInst cacao::jit::compiler2::COPYInst cacao::jit::compiler2::EndInst cacao::jit::compiler2::GETEXCEPTIONInst cacao::jit::compiler2::GETFIELDInst cacao::jit::compiler2::GETSTATICInst cacao::jit::compiler2::IF_CMPInst cacao::jit::compiler2::INCInst cacao::jit::compiler2::INSTANCEOFInst cacao::jit::compiler2::INVOKEINTERFACEInst cacao::jit::compiler2::INVOKESPECIALInst cacao::jit::compiler2::INVOKEVIRTUALInst cacao::jit::compiler2::JSRInst cacao::jit::compiler2::LoadInst cacao::jit::compiler2::MOVEInst cacao::jit::compiler2::MULTIANEWARRAYInst cacao::jit::compiler2::MultiOpInst cacao::jit::compiler2::NEWARRAYInst cacao::jit::compiler2::NEWInst cacao::jit::compiler2::NoInst cacao::jit::compiler2::NOPInst cacao::jit::compiler2::POPInst cacao::jit::compiler2::PUTFIELDInst cacao::jit::compiler2::PUTSTATICInst cacao::jit::compiler2::RETInst cacao::jit::compiler2::SHLInst cacao::jit::compiler2::STOREInst cacao::jit::compiler2::THROWInst cacao::jit::compiler2::UnaryInst cacao::jit::compiler2::USHRInst

Public Types

typedef alloc::unordered_set
< Instruction * >::type 
UserListTy
 

Public Member Functions

 Value (Type::TypeID type)
 
Type::TypeID get_type () const
 get the value type of the instruction More...
 
virtual ~Value ()
 
UserListTy::const_iterator user_begin () const
 
UserListTy::const_iterator user_end () const
 
size_t user_size () const
 Get the number of (unique) users. More...
 
void replace_value (Value *v)
 Replace this Value this the new one in all users. More...
 
virtual Instructionto_Instruction ()
 
virtual OStreamprint (OStream &OS) const
 print More...
 

Protected Member Functions

void append_user (Instruction *I)
 
OStreamprint_users (OStream &OS) const
 
void user_remove (Instruction *I)
 
void set_type (Type::TypeID t)
 

Private Attributes

Type::TypeID type
 
UserListTy user_list
 

Friends

class Instruction
 

Additional Inherited Members

- Static Public Member Functions inherited from cacao::jit::compiler2::memory::ManagerMixin< Value >
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...
 

Detailed Description

Definition at line 47 of file Value.hpp.

Member Typedef Documentation

Definition at line 49 of file Value.hpp.

Constructor & Destructor Documentation

cacao::jit::compiler2::Value::Value ( Type::TypeID  type)
inline

Definition at line 67 of file Value.hpp.

Value::~Value ( )
virtual

Definition at line 90 of file Value.cpp.

Member Function Documentation

void cacao::jit::compiler2::Value::append_user ( Instruction I)
inlineprotected

Definition at line 54 of file Value.hpp.

Type::TypeID cacao::jit::compiler2::Value::get_type ( ) const
inline

get the value type of the instruction

Definition at line 68 of file Value.hpp.

OStream & Value::print ( OStream OS) const
virtual

print

Reimplemented in cacao::jit::compiler2::CONSTInst, and cacao::jit::compiler2::Instruction.

Definition at line 40 of file Value.cpp.

OStream & Value::print_users ( OStream OS) const
protected

Definition at line 48 of file Value.cpp.

void Value::replace_value ( Value v)

Replace this Value this the new one in all users.

Definition at line 55 of file Value.cpp.

void cacao::jit::compiler2::Value::set_type ( Type::TypeID  t)
inlineprotected

Definition at line 63 of file Value.hpp.

virtual Instruction* cacao::jit::compiler2::Value::to_Instruction ( )
inlinevirtual

Reimplemented in cacao::jit::compiler2::Instruction.

Definition at line 88 of file Value.hpp.

UserListTy::const_iterator cacao::jit::compiler2::Value::user_begin ( ) const
inline

Definition at line 72 of file Value.hpp.

UserListTy::const_iterator cacao::jit::compiler2::Value::user_end ( ) const
inline

Definition at line 73 of file Value.hpp.

void cacao::jit::compiler2::Value::user_remove ( Instruction I)
inlineprotected

Definition at line 60 of file Value.hpp.

size_t cacao::jit::compiler2::Value::user_size ( ) const
inline

Get the number of (unique) users.

Note
This is not the number of usages but the number of different Instructions which use this Value, i.e. if an Instruction uses this Value multiple times it is only counted once!

Definition at line 81 of file Value.hpp.

Friends And Related Function Documentation

friend class Instruction
friend

Definition at line 94 of file Value.hpp.

Field Documentation

Type::TypeID cacao::jit::compiler2::Value::type
private

Definition at line 51 of file Value.hpp.

UserListTy cacao::jit::compiler2::Value::user_list
private

Definition at line 52 of file Value.hpp.


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