v8  3.14.5(node0.10.28)
V8 is Google's open source JavaScript engine
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
LUnallocated Class Reference

#include <lithium.h>

Inheritance diagram for LUnallocated:
Collaboration diagram for LUnallocated:

Data Structures

class  LifetimeField
 
class  PolicyField
 
class  VirtualRegisterField
 

Public Types

enum  Policy {
  NONE, ANY, FIXED_REGISTER, FIXED_DOUBLE_REGISTER,
  FIXED_SLOT, MUST_HAVE_REGISTER, WRITABLE_REGISTER, SAME_AS_FIRST_INPUT
}
 
enum  Lifetime { USED_AT_START, USED_AT_END }
 
- Public Types inherited from LOperand
enum  Kind {
  INVALID, UNALLOCATED, CONSTANT_OPERAND, STACK_SLOT,
  DOUBLE_STACK_SLOT, REGISTER, DOUBLE_REGISTER, ARGUMENT
}
 

Public Member Functions

 LUnallocated (Policy policy)
 
 LUnallocated (Policy policy, int fixed_index)
 
 LUnallocated (Policy policy, Lifetime lifetime)
 
 STATIC_ASSERT (kFixedIndexWidth > 5)
 
bool HasAnyPolicy () const
 
bool HasFixedPolicy () const
 
bool HasRegisterPolicy () const
 
bool HasSameAsInputPolicy () const
 
Policy policy () const
 
void set_policy (Policy policy)
 
int fixed_index () const
 
int virtual_register () const
 
void set_virtual_register (unsigned id)
 
LUnallocatedCopyUnconstrained (Zone *zone)
 
bool IsUsedAtStart ()
 
- Public Member Functions inherited from LOperand
 LOperand ()
 
Kind kind () const
 
int index () const
 
bool Equals (LOperand *other) const
 
void PrintTo (StringStream *stream)
 
void ConvertTo (Kind kind, int index)
 
- Public Member Functions inherited from ZoneObject
 INLINE (void *operator new(size_t size, Zone *zone))
 
void operator delete (void *, size_t)
 
void operator delete (void *pointer, Zone *zone)
 

Static Public Member Functions

static LUnallocatedcast (LOperand *op)
 
- Static Public Member Functions inherited from LOperand
static void SetUpCaches ()
 
static void TearDownCaches ()
 

Static Public Attributes

static const int kPolicyWidth = 3
 
static const int kLifetimeWidth = 1
 
static const int kVirtualRegisterWidth = 15
 
static const int kPolicyShift = kKindFieldWidth
 
static const int kLifetimeShift = kPolicyShift + kPolicyWidth
 
static const int kVirtualRegisterShift = kLifetimeShift + kLifetimeWidth
 
static const int kFixedIndexShift
 
static const int kFixedIndexWidth = 32 - kFixedIndexShift
 
static const int kMaxVirtualRegisters = 1 << kVirtualRegisterWidth
 
static const int kMaxFixedIndex = (1 << kFixedIndexWidth) - 1
 
static const int kMinFixedIndex = -(1 << kFixedIndexWidth)
 

Additional Inherited Members

- Protected Member Functions inherited from LOperand
 LOperand (Kind kind, int index)
 
- Protected Attributes inherited from LOperand
unsigned value_
 
- Static Protected Attributes inherited from LOperand
static const int kKindFieldWidth = 3
 

Detailed Description

Definition at line 93 of file lithium.h.

Member Enumeration Documentation

enum Lifetime
Enumerator
USED_AT_START 
USED_AT_END 

Definition at line 107 of file lithium.h.

enum Policy
Enumerator
NONE 
ANY 
FIXED_REGISTER 
FIXED_DOUBLE_REGISTER 
FIXED_SLOT 
MUST_HAVE_REGISTER 
WRITABLE_REGISTER 
SAME_AS_FIRST_INPUT 

Definition at line 95 of file lithium.h.

Constructor & Destructor Documentation

LUnallocated ( Policy  policy)
inlineexplicit

Definition at line 120 of file lithium.h.

References LUnallocated::USED_AT_END.

Referenced by LUnallocated::CopyUnconstrained().

LUnallocated ( Policy  policy,
int  fixed_index 
)
inline

Definition at line 124 of file lithium.h.

References LUnallocated::USED_AT_END.

LUnallocated ( Policy  policy,
Lifetime  lifetime 
)
inline

Definition at line 128 of file lithium.h.

Member Function Documentation

static LUnallocated* cast ( LOperand op)
inlinestatic

Definition at line 198 of file lithium.h.

References ASSERT.

Referenced by LOperand::PrintTo(), and UsePosition::UsePosition().

LUnallocated* CopyUnconstrained ( Zone zone)
inline
int fixed_index ( ) const
inline

Definition at line 180 of file lithium.h.

References LUnallocated::kFixedIndexShift, and LOperand::value_.

Referenced by LOperand::PrintTo().

bool HasAnyPolicy ( ) const
inline

Definition at line 162 of file lithium.h.

References LUnallocated::ANY, and LUnallocated::policy().

Referenced by UsePosition::UsePosition().

bool HasFixedPolicy ( ) const
inline
bool HasRegisterPolicy ( ) const
inline
bool HasSameAsInputPolicy ( ) const
inline

Definition at line 173 of file lithium.h.

References LUnallocated::policy(), and LUnallocated::SAME_AS_FIRST_INPUT.

bool IsUsedAtStart ( )
inline
void set_policy ( Policy  policy)
inline
void set_virtual_register ( unsigned  id)
inline
STATIC_ASSERT ( kFixedIndexWidth  ,
 
)
int virtual_register ( ) const
inline

Field Documentation

const int kFixedIndexShift
static
Initial value:

Definition at line 141 of file lithium.h.

Referenced by LUnallocated::fixed_index().

const int kFixedIndexWidth = 32 - kFixedIndexShift
static

Definition at line 143 of file lithium.h.

const int kLifetimeShift = kPolicyShift + kPolicyWidth
static

Definition at line 139 of file lithium.h.

const int kLifetimeWidth = 1
static

Definition at line 135 of file lithium.h.

const int kMaxFixedIndex = (1 << kFixedIndexWidth) - 1
static

Definition at line 159 of file lithium.h.

Referenced by OptimizingCompiler::CreateGraph().

const int kMaxVirtualRegisters = 1 << kVirtualRegisterWidth
static

Definition at line 158 of file lithium.h.

Referenced by BASE_EMBEDDED< Visitor >::GetVirtualRegister(), and LChunk::NewChunk().

const int kMinFixedIndex = -(1 << kFixedIndexWidth)
static

Definition at line 160 of file lithium.h.

Referenced by OptimizingCompiler::CreateGraph().

const int kPolicyShift = kKindFieldWidth
static

Definition at line 138 of file lithium.h.

const int kPolicyWidth = 3
static

Definition at line 134 of file lithium.h.

const int kVirtualRegisterShift = kLifetimeShift + kLifetimeWidth
static

Definition at line 140 of file lithium.h.

const int kVirtualRegisterWidth = 15
static

Definition at line 136 of file lithium.h.


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