mesa/src/compiler
Lars Hamre e25c24c638 glsl: handle unsigned int wraparound in link_shaders()
v2: change check_explicit_uniform_locations() to return an
    unsigned 0 (Timothy Arceri)

We were storing the int result of check_explicit_uniform_locations()
in num_explicit_uniform_locs as an unsigned int which caused it to
be 4294967295 when a -1 was returned.

This in turn would cause the following error during linking:
error: count of uniform locations > MAX_UNIFORM_LOCATIONS(4294967295 > 98304)

Results from running piglit tests/all with this patch
and when ARB_explicit_uniform_location disabled:

changes:     178
fixes:       176
regressions: 2

The two regressions are for the following tests:
glean@glsl1-matrix column check (1)
glean@glsl1-matrix column check (2)
which regress from FAIL to CRASH.

The regressions are acceptable because the tests are currently failing due to
the aforementioned linker error.

Signed-off-by: Lars Hamre <chemecse@gmail.com>
Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com>
2016-04-09 11:06:04 +10:00
..
glsl glsl: handle unsigned int wraparound in link_shaders() 2016-04-09 11:06:04 +10:00
nir nir: Use PRIi64 and PRIu64 instead of %ld and %lu. 2016-04-04 14:38:48 -07:00
.gitignore compiler: fix .gitignore for glsl_compiler 2016-02-03 13:32:46 -05:00
Android.gen.mk Android: fix build break from nir/glsl move to compiler/ 2016-02-29 10:51:44 +00:00
Android.mk nir: move to compiler/ 2016-01-26 16:08:30 +00:00
builtin_type_macros.h glsl/types: Add a bare "sampler" type 2016-02-13 17:22:36 -08:00
glsl_types.cpp glsl: add helper for counting varyings 2016-03-31 12:51:06 +11:00
glsl_types.h glsl: add helper for counting varyings 2016-03-31 12:51:06 +11:00
Makefile.am glsl: Ensure glsl/ exists before making the lexer/parser. 2016-02-04 09:31:17 -08:00
Makefile.sources nir/Makefile: Fix alphabetization 2016-03-28 18:32:48 -07:00
nir_types.cpp nir/types: Add a wrapper for count_attribute_slots 2016-04-07 09:44:11 +02:00
nir_types.h nir/types: Add a wrapper for count_attribute_slots 2016-04-07 09:44:11 +02:00
SConscript glsl: move to compiler/ 2016-01-26 16:08:33 +00:00
shader_enums.c
shader_enums.h compiler: random comment fixup 2016-04-01 12:34:40 -04:00