Semaphore Wait for signal accounts for 80% of total cpu usage.

As seen in the screenshot semaphore.WaitForSignal is costing up to 5.37 ms per frame. That is roughly 80% of my entire game’s cpu usage.

Sometimes I will get random spikes of up to 400ms due to the same reason causing my game to stutter horribly.

It is a 3d game with no lighting. I’m using unlit shaders only. My biggest texture is 1536 x 1536 which I’m only mapping on a single object.

How can I reduce or eliminate this?

It just means the main thread is sleeping, waiting for a signal from another thread. It’s not actually consuming CPU time. The render thread is working instead, and I guess that at some point this render thread signals the main thread when it is done.

Same problem.
It happens cyclically, regardless of what is displayed on the screen.
On Windows, Build or Editor. Unity 2019.30f5

Just in case anyone is stumbling upon this issue in Sep. 2021 (Like I do, lol) and is sitting on a Mac: In my case I just switched to opengl, restarted IDE, switched back to Metal and restarted IDE again and now everything is so fast. Used Unity for months and never knew that this Editor can actually run fast.

In case somebody else is having trouble with the stuttering issue caused by the 400 ms spikes I fixed this issue by upgrading unity from version 2019.1 to 2019.2

I am using 2019.3.7f1 recently and I am having the same problem. I am creating a very simple android game and when I use GTX1050TI as my graphic card it gives about 150fps. But when I switch to a smaller graphic card, it is about 20fps and it is too less for a simple game like I am creating right now. I am dowloading 2020.10b5 right now which is in beta version. I hope that it will fix the problem. I am open to any suggestions. I will share if 2020 version fixed the problem or not. @photonman170

I’m using 2019.3.11f1 and I’m experiencing similar issues.
This dropout occurs only on Android devices and not on iOS.
This may be an Android-specific glitch.
If you have any countermeasures, please let me know.

I have the same question in 2019.2.15f1 and 2019.3.7f1.
I am very unhappy.[159032-截屏2020-05-10上午114602.png|159032]

Hy, I’m using unity 2019.4 LTS version and facing same issue

What exactly IS Semaphore.WaitForSignal? I have the strange situation that I’m looking in a certain direction and as soon as I open up a menu I see that spiking in a sawtooth manner. When I look in a different direction, still at the menu, it’s gone. It’s also gone when I close the menu. So I thought it had to do with a shader combination but then all of a sudden the sawtoothing vanished…
It only happens on Oculus Quest, not in the editor so I do not know how to reproduce

Same problem here in Unity 2019.4.1f1 - LTS,
any solution?

Same issue, for me it shows up for the Post Processor. Has anyone figured this out yet?

I have the same issue in 2019.4.1f1 LTS
Semaphore.WaitForSignal is more than 60% of total, and I have huge framedrop for Android phones, especially when it’s a phone with low specs. It remains simple mini-games and I can’t find why it’s that buggy, I hope we’ll have an answer and it’ll be fixed soon!


In my case I literally just had to close the Logcat tab. It was causing these spikes every few moments, but it only happened in the editor.

In my case it was due to Multithread Rendering. After disabling Multithread Rendering in Player settings a Semaphore.waitForSignal not appeared in profiler anymore.

By the way it doens’t fixed the issue with CPU performance and enabling such option looks reasonable for devices with multiple or advanced (more than 1 thread) cores. But at least it helped to face with another errors for investigation the root cause ^^

Using Unity 2020.1.0b11.3380

Same problem (I realise it’s beta, just as long as it’s nothing i’m doing wrong and it’s something Unity will fix)