Search Issue Tracker
Fixed
Fixed in 2021.3.15f1, 2022.2.0b15, 2023.1.0a14
Votes
113
Found in
2021.3.8f1
2022.1.13f1
2022.2.0b4
2023.1.0a6
Issue ID
UUM-3711
Regression
No
Shader variant build preparation does not scale
When building shaders Unity enumerates through all possible shader variants to be able to strip the excess variants using scriptable stripping. With the amount of multi_compile features increasing in the shaders, the full variant space can grow into sizes where the time and memory requirements to process becomes unbearable.
URP is especially hurt by this due to how much it utilizes multi_compile. Take the URP template project and build it. A significant portion of the time goes into preparing 400M variants, after which we only compile the required ones. Now add a few multi_compiles on top of that and the preparation can take hours.
-
tom_opuscope
Sep 21, 2022 09:21
it has been months without a fix, any progress ? We have been stuck on 2021.1 for a while now because of this.
-
jay-jin
Sep 19, 2022 02:12
Time is money friend!
-
fwalker
Aug 27, 2022 02:24
This is pretty crazy. We are also in need of a fix.
-
Bwacky
Aug 23, 2022 21:26
It's incredible how damaging this is to any sort of project with tighter deadlines, yet it's still not fixed after such a ridiculously long time. Simply insane.
-
czlowiekpiotrus
Aug 10, 2022 08:07
Please fix this ASAP.
-
KrisDevelopment
Jul 19, 2022 16:27
One of the many problems with SRP. Vote!
-
matheus_inmotionvr
Jul 19, 2022 07:35
I wish I could give all my votes in one issue.
-
PiotrSamborowski
Jul 01, 2022 13:30
I was hoping this problem would disappear with the LTS version, but it persists. Building one scene takes me over 40 minutes which is a huge production bottleneck. Please fix as soon as possible, we're unable to get any work done like this.
-
rafalTylQED
Jun 29, 2022 14:52
This issue completely derails our development process. It's absolutely critical and the LTS version should have never been released in this state.
-
Blepius
Jun 23, 2022 19:29
This is critical, please vote for this!
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
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Resolution Note (fix version 2023.1.0a14):
Added a shader keyword pre-filtering system to avoid enumerating through the full variant space. Utilized by URP only for starters.
This makes the build faster again by avoiding processing millions of variants just to be stripped.
Resolution Note (fix version 2022.2.0b15):
Added a shader keyword pre-filtering system to avoid enumerating through the full variant space. Utilized by URP only for starters.
This makes the build faster again by avoiding processing millions of variants just to be stripped.
Resolution Note (fix version 2021.3.15f1):
Added a shader keyword pre-filtering system to avoid enumerating through the full variant space. Utilized by URP only for starters.
This makes the build faster again by avoiding processing millions of variants just to be stripped.