v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::Symbol Class Reference

#include <name.h>

Inheritance diagram for v8::internal::Symbol:
Collaboration diagram for v8::internal::Symbol:

Public Types

using IsPrivateBit = base::BitField<bool, 0, 1>
 
using IsWellKnownSymbolBit = IsPrivateBit::Next<bool, 1>
 
using IsInPublicSymbolTableBit = IsWellKnownSymbolBit::Next<bool, 1>
 
using IsInterestingSymbolBit = IsInPublicSymbolTableBit::Next<bool, 1>
 
using IsPrivateNameBit = IsInterestingSymbolBit::Next<bool, 1>
 
using IsPrivateBrandBit = IsPrivateNameBit::Next<bool, 1>
 
- Public Types inherited from v8::internal::Name
enum class  HashFieldType : uint32_t { kHash = 0b10 , kIntegerIndex = 0b00 , kForwardingIndex = 0b01 , kEmpty = 0b11 }
 
using HashFieldTypeBits = base::BitField<HashFieldType, 0, 2>
 
using HashBits
 
using IsInternalizedForwardingIndexBit = HashFieldTypeBits::Next<bool, 1>
 
using IsExternalForwardingIndexBit
 
using ForwardingIndexValueBits
 
using ArrayIndexValueBits
 
using ArrayIndexLengthBits
 

Public Member Functions

Tagged< PrimitiveHeapObjectdescription () const
 
void set_description (Tagged< PrimitiveHeapObject > value, WriteBarrierMode mode=UPDATE_WRITE_BARRIER)
 
bool is_private () const
 
void set_is_private (bool value)
 
bool is_well_known_symbol () const
 
void set_is_well_known_symbol (bool value)
 
bool is_interesting_symbol () const
 
void set_is_interesting_symbol (bool value)
 
bool is_in_public_symbol_table () const
 
void set_is_in_public_symbol_table (bool value)
 
bool is_private_name () const
 
void set_is_private_name ()
 
bool is_private_brand () const
 
void set_is_private_brand ()
 
void SymbolShortPrint (std::ostream &os)
 
- Public Member Functions inherited from v8::internal::Name
bool HasHashCode () const
 
bool HasForwardingIndex (AcquireLoadTag) const
 
bool HasInternalizedForwardingIndex (AcquireLoadTag) const
 
bool HasExternalForwardingIndex (AcquireLoadTag) const
 
uint32_t raw_hash_field () const
 
uint32_t raw_hash_field (AcquireLoadTag) const
 
void set_raw_hash_field (uint32_t hash)
 
void set_raw_hash_field (uint32_t hash, ReleaseStoreTag)
 
void set_raw_hash_field_if_empty (uint32_t hash)
 
uint32_t hash () const
 
bool TryGetHash (uint32_t *hash) const
 
bool Equals (Tagged< Name > other)
 
bool IsArrayIndex ()
 
bool AsArrayIndex (uint32_t *index)
 
bool AsIntegerIndex (size_t *index)
 
bool IsInteresting (Isolate *isolate)
 
bool IsPrivate ()
 
bool IsPrivateName ()
 
bool IsPrivateBrand ()
 
void NameShortPrint ()
 
int NameShortPrint (base::Vector< char > str)
 
uint32_t EnsureHash ()
 
uint32_t EnsureHash (const SharedStringAccessGuardIfNeeded &)
 
uint32_t EnsureRawHash ()
 
uint32_t EnsureRawHash (const SharedStringAccessGuardIfNeeded &)
 
uint32_t RawHash ()
 
- Public Member Functions inherited from v8::internal::HeapObjectLayout
 HeapObjectLayout ()=delete
 
Tagged< Mapmap () const
 
Tagged< Mapmap (AcquireLoadTag) const
 
MapWord map_word (RelaxedLoadTag) const
 
void set_map (Isolate *isolate, Tagged< Map > value)
 
