V8 Project
v8::internal::IntrusiveMarking Class Reference

#include <heap.h>

+ Collaboration diagram for v8::internal::IntrusiveMarking:

Static Public Member Functions

static bool IsMarked (HeapObject *object)
 
static void ClearMark (HeapObject *object)
 
static void SetMark (HeapObject *object)
 
static MapMapOfMarkedObject (HeapObject *object)
 
static int SizeOfMarkedObject (HeapObject *object)
 

Private Member Functions

 STATIC_ASSERT ((kHeapObjectTag &kNotMarkedBit) !=0)
 

Static Private Attributes

static const uintptr_t kNotMarkedBit = 0x1
 

Detailed Description

Definition at line 2409 of file heap.h.

Member Function Documentation

◆ ClearMark()

static void v8::internal::IntrusiveMarking::ClearMark ( HeapObject object)
inlinestatic

Definition at line 2415 of file heap.h.

2415  {
2416  uintptr_t map_word = object->map_word().ToRawValue();
2417  object->set_map_word(MapWord::FromRawValue(map_word | kNotMarkedBit));
2418  DCHECK(!IsMarked(object));
2419  }
static bool IsMarked(HeapObject *object)
Definition: heap.h:2411
static const uintptr_t kNotMarkedBit
Definition: heap.h:2437
#define DCHECK(condition)
Definition: logging.h:205

References DCHECK, IsMarked(), and kNotMarkedBit.

+ Here is the call graph for this function:

◆ IsMarked()

static bool v8::internal::IntrusiveMarking::IsMarked ( HeapObject object)
inlinestatic

Definition at line 2411 of file heap.h.

2411  {
2412  return (object->map_word().ToRawValue() & kNotMarkedBit) == 0;
2413  }

References kNotMarkedBit, and v8::internal::HeapObject::map_word().

Referenced by ClearMark(), v8::internal::Heap::GcSafeSizeOfOldObject(), and SetMark().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ MapOfMarkedObject()

static Map* v8::internal::IntrusiveMarking::MapOfMarkedObject ( HeapObject object)
inlinestatic

Definition at line 2427 of file heap.h.

2427  {
2428  uintptr_t map_word = object->map_word().ToRawValue();
2429  return MapWord::FromRawValue(map_word | kNotMarkedBit).ToMap();
2430  }

References kNotMarkedBit.

Referenced by SizeOfMarkedObject().

+ Here is the caller graph for this function:

◆ SetMark()

static void v8::internal::IntrusiveMarking::SetMark ( HeapObject object)
inlinestatic

Definition at line 2421 of file heap.h.

2421  {
2422  uintptr_t map_word = object->map_word().ToRawValue();
2423  object->set_map_word(MapWord::FromRawValue(map_word & ~kNotMarkedBit));
2424  DCHECK(IsMarked(object));
2425  }

References DCHECK, IsMarked(), and kNotMarkedBit.

+ Here is the call graph for this function:

◆ SizeOfMarkedObject()

static int v8::internal::IntrusiveMarking::SizeOfMarkedObject ( HeapObject object)
inlinestatic

Definition at line 2432 of file heap.h.

2432  {
2433  return object->SizeFromMap(MapOfMarkedObject(object));
2434  }
static Map * MapOfMarkedObject(HeapObject *object)
Definition: heap.h:2427

References MapOfMarkedObject().

Referenced by v8::internal::Heap::GcSafeSizeOfOldObject().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ STATIC_ASSERT()

v8::internal::IntrusiveMarking::STATIC_ASSERT ( (kHeapObjectTag &kNotMarkedBit) !  = 0)
private

Member Data Documentation

◆ kNotMarkedBit

const uintptr_t v8::internal::IntrusiveMarking::kNotMarkedBit = 0x1
staticprivate

Definition at line 2437 of file heap.h.

Referenced by ClearMark(), IsMarked(), MapOfMarkedObject(), and SetMark().


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