Hi!
We’ve been using a.UseSwappyForFramePacing=0 in our DefaultEngine.ini for quite some time. Recently, however, we decided to allow players to enable/disable dynamic resolution in the game, which required us to turn Swappy on.After enabling Swappy, we started seeing a negative impact on performance. In some cases it’s minor, but on certain devices it becomes quite noticeable.
All of the tests below were performed using an automated scenario that executes exactly the same actions for a prolonged period of time. From these runs, we collect .utrace files as well as CSV profiler data. We will attach the traces as an archive.We currently have two clear examples of performance degradation:
1) Redmi Note 13 Pro (Adreno 710)
The 95th percentile frame time increases by 3.56 ms, going from 19.893 ms to 23.764 ms.
2) Redmi Note 13 Pro Plus (Mali-G610 MC4)
The 95th percentile frame time increases by approximately 1 ms.
What we consistently observe in the traces (for example, on device (1), clearly visible around the 4th “SniperMode” timing region) is that the average frame time remains roughly the same with and without Swappy.
However, when Swappy is enabled, we start seeing random frames with very long Present times. To track this, we use a custom CSV profiler stat and an Unreal Insights counter placed in FRHICommandBeginDrawingViewport / FRHICommandEndDrawingViewport.
Concretely:
- Without Swappy (device 1), frame times are usually around ~19 ms, with max values of about ~20–20.5 ms.
- With Swappy enabled, we still see many ~19 ms frames, but also spikes up to 24–25 ms, which are caused specifically by long Present calls.
We are attaching an archive with the traces for both devices.
Could you please advise:
- whether this behavior is expected with Swappy,
- if there are known ways to mitigate these long Present spikes,
- or how we could further investigate / diagnose this issue?
Thanks in advance for your help!
Best regards,
Daniil!
[Attachment Removed]