[Android] [Vulkan] Constant FPS drop in Final Fantasy Type-0
When using 2x or higher rendering resolution and Vulkan backend, I get constant FPS drop in the game mentioned above, even with block transfer effects set to off.
On GL though, I can run it decently as long as I use any resolution not higher than 3x.
Device tested: Redmi Note 6 Pro (SD636, 4GB RAM) Android 9 Latest development build of PPSSPP. Tried going back to stable but it just makes the issue even worse.
Other settings shown below:

@kage2051 Frame rate comparison for both backends?
OpenGL, 3x rendering resolution, no texture scaling:

Vulkan, 3x rendering resolution, no texture scaling:

As you can see, the framerate difference is brutal in that game.
That is quite surprising but an interesting find. Needs investigation.
Does by any chance the new option "clear framebuffer on first use" make any measurable difference here?
Does by any chance the new option "clear framebuffer on first use" make any measurable difference here?
That option was checked during the tests to make sure.
Another thing that is worth mentioning here: sometimes when Ace (one of the characters) performs a one-hit KO with his card attack, framerate drops to 23 for a second, even on 1x resolution. Also that some non-FMV cutscenes tend to suffer from slight frame drops as well.
All of them reproduced on the same device, independently of the backend used.
This game FPS is horrible on PC as well using the Vulkan renderer and an AMD Gpu
Is this all through the game? Got a savegame at some particularly bad spot?
You can see it in the beginning of mission 1 so you dont need a save. If you use the OGL backend it will be ok but Vulkan will cause massive FPS drops. Tried this both on Win10 and a LInux distro I have in dual-boot.
So the game does a framebuffer copy that gets converted to a readback, as part of a bloom effect. It's a VRAM to VRAM copy, which should be safe enough to convert to an on-GPU framebuffer copy.
That fix will only improve performance with block transfer effects on, so there's probably more work to do.
Did #13541 make any kind of difference? (I'd primarily expect it to make a difference on Mali GPUs on mobile...)
Did #13541 make any kind of difference? (I'd primarily expect it to make a difference on Mali GPUs on mobile...)
No big difference to be honest. I could only play on 1x using Vulkan, while with GL I get 30fps on 3x.
I recently enabled the use of reduced-precision math in Vulkan fragment shaders, just like we always had on GL. Did that have any effect here?
I recently enabled the use of reduced-precision math in Vulkan fragment shaders, just like we always had on GL. Did that have any effect here?
It only improved speed a bit on 2x IR, I still get 20fps at the same scene if I increase the resolution to 3x. This is one of those few cases where Vulkan drivers perform worse because they might behave differently from OGL. What's curious though is that on OGL, even with the CPU texture scaling on, I get reasonable speeds in most games as long as they aren't in the same level as GoW.
Ok. Could you grab a GE frame dump of a scene where you're getting a large difference between the two APIs? I'd like to take a closer look. Instructions: https://github.com/hrydgard/ppsspp/wiki/How-to-create-a-frame-dump , then zip it up and drag into a message here.
Thanks! Will be very helpful when I get back to this issue.
PPSSPP latest git build
Using your ge dump
Vulkan backend Helio G85
The interesting thing would be to compare Vulkan and OpenGL on your device, since the report here is about Vulkan being unexplainably slower..
OpenGL

Vulkan
PPSSPP v1.11.3
Redmi Note 9 Mediatek Helio G85
If you increase the render resolution, is there a point where either slows down? if so, which one (or both)?
OpenGL 4X Resolution

Vulkan 4X Resolution
Redmi Note 9 default ppsspp settings
Vulkan is stll low fps on this game using the PPSSPP v1.11.3-975
OGL

VK

This game performance on vulkan improve now using ppsspp latest development build for android using default settings.

great!
sorry, is this also an issue?
OpenGL 2Xpsp

Vulkan 2Xpsp

or my device is too weak. Samsung M20
Looks to me that there's not much difference in VK vs OpenGL on your device, but neither runs quite fast enough. That's not really an issue on its own, it's just that the game is a little too heavy to emulate for your device....
I think I'm gonna go ahead and close this, as there are no recent reports of OpenGL being drastically faster than Vulkan.
Does the type 0 fixed?? i can't pass through the elevator at the start of mission. it crashes everytime