Search Issue Tracker
Fixed in 1.3.1
Votes
0
Found in [Package]
1.3.0
Issue ID
1271866
Regression
No
[Mobile Notifications] AndroidReceivedNotificationMainThreadDispatcher allocates new list in every frame
In AndroidReceivedNotificationMainThreadDispatcher.cs line 27, a new AndroidJavaObject list is allocated on each frame.
Optimize the code so it would re-use the same collection to reduce GC calls.
Steps to reproduce:
1) Create a project that utilizes AndroidReceivedNotificationMainThreadDispatcher class.
2) Build and run on Android.
3) Monitor GC.Alloc calls coming from AndroidReceivedNotificationMainThreadDispatcher in Profiler.
Expected: Fewer list allocations are done.
Actual: List allocations done in each frame.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- The Scene View becomes gray and "NullReferenceException" errors are thrown when attaching the Unity Editor process to RenderDoc
- Memory usage rapidly rises when changing colors in the color wheel
- Physically Based Sky's Horizon and Zenith Tint Color Selection Bars don't have immediate access to color pickers
- EmptyAdditionalLightShadowmapTexture leaks from memory when URP quality level is changed using QualitySettings.SetQualityLevel
- Referenced ScriptableObject field does not get updated and cannot be set to "None" when there are no Objects of that type
Add comment