This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

glProgramBinary - is it still relevant or are all shaders already cached in runtime


Does it make sense to use glProgramBinary for caching programs on runtime and storing them for further reuse. Or are shader compilations already cached by the driver and stored on the filesystem, so further application runs will not trigger shader compilation but instead just reuse the ones cached by the driver?

Regards, Aleksei

  • For Android there is a shader cache provided by the OS that is available to the driver to use, but it's a fixed size per application. The default size in upstream Android has increased in the last few Android releases, and OEMs could always configure it larger, but it can be as small as 64KB of shaders on some devices.

    In general, it is therefore still recommended to implement caching in the application as you get more guarantees about what behavior your users will see.