[Android] Swappy degenerate performance in Android 16

Since updating to Unreal 5.5, some Adreno-based Android devices seem to get in a tailspin where Swappy takes longer and longer to release its latch, leading to a 100+ms frame time. Insights isn’t showing much even with RHICommands enabled, I don’t think there is any instrumentation for where this is happening. The main confirmation we have that this is happening in Swappy is that disabling it prevents the issue from happening.

The actual cause of the tailspin is hard to ascertain. We have a company-wide SDK that uses Android primitives (i.e.: android.widget.ImageView, android.widget.TextView, etc.) to draw a little user icon badge on certain menus. If the badge is shown, the tailspin starts happening after transitioning between levels. Commenting out the badge prevents the issue from occurring.

While the device is in this state, it can be nudged back to normal by anything invalidating the swapchain, i.e.: rotating the device or folding/unfolding for a foldable.

Another data point is I was unable to reproduce this on my Pixel 7 until I updated to Android 16. Reverting to Android 14 stops the issue from happening.

Swappy stats when behaving normally:

Swappy Stats - Total Frames: 1877

Idle Frames: [0]=1830 [1]=47 [2]=0 [3]=0 [4]=0 [5]=0

Late Frames: [0]=0 [1]=516 [2]=1298 [3]=63 [4]=0 [5]=0

Offset From Previous: [0]=160 [1]=1461 [2]=248 [3]=8 [4]=0 [5]=0

Latency Frames: [0]=0 [1]=382 [2]=1487 [3]=8 [4]=0 [5]=0

Swappy stats during issue:

Swappy Stats - Total Frames: 243

Idle Frames: [0]=243 [1]=0 [2]=0 [3]=0 [4]=0 [5+]=0

Late Frames: [0]=0 [1]=0 [2]=0 [3]=0 [4]=189 [5+]=54

Offset From Previous: [0]=0 [1]=0 [2]=0 [3]=0 [4]=0 [5+]=243

Latency Frames: [0]=0 [1]=0 [2]=0 [3]=0 [4]=0 [5+]=243

Apologies for the vague report, but this is tricky to narrow down… It might be on Google’s end and I’ll be reaching out to them separately, but I wanted to see if Epic has encountered anything similar internally.

Steps to Reproduce
Mobile Deferred renderer

Android Adreno (Pixel 7) device

Swappy enabled

  1. Draw Android widget using android primitives
  2. Change levels
  3. Wait for ~30s as performance degrades

Hi Camille,

You mention at the beginning that this is occurring on Adreno-based devices, however, later in the post the issue reproduces on Pixel 7 which is MALI-based. Was there an Adreno-based device where this reproduced on Android 16 but not priorÉ Trying to determine if this is a driver issue or an OS level issue.

Best regards

I’m so sorry! Ever since Mali got into 3 digit models, I keep getting my wires crossed and sometimes interpret “Mali 710” as “Adreno 710”. I double checked the devices I personally reproed this on as well as the ones reported by the rest of the team during playtests:

  • Pixel 7
  • Pixel 7a
  • Pixel 8 Pro
  • Pixel 9

Which are all Mali/Immortalis 710 or 715.

Hi Camille,

Out of curiosity, does the issue reproduce if you invoke the software keyboard (which uses a TextView) or is it limited to the internal SDK?

Best regards.

I don’t believe so, we have an in-game chat that invokes the software keyboard and that doesn’t seem to reproduce the issue…

Thanks for confirming. The software keyboard uses an Android primitive android.widget.TextView. Is there a different usage pattern in the SDK you are integrating that is triggering the performance degeneration? Are you able to share a sample repro?

Best regards.

Correction: We have two different cases where we bring up the Android keyboard, and one of them actually can cause the issue.

4 finger tap for the console: I was not able to reproduce using this.

In-game chat box: Though not 100%, this does occasionally trigger the bug.

Both cases use the software keyboard, but the in-game chat reskins the simple text box to include a chat bubble image. So maybe the common theme is an ImageView?

If need be, I’ll try to create a repro project by integrating our SDK into the simple third person project.

Thanks Camille, we will try to reproduce with an ImageView, however,if you have a repro handy that can be shared, please let us know.

Best regards.