mesa/src/compiler
Andres Gomez de1bc2d19a glsl/linker: always validate explicit location among inputs
Outputs are always validated when having explicit locations and we
were trusting its outcome to catch similar problems with the inputs
since, in case of having undefined outputs for existing inputs, we
would be already reporting a linker error.

However, consider this case:

  " Shader stage n:
    ---------------

    ...

    layout(location = 0) out float a;

    ...

    Shader stage n+1:
    -----------------

    ...

    layout(location = 0) in float b;
    layout(location = 0) in float c;

    ...
  "

Currently, this won't report a linker error even though location
aliasing is happening for the inputs.

Therefore, we also need to validate the inputs independently from the
outcome of the outputs validation.

Cc: Timothy Arceri <tarceri@itsqueeze.com>
Cc: Iago Toral Quiroga <itoral@igalia.com>
Cc: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Andres Gomez <agomez@igalia.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
2019-03-19 17:23:27 +02:00
..
glsl glsl/linker: always validate explicit location among inputs 2019-03-19 17:23:27 +02:00
nir Revert "nir: const nir_call_instr::callee" 2019-03-19 10:19:42 -05:00
spirv Revert "nir: const nir_call_instr::callee" 2019-03-19 10:19:42 -05:00
.gitignore
Android.glsl.gen.mk android,autotools,i965: Fix location of float64_glsl.h 2019-01-31 19:04:30 +00:00
Android.glsl.mk
Android.mk
Android.nir.gen.mk
Android.nir.mk
blob.c
blob.h
builtin_type_macros.h
glsl_types.cpp glsl: add cl_size and cl_alignment 2019-03-19 04:08:07 +00:00
glsl_types.h glsl: add cl_size and cl_alignment 2019-03-19 04:08:07 +00:00
Makefile.am configure: allow building with python3 2018-10-31 19:15:50 +00:00
Makefile.glsl.am automake: Add float64.glsl to dist tarball 2019-01-29 23:24:57 +00:00
Makefile.nir.am nir/algebraic: Add unit tests for bitsize validation 2018-12-05 17:57:40 +01:00
Makefile.sources nir: Add a new pass to lower array dereferences on vectors 2019-03-15 23:10:27 -05:00
Makefile.spirv.am
meson.build
nir_types.cpp glsl: add cl_size and cl_alignment 2019-03-19 04:08:07 +00:00
nir_types.h glsl: add cl_size and cl_alignment 2019-03-19 04:08:07 +00:00
SConscript
SConscript.glsl scons: Generate float64_glsl.h for glsl_to_nir fp64 lowering 2019-03-02 14:33:44 -08:00
SConscript.nir
SConscript.spirv
shader_enums.c mesa: add MESA_SHADER_KERNEL 2019-01-21 20:36:41 +01:00
shader_enums.h nir/vtn: add support for SpvBuiltInGlobalLinearId 2019-03-05 22:28:29 +01:00
shader_info.h nir/spirv: improve parsing of the memory model 2019-03-05 22:28:29 +01:00