Search Issue Tracker

By Design

By Design in 6000.5.X

Votes

1

Found in

6000.4.0b3

6000.5.0a4

Issue ID

UUM-131202

Regression

No

Memory leak in UniversalRenderPipeline.CameraMetadataCache when switching between Scenes

Camera

-

Reproduction steps:
1. Open the attached project "ReproProj"
2. Open the “/Assets/Scenes/ProfilingScene.unity” Scene
3. Open Build Profiles (File > Build Profiles)
4. Tick Development Build
5. Click “Build And Run“
6. In Player, click "Load ProfilingScene"
7. Open Memory Profiler (Window > Analysis > Memory Profiler)
8. In Memory Profiler window, select Player and click Capture
9. In Player, click "Load MainScene"
10. Repeat steps 6-8
11. In Memory Profiler window, select first Capture
12. In All Of Memory tab and seach for “CameraMetadataCache“
13. Expand “Managed“ and “Managed Objects“
14. Observe Allocated Size of “UnityEngine.Rendering.Universal…”
15. Repeat steps 12-14 for second Snapshot

Expected result: Allocated Size is the same for both Snapshots
Actual result: 2nd Snapshot has Allocated Size higher by ~48 B

Reproducible with: 6000.4.0b3, 6000.5.0a4
Could not test with: 6000.0.65f1, 6000.3.3f1 (Library\PackageCache\com.unity.memoryprofiler@077eae9ba83a\Editor\Utilities\EditorAssetFinderUtility.cs(809,75): error CS0234: The type or namespace name 'GUID' does not exist in the namespace 'UnityEngine' (are you missing an assembly reference?))

Reproducible on:
Windows Standalone Player
Play Mode

Testing environment: Windows 10 Enterprise 21H2
Not reproducible on: No other environment tested

Notee:
- "UnityEngine.Rendering.Universal.UniversalRenderPipeline.CameraMetadataCache.s_MetadataCache" grows and its items/memory is never released. In Memory Profiler check "Managed/Managed Objects/UnityEngine.Rendering.ProfilingSampler" for example

  1. Resolution Note:

    Thank you for reporting a bug to Unity.

    After reviewing the behavior, we've confirmed it aligns with the current design and intended use of the feature. We understand this may differ from your expectations or workflow.

    We will close this case as 'As Designed.' If you have feedback on how the feature could better meet your needs, please let us know - we value your input and consider it in future improvements.

  2. Resolution Note (6000.5.X):

    Thank you for reporting a bug to Unity.

    After reviewing the behavior, we've confirmed it aligns with the current design and intended use of the feature. We understand this may differ from your expectations or workflow.

    We will close this case as 'As Designed.' If you have feedback on how the feature could better meet your needs, please let us know - we value your input and consider it in future improvements.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.