Search Issue Tracker
Fixed
Fixed in 1.1.3
Votes
0
Found in [Package]
Issue ID
PROFB-118
Regression
Yes
[Memory Profiler] Allocated Size is smaller than Managed Size when observing Snapshot
Reproduction steps:
1. Open the attached project "ReproProj"
2. Open the Memory Profiler (Window > Analysis > Memory Profiler)
3. Select the Snapshot “Snapshot-638170002907770372“
4. Select the "All Of Memory" tab
5. Expand Managed, Managed Objects, and then System.Byte[]
6. Select the first one, and observe the value in the Allocated Size column and the value of the Managed Size in the right panel
Expected result: Total Size and Managed Size show the same size
Actual result: Total Size and Managed Size differ
Reproducible with: 1.1.0-exp.1 (2022.2.17f1, 2023.1.0b13, 2023.2.0a11), 1.1.0-exp.2 (2022.2.17f1, 2023.2.0a11)
Not reproducible with: 0.7.1-preview.1 (2020.3.47f1, 2021.3.23f1), 1.0.0 (2022.2.17f1)
Could not test with: 1.1.0-exp.2 (2023.1.0b13) (Library\PackageCache\com.unity.memoryprofiler@1.1.0-exp.2\Editor\UI\Workbench\SnapshotFilesListItem\SnapshotFileTreeItemViewController.cs(132,55): error CS1061: 'FocusController' does not contain a definition for 'IgnoreEvent' and no accessible extension method 'IgnoreEvent' accepting a first argument of type 'FocusController' could be found)
Reproducible on: Windows 10 Enterprise 21H2
Notes:
- Snapshot is captured on an Android device using Unity Editor 2020.3.30 and Memory Profiler 0.7.1-preview.1
- The reproduction video and screenshot are attached as Repro.mp4 and Repro.png
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Clicking on the project's title does not open the project when the long path tooltip is shown
- [Linux] "Select Preset..." window closes without creating another preset when "Create New Preset..." is double-clicked again after creating the first preset
- “Screen position out of view frustum” error is thrown and Game window renders black when Camera Clipping Planes fields are set to “Infinity”
- Foldouts in the Library section of UI Builder do not open when clicked on title and Tree View is enabled
- VisualElement with DynamicTransform and animated scale from 0 is not rendered until hovered when parent uses GroupTransform
Resolution Note:
These objects where incorrectly found by the managed data crawler in the Memory Profiler Package when reading the dumped heap data. They don't represent valid object data and most likely came about due to a crawler issue or UUM-53413, i.e. a timing delay between dumping the managed heap bytes and reporting Unity's native objects with GCHandles pointing at their managed heap bytes without locking the creation of new objects in between of these 2 steps, leading to the report of invalid GCHandles pointing at heap bytes that looked like a valid object (Sidenote: Boehm does not stomp over garbage collected allocations).