Age | Commit message (Collapse) | Author |
|
Like the constant handling and the handling of other uniforms, we add
the whole thing to the Parameters, avoiding messy, incomplete logic
for adding just the elements of a builting uniform that get used.
This means that a driver that relies only on ParameterValues[] for its
parameters will have an increased parameter load, but drivers
generally don't do that (since they have other params they need to
handle, too).
Fixes glsl-fs-statevar-call (testcase for Ember). Bug #29687.
Regresses glsl-vs-array-04 on 965. Thanks to a slight change in
register allocation, this test of undefined behavior now wraps around
the register space and unexpectedly reads the constant value it's
trying to compare to. The test should probably not look at the
resulting color, since behavior is undefined.
|
|
|
|
|
|
Both i965 and swrast rely on UsesKill to determine whether to do early
depth writes. Fixes glsl-fs-discard-02.
Bug #29835.
|
|
Fixes glsl-uniform-linking-1 and failure to link a shader in Unigine.
An alternative here would be to just ditch using _mesa_add_parameter
and build the initial params list on our own, but that would require
two walks of the list as well.
Bug #29822
|
|
|
|
cond_update wasn't being set by emit_op3, leading to valgrind
complaints, and failures in several piglit tests when built with
clang.
|
|
sqrt(x) = 1/rsq(x) = x*rsq(x)
This optimization already was in the old GLSL compiler.
Acked on irc by Eric Anholt.
|
|
Addresses the warnings:
warning: ‘target’ may be used uninitialized in this function
warning: ‘target_string’ may be used uninitialized in this function
|
|
Fixes gcc warning
In function ‘_mesa_add_unnamed_constant’:
warning: ‘pos’ may be used uninitialized in this function
but also what appears to be a bug.
|
|
Fixes piglit glsl-fs-loop valgrind uninitialized value error on softpipe
and llvmpipe.
|
|
Fixes:
glsl-array-bounds-02 (software)
glsl-array-bounds-04
glsl-array-bounds-06 (software)
glsl-array-bounds-08
|
|
We do the generation of "what sampler number within Parameters are we"
right in ir_to_mesa.cpp, instead of repeatedly walking the existing
list to find out.
|
|
Fixes:
glsl-fs-uniform-sampler-struct
glsl-fs-sampler-numbering-3
Bug #29690
|
|
We had to inline it to avoid doing a double-lookup in the process of
adding assertion checks.
|
|
Fixes: glsl-fs-uniform-array-4.
|
|
This was in place for uniform handling, but nothing actually needs the
value now, since presence in a parameter list indicates that the
uniform was used as far as the linker was concerned.
|
|
This fixes relative addressing of temporaries (and maybe others)
in all gallium drivers.
Acked on irc by Eric Anholt.
|
|
Previously, uniform initializers were handled by ir_to_mesa as it made
its Parameters list. However, uniform values are global to all
shaders, and the value set in one Parameters list wasn't propagated to
the other gl_program->Parameters lists. By going back through the
general Mesa uniform handling, we make sure that all gl_programs get
updated values, and also successfully separate uniform initializer
handling from ir_to_mesa gl_program generation.
Fixes:
glsl-uniform-initializer-5.
|
|
Fixes bugzilla #29628
|
|
The previous any() implementation would generate arg0.x || arg0.y ||
arg0.z. Having an expression operation for this makes it easy for the
backend to generate something easier (DPn + SNE for 915 FS, .any
predication on 965 VS)
|
|
Fixes: glsl-fs-any
|
|
We ended up returning CONST[loc] rather than TEMP[loc2]. Things would
*usually* end up working out OK, since the constants often ended up
getting allocated to CONST[loc..loc+columns] with no swizzle. But for
the case where the contigous temporary copy of the swizzled constant
vec4 args was actually needed, we'd end up reading some other constant
values, possibly including ones not actually allocated.
Fixes: glsl-varying-mat3x2.
|
|
The default constructor did not initialize some member variables.
|
|
|
|
|
|
Again, this is a one-element struct that was incorrectly missing the
field.
|
|
This was triggered by the previous bug, but is a separate problem
in the general sense.
|
|
According to both GLSL 1.20 and 4.0, these are a struct with one field
called "sceneColor".
Fixes a crash on loading in FlightGear.
|
|
|
|
This might happen if we manage to trigger the right linker errors.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Otherwise, with repeated program recompile, we never free the results
of the previous compile.
|
|
|
|
I didn't expect that this would really work, but it turns out there
are shaders in the wild that do it.
Fixes: (with swrast)
glsl-fs-main-return
glsl-vs-main-return
|
|
These binops are the vector-to-bool comparisons, not vec-to-bvec. We
likely want both operations avilable as expression, since 915 and 965
FS naturally does the vector version, while 965 VS can also naturally
do the scalar version. However, we can save that until later.
Fixes:
glsl-fs-vec4-operator-equal.shader_test
glsl-fs-vec4-operator-notequal.shader_test
glsl-vs-vec4-operator-equal.shader_test
glsl-vs-vec4-operator-notequal.shader_test
|
|
In one optimization pass, register files may have been messed therefore
merging instructions which use the same index in two different register
files.
|
|
This will make extracting source to produce minimal testcases for
shader compile issues easier.
|
|
Conflicts:
src/mesa/program/prog_optimize.c
|
|
|
|
|
|
|
|
|
|
|
|
|