glsl/linker: assign explicit uniform locations
glsl/linker: assign explicit uniform locations

Patch refactors the existing uniform processing so explicit locations
are taken in to account during variable processing. These locations
are temporarily stored in gl_uniform_storage before actual locations
are set.

UNMAPPED_UNIFORM_LOC marks unset location so that we can use 0 as a
valid explicit location.

When locations are set, UniformRemapTable is first populated with
uniforms that have explicit location set (inactive and active ones),
rest are put after explicit location slots.

v2: introduce define for locations that have not been set yet (Ian)

Signed-off-by: Tapani Pälli <cdcb67a5e49297de94340ca09f25994bd5e7f762@intel.com>
Reviewed-by: Ian Romanick <2b237cafb16dc45038e85df6c85e74e6d899eba9@intel.com>

dellis1972/glsl-optimizer,zz85/glsl-optimizer,bkaradzic/glsl-optimizer,jbarczak/glsl-optimizer,zeux/glsl-optimizer,zz85/glsl-optimizer,zz85/glsl-optimizer,mcanthony/glsl-optimizer,jbarczak/glsl-optimizer,djreep81/glsl-optimizer,bkaradzic/glsl-optimizer,tokyovigilante/glsl-optimizer,jbarczak/glsl-optimizer,wolf96/glsl-optimizer,benaadams/glsl-optimizer,zeux/glsl-optimizer,zz85/glsl-optimizer,bkaradzic/glsl-optimizer,jbarczak/glsl-optimizer,metora/MesaGLSLCompiler,djreep81/glsl-optimizer,wolf96/glsl-optimizer,zeux/glsl-optimizer,tokyovigilante/glsl-optimizer,dellis1972/glsl-optimizer,tokyovigilante/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer,metora/MesaGLSLCompiler,benaadams/glsl-optimizer,djreep81/glsl-optimizer,tokyovigilante/glsl-optimizer,dellis1972/glsl-optimizer,benaadams/glsl-optimizer,bkaradzic/glsl-optimizer,mcanthony/glsl-optimizer,mcanthony/glsl-optimizer,benaadams/glsl-optimizer,bkaradzic/glsl-optimizer,dellis1972/glsl-optimizer,tokyovigilante/glsl-optimizer,mcanthony/glsl-optimizer,wolf96/glsl-optimizer,dellis1972/glsl-optimizer,zeux/glsl-optimizer,zeux/glsl-optimizer,zz85/glsl-optimizer,wolf96/glsl-optimizer,benaadams/glsl-optimizer,jbarczak/glsl-optimizer,benaadams/glsl-optimizer,metora/MesaGLSLCompiler,djreep81/glsl-optimizer,wolf96/glsl-optimizer,djreep81/glsl-optimizer