Version: 2021.2
LanguageEnglish
  • C#
Experimental: this API is experimental and might be changed or removed in the future.

PackedMemorySnapshot

class in UnityEditor.Profiling.Memory.Experimental

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

PackedMemorySnapshot is a compact representation of a memory snapshot that a player has sent through the profiler connection.

Properties

captureFlagsFlags corresponding to the fields present in a returned memory snapshot.
connectionsConnections is an array of from,to pairs that describe which things are keeping which other things alive.
fieldDescriptionsArray of Field Descriptions, referenced by Type Description entries by array index.
filePathPath to the memory snapshot file.
gcHandlesAll GC handles in use in the memorysnapshot.
managedHeapSectionsArray of actual managed heap memory sections.
managedStacksArray of managed stacks in a memory snapshot.
metadataMeta data that was collected during memory snapshot capture.
nativeAllocationsArray of native allocation data, captured in C++.
nativeAllocationSitesArray of native allocation site data, captured in C++.
nativeCallstackSymbolsArray of callstack symbols, used by native allocation site data.
nativeMemoryLabelsArray of memory labels, used by native allocation site data.
nativeMemoryRegionsArray of native memory regions, which houses native allocations.
nativeObjectsAll native C++ objects that were loaded at time of the snapshot.
nativeRootReferencesArray of native root references, which represent ownership of native allocation data.
nativeTypesDescriptions of all the C++ unity types the profiled player knows about.
recordDateThe time and date at which the snapshot was recorded.
typeDescriptionsAn array of indexes into PackedMemorySnapshot.typeDescriptions indetifying the type this field belongs to.
versionThe current snapshot format version.
virtualMachineInformationInformation about the virtual machine running executing the managed code inside the player.

Public Methods

DisposeDisposes of an existing PackedMemorySnapshot object and closes the file reader.

Static Methods

ConvertConverts the specified old format PackedMemorySnapshot object to a new PackedMemorySnapshot format object and writes it to the location and file name specified the the write path.
LoadLoad memory snapshot from given file path.
SaveCopy the memory snapshot file to the given file path.