Search Unity

Empty projects runs max 60 fps on 2019.2.13f1

Discussion in 'Editor & General Support' started by K97, Nov 26, 2019.

  1. K97

    K97

    Joined:
    Mar 24, 2016
    Posts:
    10
    Hi there,
    previously i had installed unity 2019.2.7f1 (i guess) and it ran ok. However since i updated to unity 2019.2.13f1 max frames an empty project can run is 60. It's using too much CPU. No idea what happened!

    In profiler I can see that everything is using reasonable amount of CPU except Others. (Check screenshot)

    • What Others actually is?
    • Is this a bug?
    • How can i reduce CPU amount that Others is using?
    Thanks for any advice!


    Annotation 2019-11-26 152132.png
     
  2. MartinTilo

    MartinTilo

    Unity Technologies

    Joined:
    Aug 16, 2017
    Posts:
    2,451
    The Other Category was previously not shown unless a sample was selected. That bug is fixed now. Profiling playmode in the Editor always includes time for the Editor being rendered around it. There are other system that attribute to Other but EditorLoop is likely by far the largest one while propfiling playmode. (Other categories are anything in timeline view that has a color that doesn't map to the CPU Usage chart)

    Ergo: nothing changed, it just became way more visible. Nothing needed for you to do here, except what held true before this: measure the performance in a built player, not in playmode, if you need accurate numbers to find issues. Use Playmode profiling to iterate on issues found this way.

    You can toggle the box for "Other" in the legend of the chart. That way you can hide the Other category again. Notice however, as shown in your screenshot: The EditorLoop still takes a significant amount of time on the main thread. This also changes the timings of scheduled jobs and render commands. That means while in the Editor, your game might have all the time it needs to render while the Editor does calculations, a built player might be done on the main thread faster and then need to wait on the Render thread the next frame. In the Editor, we can "hide" some time through toggles, but this kind of base difference is just not going to go away soon.
     
    K97 likes this.
  3. MartinTilo

    MartinTilo

    Unity Technologies

    Joined:
    Aug 16, 2017
    Posts:
    2,451
  4. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    You've got a lot of WaitForTargetFPS in that profiler output. WaitForTargetFPS taking up time usually means you've got VSync enabled or are using Application.targetFrameRate. You probably have a 60hz display, which would mean VSync would try to hit 60 FPS. WaitForTargetFPS is Unity saying it finished all its work ahead of time so it is just going to sleep a while so it doesn't get ahead of the FPS it is trying to hit.
     
    K97 likes this.
  5. MartinTilo

    MartinTilo

    Unity Technologies

    Joined:
    Aug 16, 2017
    Posts:
    2,451
  6. K97

    K97

    Joined:
    Mar 24, 2016
    Posts:
    10
    @MartinTilo Thank you very much for your reply! I was making a mobile game, so performance is truly important. Mobiles are low end devices after all. I am really happy that issue wasn't anything important at all.

    Again, thanks for your time!
     
    MartinTilo likes this.