template<typename IsolateT >
void set_map (IsolateT *isolate, Tagged< Map > value, ReleaseStoreTag)
 
template<typename IsolateT >
void set_map_safe_transition (IsolateT *isolate, Tagged< Map > value, ReleaseStoreTag)
 
void set_map_safe_transition_no_write_barrier (Isolate *isolate, Tagged< Map > value, RelaxedStoreTag=kRelaxedStore)
 
template<typename IsolateT >
void set_map_after_allocation (IsolateT *isolate, Tagged< Map > value, WriteBarrierMode mode=UPDATE_WRITE_BARRIER)
 
void set_map_no_write_barrier (Isolate *isolate, Tagged< Map > value, RelaxedStoreTag=kRelaxedStore)
 
void set_map_word_forwarded (Tagged< HeapObject > target_object, ReleaseStoreTag)
 
void set_map_word_forwarded (Tagged< HeapObject > target_object, RelaxedStoreTag)
 
Address ptr () const
 
Address address () const
 
ReadOnlyRoots EarlyGetReadOnlyRoots () const
 
int Size () const
 
V8_EXPORT_PRIVATE int SizeFromMap (Tagged< Map > map) const
 
WriteBarrierMode GetWriteBarrierMode (const DisallowGarbageCollection &promise)
 

Private Member Functions

uint32_t flags () const
 
void set_flags (uint32_t value)
 
const char * PrivateSymbolToName () const
 

Private Attributes

uint32_t flags_
 
TaggedMember< PrimitiveHeapObjectdescription_
 

Friends

class Factory
 
struct ObjectTraits< Symbol >
 
struct OffsetsForDebug
 
class V8HeapExplorer
 
class CodeStubAssembler
 
class maglev::MaglevAssembler
 
class TorqueGeneratedSymbolAsserts
 
class Name
 

Additional Inherited Members

- Static Public Member Functions inherited from v8::internal::Name
static bool Equals (Isolate *isolate, DirectHandle< Name > one, DirectHandle< Name > two)
 
static bool ContainsCachedArrayIndex (uint32_t hash)
 
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< StringToFunctionName (Isolate *isolate, DirectHandle< Name > name)
 
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< StringToFunctionName (Isolate *isolate, DirectHandle< Name > name, DirectHandle< String > prefix)
 
static bool IsHashFieldComputed (uint32_t raw_hash_field)
 
static bool IsHash (uint32_t raw_hash_field)
 
static bool IsIntegerIndex (uint32_t raw_hash_field)
 
static bool IsForwardingIndex (uint32_t raw_hash_field)
 
static bool IsInternalizedForwardingIndex (uint32_t raw_hash_field)
 
static bool IsExternalForwardingIndex (uint32_t raw_hash_field)
 
static uint32_t CreateHashFieldValue (uint32_t hash, HashFieldType type)
 
static uint32_t CreateInternalizedForwardingIndex (uint32_t index)
 
static uint32_t CreateExternalForwardingIndex (uint32_t index)
 
- Static Public Attributes inherited from v8::internal::Name
static constexpr int kHashNotComputedMask = 1
 
static constexpr int kEmptyHashField
 
static const int kMaxCachedArrayIndexLength = 7
 
static const uint32_t kMaxArrayIndex = kMaxUInt32 - 1
 
static const int kMaxArrayIndexSize = 10
 
static const int kMaxIntegerIndexSize
 
static const int kArrayIndexValueBits = 24
 
static const int kArrayIndexLengthBits
 
static const unsigned int kDoesNotContainCachedArrayIndexMask
 
static const unsigned int kDoesNotContainIntegerOrForwardingIndexMask = 0b10
 

Detailed Description

Definition at line 248 of file name.h.

Member Typedef Documentation

◆ IsInPublicSymbolTableBit

◆ IsInterestingSymbolBit

◆ IsPrivateBit

Definition at line 250 of file name.h.

◆ IsPrivateBrandBit

◆ IsPrivateNameBit

