Working on iOS platform / 2018 mac mini and recently upgraded to the latest 2019.4 LTS. I was previous on 2018.4 LTS.
Ever since updating Unity, play mode has been extremely slow. The unusual thing is that restarting Unity fixes the problem every single time, and then eventually the problem will reoccur. It’s difficult to say exactly what causes the issue to reoccur, but I’ve noticed it happens often after switching my repo to a different commit or pulling changes. It seems that every time that happens, I need to open the project in Unity & then restart Unity before play mode returns to normal behavior.
The issue appears to be either Semaphore.WaitForSignal or EditorLoop (see attached image from profiler). The fact that restarting Unity fixes the issue, and that it never occurred before upgrading to 2019.4, makes me assume this is most likely a bug. Note that I already have VSync disabled.
I’ve also tried profiling the GPU but all I get is a yellow warning icon in the profiler. It says “GPU profiling is not supported when using Metal”. I’ve tried disabling Metal and still get the same message.
Could you please provide a screenshot where the render thread, which contains the Semaphore that the main thread is waiting on, is fully visible? Ideally also for the previous frame because that likely started work on it that hasn’t finished in time.
Also could you additionally try profiling the editor while you’re in Playmode?
Easiest way to do so is is with the Profiler set to Deep Profiling and targeting Editor instead of Playmode, you can then either start recording via the record button of the window, before closing it, or via the Profiler recording shortcuts F9 while still in Editmode.
Run Playmode for a bit, then hit F9 again to stop the profiler and open its window again.