Mesa shader compiling/optimizing process is too slow

Eric Anholt eric at anholt.net
Mon Jul 9 10:17:40 PDT 2012


Tiziano Bacocco <tiziano at tizbac.dyndns.org> writes:

> I've done benchmarks and comparison between proprietary drivers and 
> Mesa, Mesa seems to be up to 200x slower compiling the same shader, 
> since i understand optimizing such part of code may take months or even 
> more, i have thought to solve it this way:
>
> Upon calling glLinkProgram , an unoptimized version of the shader ( 
> compiles much much faster ) is uploaded to the GPU
> Then a separate thread is launched that will optimize the shader and as 
> soon it is done, on the next call to glUseProgram it will upload 
> optimized version in place of unoptimized one.
>
> This will solve many performance issues and temporary freezes with games 
> that load/unload content while running, while not reducing performance 
> once the background optimization is done

Yeah, we've thought of this, and it would take some work.  Sounds like a
fun project for someone.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/dri-devel/attachments/20120709/0b21e4c7/attachment.pgp>


More information about the dri-devel mailing list