Search Issue Tracker
Won't Fix
Votes
0
Found in
2020.3.47f1
2021.3.22f1
2022.2.14f1
2023.1.0b12
2023.2.0a10
Issue ID
UUM-34319
Regression
No
Memory Leak caused by multithreading in a development build with script debugging enabled when the Player is opened
Reproduction steps:
1. Open the attached project “MemoryLeak”
2. Open File > Build Settings
3. Ensure that you are building the SampleScene and that Development Build and Script Debugging are enabled
4. Select Build And Run
5. Open the Task Manager, go to Details and enable the Column Handles
6. Observe the amount of Handles of ThreadHandleLeak.exe
Expected result: Amount of Handles do not increase
Actual result: Amount of handles constantly increasing
Reproducible with: 2020.3.47f1 2021.3.22f1, 2022.2.14f1, 2023.1.0b12, 2023.2.0a10
Reproducible on: Windows 10, macOS 13.3
Notes:
Changing "threadCountPerFrame" in MainSceneObject.cs to a higher value before building makes the Handles created increase faster.
A build without Script Debugging enabled will work fine, and regularly collect handles. To make this more visible, one can increase the number of threads per frame, and manually run the Garbage Collector during a regular build.
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
- The tag adder functionality does not work if a space is entered instead of a name
- Errors thrown in the Console when configuring In-App Purchases package
- Longer Scaler Profile names go out of the"Scaler Profilers" section
- AI Navigation window UI elements overlap when the AI Navigation window is docked and resized
- Editor freezes after some time when using NavMeshQuery::Raycast
Resolution Note:
The thread handle and memory leaks are currently expected based on the debugger implementation. We don't expect they will be a problem in practice in real projects, but please respond here if they are and we can consider changing the implementation.