I occasionally experience severe lag, so I tried profiling, but I can’t pinpoint the cause.
I’m pretty sure it’s a CPU bottleneck since I’m doing physics calculations. It’s all in WaitForTasks, and it’s happening inside an EngineLoop and I don’t know what’s causing this.
Everything else is completely clean and this is the reason for almost everything.
All actor and component ticks are disabled and I’m simulating around 100 objects at a time. Only the object being simulated has CCD enabled, but the simulation time is only a few seconds. Apart from some extreme localized lag, performance generally doesn’t degrade that much.
I don’t know what task is being waited for and what is looping that is causing this lag. How can I find out the cause?