Search Issue Tracker
Duplicate
Votes
0
Found in
2020.3
2020.3.3f1
2021.1
2021.2
Issue ID
1335879
Regression
No
Shader.CompileGPUProgram takes more time to execute every time URP settings are modified and a shader is compiled
Reproduction steps:
1. Open the user's attached "AssetDatabaseRefreshBug.zip" project
2. Open the Profiler window and switch to Editor profiling
3. Select "UniversalRP-HighQuality" asset in the Settings folder
4. Change Lighting or Shadows settings (e.g. Main Light, Soft Shadows, etc) in the Inspector
5. Open the NewUnlitShader and make any change (e.g change LOD from 100 to 1000)
6. Open the Editor and note the CPU spike in the Profiler window
7. Repeat steps 3-6 a few more times (~3-10) and observe the Profiler
Expected result: Shader.CompileGPUProgram execution time does not change
Actual result: Shader.CompileGPUProgram execution time increases
Reproducible with: 2020.3.12f1, 2021.1.11f1, 2021.2.0a15
Not reproducible with: 2021.2.0a16 (<100ms), 2021.2.0a19
Could not test with: 2018.4, 2019.4 (project breaks on downgrade)
Notes:
- the execution time increases inconsistently, it might only increase only after every 5 or 10 attempts
- an example of how fast it can increase in 2021.1.10f1 (ms): 85, 283, 353, 330, 355, 340, 341, 436, 550, 670, 671
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
- Crash on when D3D12RenderPass::SetupDeviceResources when opening FBX animation preview
- Serialization errors are thrown when "com.unity.render-pipelines.core" is added as a custom package and Graphics window is opened
- Character Joints unexpectedly rotate when a ragdoll is created using the Ragdoll Wizard
- Crash on GfxDeviceD3D11Base::DrawBuffersBatchMode when rendering the Scene view
- The shared EditorBuildSettings.asset file of symlinked projects is not updated when changing the order of the Scenes in Build Settings in one of the projects
This is a duplicate of issue #1330453