Search Issue Tracker
By Design
Votes
0
Found in [Package]
12.0.0
Issue ID
1311843
Regression
No
Unity CPU usage spikes to 30% when Time Node is connected to any other Node in ShaderGraph
How to reproduce:
1. Open the "ShaderGraphTime.zip" project
2. Open the "Time" Shader Graph in the Project window
3. Connect Time Node to Multiply Node in the Shader Graph window
4. Observe the CPU usage in Task Manager/Activity Monitor
Expected result: No spike in CPU usage
Actual result: 30% CPU usage spike
Reproducible with: 7.5.3 (2019.4.20f1), 10.2.2 (2020.2.5f1), 11.0.0 (2021.1.0b7), 12.0.0 (2021.2.0a5)
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
- Out-of-bounds memory access with multiple CanvasRenderers under a Canvas when using Mesh API
- Inspector tries to access file after it was deleted when the file was locked in Inspector window
- Changing Transform values in Search window Inspector loses focus while dragging and stopping mouse without releasing dragging action
- Saving changes on the dirty VFX Graph during the Play mode throws "The referenced script (Unknown) on this Behaviour is missing!" warnings
- VFX Graph Debug Info overlaps the "Initialize" block debug info by default
Resolution Note:
The time node causes the node previews to re-render every frame, which definitely costs a bit of CPU.
I took a quick look at the profiler in 2021.2, and I didn't see anything unexpected in the costs.
There are a few things we could probably optimize a bit more, and there are a few things on our backlog to address there, but I didn't see anything that would count as a bug.
The rendering cost is proportional to the number of visible previews that are animated (connected to a time node upstream).
You can hide all the previews to get rid of the cost.
Definitely send it back to us if you can't get rid of the cost by hiding the previews, or if you can find evidence in the profiler that something bad is going on.
Thanks!