◆ IsWellKnownSymbolBit

Member Function Documentation

◆ description()

Tagged< PrimitiveHeapObject > v8::internal::Symbol::description ( ) const
inline

Definition at line 25 of file name-inl.h.

◆ flags()

uint32_t v8::internal::Symbol::flags ( ) const
inlineprivate

Definition at line 319 of file name.h.

Here is the caller graph for this function:

◆ is_in_public_symbol_table()

bool v8::internal::Symbol::is_in_public_symbol_table ( ) const
inline

◆ is_interesting_symbol()

bool v8::internal::Symbol::is_interesting_symbol ( ) const
inline

◆ is_private()

bool v8::internal::Symbol::is_private ( ) const
inline
Here is the caller graph for this function:

◆ is_private_brand()

bool v8::internal::Symbol::is_private_brand ( ) const
inline

◆ is_private_name()

bool v8::internal::Symbol::is_private_name ( ) const
inline

Definition at line 54 of file name-inl.h.

Here is the call graph for this function:

◆ is_well_known_symbol()

bool v8::internal::Symbol::is_well_known_symbol ( ) const
inline

◆ PrivateSymbolToName()

const char * v8::internal::Symbol::PrivateSymbolToName ( ) const
private

Definition at line 4984 of file objects.cc.

Here is the call graph for this function:

◆ set_description()

void v8::internal::Symbol::set_description ( Tagged< PrimitiveHeapObject > value,
WriteBarrierMode mode = UPDATE_WRITE_BARRIER )
inline

Definition at line 28 of file name-inl.h.

◆ set_flags()

void v8::internal::Symbol::set_flags ( uint32_t value)
inlineprivate

Definition at line 320 of file name.h.

Here is the caller graph for this function:

◆ set_is_in_public_symbol_table()

void v8::internal::Symbol::set_is_in_public_symbol_table ( bool value)
inline

◆ set_is_interesting_symbol()

void v8::internal::Symbol::set_is_interesting_symbol ( bool value)
inline

◆ set_is_private()

void v8::internal::Symbol::set_is_private ( bool value)
inline

◆ set_is_private_brand()

void v8::internal::Symbol::set_is_private_brand ( )
inline

◆ set_is_private_name()

void v8::internal::Symbol::set_is_private_name ( )
inline

Definition at line 60 of file name-inl.h.

Here is the call graph for this function:

◆ set_is_well_known_symbol()

void v8::internal::Symbol::set_is_well_known_symbol ( bool value)
inline

◆ SymbolShortPrint()

void v8::internal::Symbol::SymbolShortPrint ( std::ostream & os)

Definition at line 3860 of file objects-printer.cc.

Here is the call graph for this function:

Friends And Related Symbol Documentation

◆ CodeStubAssembler

friend class CodeStubAssembler
friend

Definition at line 312 of file name.h.

◆ Factory

friend class Factory
friend

Definition at line 308 of file name.h.

◆ maglev::MaglevAssembler

friend class maglev::MaglevAssembler
friend

Definition at line 313 of file name.h.

◆ Name

friend class Name
friend

Definition at line 317 of file name.h.

◆ ObjectTraits< Symbol >

friend struct ObjectTraits< Symbol >
friend

Definition at line 308 of file name.h.

◆ OffsetsForDebug

friend struct OffsetsForDebug
friend

Definition at line 310 of file name.h.

◆ TorqueGeneratedSymbolAsserts

friend class TorqueGeneratedSymbolAsserts
friend

Definition at line 314 of file name.h.

◆ V8HeapExplorer

friend class V8HeapExplorer
friend

Definition at line 311 of file name.h.

Member Data Documentation

◆ description_

TaggedMember<PrimitiveHeapObject> v8::internal::Symbol::description_
private

Definition at line 327 of file name.h.

◆ flags_

uint32_t v8::internal::Symbol::flags_
private

Definition at line 324 of file name.h.


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