ARB_get_program_binary Implementation Lands In Core Mesa, Intel Driver
Written by Michael Larabel in Mesa on 8 December 2017 at 06:01 AM EST. Add A Comment
The past few weeks Intel developers working on their Mesa open-source graphics driver have been working on the ARB_get_program_binary OpenGL extension so it actually works for applications wanting to use this extension to retrieve a compiled shader/program by the driver.

ARB_get_program_binary makes it possible to easily get a binary representation of an OpenGL program object. That binary can then be supplied later on back to the OpenGL driver for execution, if the application wants to function as an offline compiler or handle its own caching to avoid recompilation of GLSL source shaders on future runs, etc. ARB_get_program_binary is required by OpenGL 4.1 and Mesa's support for it up until now was just saying it didn't support any formats for the binary programs.

There is now the MESA_program_binary_formats that is part of the OpenGL Registry and Intel wired in this support so apps/games can get/set their own NIR representation. In the future Intel might also further this to not support only NIR as their binary representation but also their GEN hardware instructions.

Jordan Justen of Intel has landed this core Mesa implementation and the necessary Intel i965 driver changes into Mesa 17.4-dev Git. So it should be working for the Intel driver at this point with Mesa Git.

Timothy Arceri of Valve meanwhile sent out his patches for extending this core Mesa work so ARB_get_program_binary can be used by the Gallium3D drivers. In the case of the Gallium3D drivers, TGSI IR is used as the program binary representation.

Similar to the Mesa on-disk shader cache, these binary representations can only be fed back into the OpenGL driver via ARB_get_program_binary when using the same Mesa build on the same GPU. At least one Linux game making use of this extension is the Dead Island game.
Related News
About The Author
Author picture

Michael Larabel is the principal author of and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and automated benchmarking software. He can be followed via Twitter or contacted via

Popular News This Week