Age | Commit message (Collapse) | Author |
|
|
|
|
|
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
|
|
This makes a little progress on CorrectParse2.frag.
|
|
Fixes constFunc.frag.
|
|
This regresses constFunc.frag, but that's just unexpectedly passing
because of the FINISHME just above.
|
|
Fixes segfaults in a shader consisting of just:
void main(void) { }
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
|
|
It isn't a type (is was enum specifying the kind of node), it was
unused, and it was easily confused with actual type fields. Kill with fire.
|
|
For unsized arrays, we can't flag out-of-bounds accesses until the
array is redeclared with a size. Track the maximum accessed element
and generate an error if the declaration specifies a size that would
cause that access to be out-of-bounds.
This causes the following tests to pass:
glslparsertest/shaders/array10.frag
|
|
This causes the following tests to pass:
glslparsertest/shaders/parser3.frag
glslparsertest/shaders/varying3.frag (also generates spurious error)
|
|
|
|
Test glslparsertest/shaders/array11.frag now passes for the right reason.
|
|
The former gets the type of elements in an array, and the later gets
the declared size, if any, of the array.
|
|
I haven't verified that these are all correct, but it's still a lot
better than not having anything.
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
|
|
ast_function::hir consists of bits pulled out of
ast_function_definition::hir. In fact, the later uses the former to
do a lot of its processing. Several class private data fields were
added to ast_function to facilitate communicate between the two.
This causes the following tests to pass:
glslparsertest/shaders/CorrectModule.frag
This causes the following tests to fail. These shaders were
previously failing to compile, but they were all failing for the wrong
reasons.
glslparsertest/shaders/function9.frag
glslparsertest/shaders/function10.frag
|
|
|
|
Several other code movements were also done. This partitions this
function into two halves. The first half processes the prototype
part, and the second have processes the actual function definition.
The coming patch series will parition ast_function_definition::hir
into (at least) two separate functions.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ir_function_signature now has a pointer back to the ir_function that owns it.
|
|
Generates a symbol table entry and the IR approximation of a prototype for a
type's constructor. Currently only arrays are supported.
|
|
process_call
These will be used in the functions that implement calls to array constructors.
|
|
|
|
This is the first baby step towards getting array constructors working.
|
|
This make is easily accessible from other modules.
|
|
|
|
hash_table_insert needs to keep the key so that it compare keys on a
following hash_table_find call. Since key was allocated on the stack,
it disappeared out from under the hash table.
|
|
|
|
Fixes dataType6.frag, and also array2.frag for an unexpected but valid
reason.
|
|
'in' and 'out' can only be used in function parameter lists or at
global scope (1.30 and later). This change enforces this.
|
|
This goes along with the qualifier-?? tests.
|
|
|
|
|
|
This causes the following tests to pass:
glslparsertest/shaders/uniform.frag
glslparsertest/shaders/varying.frag
|
|
|
|
Fixes parser9.frag.
|
|
Fixes identifier2.frag.
|
|
Fixes fragmentOnly4.vert.
|
|
Fixes main2.vert.
|
|
|
|
Fixes function1.frag.
|
|
|
|
This causes the following tests to pass:
glslparsertest/shaders/array3.frag
|
|
This causes the following tests to pass:
glslparsertest/shaders/array4.frag
glslparsertest/shaders/array5.frag
This causes the following tests to fail. These shaders were
previously failing to compile, but they were all failing for the wrong
reasons.
glslparsertest/shaders/array3.frag
|
|
Since all glsl_type objects are flyweights, support is added to track all
known array types. This accounts for most of the changes.
|
|
|