nir/linker: handle uniforms without explicit location
authorAlejandro Piñeiro <apinheiro@igalia.com>
Fri, 13 Apr 2018 13:47:49 +0000 (15:47 +0200)
committerAlejandro Piñeiro <apinheiro@igalia.com>
Tue, 3 Jul 2018 10:37:32 +0000 (12:37 +0200)
commita9e6298727e4e2acbc09cf7efdbd8b5b4b192973
tree171557cacb0be35b4dd801999754d05528bbb1a9
parentb0712df6cfbc40ce770077a12e7e2beccd692019
nir/linker: handle uniforms without explicit location

ARB_gl_spirv points that uniforms in general need explicit
location. But there are still some cases of uniforms without location,
like for example uniform atomic counters. Those doesn't have a
location from the OpenGL point of view (they are identified with a
binding and offset), but Mesa internally assigns it a location.

Signed-off-by: Eduardo Lima <elima@igalia.com>
Signed-off-by: Alejandro Piñeiro <apinheiro@igalia.com>
Signed-off-by: Neil Roberts <nroberts@igalia.com>
v2: squash with another patch, minor variable name tweak (Timothy
Arceri)

Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
src/compiler/glsl/gl_nir_link_uniforms.c