Search Issue Tracker
Won't Fix
Won't Fix in 2022.2.X
Votes
0
Found in
2021.3.6f1
2022.1.8f1
2022.2.0b1
Issue ID
UUM-8638
Regression
No
GC calls generate micro-freezes when UnityEventBase creates a lot of m_Calls
Reproduction steps:
1. Open the attached project “IN-3528.zip”
2. Start Play Mode
3. Click Window > Analysis > Memory profiler
4. Take a Snapshot and after 30 seconds or more take another Snapshot
5. In the Memory Profiler window, select Compare Snapshot
6. Click the first Snapshot, and then the second Snapshot
7. Click “Objects and Allocations”
8. Click Diff filter, and then click Group
9. Click Type filter, and then click Group
10. Click Size and then click “Sort Descending”
11. Click the “Deleted in B” dropdown
12. Find “Systems.Collections.Generic.List<UnityEngine.Events.BaseInvokableCall>”
Expected result: UnityEventBase creates only the needed amount of m_Calls.
Actual result: UnityEventBase creates a lot of m_Calls.
Reproducible with: 2021.3.6f1, 2022.1.8f1, 2022.2.0b1
Couldn't test with: 2020.3.36f1 (package errors), 2023.1.0a3 (Memory profiler doesn’t display any references)
Reproducible on: Windows Pro 21H2
Note: If you can’t find “Systems.Collections.Generic.List<UnityEngine.Events.BaseInvokableCall>” or there is a really low number of the “Referenced by”, try searching for it in the “Same” or “New in B” dropdown.
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
- Spring Joint shows only one anchor gizmo in Scene view when "Auto Configure Connected Anchor" is enabled
- Crash on _platform_memmove after entering large value in Graphics settings Preloaded Shaders field
- Disproportionally large impact on CPU frame time when writing to a rendering entity's LocalToWorld
- "Constant Force" Component numeric fields drift out of view while entering a really big value in the Inspector
- Scene view camera speed pop-up appears empty or cut off when Scene view is very narrow
Resolution Note:
There is as many m_calls as there is objects that require the call. We dont try and do any additional processing to consolidate calls as if there is any variation what so ever separating them at a later point would not be trivial.
There should be no micro-freezes noticeable as these calls are also generated at the time of object instantiation and in comparison to the rest of object creation is a minimal time.
Resolution Note (2022.2.X):
There is as many m_calls as there is objects that require the call. We dont try and do any additional processing to consolidate calls as if there is any variation what so ever separating them at a later point would not be trivial.
There should be no micro-freezes noticeable as these calls are also generated at the time of object instantiation and in comparison to the rest of object creation is a minimal time.