v8  3.25.30(node0.11.13)
V8 is Google's open source JavaScript engine
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
List< T, P > Class Template Reference

#include <globals.h>

Public Types

typedef Titerator
 

Public Member Functions

 List (AllocationPolicy allocator=AllocationPolicy())
 
 INLINE (explicit List(int capacity, AllocationPolicy allocator=AllocationPolicy()))
 
 INLINE (~List())
 
void Free ()
 
 INLINE (void *operator new(size_t size, AllocationPolicy allocator=AllocationPolicy()))
 
 INLINE (void operator delete(void *p))
 
 INLINE (void operator delete(void *p, AllocationPolicy allocator))
 
Toperator[] (int i) const
 
Tat (int i) const
 
Tlast () const
 
Tfirst () const
 
iterator begin () const
 
iterator end () const
 
 INLINE (bool is_empty() const)
 
 INLINE (int length() const)
 
 INLINE (int capacity() const)
 
Vector< TToVector () const
 
Vector< const TToConstVector ()
 
void Add (const T &element, AllocationPolicy allocator=AllocationPolicy())
 
void AddAll (const List< T, AllocationPolicy > &other, AllocationPolicy allocator=AllocationPolicy())
 
void AddAll (const Vector< T > &other, AllocationPolicy allocator=AllocationPolicy())
 
void InsertAt (int index, const T &element, AllocationPolicy allocator=AllocationPolicy())
 
void Set (int index, const T &element)
 
Vector< TAddBlock (T value, int count, AllocationPolicy allocator=AllocationPolicy())
 
T Remove (int i)
 
bool RemoveElement (const T &elm)
 
 INLINE (T RemoveLast())
 
 INLINE (void Allocate(int length, AllocationPolicy allocator=AllocationPolicy()))
 
 INLINE (void Clear())
 
 INLINE (void Rewind(int pos))
 
 INLINE (void RewindBy(int count))
 
 INLINE (void Trim(AllocationPolicy allocator=AllocationPolicy()))
 
bool Contains (const T &elm) const
 
int CountOccurrences (const T &elm, int start, int end) const
 
void Iterate (void(*callback)(T *x))
 
template<class Visitor >
void Iterate (Visitor *visitor)
 
void Sort (int(*cmp)(const T *x, const T *y))
 
void Sort ()
 
 INLINE (void Initialize(int capacity, AllocationPolicy allocator=AllocationPolicy()))
 

Detailed Description

template<typename T, class P = FreeStoreAllocationPolicy>
class v8::internal::List< T, P >

Definition at line 408 of file globals.h.

Member Typedef Documentation

typedef T* iterator

Definition at line 94 of file list.h.

Constructor & Destructor Documentation

List ( AllocationPolicy  allocator = AllocationPolicy())
inlineexplicit

Definition at line 53 of file list.h.

Member Function Documentation

void Add ( const T element,
AllocationPolicy  allocator = AllocationPolicy() 
)

Definition at line 39 of file list-inl.h.

