Definition at line 5903 of file app_snapshot.cc.
◆ DeltaEncodedTypedDataSerializationCluster()
dart::DeltaEncodedTypedDataSerializationCluster::DeltaEncodedTypedDataSerializationCluster |
( |
| ) |
|
|
inline |
Definition at line 5905 of file app_snapshot.cc.
5907 kDeltaEncodedTypedDataCid) {}
SerializationCluster(const char *name, intptr_t cid, intptr_t target_instance_size=kSizeVaries, bool is_canonical=false)
◆ ~DeltaEncodedTypedDataSerializationCluster()
dart::DeltaEncodedTypedDataSerializationCluster::~DeltaEncodedTypedDataSerializationCluster |
( |
| ) |
|
|
inline |
◆ Trace()
void dart::DeltaEncodedTypedDataSerializationCluster::Trace |
( |
Serializer * |
s, |
|
|
ObjectPtr |
object |
|
) |
| |
|
inlinevirtual |
◆ WriteAlloc()
void dart::DeltaEncodedTypedDataSerializationCluster::WriteAlloc |
( |
Serializer * |
s | ) |
|
|
inlinevirtual |
Implements dart::SerializationCluster.
Definition at line 5915 of file app_snapshot.cc.
5915 {
5918 for (intptr_t
i = 0;
i <
count;
i++) {
5919 const TypedDataPtr
data = objects_[
i];
5924 const intptr_t length_in_bytes =
5926 s->WriteUnsigned(length_in_bytes);
5929 }
5930 }
#define AutoTraceObject(obj)
intptr_t target_memory_size_
intptr_t ElementSizeInBytes() const
static word InstanceSize()
◆ WriteFill()
void dart::DeltaEncodedTypedDataSerializationCluster::WriteFill |
( |
Serializer * |
s | ) |
|
|
inlinevirtual |
Implements dart::SerializationCluster.
Definition at line 5932 of file app_snapshot.cc.
5932 {
5935 for (intptr_t
i = 0;
i <
count;
i++) {
5936 const TypedDataPtr
data = objects_[
i];
5938 const intptr_t
cid =
data->GetClassId();
5939
5940
5941 ASSERT(
cid == kTypedDataUint16ArrayCid ||
5942 cid == kTypedDataUint32ArrayCid);
5943 const intptr_t cid_flag =
cid == kTypedDataUint16ArrayCid ? 0 : 1;
5945 const intptr_t encoded_length = (
length << 1) | cid_flag;
5946 s->WriteUnsigned(encoded_length);
5949 for (intptr_t j = 0; j <
length; ++j) {
5950 const intptr_t
value = (
cid == kTypedDataUint16ArrayCid)
5951 ? typed_data.GetUint16(j << 1)
5952 : typed_data.GetUint32(j << 2);
5956 }
5957 }
5958 }
static float prev(float f)
The documentation for this class was generated from the following file: