[ANDROID] Low performance after upgrade to 4.11.2

Hello,

we have the following problem with out small mobile game.

First we have the following devices to play around with:

  • Sony Xperia M4 Aqua, Android Version 5.0
  • Samsung Galaxy S2, Android Version 4.1.2
  • Samsung Galaxy S7, Android Version 6.0.1
  • Phicomm i600, Android Version 4.1.2
  • LG Nexus 5, Android Version 6.0.1

On UE 4.10.4 the game worked fine on every device except for the Galaxy S7, because there were no textures rendered so the games was completely black.

So we decided to upgrade our game to UE 4.11.2 which worked fine on the first look. We got textures rendered on the S7 and increased FPS on the Nexus 5 aswell on the Galaxy S2. But on the Sony Xperia M4 the FPS have decreased from about 25 down to 5. On the Phicomm i600 the games does not start anymore.

Are there any changes with the device profiles which cousing this error? How can i get rid of the performance decrease on the Xperia M4 and the Phicomm i600 device?

Thanks for answering.

Kind regards,
pyr0t0n

Do you have any logs from the Phicomm i600 crash? I don’t believe we have an example of this device for testing I’m afraid, although we have other devices with a Adreno 203 GPU.

The Sony Xperia M4 has an Adreno 405 which in both 4.10 and 4.11 would have been detected as Android_4xx which is based on Android_High which chooses 720p resolution. I will ask our QA to see if they can replicate the performance regression on that device here.

Thanks
Jack

Hey Jack,

thanks for responding and looking further into our issue here.

As attachment, i provide the log of the Phicomm device but it seems that the device does not have enough memory to handle the app.

Our problem with the Xperia occured after we change from 4.10 to 4.11 but changed nothing on the settings for the rendering. It’s weird because we are getting more FPS on older devices.

I also attached a log for our Xpera M4 device possible you see something why it comes to our problem.

Thanks again for your time and help.

As an update we’ve purchased an Xperia M4 and we’re looking at the issue.
We have a ticket UE-31393 for it.

Thanks

Thanks for letting us know and your further investigation.

We were able fix regression and performance is back to normal on those devices. Unfortunately these fixes will not be a part of 4.12 release, as it’s already locked for changes. Changes will be visible in GtiHub in a few days when we push our dev branch to main. I will post a link here once they become visible.

Hi,

https://github.com/EpicGames/UnrealEngine/commit/9e86647a3dcfde0c1368f085bad0afd21b54e51b

The mobile performance fix is in this file:
Engine/Shaders/MobileBasePassPixelShader.usf (in your version this file will be Engine/Shaders/BasePassForForwardShadingPixelShader.usf)

Could you integrate that shader changes and see if it helps?

Hey,

we have integrated the changes to the shader file and it works great on the Sony Xperia device.

On the Phicomm device the app closes without a comment while we open the level after the main menu. Can you see something in the log above about this behavior?

Thanks

The phicommi600.log file doesn’t actually show a crash, although it’s possible it’s truncated or appeared under another category other than UE4 on the console.

Could you please try rebooting the device and then launching with it connected to USB? After it crashes, run

adb logcat -d > log.txt

from the command prompt. That will dump the entire log to file. Then attach the file here.

Thanks
Jack

Hey Jack,

sorry for the late answer, as attachment the log you asked for.

Thanks again for you help!

Hi pyr0t0n,

I’m afraid that log doesn’t tell us anything new about what went wrong. I’ll see if we can source one of these for an engineer in our UK office to check out.

Cheers
Jack

Hmm, I wonder if it’s due to low memory.
There’s no call stack in that log, could you go to AndroidJNI.cpp and comment out FPlatformMisc::SetCrashHandler(EngineCrashHandler); and rebuild + deploy.

After that could you shut down the device, start it up and run the app and then send us the log as Jack describes.

Hey Allan,

here the log you requested, hope you find something that helps.

Thanks for your help too.

Kind regards,
Marcel

EDIT: While the log above is a shipping build i made a second log with a developement build.

I’m not sure if it’s your case, but I found that in some devices there’s a performance drop to single digits if UE 4.11 is not running at the native resolution (r.MobileContentScaleFactor is set to anything but 0). In my case it was a Samsung Galaxy S3 with Cyanogen. It’s worth a try changing the deviceprofile for the GPU.

Interesting, we’ve never seen this issue. The Android hardware scaler is essential for getting decent performance on other devices which have much higher native resolutions than the GPU can realistically render to with any decent performance. 720p (native res for the S3) is too high for the Mali-400 GPU in the device, in my opinion.

Maybe something about CM is making the hardware scaler work incorrectly?

The device is running out of memory, this line confirmes it:

D/UE4     ( 1518): [2016.07.07-11.58.54:277][  0]LogAndroid: Case APP_CMD_LOW_MEMORY

I too have my suspicions about CM. I barely have Android devices to test on, but I tested the game on Google’s Cloud TestLab and even on other Mali 400 devices like the Galaxy Tab 2 performance was good. Anyway, since our game doesn’t use mobile HDR and is mostly unlit, we can afford using native res and still get over 40fps on the Mali 400, so I’m going with that (we even get a solid 30fps on the infamous iPad 3, but had to reduce the resolution because the frame rate on the UMG menus is much worse).