Search Issue Tracker
By Design
By Design in 2023.2.X
Votes
0
Found in
2021.3.6f1
2022.1.8f1
2022.2.0a18
2023.1.0a1
2023.2.0a1
Issue ID
UUM-2523
Regression
Yes
Application.targetFrameRate is ignored and causes huge CPU usage
How to reproduce:
1. Open the attached "TestFPS2019.zip" project
2. Open the "SampleScene" Scene
3. Enter Play Mode
4. Open the Activity Monitor or Task Manager on your OS
5. Select the "<Script>" GameObject from the Hierarchy Window
6. Click once on any of the different buttons labeled "Set xx FPS"
Expected result: No degradation of the CPU performance
Actual result: CPU performance degradation
Reproducible with: 2021.2.0a2, 2021.3.10f1, 2022.1.17f1, 2022.2.0b8, 2023.1.0a11
Not reproducible with: 2019.4.39f1, 2020.3.40f1, 2021.2.0a1
Reproduced on: macOS (Intel) Monterey 12.0.1
Important: User reported the issue on Windows. For macOS (Silicon), the targetFrameRate is already being tracked in:
[https://issuetracker.unity3d.com/issues/m1-max-player-ignores-application-dot-targetframerate]
Note:
- CPU usage sways between ~110-125% of usage on macOS
- Not Reproducible on Windows OS
- Reproducible with these APIs: Metal, OpenGL
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
- "Shader warning in 'Hidden/Light2D': implicit truncation of vector type" is thrown when building Universal 2D template
- AI Assistant breaks compilation of packages using System.Runtime.CompilerServices.Unsafe via auto-referencing
- Unity Hub checks the "Documentation" module by default on the 6.4 and 6.5 streams despite that it was unchecked with the previous installs
- Shortcut that toggles between Dopesheet and Curves Views in the Animation Window's Timeline is mislabed
- Property List Items Overlap onto the Property List's top edge when scrolling through a long Property List
Resolution Note:
This is a documented behaviour: https://docs.unity3d.com/ScriptReference/Application-targetFrameRate.html
<...> On all other platforms (Mac editor included), Unity ignores the value of targetFrameRate if you set vSyncCount. When you use vSyncCount, Unity calculates the target frame rate by dividing the platform's default target frame rate by the value of vSyncCount. For example, if the platform's default render rate is 60 fps and vSyncCount is 2, Unity tries to render the game at 30 frames per second. <...>
High FPS is expected to in turn cause high CPU usage.
Resolution Note (2023.2.X):
This is a documented behaviour: https://docs.unity3d.com/ScriptReference/Application-targetFrameRate.html
<...> On all other platforms (Mac editor included), Unity ignores the value of targetFrameRate if you set vSyncCount. When you use vSyncCount, Unity calculates the target frame rate by dividing the platform's default target frame rate by the value of vSyncCount. For example, if the platform's default render rate is 60 fps and vSyncCount is 2, Unity tries to render the game at 30 frames per second. <...>
High FPS is expected to in turn cause high CPU usage.