Search Issue Tracker

Won't Fix

Votes

4

Found in

2022.2.12f1

2023.1.0b9

2023.2.0a7

Issue ID

UUM-31315

Regression

Yes

Build times are very long when building for WebGL

--

-

Reproduction steps:
1. Open the attached "repro_IN-36000SlowBuild.zip" project
2. Open File -> Build Settings
3. Select "WebGL" and press "Build And Run"
4. Wait for the build to finish

Expected result: The build finishes in around 5 minutes
Actual result: The build finishes in around 12 minutes

Reproducible with: 2022.2.0a16, 2022.2.12f1, 2023.1.0b9, 2023.2.0a7
Not reproducible with: 2020.3.46f1, 2021.3.21f1, 2022.2.0a15

Reproducible on: Windows 10, macOS 13.2.1 (M1) (by the reporter)

  1. Resolution Note:

    Upgrading version of emscripten resulted in longer build times when performing Release builds. Currently unable to identify a regression in build times after that change was made.

    If this is impacting you please add a comment on this issue or add additional details in the existing forum thread here: https://forum.unity.com/threads/webgl-build-linking-build-js-wasm-takes-forever.1315203/

Comments (5)

  1. ProGameDevUser

    Nov 14, 2023 15:50

    "Won't Fix" - Is this a joke???

  2. atomikm

    Jul 17, 2023 22:37

    This issue is still happening on 2022.3.3f1 LTS

    Build time used to take a few minutes and now won't complete after 2 hours

    Macbook Pro 2021
    Unity 2022.3.3f1

  3. Nodo42

    Jun 12, 2023 12:25

    Seems like multithreading is not used on Runtime Speed and Disk Size on Code Optimization, this why it takes so long

  4. therobby3

    Mar 28, 2023 19:54

    Also having the issue. Here is some info on my end:

    Offhand, I'll provide some quick info I have.

    Operating system: Windows 10 Home. OS build: 19045.2728
    Processor: Intel i7-7700
    Unity Editor version: 2022.2.12
    Code optimization setting: Runtime speed
    Time taken to complete: Roughly 40 minutes. Was previously in the ballpark of 6 minutes in Unity 2021.

  5. amateurd

    Mar 28, 2023 14:51

    "Linking build js.wasm" can take several hours.

    Deleting the Library folder and the Temp folder does stop the problem happening, but only for a time on before it comes back. It would be more understandable with old projects but here it happens on a brand new project created in Unity 2022.2.11 containing one scene, one GameObject and one script.

    Perhaps we could ask for a feature to be added to Unity so it will delete and rebuild the LIbrary folder before each WebGL build?

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.