Skip to content
  • Kenneth Graunke's avatar
    iris: Avoid uploading SURFACE_STATE descriptors for UBOs if possible · 3da8a8a3
    Kenneth Graunke authored
    
    
    If we can entirely push uniform data, we don't need a SURFACE_STATE
    descriptor for pulling data.  Since constant uploads are a very common
    operation, and being able to push all data is also very common, we would
    like to avoid the overhead in this case.
    
    This patch defers uploading new descriptors.  Instead of handling that
    at iris_set_constant_buffer, we do it at iris_update_compiled_shaders,
    where we can see the currently bound shader variants.  If any need pull
    descriptors, and descriptors are missing, we update them and flag that
    the binding table also needs to be refreshed.
    
    Improves performance in GFXBench5 gl_driver2 on an i7-6770HQ by
    31.9774% +/- 1.12947% (n=15).
    
    Reviewed-by: default avatarCaio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
    3da8a8a3