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
- Channel remapping dropdown in the Terrain Layer does not open when clicked on the title
- The Editor freezes indefinitely when a large number of elements are entered in the Subgraphs or Categories lists
- Some Visual Effects package Assets links to documentation are not working
- Heatmap asset’s documentation button in the Inspector window leads to “Sorry... that page seems to be missing!” page when clicked
- Crash on MonoBehaviour::CallMethodIfAvailable when performing various actions
This is a duplicate of issue #1330453