v8
3.11.10(node0.8.26)
V8 is Google's open source JavaScript engine
|
#include <hashmap.h>
Data Structures | |
struct | Entry |
Public Types | |
typedef bool(* | MatchFun )(void *key1, void *key2) |
Public Member Functions | |
TemplateHashMapImpl (MatchFun match, uint32_t capacity=kDefaultHashMapCapacity, AllocationPolicy allocator=AllocationPolicy()) | |
~TemplateHashMapImpl () | |
Entry * | Lookup (void *key, uint32_t hash, bool insert, AllocationPolicy allocator=AllocationPolicy()) |
void * | Remove (void *key, uint32_t hash) |
void | Clear () |
uint32_t | occupancy () const |
uint32_t | capacity () const |
Entry * | Start () const |
Entry * | Next (Entry *p) const |
Static Public Attributes | |
static const uint32_t | kDefaultHashMapCapacity = 8 |
TemplateHashMapImpl | ( | MatchFun | match, |
uint32_t | capacity = kDefaultHashMapCapacity , |
||
AllocationPolicy | allocator = AllocationPolicy() |
||
) |
~TemplateHashMapImpl | ( | ) |
|
inline |
Definition at line 87 of file hashmap.h.
Referenced by StringsStorage::GetUsedMemorySize(), HeapObjectsMap::GetUsedMemorySize(), and HeapSnapshotsCollection::GetUsedMemorySize().
void Clear | ( | ) |
Definition at line 222 of file hashmap.h.
References v8::internal::NULL.
Referenced by HeapObjectsSet::Clear(), and LargeObjectSpace::SetUp().
TemplateHashMapImpl< AllocationPolicy >::Entry * Lookup | ( | void * | key, |
uint32_t | hash, | ||
bool | insert, | ||
AllocationPolicy | allocator = AllocationPolicy() |
||
) |
Definition at line 130 of file hashmap.h.
References TemplateHashMapImpl< AllocationPolicy >::Entry::hash, TemplateHashMapImpl< AllocationPolicy >::Entry::key, v8::internal::NULL, and TemplateHashMapImpl< AllocationPolicy >::Entry::value.
Referenced by SerializationAddressMapper::AddMapping(), LargeObjectSpace::AllocateRaw(), ObjectLiteral::CalculateEmitStore(), ObjectLiteralPropertyChecker::CheckProperty(), HeapObjectsSet::Contains(), TemplateHashMap< Literal, ObjectLiteral::Accessors, ZoneAllocationPolicy >::find(), ProfileNode::FindChild(), HeapObjectsMap::FindEntry(), ProfileNode::FindOrAddChild(), HeapObjectsMap::FindOrAddEntry(), LargeObjectSpace::FindPage(), HeapSnapshotsCollection::GetSnapshot(), HeapObjectsSet::GetTag(), HeapObjectsSet::Insert(), SerializationAddressMapper::IsMapped(), CounterMap::Lookup(), Interface::Lookup(), HeapEntriesMap::Map(), SerializationAddressMapper::MappedTo(), HeapObjectsMap::MoveObject(), HeapEntriesMap::Pair(), CounterMap::Set(), HeapObjectsSet::SetTag(), HeapSnapshotsCollection::SnapshotGenerationFinished(), and CpuProfilesCollection::StopProfiling().
TemplateHashMapImpl< AllocationPolicy >::Entry * Next | ( | Entry * | p | ) | const |
Definition at line 241 of file hashmap.h.
References ASSERT, TemplateHashMapImpl< AllocationPolicy >::Entry::key, and v8::internal::NULL.
Referenced by Interface::Iterator::Advance(), Scope::AllocateNonParameterLocals(), Scope::CollectStackAndContextLocals(), StringsStorage::GetUsedMemorySize(), NativeObjectsExplorer::IterateAndExtractReferences(), CounterMap::Iterator::Next(), ProfileNode::Print(), CpuProfilesCollection::RemoveProfile(), Logger::NameMap::~NameMap(), NativeObjectsExplorer::~NativeObjectsExplorer(), and StringsStorage::~StringsStorage().
|
inline |
Definition at line 82 of file hashmap.h.
Referenced by NativeObjectsExplorer::EstimateObjectsCount(), HeapObjectsMap::FindEntry(), HeapObjectsMap::FindOrAddEntry(), HeapObjectsSet::is_empty(), and Interface::Unify().
void * Remove | ( | void * | key, |
uint32_t | hash | ||
) |
Definition at line 160 of file hashmap.h.
References ASSERT, TemplateHashMapImpl< AllocationPolicy >::Entry::hash, TemplateHashMapImpl< AllocationPolicy >::Entry::key, v8::internal::NULL, and TemplateHashMapImpl< AllocationPolicy >::Entry::value.
Referenced by LargeObjectSpace::FreeUnmarkedObjects(), HeapObjectsMap::MoveObject(), CpuProfilesCollection::RemoveProfile(), and HeapSnapshotsCollection::RemoveSnapshot().
TemplateHashMapImpl< AllocationPolicy >::Entry * Start | ( | ) | const |
Definition at line 234 of file hashmap.h.
Referenced by Scope::AllocateNonParameterLocals(), TemplateHashMap< Literal, ObjectLiteral::Accessors, ZoneAllocationPolicy >::begin(), Scope::CollectStackAndContextLocals(), StringsStorage::GetUsedMemorySize(), NativeObjectsExplorer::IterateAndExtractReferences(), ProfileNode::Print(), CpuProfilesCollection::RemoveProfile(), Logger::NameMap::~NameMap(), NativeObjectsExplorer::~NativeObjectsExplorer(), and StringsStorage::~StringsStorage().