Referenced by SmallPointerList< v8::internal::Map * >::Add(), BufferedZoneList< v8::internal::RegExpTree, 2 >::Add(), V8::AddCallCompletedCallback(), RegExpBuilder::AddCharacter(), HeapSnapshot::AddEntry(), FuncNameInferrer::AddFunction(), Heap::AddGCEpilogueCallback(), Heap::AddGCPrologueCallback(), GuardedAlternative::AddGuard(), LChunk::AddInstruction(), MemoryAllocator::AddMemoryAllocationCallback(), ExternalStringTable::AddString(), Bootstrapper::AllocateAutoDeletedArray(), BoyerMoorePositionInfo::BoyerMoorePositionInfo(), HOsrBuilder::BuildOsrLoopEntry(), CharacterRangeSplitter::Call(), ExternalStringTable::CleanUp(), TypeFeedbackOracle::CollectReceiverTypes(), KeyedLoadStubCompiler::CompileElementHandlers(), BaseLoadStoreStubCompiler::CompileMonomorphicIC(), StubCache::ComputeLoadElementPolymorphic(), EternalHandles::Create(), FuncNameInferrer::Enter(), Scope::FinalizeBlockScope(), Code::FindAllMaps(), Code::FindAllTypes(), v8::internal::FindAsciiStringIndices(), Code::FindHandlers(), HeapObjectsMap::FindOrAddEntry(), v8::internal::FindStringIndices(), v8::internal::FindTwoByteStringIndices(), HeapObjectsMap::FindUntrackedObjects(), CodeRange::FreeRawMemory(), JavaScriptFrame::GetFunctions(), OptimizedFrame::GetFunctions(), BufferedZoneList< v8::internal::RegExpTree, 2 >::GetList(), HeapObjectsMap::HeapObjectsMap(), HEnvironmentLivenessAnalysisPhase::HEnvironmentLivenessAnalysisPhase(), ZoneList< RegExpCapture * >::INLINE(), PromotionQueue::insert(), Deoptimizer::MaterializeHeapObjects(), Scope::NewUnresolved(), HLoadEliminationEffects::Process(), HCheckMapsEffects::Process(), FuncNameInferrer::PushEnclosingName(), HeapObjectsMap::PushHeapObjectsStats(), FuncNameInferrer::PushLiteralName(), FuncNameInferrer::PushVariableName(), V8_FINAL< kOperandKind, kNumCachedOperands >::RecordUint32Instruction(), SmallPointerList< v8::internal::Map * >::Reserve(), HMergeRemovableSimulatesPhase::Run(), HRepresentationChangesPhase::Run(), Shell::RunMain(), MaterializedObjectStore::Set(), CodeRange::SetUp(), JavaScriptFrame::Summarize(), OptimizedFrame::Summarize(), RootsReferencesExtractor::Synchronize(), TEST(), TextNode::TextNode(), HLoadEliminationEffects::Union(), HCheckMapsEffects::Union(), IC::UpdatePolymorphicIC(), and RootsReferencesExtractor::VisitPointers().

void AddAll ( const List< T, AllocationPolicy > &  other,
AllocationPolicy  allocator = AllocationPolicy() 
)
void AddAll ( const Vector< T > &  other,
AllocationPolicy  allocator = AllocationPolicy() 
)
Vector< T > AddBlock ( T  value,
int  count,
AllocationPolicy  allocator = AllocationPolicy() 
)
T& at ( int  i) const
inline

Definition at line 90 of file list.h.

Referenced by V8::AddCallCompletedCallback(), PolymorphicCodeCacheHashTableKey::AsObject(), SmallPointerList< v8::internal::Map * >::at(), BoyerMoorePositionInfo::at(), TextNode::CalculateOffsets(), TypeFeedbackOracle::CollectReceiverTypes(), KeyedLoadStubCompiler::CompileElementHandlers(), KeyedStoreStubCompiler::CompileStoreElementPolymorphic(), StubCache::ComputeLoadElementPolymorphic(), StubCache::ComputePolymorphicIC(), IC::CopyICToMegamorphicCache(), TextNode::FillInBMInfo(), HeapObjectsMap::FindEntry(), HeapObjectsMap::FindOrAddEntry(), HeapObjectsMap::FindUntrackedObjects(), HOsrBuilder::FinishOsrValues(), V8::FireCallCompletedCallback(), List< T, ZoneAllocationPolicy >::first(), BufferedZoneList< v8::internal::RegExpTree, 2 >::Get(), HeapSnapshot::GetEntryById(), BaseLoadStoreStubCompiler::IncludesNumberType(), PolymorphicCodeCacheHashTableKey::IsMatch(), NativeObjectsExplorer::IterateAndExtractReferences(), List< T, ZoneAllocationPolicy >::last(), PolymorphicCodeCacheHashTableKey::MapsHashHelper(), Deoptimizer::MaterializeHeapObjects(), HeapObjectsMap::MoveObject(), ProfileGenerator::RecordTickSample(), V8::RemoveCallCompletedCallback(), HeapObjectsMap::RemoveDeadEntries(), HRepresentationChangesPhase::Run(), HDehoistIndexComputationsPhase::Run(), HCanonicalizePhase::Run(), HInferRepresentationPhase::Run(), HRedundantPhiEliminationPhase::Run(), HMarkDeoptimizeOnUndefinedPhase::Run(), HComputeChangeUndefinedToNaN::Run(), KeyedStoreIC::StoreElementStub(), Bootstrapper::TearDown(), TEST(), IC::TryRemoveInvalidHandlers(), and IC::UpdatePolymorphicIC().

