In order to further optimize our game, we are adding a PSO cache to reduce hitching when particle effects and other textures are loaded for the first time in the game.
The first steps of this process are to generate a build which allows PSO caching.
This is the best relevant tutorial on the steps although it is not Quest2 focused.
Unreal Engine 4: PSO Caching (Pipeline State Object) to Reduce Load Times/Hitches (youtube.com)
This is the official docs on it from Epic:
PSO Caching on Android | Unreal Engine 4.27 Documentation
These below are the steps for an unreal 4.27 project.
Enabling in project settings these two settings

Unreal Config File Changes
In AndroidEngine.ini, add these lines:
[DevOptions.Shaders]
NeedsShaderStableKeys=true
[ConsoleVariables]
r.ShaderPipelineCache.LogPSO = 1
r.ShaderPipelineCache.SaveBoundPSOLog = 1
In DefaultDeviceProfiles.ini (add this if you don’t have it), add these lines under the Android section to ensure it runs with PSO and PSO is enabled:
+CVars=r.ShaderPipelineCache.Enabled=1
+CVars=r.ShaderPipelineCache.ReportPSO=1
+CVars=r.ShaderPipelineCache.StartupMode=1
+CVars=r.ShaderPipelineCache.GameFileMaskEnabled=0 +Cvars=r.ShaderPipelineCache.LazyLoadShadersWhenPSOCacheIsPresent=1
+CVars=r.ShaderPipelineCache.BatchSize=10
+CVars=r.ShaderPipelineCache.BatchTime=0.0
+CVars=r.ShaderPipelineCache.LogPSO=1
+CVars=r.ShaderPipelineCache.SaveBoundPSOLog=1
+CVars=r.Vulkan.PipelineCacheFromShaderPipelineCache=1
This build must be marked as android version 29 and with “For distribution” unchecked on packaging settings.
The reason it must be marked with for distribution unchecked is so that you can access the pso logs when they are written, and it must be android 29 for Quest to have the permission to write the PSO cache for some reason.
Package this build and deploy it to your device
Playing the game in all areas and generating the PSO cache
Once you package a build like this, play it and then check this folder to see if you have a PSO cache file.
This PC\Quest 3\Internal shared storage\UE4Game\VRFitnessProject\VRFitnessProject\Saved\CollectedPSOs
Run a command to generate the PSO cache from all your collected PSOs. Create a .bat file with something like this for your project name.
“C:\ue427oc\Engine\Binaries\Win64\UE4Editor-Cmd.exe” “D:\dopf\depot\VRFitnessProject\VRFitnessProject.uproject” -run=ShaderPipelineCacheTools expand D:\dopf\depot\VRFitnessProject\PSOCaching/.rec.upipelinecache D:\dopf\depot\VRFitnessProject\PSOCaching/.shk VRFitnessProject_SF_VULKAN_ES31_ANDROID.stablepc.csv
Drag in the .shk files from this folder:
D:\dopf\depot\VRFitnessProject\Saved\Shaders\SF_VULKAN_ES31_ANDROID
When you run that .bat file, it gets created in your engine folder here:
C:\ue427oc\Engine\Binaries\Win64
You have to place the resulting .csv file into this folder:
D:\dopf\depot\VRFitnessProject\Build\Android\PipelineCaches

Leave a comment