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

Public Member Functions

 MapMessageDeserializationCluster (bool is_canonical, intptr_t cid)
 
 ~MapMessageDeserializationCluster ()
 
void ReadNodes (MessageDeserializer *d)
 
void ReadEdges (MessageDeserializer *d)
 
ObjectPtr PostLoad (MessageDeserializer *d)
 
- Public Member Functions inherited from dart::MessageDeserializationCluster
 MessageDeserializationCluster (const char *name, bool is_canonical=false)
 
virtual ~MessageDeserializationCluster ()
 
virtual void ReadNodes (MessageDeserializer *d)=0
 
virtual void ReadEdges (MessageDeserializer *d)
 
virtual ObjectPtr PostLoad (MessageDeserializer *d)
 
virtual void ReadNodesApi (ApiMessageDeserializer *d)
 
virtual void ReadEdgesApi (ApiMessageDeserializer *d)
 
virtual void PostLoadApi (ApiMessageDeserializer *d)
 
void ReadNodesWrapped (MessageDeserializer *d)
 
void ReadNodesWrappedApi (ApiMessageDeserializer *d)
 
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::MessageDeserializationCluster
ObjectPtr PostLoadAbstractType (MessageDeserializer *d)
 
ObjectPtr PostLoadLinkedHash (MessageDeserializer *d)
 
 DISALLOW_COPY_AND_ASSIGN (MessageDeserializationCluster)
 
- Protected Attributes inherited from dart::MessageDeserializationCluster
const char *const name_
 
const bool is_canonical_
 
intptr_t start_index_
 
intptr_t stop_index_
 

Detailed Description

Definition at line 2156 of file message_snapshot.cc.

Constructor & Destructor Documentation

◆ MapMessageDeserializationCluster()

dart::MapMessageDeserializationCluster::MapMessageDeserializationCluster ( bool  is_canonical,
intptr_t  cid 
)
inline

Definition at line 2158 of file message_snapshot.cc.

MessageDeserializationCluster(const char *name, bool is_canonical=false)
const intptr_t cid

◆ ~MapMessageDeserializationCluster()

dart::MapMessageDeserializationCluster::~MapMessageDeserializationCluster ( )
inline

Definition at line 2160 of file message_snapshot.cc.

2160{}

Member Function Documentation

◆ PostLoad()

ObjectPtr dart::MapMessageDeserializationCluster::PostLoad ( MessageDeserializer d)
inlinevirtual

Reimplemented from dart::MessageDeserializationCluster.

Definition at line 2181 of file message_snapshot.cc.

2181 {
2182 if (!is_canonical()) {
2183 ASSERT(cid_ == kMapCid);
2184 return PostLoadLinkedHash(d);
2185 }
2186
2187 ASSERT(cid_ == kConstMapCid);
2188 SafepointMutexLocker ml(
2189 d->isolate_group()->constant_canonicalization_mutex());
2190 Map& instance = Map::Handle(d->zone());
2191 for (intptr_t i = start_index_; i < stop_index_; i++) {
2192 instance ^= d->Ref(i);
2193 instance ^= instance.CanonicalizeLocked(d->thread());
2194 d->UpdateRef(i, instance);
2195 }
2196 return nullptr;
2197 }
ObjectPtr PostLoadLinkedHash(MessageDeserializer *d)
static Object & Handle()
Definition: object.h:407
#define ASSERT(E)
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE auto & d
Definition: main.cc:19
VkInstance instance
Definition: main.cc:48

◆ ReadEdges()

void dart::MapMessageDeserializationCluster::ReadEdges ( MessageDeserializer d)
inlinevirtual

Reimplemented from dart::MessageDeserializationCluster.

Definition at line 2169 of file message_snapshot.cc.

2169 {
2170 for (intptr_t id = start_index_; id < stop_index_; id++) {
2171 MapPtr map = static_cast<MapPtr>(d->Ref(id));
2172 map->untag()->set_hash_mask(Smi::New(0));
2173 map->untag()->set_type_arguments(
2174 static_cast<TypeArgumentsPtr>(d->ReadRef()));
2175 map->untag()->set_data(static_cast<ArrayPtr>(d->ReadRef()));
2176 map->untag()->set_used_data(static_cast<SmiPtr>(d->ReadRef()));
2177 map->untag()->set_deleted_keys(Smi::New(0));
2178 }
2179 }
static SmiPtr New(intptr_t value)
Definition: object.h:10006
SI auto map(std::index_sequence< I... >, Fn &&fn, const Args &... args) -> skvx::Vec< sizeof...(I), decltype(fn(args[0]...))>
Definition: SkVx.h:680

◆ ReadNodes()

void dart::MapMessageDeserializationCluster::ReadNodes ( MessageDeserializer d)
inlinevirtual

Implements dart::MessageDeserializationCluster.

Definition at line 2162 of file message_snapshot.cc.

2162 {
2163 const intptr_t count = d->ReadUnsigned();
2164 for (intptr_t i = 0; i < count; i++) {
2165 d->AssignRef(Map::NewUninitialized(cid_));
2166 }
2167 }
int count
Definition: FontMgrTest.cpp:50

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