iterator begin ( ) const
inline

Definition at line 95 of file list.h.

bool Contains ( const T elm) const
int CountOccurrences ( const T elm,
int  start,
int  end 
) const
iterator end ( ) const
inline

Definition at line 96 of file list.h.

T& first ( ) const
inline

Definition at line 92 of file list.h.

Referenced by HeapObjectsMap::PushHeapObjectsStats().

void Free ( )
inline

Definition at line 64 of file list.h.

Referenced by ExternalStringTable::TearDown(), and CodeRange::TearDown().

INLINE ( explicit   Listint capacity,AllocationPolicy allocator=AllocationPolicy())
inline

Definition at line 56 of file list.h.

INLINE ( List())
inline

Definition at line 60 of file list.h.

INLINE ( void *operator   newsize_t size,AllocationPolicy allocator=AllocationPolicy())
inline

Definition at line 69 of file list.h.

INLINE ( void operator   deletevoid *p)
inline

Definition at line 73 of file list.h.

INLINE ( void operator   deletevoid *p, AllocationPolicy allocator)
inline

Definition at line 78 of file list.h.

INLINE ( bool is_empty()  const)
inline

Definition at line 98 of file list.h.

INLINE ( int length()  const)
inline

Definition at line 99 of file list.h.

INLINE ( int capacity()  const)
inline

Definition at line 100 of file list.h.

INLINE ( T   RemoveLast())
inline

Definition at line 143 of file list.h.

INLINE ( void   Allocateint length, AllocationPolicy allocator=AllocationPolicy())
INLINE ( void   Clear())
INLINE ( void   Rewindint pos)
INLINE ( void   RewindByint count)
inline

Definition at line 157 of file list.h.

INLINE ( void   TrimAllocationPolicy allocator=AllocationPolicy())
INLINE ( void   Initializeint capacity, AllocationPolicy allocator=AllocationPolicy())
void InsertAt ( int  index,
const T element,
AllocationPolicy  allocator = AllocationPolicy() 
)

Definition at line 114 of file list-inl.h.

References ASSERT.

Referenced by ZoneList< RegExpCapture * >::INLINE().

void Iterate ( void(*)(T *x)  callback)

Definition at line 183 of file list-inl.h.

Referenced by AllocationTracker::~AllocationTracker().

void Iterate ( Visitor *  visitor)

Definition at line 190 of file list-inl.h.

T& last ( ) const
inline

Definition at line 91 of file list.h.

Referenced by HeapSnapshot::AddEntry(), HeapObjectsMap::PushHeapObjectsStats(), and TEST().

T& operator[] ( int  i) const
inline

Definition at line 85 of file list.h.

Referenced by List< T, ZoneAllocationPolicy >::at().

bool RemoveElement ( const T elm)

Definition at line 137 of file list-inl.h.

Referenced by SmallPointerList< v8::internal::Map * >::RemoveElement().

void Set ( int  index,
const T element 
)

Definition at line 107 of file list-inl.h.

References ASSERT.

Referenced by HEnvironmentLivenessAnalysisPhase::Run(), and IC::UpdatePolymorphicIC().

void Sort ( int(*)(const T *x, const T *y)  cmp)
void Sort ( )

Definition at line 226 of file list-inl.h.

Vector<const T> ToConstVector ( )
inline

Definition at line 104 of file list.h.

Referenced by RegExpBuilder::AddQuantifierToAtom().

Vector<T> ToVector ( ) const
inline

Definition at line 102 of file list.h.


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