Search Issue Tracker

Fixed

Fixed in 2022.3.20f1, 6000.0.0b11

Votes

20

Found in

2022.3.13f1

2023.1.20f1

2023.2.0f1

2023.3.0a14

6000.0.0b11

Issue ID

UUM-56323

Regression

Yes

Memory leak when building AssetBundle with Sprite Atlas enabled on macOS

--

-

Reproduction steps:
1. Open the attached "PROJECTFILE" project
2. Open the Activity Monitor and observe the Unity process Memory usage
3. In the Unity Editor Menu bar, press Test > BuildAssetBundle
4. Observe the Unity Memory usage in the Activity Monitor

Expected result: Memory usage does not increase
Actual result: Memory usage slowly increases and does not stop

Reproducible with: 2022.1.0a7, 2022.3.13f1, 2023.1.20f1, 2023.2.0f1, 2023.3.0a14
Not reproducible with: 2021.3.32f1, 2022.1.0a6

Reproducible on: macOS Ventura 13.6 (M1 Max), macOS Sonoma 14.0 (Intel)
Not reproducible on: Windows 11

Note:
-issue is not reproducible with Sprite Atlas “Disabled” mode selected
-with version 2022.3.13f1, the issue is not reproducible when Sprite Atlas “Disabled” or “Sprite Atlas V2 - Enabled” is selected

Comments (3)

  1. mhchoi_unity

    Apr 09, 2024 03:10

    Here's the sample project (bit.ly/4b52e9t) that we've made for reproducing this issue easily. We've tested the project on 2022.3.22f1 and found that it didn't release any sprites that was used during asset bundle build process. You can check it on the profiler. Here's the screenshot of the our profiler (bit.ly/4aNtmcQ) that allocated over 12GB memory with the sprites during the build.

  2. mhchoi_unity

    Mar 28, 2024 03:22

    No, this issue is not resolved yet. Could you please take look at it again? As we tested on 2022.3.20f1, there's still the memory increasing issue on our project. It takes up to 30GB of memory during asset bundle build on our mac machine. When we see the memory profiler, it seems that all of sprites in asset bundle were not released from memory during the whole build process. It didn't work like that on 2019.3.31f1 - Sprites was released from memory right after using it and keep the memory usage below 5GB during the build. We're still waiting for the fix now.

  3. SZCodeLab

    Feb 15, 2024 10:36

    Upvote for subscribing to the solving alarm.

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.