Flutter Engine
The Flutter Engine
Public Member Functions | List of all members
dart::ContextDeserializationCluster Class Reference
Inheritance diagram for dart::ContextDeserializationCluster:
dart::DeserializationCluster dart::ZoneAllocated

Public Member Functions

 ContextDeserializationCluster ()
 
 ~ContextDeserializationCluster ()
 
void ReadAlloc (Deserializer *d) override
 
void ReadFill (Deserializer *d_) override
 
- Public Member Functions inherited from dart::DeserializationCluster
 DeserializationCluster (const char *name, bool is_canonical=false, bool is_immutable=false)
 
virtual ~DeserializationCluster ()
 
virtual void ReadAlloc (Deserializer *deserializer)=0
 
virtual void ReadFill (Deserializer *deserializer)=0
 
virtual void PostLoad (Deserializer *deserializer, const Array &refs)
 
const char * name () const
 
bool is_canonical () const
 
- Public Member Functions inherited from dart::ZoneAllocated
 ZoneAllocated ()
 
void * operator new (size_t size)
 
void * operator new (size_t size, Zone *zone)
 
void operator delete (void *pointer)
 

Additional Inherited Members

- Protected Member Functions inherited from dart::DeserializationCluster
void ReadAllocFixedSize (Deserializer *deserializer, intptr_t instance_size)
 
- Protected Attributes inherited from dart::DeserializationCluster
const char *const name_
 
const bool is_canonical_
 
const bool is_immutable_
 
intptr_t start_index_
 
intptr_t stop_index_
 

Detailed Description

Definition at line 3883 of file app_snapshot.cc.

Constructor & Destructor Documentation

◆ ContextDeserializationCluster()

dart::ContextDeserializationCluster::ContextDeserializationCluster ( )
inline

Definition at line 3885 of file app_snapshot.cc.

3885: DeserializationCluster("Context") {}
DeserializationCluster(const char *name, bool is_canonical=false, bool is_immutable=false)

◆ ~ContextDeserializationCluster()

dart::ContextDeserializationCluster::~ContextDeserializationCluster ( )
inline

Definition at line 3886 of file app_snapshot.cc.

3886{}

Member Function Documentation

◆ ReadAlloc()

void dart::ContextDeserializationCluster::ReadAlloc ( Deserializer d)
inlineoverridevirtual

Implements dart::DeserializationCluster.

Definition at line 3888 of file app_snapshot.cc.

3888 {
3889 start_index_ = d->next_index();
3890 const intptr_t count = d->ReadUnsigned();
3891 for (intptr_t i = 0; i < count; i++) {
3892 const intptr_t length = d->ReadUnsigned();
3893 d->AssignRef(d->Allocate(Context::InstanceSize(length)));
3894 }
3895 stop_index_ = d->next_index();
3896 }
int count
Definition: FontMgrTest.cpp:50
static intptr_t InstanceSize()
Definition: object.h:7448
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE auto & d
Definition: main.cc:19
size_t length

◆ ReadFill()

void dart::ContextDeserializationCluster::ReadFill ( Deserializer d_)
inlineoverridevirtual

Implements dart::DeserializationCluster.

Definition at line 3898 of file app_snapshot.cc.

3898 {
3899 Deserializer::Local d(d_);
3900
3901 ASSERT(!is_canonical()); // Never canonical.
3902 for (intptr_t id = start_index_, n = stop_index_; id < n; id++) {
3903 ContextPtr context = static_cast<ContextPtr>(d.Ref(id));
3904 const intptr_t length = d.ReadUnsigned();
3905 Deserializer::InitializeHeader(context, kContextCid,
3907 context->untag()->num_variables_ = length;
3908 context->untag()->parent_ = static_cast<ContextPtr>(d.ReadRef());
3909 for (intptr_t j = 0; j < length; j++) {
3910 context->untag()->data()[j] = d.ReadRef();
3911 }
3912 }
3913 }
static void InitializeHeader(ObjectPtr raw, intptr_t cid, intptr_t size, bool is_canonical=false)
#define ASSERT(E)

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