diff options
Diffstat (limited to 'src/glsl')
51 files changed, 4001 insertions, 3070 deletions
diff --git a/src/glsl/Makefile b/src/glsl/Makefile index 47ac42667c..83869b1d84 100644 --- a/src/glsl/Makefile +++ b/src/glsl/Makefile @@ -76,6 +76,7 @@ CXX_SOURCES = \ loop_controls.cpp \ loop_unroll.cpp \ lower_noise.cpp \ + lower_texture_projection.cpp \ lower_variable_index_to_cond_assign.cpp \ opt_redundant_jumps.cpp \ s_expression.cpp diff --git a/src/glsl/ast.h b/src/glsl/ast.h index 44c31b6e62..e5aa5c1b3b 100644 --- a/src/glsl/ast.h +++ b/src/glsl/ast.h @@ -33,6 +33,20 @@ struct _mesa_glsl_parse_state; struct YYLTYPE; +/** + * \defgroup AST Abstract syntax tree node definitions + * + * An abstract syntax tree is generated by the parser. This is a fairly + * direct representation of the gramma derivation for the source program. + * No symantic checking is done during the generation of the AST. Only + * syntactic checking is done. Symantic checking is performed by a later + * stage that converts the AST to a more generic intermediate representation. + * + *@{ + */ +/** + * Base class of all abstract syntax tree nodes + */ class ast_node { public: /* Callers of this talloc-based new need not call delete. It's @@ -54,7 +68,14 @@ public: talloc_free(table); } + /** + * Print an AST node in something approximating the original GLSL code + */ virtual void print(void) const; + + /** + * Convert the AST node to the high-level intermediate representation + */ virtual ir_rvalue *hir(exec_list *instructions, struct _mesa_glsl_parse_state *state); @@ -91,19 +112,29 @@ public: this->location.column = locp.first_column; } + /** + * Source location of the AST node. + */ struct { - unsigned source; - unsigned line; - unsigned column; + unsigned source; /**< GLSL source number. */ + unsigned line; /**< Line number within the source string. */ + unsigned column; /**< Column in the line. */ } location; exec_node link; protected: + /** + * The only constructor is protected so that only derived class objects can + * be created. + */ ast_node(void); }; +/** + * Operators for AST expression nodes. + */ enum ast_operators { ast_assign, ast_plus, /**< Unary + operator. */ @@ -161,6 +192,9 @@ enum ast_operators { ast_sequence }; +/** + * Representation of any sort of expression. + */ class ast_expression : public ast_node { public: ast_expression(int oper, ast_expression *, @@ -290,23 +324,42 @@ enum { }; struct ast_type_qualifier { - unsigned invariant:1; - unsigned constant:1; - unsigned attribute:1; - unsigned varying:1; - unsigned in:1; - unsigned out:1; - unsigned centroid:1; - unsigned uniform:1; - unsigned smooth:1; - unsigned flat:1; - unsigned noperspective:1; - - /** \name Layout qualifiers for GL_ARB_fragment_coord_conventions */ - /*@{*/ - unsigned origin_upper_left:1; - unsigned pixel_center_integer:1; - /*@}*/ + union { + struct { + unsigned invariant:1; + unsigned constant:1; + unsigned attribute:1; + unsigned varying:1; + unsigned in:1; + unsigned out:1; + unsigned centroid:1; + unsigned uniform:1; + unsigned smooth:1; + unsigned flat:1; + unsigned noperspective:1; + + /** \name Layout qualifiers for GL_ARB_fragment_coord_conventions */ + /*@{*/ + unsigned origin_upper_left:1; + unsigned pixel_center_integer:1; + /*@}*/ + + /** + * Flag set if GL_ARB_explicit_attrib_location "location" layout + * qualifier is used. + */ + unsigned explicit_location:1; + } q; + unsigned i; + } flags; + + /** + * Location specified via GL_ARB_explicit_attrib_location layout + * + * \note + * This field is only valid if \c explicit_location is set. + */ + unsigned location; }; class ast_struct_specifier : public ast_node { @@ -651,7 +704,7 @@ public: ast_function *prototype; ast_compound_statement *body; }; - +/*@}*/ extern void _mesa_ast_to_hir(exec_list *instructions, struct _mesa_glsl_parse_state *state); diff --git a/src/glsl/ast_function.cpp b/src/glsl/ast_function.cpp index 5d9d35b2d9..20448f5a97 100644 --- a/src/glsl/ast_function.cpp +++ b/src/glsl/ast_function.cpp @@ -504,8 +504,9 @@ emit_inline_vector_constructor(const glsl_type *type, instructions->push_tail(inst); } else { unsigned base_component = 0; + unsigned base_lhs_component = 0; ir_constant_data data; - unsigned constant_mask = 0; + unsigned constant_mask = 0, constant_components = 0; memset(&data, 0, sizeof(data)); @@ -515,8 +516,8 @@ emit_inline_vector_constructor(const glsl_type *type, /* Do not try to assign more components to the vector than it has! */ - if ((rhs_components + base_component) > lhs_components) { - rhs_components = lhs_components - base_component; + if ((rhs_components + base_lhs_component) > lhs_components) { + rhs_components = lhs_components - base_lhs_component; } const ir_constant *const c = param->as_constant(); @@ -543,18 +544,23 @@ emit_inline_vector_constructor(const glsl_type *type, /* Mask of fields to be written in the assignment. */ - constant_mask |= ((1U << rhs_components) - 1) << base_component; - } + constant_mask |= ((1U << rhs_components) - 1) << base_lhs_component; + constant_components++; - /* Advance the component index by the number of components that were - * just assigned. + base_component += rhs_components; + } + /* Advance the component index by the number of components + * that were just assigned. */ - base_component += rhs_components; + base_lhs_component += rhs_components; } if (constant_mask != 0) { ir_dereference *lhs = new(ctx) ir_dereference_variable(var); - ir_rvalue *rhs = new(ctx) ir_constant(var->type, &data); + const glsl_type *rhs_type = glsl_type::get_instance(var->type->base_type, + constant_components, + 1); + ir_rvalue *rhs = new(ctx) ir_constant(rhs_type, &data); ir_instruction *inst = new(ctx) ir_assignment(lhs, rhs, NULL, constant_mask); @@ -574,12 +580,10 @@ emit_inline_vector_constructor(const glsl_type *type, const ir_constant *const c = param->as_constant(); if (c == NULL) { - /* Generate a swizzle that puts the first element of the source at - * the location of the first element of the destination. - */ + /* Generate a swizzle in case rhs_components != rhs->type->vector_elements. */ unsigned swiz[4] = { 0, 0, 0, 0 }; for (unsigned i = 0; i < rhs_components; i++) - swiz[i + base_component] = i; + swiz[i] = i; /* Mask of fields to be written in the assignment. */ @@ -587,7 +591,7 @@ emit_inline_vector_constructor(const glsl_type *type, << base_component; ir_dereference *lhs = new(ctx) ir_dereference_variable(var); - ir_rvalue *rhs = new(ctx) ir_swizzle(param, swiz, lhs_components); + ir_rvalue *rhs = new(ctx) ir_swizzle(param, swiz, rhs_components); ir_instruction *inst = new(ctx) ir_assignment(lhs, rhs, NULL, write_mask); @@ -632,10 +636,10 @@ assign_to_matrix_column(ir_variable *var, unsigned column, unsigned row_base, */ unsigned swiz[4] = { src_base, src_base, src_base, src_base }; for (unsigned i = 0; i < count; i++) - swiz[i + row_base] = src_base + i; + swiz[i + row_base] = i; ir_rvalue *const rhs = - new(mem_ctx) ir_swizzle(src, swiz, column_ref->type->components()); + new(mem_ctx) ir_swizzle(src, swiz, count); /* Mask of fields to be written in the assignment. */ @@ -816,7 +820,7 @@ emit_inline_matrix_constructor(const glsl_type *type, var->type->matrix_columns); unsigned swiz[4] = { 0, 0, 0, 0 }; - for (unsigned i = 1; i < src_matrix->type->vector_elements; i++) + for (unsigned i = 1; i < last_row; i++) swiz[i] = i; const unsigned write_mask = (1U << last_row) - 1; @@ -837,14 +841,11 @@ emit_inline_matrix_constructor(const glsl_type *type, */ ir_rvalue *rhs; if (lhs->type->vector_elements != rhs_col->type->vector_elements) { - rhs = new(ctx) ir_swizzle(rhs_col, swiz, - lhs->type->vector_elements); + rhs = new(ctx) ir_swizzle(rhs_col, swiz, last_row); } else { rhs = rhs_col; } - assert(lhs->type == rhs->type); - ir_instruction *inst = new(ctx) ir_assignment(lhs, rhs, NULL, write_mask); instructions->push_tail(inst); diff --git a/src/glsl/ast_to_hir.cpp b/src/glsl/ast_to_hir.cpp index 96385449bd..b37fcbd3bc 100644 --- a/src/glsl/ast_to_hir.cpp +++ b/src/glsl/ast_to_hir.cpp @@ -748,9 +748,64 @@ ast_expression::hir(exec_list *instructions, case ast_lshift: case ast_rshift: - _mesa_glsl_error(& loc, state, "FINISHME: implement bit-shift operators"); - error_emitted = true; - break; + if (state->language_version < 130) { + _mesa_glsl_error(&loc, state, "operator %s requires GLSL 1.30", + operator_string(this->oper)); + error_emitted = true; + break; + } + + /* From page 50 (page 56 of the PDF) of the GLSL 1.30 spec: + * + * The shift operators (<<) and (>>). For both operators, the operands + * must be signed or unsigned integers or integer vectors. One operand + * can be signed while the other is unsigned. In all cases, the + * resulting type will be the same type as the left operand. If the + * first operand is a scalar, the second operand has to be a scalar as + * well. If the first operand is a vector, the second operand must be + * a scalar or a vector, [...] + */ + + op[0] = this->subexpressions[0]->hir(instructions, state); + op[1] = this->subexpressions[1]->hir(instructions, state); + + if (!op[0]->type->is_integer()) { + _mesa_glsl_error(& loc, state, + "LHS of operator %s must be an integer or integer vector", + operator_string(this->oper)); + error_emitted = true; + break; + } + if (!op[1]->type->is_integer()) { + _mesa_glsl_error(& loc, state, + "RHS of operator %s must be an integer or integer vector", + operator_string(this->oper)); + error_emitted = true; + break; + } + if (op[0]->type->is_scalar() && !op[1]->type->is_scalar()) { + _mesa_glsl_error(& loc, state, + "If the first operand of %s is scalar, the second must be" + "scalar as well", operator_string(this->oper)); + error_emitted = true; + break; + } + if (op[0]->type->is_vector() && + op[1]->type->is_vector() && + op[0]->type->components() != op[1]->type->components()) { + + _mesa_glsl_error(& loc, state, + "Vector operands of %s must have same number of components", + operator_string(this->oper)); + error_emitted = true; + break; + } + + type = op[0]->type; + result = new(ctx) ir_expression(operations[this->oper], type, + op[0], op[1]); + error_emitted = op[0]->type->is_error() || op[1]->type->is_error(); + break; case ast_less: case ast_greater: @@ -1534,17 +1589,12 @@ ast_type_specifier::glsl_type(const char **name, { const struct glsl_type *type; - if ((this->type_specifier == ast_struct) && (this->type_name == NULL)) { - /* FINISHME: Handle annonymous structures. */ - type = NULL; - } else { - type = state->symbols->get_type(this->type_name); - *name = this->type_name; + type = state->symbols->get_type(this->type_name); + *name = this->type_name; - if (this->is_array) { - YYLTYPE loc = this->get_location(); - type = process_array_type(&loc, type, this->array_size, state); - } + if (this->is_array) { + YYLTYPE loc = this->get_location(); + type = process_array_type(&loc, type, this->array_size, state); } return type; @@ -1557,18 +1607,19 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, struct _mesa_glsl_parse_state *state, YYLTYPE *loc) { - if (qual->invariant) + if (qual->flags.q.invariant) var->invariant = 1; /* FINISHME: Mark 'in' variables at global scope as read-only. */ - if (qual->constant || qual->attribute || qual->uniform - || (qual->varying && (state->target == fragment_shader))) + if (qual->flags.q.constant || qual->flags.q.attribute + || qual->flags.q.uniform + || (qual->flags.q.varying && (state->target == fragment_shader))) var->read_only = 1; - if (qual->centroid) + if (qual->flags.q.centroid) var->centroid = 1; - if (qual->attribute && state->target != vertex_shader) { + if (qual->flags.q.attribute && state->target != vertex_shader) { var->type = glsl_type::error_type; _mesa_glsl_error(loc, state, "`attribute' variables may not be declared in the " @@ -1582,7 +1633,7 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, * float, vec2, vec3, vec4, mat2, mat3, and mat4, or arrays of * these." */ - if (qual->varying) { + if (qual->flags.q.varying) { const glsl_type *non_array_type; if (var->type && var->type->is_array()) @@ -1600,28 +1651,29 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, /* If there is no qualifier that changes the mode of the variable, leave * the setting alone. */ - if (qual->in && qual->out) + if (qual->flags.q.in && qual->flags.q.out) var->mode = ir_var_inout; - else if (qual->attribute || qual->in - || (qual->varying && (state->target == fragment_shader))) + else if (qual->flags.q.attribute || qual->flags.q.in + || (qual->flags.q.varying && (state->target == fragment_shader))) var->mode = ir_var_in; - else if (qual->out || (qual->varying && (state->target == vertex_shader))) + else if (qual->flags.q.out + || (qual->flags.q.varying && (state->target == vertex_shader))) var->mode = ir_var_out; - else if (qual->uniform) + else if (qual->flags.q.uniform) var->mode = ir_var_uniform; - if (qual->flat) + if (qual->flags.q.flat) var->interpolation = ir_var_flat; - else if (qual->noperspective) + else if (qual->flags.q.noperspective) var->interpolation = ir_var_noperspective; else var->interpolation = ir_var_smooth; - var->pixel_center_integer = qual->pixel_center_integer; - var->origin_upper_left = qual->origin_upper_left; - if ((qual->origin_upper_left || qual->pixel_center_integer) + var->pixel_center_integer = qual->flags.q.pixel_center_integer; + var->origin_upper_left = qual->flags.q.origin_upper_left; + if ((qual->flags.q.origin_upper_left || qual->flags.q.pixel_center_integer) && (strcmp(var->name, "gl_FragCoord") != 0)) { - const char *const qual_string = (qual->origin_upper_left) + const char *const qual_string = (qual->flags.q.origin_upper_left) ? "origin_upper_left" : "pixel_center_integer"; _mesa_glsl_error(loc, state, @@ -1630,6 +1682,65 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, qual_string); } + if (qual->flags.q.explicit_location) { + const bool global_scope = (state->current_function == NULL); + bool fail = false; + const char *string = ""; + + /* In the vertex shader only shader inputs can be given explicit + * locations. + * + * In the fragment shader only shader outputs can be given explicit + * locations. + */ + switch (state->target) { + case vertex_shader: + if (!global_scope || (var->mode != ir_var_in)) { + fail = true; + string = "input"; + } + break; + + case geometry_shader: + _mesa_glsl_error(loc, state, + "geometry shader variables cannot be given " + "explicit locations\n"); + break; + + case fragment_shader: + if (!global_scope || (var->mode != ir_var_in)) { + fail = true; + string = "output"; + } + break; + } + + if (fail) { + _mesa_glsl_error(loc, state, + "only %s shader %s variables can be given an " + "explicit location\n", + _mesa_glsl_shader_target_name(state->target), + string); + } else { + var->explicit_location = true; + + /* This bit of silliness is needed because invalid explicit locations + * are supposed to be flagged during linking. Small negative values + * biased by VERT_ATTRIB_GENERIC0 or FRAG_RESULT_DATA0 could alias + * built-in values (e.g., -16+VERT_ATTRIB_GENERIC0 = VERT_ATTRIB_POS). + * The linker needs to be able to differentiate these cases. This + * ensures that negative values stay negative. + */ + if (qual->location >= 0) { + var->location = (state->target == vertex_shader) + ? (qual->location + VERT_ATTRIB_GENERIC0) + : (qual->location + FRAG_RESULT_DATA0); + } else { + var->location = qual->location; + } + } + } + if (var->type->is_array() && state->language_version != 110) { var->array_lvalue = true; } @@ -1759,13 +1870,13 @@ ast_declarator_list::hir(exec_list *instructions, * This is relaxed in GLSL 1.30. */ if (state->language_version < 120) { - if (this->type->qualifier.out) { + if (this->type->qualifier.flags.q.out) { _mesa_glsl_error(& loc, state, "`out' qualifier in declaration of `%s' " "only valid for function parameters in GLSL 1.10.", decl->identifier); } - if (this->type->qualifier.in) { + if (this->type->qualifier.flags.q.in) { _mesa_glsl_error(& loc, state, "`in' qualifier in declaration of `%s' " "only valid for function parameters in GLSL 1.10.", @@ -1777,7 +1888,7 @@ ast_declarator_list::hir(exec_list *instructions, apply_type_qualifier_to_variable(& this->type->qualifier, var, state, & loc); - if (this->type->qualifier.invariant) { + if (this->type->qualifier.flags.q.invariant) { if ((state->target == vertex_shader) && !(var->mode == ir_var_out || var->mode == ir_var_inout)) { /* FINISHME: Note that this doesn't work for invariant on @@ -1804,16 +1915,16 @@ ast_declarator_list::hir(exec_list *instructions, /* There is no need to check for 'inout' here because the parser will * only allow that in function parameter lists. */ - if (this->type->qualifier.attribute) { + if (this->type->qualifier.flags.q.attribute) { mode = "attribute"; - } else if (this->type->qualifier.uniform) { + } else if (this->type->qualifier.flags.q.uniform) { mode = "uniform"; - } else if (this->type->qualifier.varying) { + } else if (this->type->qualifier.flags.q.varying) { mode = "varying"; - } else if (this->type->qualifier.in) { + } else if (this->type->qualifier.flags.q.in) { mode = "in"; extra = " or in function parameter list"; - } else if (this->type->qualifier.out) { + } else if (this->type->qualifier.flags.q.out) { mode = "out"; extra = " or in function parameter list"; } @@ -1919,7 +2030,8 @@ ast_declarator_list::hir(exec_list *instructions, /* Calculate the constant value if this is a const or uniform * declaration. */ - if (this->type->qualifier.constant || this->type->qualifier.uniform) { + if (this->type->qualifier.flags.q.constant + || this->type->qualifier.flags.q.uniform) { ir_rvalue *new_rhs = validate_assignment(state, var->type, rhs); if (new_rhs != NULL) { rhs = new_rhs; @@ -1929,7 +2041,7 @@ ast_declarator_list::hir(exec_list *instructions, _mesa_glsl_error(& initializer_loc, state, "initializer of %s variable `%s' must be a " "constant expression", - (this->type->qualifier.constant) + (this->type->qualifier.flags.q.constant) ? "const" : "uniform", decl->identifier); if (var->type->is_numeric()) { @@ -1954,12 +2066,12 @@ ast_declarator_list::hir(exec_list *instructions, if (rhs && !rhs->type->is_error()) { bool temp = var->read_only; - if (this->type->qualifier.constant) + if (this->type->qualifier.flags.q.constant) var->read_only = false; /* Never emit code to initialize a uniform. */ - if (!this->type->qualifier.uniform) + if (!this->type->qualifier.flags.q.uniform) result = do_assignment(&initializer_instructions, state, lhs, rhs, this->get_location()); @@ -1973,7 +2085,7 @@ ast_declarator_list::hir(exec_list *instructions, * its declaration, so they must be initialized when * declared." */ - if (this->type->qualifier.constant && decl->initializer == NULL) { + if (this->type->qualifier.flags.q.constant && decl->initializer == NULL) { _mesa_glsl_error(& loc, state, "const declaration of `%s' must be initialized"); } @@ -2705,7 +2817,6 @@ ast_struct_specifier::hir(exec_list *instructions, } } - /* Allocate storage for the structure fields and process the field * declarations. As the declarations are processed, try to also convert * the types to HIR. This ensures that structure definitions embedded in @@ -2750,21 +2861,8 @@ ast_struct_specifier::hir(exec_list *instructions, assert(i == decl_count); - const char *name; - if (this->name == NULL) { - static unsigned anon_count = 1; - char buf[32]; - - snprintf(buf, sizeof(buf), "#anon_struct_%04x", anon_count); - anon_count++; - - name = strdup(buf); - } else { - name = this->name; - } - const glsl_type *t = - glsl_type::get_record_instance(fields, decl_count, name); + glsl_type::get_record_instance(fields, decl_count, this->name); YYLTYPE loc = this->get_location(); if (!state->symbols->add_type(name, t)) { diff --git a/src/glsl/ast_type.cpp b/src/glsl/ast_type.cpp index 9a957044e7..b7488cf6e9 100644 --- a/src/glsl/ast_type.cpp +++ b/src/glsl/ast_type.cpp @@ -114,9 +114,5 @@ ast_type_specifier::ast_type_specifier(int specifier) bool ast_fully_specified_type::has_qualifiers() const { - return qualifier.invariant || qualifier.constant || qualifier.attribute - || qualifier.varying || qualifier.in - || qualifier.out || qualifier.centroid - || qualifier.uniform || qualifier.smooth - || qualifier.flat || qualifier.noperspective; + return this->qualifier.flags.i != 0; } diff --git a/src/glsl/builtin_function.cpp b/src/glsl/builtin_function.cpp index 1e633e3f3a..f65f91f6b7 100644 --- a/src/glsl/builtin_function.cpp +++ b/src/glsl/builtin_function.cpp @@ -30,12 +30,12 @@ #include "ast.h" extern "C" struct gl_shader * -_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type); +_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type); gl_shader * read_builtins(GLenum target, const char *protos, const char **functions, unsigned count) { - GLcontext fakeCtx; + struct gl_context fakeCtx; fakeCtx.API = API_OPENGL; gl_shader *sh = _mesa_new_shader(NULL, 0, target); struct _mesa_glsl_parse_state *st = @@ -787,73 +787,73 @@ static const char *builtin_equal = " (parameters\n" " (declare (in) vec2 arg0)\n" " (declare (in) vec2 arg1))\n" - " ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) vec3 arg0)\n" " (declare (in) vec3 arg1))\n" - " ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) vec4 arg0)\n" " (declare (in) vec4 arg1))\n" - " ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) bvec2 arg0)\n" " (declare (in) bvec2 arg1))\n" - " ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) bvec3 arg0)\n" " (declare (in) bvec3 arg1))\n" - " ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) bvec4 arg0)\n" " (declare (in) bvec4 arg1))\n" - " ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) ivec2 arg0)\n" " (declare (in) ivec2 arg1))\n" - " ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) ivec3 arg0)\n" " (declare (in) ivec3 arg1))\n" - " ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) ivec4 arg0)\n" " (declare (in) ivec4 arg1))\n" - " ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) uvec2 arg0)\n" " (declare (in) uvec2 arg1))\n" - " ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) uvec3 arg0)\n" " (declare (in) uvec3 arg1))\n" - " ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 == (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) uvec4 arg0)\n" " (declare (in) uvec4 arg1))\n" - " ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 == (var_ref arg0) (var_ref arg1)))))\n" "))\n" "" ; @@ -1044,91 +1044,55 @@ static const char *builtin_greaterThan = " (parameters\n" " (declare (in) vec2 arg0)\n" " (declare (in) vec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) vec3 arg0)\n" " (declare (in) vec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) vec4 arg0)\n" " (declare (in) vec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool > (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) ivec2 arg0)\n" " (declare (in) ivec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) ivec3 arg0)\n" " (declare (in) ivec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) ivec4 arg0)\n" " (declare (in) ivec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool > (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) uvec2 arg0)\n" " (declare (in) uvec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) uvec3 arg0)\n" " (declare (in) uvec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 > (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) uvec4 arg0)\n" " (declare (in) uvec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool > (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 > (var_ref arg0) (var_ref arg1)))))\n" "))\n" "" ; @@ -1138,91 +1102,55 @@ static const char *builtin_greaterThanEqual = " (parameters\n" " (declare (in) vec2 arg0)\n" " (declare (in) vec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) vec3 arg0)\n" " (declare (in) vec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) vec4 arg0)\n" " (declare (in) vec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool >= (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) ivec2 arg0)\n" " (declare (in) ivec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) ivec3 arg0)\n" " (declare (in) ivec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) ivec4 arg0)\n" " (declare (in) ivec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool >= (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) uvec2 arg0)\n" " (declare (in) uvec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) uvec3 arg0)\n" " (declare (in) uvec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 >= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) uvec4 arg0)\n" " (declare (in) uvec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool >= (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 >= (var_ref arg0) (var_ref arg1)))))\n" "))\n" "" ; @@ -1280,91 +1208,55 @@ static const char *builtin_lessThan = " (parameters\n" " (declare (in) vec2 arg0)\n" " (declare (in) vec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) vec3 arg0)\n" " (declare (in) vec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) vec4 arg0)\n" " (declare (in) vec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool < (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) ivec2 arg0)\n" " (declare (in) ivec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) ivec3 arg0)\n" " (declare (in) ivec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) ivec4 arg0)\n" " (declare (in) ivec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool < (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) uvec2 arg0)\n" " (declare (in) uvec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) uvec3 arg0)\n" " (declare (in) uvec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 < (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) uvec4 arg0)\n" " (declare (in) uvec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool < (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 < (var_ref arg0) (var_ref arg1)))))\n" "))\n" "" ; @@ -1374,91 +1266,55 @@ static const char *builtin_lessThanEqual = " (parameters\n" " (declare (in) vec2 arg0)\n" " (declare (in) vec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) vec3 arg0)\n" " (declare (in) vec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) vec4 arg0)\n" " (declare (in) vec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool <= (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) ivec2 arg0)\n" " (declare (in) ivec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) ivec3 arg0)\n" " (declare (in) ivec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) ivec4 arg0)\n" " (declare (in) ivec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool <= (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) uvec2 arg0)\n" " (declare (in) uvec2 arg1))\n" - " ((declare () bvec2 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec2 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) uvec3 arg0)\n" " (declare (in) uvec3 arg1))\n" - " ((declare () bvec3 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec3 <= (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) uvec4 arg0)\n" " (declare (in) uvec4 arg1))\n" - " ((declare () bvec4 temp)\n" - " (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1))))\n" - " (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1))))\n" - " (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1))))\n" - " (assign (constant bool (1)) (w) (var_ref temp) (expression bool <= (swiz w (var_ref arg0))(swiz w (var_ref arg1))))\n" - " (return (var_ref temp))))\n" + " ((return (expression bvec4 <= (var_ref arg0) (var_ref arg1)))))\n" "))\n" "" ; @@ -2033,8 +1889,8 @@ static const char *builtin_noise2 = "\n" " (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p)))\n" " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2047,8 +1903,8 @@ static const char *builtin_noise2 = "\n" " (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p)))\n" " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0)))))\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2063,8 +1919,8 @@ static const char *builtin_noise2 = "\n" " (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p)))\n" " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0)))))\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2079,8 +1935,8 @@ static const char *builtin_noise2 = "\n" " (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p)))\n" " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0)))))\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "))\n" @@ -2100,9 +1956,9 @@ static const char *builtin_noise3 = " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" " (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b)))\n" - " (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (constant bool (1)) (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2118,9 +1974,9 @@ static const char *builtin_noise3 = " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0)))))\n" " (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b)))\n" - " (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (constant bool (1)) (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2136,9 +1992,9 @@ static const char *builtin_noise3 = " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0)))))\n" " (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b)))\n" - " (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (constant bool (1)) (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2154,9 +2010,9 @@ static const char *builtin_noise3 = " (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0)))))\n" " (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression float + (var_ref p) (constant float (1559.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a)))\n" - " (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b)))\n" - " (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c)))\n" + " (assign (constant bool (1)) (x) (var_ref t) (var_ref a))\n" + " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (constant bool (1)) (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "))\n" @@ -2181,10 +2037,10 @@ static const char *builtin_noise4 = " (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p)))\n" " (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression vec4 + (var_ref _p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x)))\n" - " (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y)))\n" - " (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z)))\n" - " (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w)))\n" + " (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x))\n" + " (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y))\n" + " (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z))\n" + " (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "\n" @@ -2205,10 +2061,10 @@ static const char *builtin_noise4 = " (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p)))\n" " (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression vec3 + (var_ref _p) (constant vec3 (601.0 313.0 29.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x)))\n" - " (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y)))\n" - " (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z)))\n" - " (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w)))\n" + " (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x))\n" + " (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y))\n" + " (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z))\n" + " (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "\n" @@ -2229,10 +2085,10 @@ static const char *builtin_noise4 = " (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p)))\n" " (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression vec2 + (var_ref _p) (constant vec2 (601.0 313.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x)))\n" - " (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y)))\n" - " (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z)))\n" - " (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w)))\n" + " (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x))\n" + " (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y))\n" + " (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z))\n" + " (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "\n" @@ -2246,17 +2102,17 @@ static const char *builtin_noise4 = " (declare () vec4 _r)\n" "\n" " (declare () float _p)\n" - " (assign (constant bool (1)) (xy) (var_ref _p) (expression float + (var_ref p) (constant float (1559.0))) )\n" + " (assign (constant bool (1)) (x) (var_ref _p) (expression float + (var_ref p) (constant float (1559.0))) )\n" "\n" " (assign (constant bool (1)) (x) (var_ref _x) (expression float noise(var_ref p)))\n" " (assign (constant bool (1)) (x) (var_ref _y) (expression float noise(expression float + (var_ref p) (constant float (601.0 313.0 29.0 277.0)))))\n" " (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p)))\n" " (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression float + (var_ref _p) (constant float (601.0 313.0 29.0 277.0)))))\n" "\n" - " (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x)))\n" - " (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y)))\n" - " (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z)))\n" - " (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w)))\n" + " (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x))\n" + " (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y))\n" + " (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z))\n" + " (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "))\n" @@ -2311,73 +2167,73 @@ static const char *builtin_notEqual = " (parameters\n" " (declare (in) vec2 arg0)\n" " (declare (in) vec2 arg1))\n" - " ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) vec3 arg0)\n" " (declare (in) vec3 arg1))\n" - " ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) vec4 arg0)\n" " (declare (in) vec4 arg1))\n" - " ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) bvec2 arg0)\n" " (declare (in) bvec2 arg1))\n" - " ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) bvec3 arg0)\n" " (declare (in) bvec3 arg1))\n" - " ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) bvec4 arg0)\n" " (declare (in) bvec4 arg1))\n" - " ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) ivec2 arg0)\n" " (declare (in) ivec2 arg1))\n" - " ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) ivec3 arg0)\n" " (declare (in) ivec3 arg1))\n" - " ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) ivec4 arg0)\n" " (declare (in) ivec4 arg1))\n" - " ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec2\n" " (parameters\n" " (declare (in) uvec2 arg0)\n" " (declare (in) uvec2 arg1))\n" - " ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec2 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec3\n" " (parameters\n" " (declare (in) uvec3 arg0)\n" " (declare (in) uvec3 arg1))\n" - " ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec3 != (var_ref arg0) (var_ref arg1)))))\n" "\n" " (signature bvec4\n" " (parameters\n" " (declare (in) uvec4 arg0)\n" " (declare (in) uvec4 arg1))\n" - " ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1)))))\n" + " ((return (expression bvec4 != (var_ref arg0) (var_ref arg1)))))\n" "))\n" "" ; @@ -2694,6 +2550,54 @@ static const char *builtin_refract = "))\n" "" ; +static const char *builtin_round = + "((function round\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float arg0))\n" + " ((return (expression float round_even (var_ref arg0)))))\n" + "\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 arg0))\n" + " ((return (expression vec2 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 arg0))\n" + " ((return (expression vec3 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 arg0))\n" + " ((return (expression vec4 round_even (var_ref arg0)))))\n" + "))\n" + "" +; +static const char *builtin_roundEven = + "((function roundEven\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float arg0))\n" + " ((return (expression float round_even (var_ref arg0)))))\n" + "\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 arg0))\n" + " ((return (expression vec2 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 arg0))\n" + " ((return (expression vec3 round_even (var_ref arg0)))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 arg0))\n" + " ((return (expression vec4 round_even (var_ref arg0)))))\n" + "))\n" + "" +; static const char *builtin_shadow1D = "((function shadow1D\n" " (signature vec4\n" @@ -4843,6 +4747,30 @@ static const char *builtin_transpose = "\n" "" ; +static const char *builtin_trunc = + "((function trunc\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float arg0))\n" + " ((return (expression float trunc (var_ref arg0)))))\n" + "\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 arg0))\n" + " ((return (expression vec2 trunc (var_ref arg0)))))\n" + "\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 arg0))\n" + " ((return (expression vec3 trunc (var_ref arg0)))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 arg0))\n" + " ((return (expression vec4 trunc (var_ref arg0)))))\n" + "))\n" + "" +; static const char *prototypes_for_100_frag = "(\n" "(function radians\n" @@ -13370,6 +13298,57 @@ static const char *prototypes_for_130_frag = " (parameters\n" " (declare (in) vec4 x))\n" " ()))\n" + "(function trunc\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" + "(function round\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" + "(function roundEven\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" "(function ceil\n" " (signature float\n" " (parameters\n" @@ -15979,6 +15958,8 @@ static const char *functions_for_130_frag [] = { builtin_radians, builtin_reflect, builtin_refract, + builtin_round, + builtin_roundEven, builtin_shadow1D, builtin_shadow1DLod, builtin_shadow1DProj, @@ -16017,6 +15998,7 @@ static const char *functions_for_130_frag [] = { builtin_textureProjGrad, builtin_textureProjLod, builtin_transpose, + builtin_trunc, }; static const char *prototypes_for_130_vert = "(\n" @@ -16433,6 +16415,57 @@ static const char *prototypes_for_130_vert = " (parameters\n" " (declare (in) vec4 x))\n" " ()))\n" + "(function trunc\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" + "(function round\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" + "(function roundEven\n" + " (signature float\n" + " (parameters\n" + " (declare (in) float x))\n" + " ())\n" + " (signature vec2\n" + " (parameters\n" + " (declare (in) vec2 x))\n" + " ())\n" + " (signature vec3\n" + " (parameters\n" + " (declare (in) vec3 x))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) vec4 x))\n" + " ()))\n" "(function ceil\n" " (signature float\n" " (parameters\n" @@ -18993,6 +19026,8 @@ static const char *functions_for_130_vert [] = { builtin_radians, builtin_reflect, builtin_refract, + builtin_round, + builtin_roundEven, builtin_shadow1D, builtin_shadow1DLod, builtin_shadow1DProj, @@ -19031,6 +19066,7 @@ static const char *functions_for_130_vert [] = { builtin_textureProjGrad, builtin_textureProjLod, builtin_transpose, + builtin_trunc, }; static const char *prototypes_for_ARB_texture_rectangle_frag = "(\n" diff --git a/src/glsl/builtin_types.h b/src/glsl/builtin_types.h index 6dabbf0d32..7175e08afb 100644 --- a/src/glsl/builtin_types.h +++ b/src/glsl/builtin_types.h @@ -251,6 +251,8 @@ const glsl_type glsl_type::builtin_130_types[] = { }; const glsl_type *const glsl_type::uint_type = & builtin_130_types[0]; +const glsl_type *const glsl_type::uvec2_type = & builtin_130_types[1]; +const glsl_type *const glsl_type::uvec3_type = & builtin_130_types[2]; const glsl_type *const glsl_type::uvec4_type = & builtin_130_types[3]; /*@}*/ diff --git a/src/glsl/builtins/ir/equal b/src/glsl/builtins/ir/equal index f6578dc1e3..a414b3e535 100644 --- a/src/glsl/builtins/ir/equal +++ b/src/glsl/builtins/ir/equal @@ -3,71 +3,71 @@ (parameters (declare (in) vec2 arg0) (declare (in) vec2 arg1)) - ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 == (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) vec3 arg0) (declare (in) vec3 arg1)) - ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 == (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) vec4 arg0) (declare (in) vec4 arg1)) - ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 == (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) bvec2 arg0) (declare (in) bvec2 arg1)) - ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 == (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) bvec3 arg0) (declare (in) bvec3 arg1)) - ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 == (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) bvec4 arg0) (declare (in) bvec4 arg1)) - ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 == (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) ivec2 arg0) (declare (in) ivec2 arg1)) - ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 == (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) ivec3 arg0) (declare (in) ivec3 arg1)) - ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 == (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) ivec4 arg0) (declare (in) ivec4 arg1)) - ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 == (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) uvec2 arg0) (declare (in) uvec2 arg1)) - ((return (expression bvec2 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 == (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) uvec3 arg0) (declare (in) uvec3 arg1)) - ((return (expression bvec3 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 == (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) uvec4 arg0) (declare (in) uvec4 arg1)) - ((return (expression bvec4 all_equal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 == (var_ref arg0) (var_ref arg1))))) )) diff --git a/src/glsl/builtins/ir/greaterThan b/src/glsl/builtins/ir/greaterThan index f5489008ed..18af865288 100644 --- a/src/glsl/builtins/ir/greaterThan +++ b/src/glsl/builtins/ir/greaterThan @@ -3,89 +3,53 @@ (parameters (declare (in) vec2 arg0) (declare (in) vec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 > (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) vec3 arg0) (declare (in) vec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 > (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) vec4 arg0) (declare (in) vec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool > (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 > (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) ivec2 arg0) (declare (in) ivec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 > (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) ivec3 arg0) (declare (in) ivec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 > (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) ivec4 arg0) (declare (in) ivec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool > (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 > (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) uvec2 arg0) (declare (in) uvec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 > (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) uvec3 arg0) (declare (in) uvec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 > (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) uvec4 arg0) (declare (in) uvec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool > (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool > (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool > (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool > (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 > (var_ref arg0) (var_ref arg1))))) )) diff --git a/src/glsl/builtins/ir/greaterThanEqual b/src/glsl/builtins/ir/greaterThanEqual index d00354042a..6d3bc892cb 100644 --- a/src/glsl/builtins/ir/greaterThanEqual +++ b/src/glsl/builtins/ir/greaterThanEqual @@ -3,89 +3,53 @@ (parameters (declare (in) vec2 arg0) (declare (in) vec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 >= (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) vec3 arg0) (declare (in) vec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 >= (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) vec4 arg0) (declare (in) vec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool >= (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 >= (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) ivec2 arg0) (declare (in) ivec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 >= (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) ivec3 arg0) (declare (in) ivec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 >= (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) ivec4 arg0) (declare (in) ivec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool >= (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 >= (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) uvec2 arg0) (declare (in) uvec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 >= (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) uvec3 arg0) (declare (in) uvec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 >= (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) uvec4 arg0) (declare (in) uvec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool >= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool >= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool >= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool >= (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 >= (var_ref arg0) (var_ref arg1))))) )) diff --git a/src/glsl/builtins/ir/lessThan b/src/glsl/builtins/ir/lessThan index e29288a972..8401fe9db6 100644 --- a/src/glsl/builtins/ir/lessThan +++ b/src/glsl/builtins/ir/lessThan @@ -3,89 +3,53 @@ (parameters (declare (in) vec2 arg0) (declare (in) vec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 < (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) vec3 arg0) (declare (in) vec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 < (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) vec4 arg0) (declare (in) vec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool < (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 < (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) ivec2 arg0) (declare (in) ivec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 < (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) ivec3 arg0) (declare (in) ivec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 < (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) ivec4 arg0) (declare (in) ivec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool < (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 < (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) uvec2 arg0) (declare (in) uvec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 < (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) uvec3 arg0) (declare (in) uvec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 < (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) uvec4 arg0) (declare (in) uvec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool < (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool < (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool < (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool < (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 < (var_ref arg0) (var_ref arg1))))) )) diff --git a/src/glsl/builtins/ir/lessThanEqual b/src/glsl/builtins/ir/lessThanEqual index 669f2341d4..c1cdd3fb60 100644 --- a/src/glsl/builtins/ir/lessThanEqual +++ b/src/glsl/builtins/ir/lessThanEqual @@ -3,89 +3,53 @@ (parameters (declare (in) vec2 arg0) (declare (in) vec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 <= (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) vec3 arg0) (declare (in) vec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 <= (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) vec4 arg0) (declare (in) vec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool <= (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 <= (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) ivec2 arg0) (declare (in) ivec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 <= (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) ivec3 arg0) (declare (in) ivec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 <= (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) ivec4 arg0) (declare (in) ivec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool <= (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 <= (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) uvec2 arg0) (declare (in) uvec2 arg1)) - ((declare () bvec2 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec2 <= (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) uvec3 arg0) (declare (in) uvec3 arg1)) - ((declare () bvec3 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec3 <= (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) uvec4 arg0) (declare (in) uvec4 arg1)) - ((declare () bvec4 temp) - (assign (constant bool (1)) (x) (var_ref temp) (expression bool <= (swiz x (var_ref arg0))(swiz x (var_ref arg1)))) - (assign (constant bool (1)) (y) (var_ref temp) (expression bool <= (swiz y (var_ref arg0))(swiz y (var_ref arg1)))) - (assign (constant bool (1)) (z) (var_ref temp) (expression bool <= (swiz z (var_ref arg0))(swiz z (var_ref arg1)))) - (assign (constant bool (1)) (w) (var_ref temp) (expression bool <= (swiz w (var_ref arg0))(swiz w (var_ref arg1)))) - (return (var_ref temp)))) + ((return (expression bvec4 <= (var_ref arg0) (var_ref arg1))))) )) diff --git a/src/glsl/builtins/ir/noise2 b/src/glsl/builtins/ir/noise2 index 008f8b00f1..383fccfadf 100644 --- a/src/glsl/builtins/ir/noise2 +++ b/src/glsl/builtins/ir/noise2 @@ -8,8 +8,8 @@ (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p))) (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) @@ -22,8 +22,8 @@ (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p))) (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) @@ -38,8 +38,8 @@ (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p))) (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) @@ -54,8 +54,8 @@ (assign (constant bool (1)) (x) (var_ref a) (expression float noise (var_ref p))) (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xx (var_ref b))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) )) diff --git a/src/glsl/builtins/ir/noise3 b/src/glsl/builtins/ir/noise3 index f191e145f9..ed7ad5190f 100644 --- a/src/glsl/builtins/ir/noise3 +++ b/src/glsl/builtins/ir/noise3 @@ -11,9 +11,9 @@ (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0))))) (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b))) - (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (constant bool (1)) (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) @@ -29,9 +29,9 @@ (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0))))) (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b))) - (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (constant bool (1)) (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) @@ -47,9 +47,9 @@ (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0))))) (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b))) - (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (constant bool (1)) (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) @@ -65,9 +65,9 @@ (assign (constant bool (1)) (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0))))) (assign (constant bool (1)) (x) (var_ref c) (expression float noise (expression float + (var_ref p) (constant float (1559.0))))) - (assign (constant bool (1)) (x) (var_ref t) (swiz xxx (var_ref a))) - (assign (constant bool (1)) (y) (var_ref t) (swiz xxx (var_ref b))) - (assign (constant bool (1)) (z) (var_ref t) (swiz xxx (var_ref c))) + (assign (constant bool (1)) (x) (var_ref t) (var_ref a)) + (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (constant bool (1)) (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) )) diff --git a/src/glsl/builtins/ir/noise4 b/src/glsl/builtins/ir/noise4 index fb300fd148..77a2529a18 100644 --- a/src/glsl/builtins/ir/noise4 +++ b/src/glsl/builtins/ir/noise4 @@ -16,10 +16,10 @@ (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p))) (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression vec4 + (var_ref _p) (constant vec4 (601.0 313.0 29.0 277.0))))) - (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x))) - (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y))) - (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z))) - (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w))) + (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x)) + (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y)) + (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z)) + (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) @@ -40,10 +40,10 @@ (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p))) (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression vec3 + (var_ref _p) (constant vec3 (601.0 313.0 29.0))))) - (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x))) - (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y))) - (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z))) - (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w))) + (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x)) + (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y)) + (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z)) + (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) @@ -64,10 +64,10 @@ (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p))) (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression vec2 + (var_ref _p) (constant vec2 (601.0 313.0))))) - (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x))) - (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y))) - (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z))) - (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w))) + (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x)) + (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y)) + (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z)) + (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) @@ -81,17 +81,17 @@ (declare () vec4 _r) (declare () float _p) - (assign (constant bool (1)) (xy) (var_ref _p) (expression float + (var_ref p) (constant float (1559.0))) ) + (assign (constant bool (1)) (x) (var_ref _p) (expression float + (var_ref p) (constant float (1559.0))) ) (assign (constant bool (1)) (x) (var_ref _x) (expression float noise(var_ref p))) (assign (constant bool (1)) (x) (var_ref _y) (expression float noise(expression float + (var_ref p) (constant float (601.0 313.0 29.0 277.0))))) (assign (constant bool (1)) (x) (var_ref _z) (expression float noise(var_ref _p))) (assign (constant bool (1)) (x) (var_ref _w) (expression float noise(expression float + (var_ref _p) (constant float (601.0 313.0 29.0 277.0))))) - (assign (constant bool (1)) (x) (var_ref _r) (swiz xxxx (var_ref _x))) - (assign (constant bool (1)) (y) (var_ref _r) (swiz xxxx (var_ref _y))) - (assign (constant bool (1)) (z) (var_ref _r) (swiz xxxx (var_ref _z))) - (assign (constant bool (1)) (w) (var_ref _r) (swiz xxxx (var_ref _w))) + (assign (constant bool (1)) (x) (var_ref _r) (var_ref _x)) + (assign (constant bool (1)) (y) (var_ref _r) (var_ref _y)) + (assign (constant bool (1)) (z) (var_ref _r) (var_ref _z)) + (assign (constant bool (1)) (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) )) diff --git a/src/glsl/builtins/ir/notEqual b/src/glsl/builtins/ir/notEqual index d07cdbf41f..abaf1914c9 100644 --- a/src/glsl/builtins/ir/notEqual +++ b/src/glsl/builtins/ir/notEqual @@ -3,71 +3,71 @@ (parameters (declare (in) vec2 arg0) (declare (in) vec2 arg1)) - ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 != (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) vec3 arg0) (declare (in) vec3 arg1)) - ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 != (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) vec4 arg0) (declare (in) vec4 arg1)) - ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 != (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) bvec2 arg0) (declare (in) bvec2 arg1)) - ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 != (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) bvec3 arg0) (declare (in) bvec3 arg1)) - ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 != (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) bvec4 arg0) (declare (in) bvec4 arg1)) - ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 != (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) ivec2 arg0) (declare (in) ivec2 arg1)) - ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 != (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) ivec3 arg0) (declare (in) ivec3 arg1)) - ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 != (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) ivec4 arg0) (declare (in) ivec4 arg1)) - ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 != (var_ref arg0) (var_ref arg1))))) (signature bvec2 (parameters (declare (in) uvec2 arg0) (declare (in) uvec2 arg1)) - ((return (expression bvec2 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec2 != (var_ref arg0) (var_ref arg1))))) (signature bvec3 (parameters (declare (in) uvec3 arg0) (declare (in) uvec3 arg1)) - ((return (expression bvec3 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec3 != (var_ref arg0) (var_ref arg1))))) (signature bvec4 (parameters (declare (in) uvec4 arg0) (declare (in) uvec4 arg1)) - ((return (expression bvec4 any_nequal (var_ref arg0) (var_ref arg1))))) + ((return (expression bvec4 != (var_ref arg0) (var_ref arg1))))) )) diff --git a/src/glsl/builtins/ir/round b/src/glsl/builtins/ir/round new file mode 100644 index 0000000000..d0d425bd65 --- /dev/null +++ b/src/glsl/builtins/ir/round @@ -0,0 +1,21 @@ +((function round + (signature float + (parameters + (declare (in) float arg0)) + ((return (expression float round_even (var_ref arg0))))) + + (signature vec2 + (parameters + (declare (in) vec2 arg0)) + ((return (expression vec2 round_even (var_ref arg0))))) + + (signature vec3 + (parameters + (declare (in) vec3 arg0)) + ((return (expression vec3 round_even (var_ref arg0))))) + + (signature vec4 + (parameters + (declare (in) vec4 arg0)) + ((return (expression vec4 round_even (var_ref arg0))))) +)) diff --git a/src/glsl/builtins/ir/roundEven b/src/glsl/builtins/ir/roundEven new file mode 100644 index 0000000000..a9c99b6f44 --- /dev/null +++ b/src/glsl/builtins/ir/roundEven @@ -0,0 +1,21 @@ +((function roundEven + (signature float + (parameters + (declare (in) float arg0)) + ((return (expression float round_even (var_ref arg0))))) + + (signature vec2 + (parameters + (declare (in) vec2 arg0)) + ((return (expression vec2 round_even (var_ref arg0))))) + + (signature vec3 + (parameters + (declare (in) vec3 arg0)) + ((return (expression vec3 round_even (var_ref arg0))))) + + (signature vec4 + (parameters + (declare (in) vec4 arg0)) + ((return (expression vec4 round_even (var_ref arg0))))) +)) diff --git a/src/glsl/builtins/ir/trunc b/src/glsl/builtins/ir/trunc new file mode 100644 index 0000000000..d320a2a772 --- /dev/null +++ b/src/glsl/builtins/ir/trunc @@ -0,0 +1,21 @@ +((function trunc + (signature float + (parameters + (declare (in) float arg0)) + ((return (expression float trunc (var_ref arg0))))) + + (signature vec2 + (parameters + (declare (in) vec2 arg0)) + ((return (expression vec2 trunc (var_ref arg0))))) + + (signature vec3 + (parameters + (declare (in) vec3 arg0)) + ((return (expression vec3 trunc (var_ref arg0))))) + + (signature vec4 + (parameters + (declare (in) vec4 arg0)) + ((return (expression vec4 trunc (var_ref arg0))))) +)) diff --git a/src/glsl/builtins/profiles/130.frag b/src/glsl/builtins/profiles/130.frag index aa7a6adb1d..96440703bd 100644 --- a/src/glsl/builtins/profiles/130.frag +++ b/src/glsl/builtins/profiles/130.frag @@ -143,6 +143,21 @@ vec2 floor(vec2 x); vec3 floor(vec3 x); vec4 floor(vec4 x); +float trunc(float x); +vec2 trunc(vec2 x); +vec3 trunc(vec3 x); +vec4 trunc(vec4 x); + +float round(float x); +vec2 round(vec2 x); +vec3 round(vec3 x); +vec4 round(vec4 x); + +float roundEven(float x); +vec2 roundEven(vec2 x); +vec3 roundEven(vec3 x); +vec4 roundEven(vec4 x); + float ceil(float x); vec2 ceil(vec2 x); vec3 ceil(vec3 x); diff --git a/src/glsl/builtins/profiles/130.vert b/src/glsl/builtins/profiles/130.vert index d0152b0374..eb765186fc 100644 --- a/src/glsl/builtins/profiles/130.vert +++ b/src/glsl/builtins/profiles/130.vert @@ -143,6 +143,21 @@ vec2 floor(vec2 x); vec3 floor(vec3 x); vec4 floor(vec4 x); +float trunc(float x); +vec2 trunc(vec2 x); +vec3 trunc(vec3 x); +vec4 trunc(vec4 x); + +float round(float x); +vec2 round(vec2 x); +vec3 round(vec3 x); +vec4 round(vec4 x); + +float roundEven(float x); +vec2 roundEven(vec2 x); +vec3 roundEven(vec3 x); +vec4 roundEven(vec4 x); + float ceil(float x); vec2 ceil(vec2 x); vec3 ceil(vec3 x); diff --git a/src/glsl/builtins/tools/generate_builtins.py b/src/glsl/builtins/tools/generate_builtins.py index 691a318c1c..e8191ee9fd 100755 --- a/src/glsl/builtins/tools/generate_builtins.py +++ b/src/glsl/builtins/tools/generate_builtins.py @@ -123,12 +123,12 @@ if __name__ == "__main__": #include "ast.h" extern "C" struct gl_shader * -_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type); +_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type); gl_shader * read_builtins(GLenum target, const char *protos, const char **functions, unsigned count) { - GLcontext fakeCtx; + struct gl_context fakeCtx; fakeCtx.API = API_OPENGL; gl_shader *sh = _mesa_new_shader(NULL, 0, target); struct _mesa_glsl_parse_state *st = diff --git a/src/glsl/glcpp/glcpp-parse.c b/src/glsl/glcpp/glcpp-parse.c index 1773ca5c13..30b6fd6ef9 100644 --- a/src/glsl/glcpp/glcpp-parse.c +++ b/src/glsl/glcpp/glcpp-parse.c @@ -1,9 +1,10 @@ -/* A Bison parser, made by GNU Bison 2.4.3. */ + +/* A Bison parser, made by GNU Bison 2.4.1. */ /* Skeleton implementation for Bison's Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - 2009, 2010 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -45,7 +46,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.4.3" +#define YYBISON_VERSION "2.4.1" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -219,7 +220,7 @@ add_builtin_define(glcpp_parser_t *parser, const char *name, int value); /* Line 189 of yacc.c */ -#line 223 "glcpp/glcpp-parse.c" +#line 224 "glcpp/glcpp-parse.c" /* Enabling traces. */ #ifndef YYDEBUG @@ -307,7 +308,7 @@ typedef struct YYLTYPE /* Line 264 of yacc.c */ -#line 311 "glcpp/glcpp-parse.c" +#line 312 "glcpp/glcpp-parse.c" #ifdef short # undef short @@ -357,7 +358,7 @@ typedef short int yytype_int16; #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ -# if defined YYENABLE_NLS && YYENABLE_NLS +# if YYENABLE_NLS # if ENABLE_NLS # include <libintl.h> /* INFRINGES ON USER NAME SPACE */ # define YY_(msgid) dgettext ("bison-runtime", msgid) @@ -945,18 +946,9 @@ static const yytype_uint8 yystos[] = /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. However, - YYFAIL appears to be in use. Nevertheless, it is formally deprecated - in Bison 2.4.2's NEWS entry, where a plan to phase it out is - discussed. */ + Once GCC version 2 has supplanted version 1, this can go. */ #define YYFAIL goto yyerrlab -#if defined YYFAIL - /* This is here to suppress warnings from the GCC cpp's - -Wunused-macros. Normally we don't worry about that warning, but - some users do, and we want to make it easy for users to remove - YYFAIL uses, which will produce warnings from Bison 2.5. */ -#endif #define YYRECOVERING() (!!yyerrstatus) @@ -1013,7 +1005,7 @@ while (YYID (0)) we won't break user code: when these are the locations we know. */ #ifndef YY_LOCATION_PRINT -# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL +# if YYLTYPE_IS_TRIVIAL # define YY_LOCATION_PRINT(File, Loc) \ fprintf (File, "%d.%d-%d.%d", \ (Loc).first_line, (Loc).first_column, \ @@ -1555,7 +1547,7 @@ YYLTYPE yylloc; YYLTYPE *yylsp; /* The locations where the error started and ended. */ - YYLTYPE yyerror_range[3]; + YYLTYPE yyerror_range[2]; YYSIZE_T yystacksize; @@ -1602,7 +1594,7 @@ YYLTYPE yylloc; yyvsp = yyvs; yylsp = yyls; -#if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL +#if YYLTYPE_IS_TRIVIAL /* Initialize the default location before parsing starts. */ yylloc.first_line = yylloc.last_line = 1; yylloc.first_column = yylloc.last_column = 1; @@ -1610,7 +1602,7 @@ YYLTYPE yylloc; /* User initialization code. */ -/* Line 1251 of yacc.c */ +/* Line 1242 of yacc.c */ #line 155 "glcpp/glcpp-parse.y" { yylloc.first_line = 1; @@ -1620,8 +1612,8 @@ YYLTYPE yylloc; yylloc.source = 0; } -/* Line 1251 of yacc.c */ -#line 1625 "glcpp/glcpp-parse.c" +/* Line 1242 of yacc.c */ +#line 1617 "glcpp/glcpp-parse.c" yylsp[0] = yylloc; goto yysetstate; @@ -1808,7 +1800,7 @@ yyreduce: { case 4: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 194 "glcpp/glcpp-parse.y" { glcpp_print(parser->output, "\n"); @@ -1817,7 +1809,7 @@ yyreduce: case 5: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 197 "glcpp/glcpp-parse.y" { _glcpp_parser_print_expanded_token_list (parser, (yyvsp[(1) - (1)].token_list)); @@ -1828,7 +1820,7 @@ yyreduce: case 8: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 207 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_push_if (parser, & (yylsp[(1) - (3)]), (yyvsp[(2) - (3)].ival)); @@ -1837,7 +1829,7 @@ yyreduce: case 9: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 210 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_change_if (parser, & (yylsp[(1) - (3)]), "elif", (yyvsp[(2) - (3)].ival)); @@ -1846,7 +1838,7 @@ yyreduce: case 10: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 216 "glcpp/glcpp-parse.y" { _define_object_macro (parser, & (yylsp[(2) - (4)]), (yyvsp[(2) - (4)].str), (yyvsp[(3) - (4)].token_list)); @@ -1855,7 +1847,7 @@ yyreduce: case 11: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 219 "glcpp/glcpp-parse.y" { _define_function_macro (parser, & (yylsp[(2) - (6)]), (yyvsp[(2) - (6)].str), NULL, (yyvsp[(5) - (6)].token_list)); @@ -1864,7 +1856,7 @@ yyreduce: case 12: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 222 "glcpp/glcpp-parse.y" { _define_function_macro (parser, & (yylsp[(2) - (7)]), (yyvsp[(2) - (7)].str), (yyvsp[(4) - (7)].string_list), (yyvsp[(6) - (7)].token_list)); @@ -1873,7 +1865,7 @@ yyreduce: case 13: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 225 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, (yyvsp[(2) - (3)].str)); @@ -1887,7 +1879,7 @@ yyreduce: case 14: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 233 "glcpp/glcpp-parse.y" { /* Be careful to only evaluate the 'if' expression if @@ -1912,7 +1904,7 @@ yyreduce: case 15: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 252 "glcpp/glcpp-parse.y" { /* #if without an expression is only an error if we @@ -1928,7 +1920,7 @@ yyreduce: case 16: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 262 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, (yyvsp[(2) - (4)].str)); @@ -1939,7 +1931,7 @@ yyreduce: case 17: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 267 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, (yyvsp[(2) - (4)].str)); @@ -1950,7 +1942,7 @@ yyreduce: case 18: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 272 "glcpp/glcpp-parse.y" { /* Be careful to only evaluate the 'elif' expression @@ -1975,7 +1967,7 @@ yyreduce: case 19: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 291 "glcpp/glcpp-parse.y" { /* #elif without an expression is an error unless we @@ -1996,7 +1988,7 @@ yyreduce: case 20: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 306 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_change_if (parser, & (yylsp[(1) - (2)]), "else", 1); @@ -2005,7 +1997,7 @@ yyreduce: case 21: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 309 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_pop (parser, & (yylsp[(1) - (2)])); @@ -2014,7 +2006,7 @@ yyreduce: case 22: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 312 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, "__VERSION__"); @@ -2033,7 +2025,7 @@ yyreduce: case 24: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 329 "glcpp/glcpp-parse.y" { if (strlen ((yyvsp[(1) - (1)].str)) >= 3 && strncmp ((yyvsp[(1) - (1)].str), "0x", 2) == 0) { @@ -2048,7 +2040,7 @@ yyreduce: case 25: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 338 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (1)].ival); @@ -2057,7 +2049,7 @@ yyreduce: case 27: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 344 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) || (yyvsp[(3) - (3)].ival); @@ -2066,7 +2058,7 @@ yyreduce: case 28: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 347 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) && (yyvsp[(3) - (3)].ival); @@ -2075,7 +2067,7 @@ yyreduce: case 29: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 350 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) | (yyvsp[(3) - (3)].ival); @@ -2084,7 +2076,7 @@ yyreduce: case 30: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 353 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) ^ (yyvsp[(3) - (3)].ival); @@ -2093,7 +2085,7 @@ yyreduce: case 31: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 356 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) & (yyvsp[(3) - (3)].ival); @@ -2102,7 +2094,7 @@ yyreduce: case 32: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 359 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) != (yyvsp[(3) - (3)].ival); @@ -2111,7 +2103,7 @@ yyreduce: case 33: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 362 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) == (yyvsp[(3) - (3)].ival); @@ -2120,7 +2112,7 @@ yyreduce: case 34: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 365 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) >= (yyvsp[(3) - (3)].ival); @@ -2129,7 +2121,7 @@ yyreduce: case 35: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 368 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) <= (yyvsp[(3) - (3)].ival); @@ -2138,7 +2130,7 @@ yyreduce: case 36: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 371 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) > (yyvsp[(3) - (3)].ival); @@ -2147,7 +2139,7 @@ yyreduce: case 37: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 374 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) < (yyvsp[(3) - (3)].ival); @@ -2156,7 +2148,7 @@ yyreduce: case 38: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 377 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) >> (yyvsp[(3) - (3)].ival); @@ -2165,7 +2157,7 @@ yyreduce: case 39: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 380 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) << (yyvsp[(3) - (3)].ival); @@ -2174,7 +2166,7 @@ yyreduce: case 40: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 383 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) - (yyvsp[(3) - (3)].ival); @@ -2183,7 +2175,7 @@ yyreduce: case 41: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 386 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) + (yyvsp[(3) - (3)].ival); @@ -2192,7 +2184,7 @@ yyreduce: case 42: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 389 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) % (yyvsp[(3) - (3)].ival); @@ -2201,7 +2193,7 @@ yyreduce: case 43: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 392 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) / (yyvsp[(3) - (3)].ival); @@ -2210,7 +2202,7 @@ yyreduce: case 44: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 395 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) * (yyvsp[(3) - (3)].ival); @@ -2219,7 +2211,7 @@ yyreduce: case 45: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 398 "glcpp/glcpp-parse.y" { (yyval.ival) = ! (yyvsp[(2) - (2)].ival); @@ -2228,7 +2220,7 @@ yyreduce: case 46: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 401 "glcpp/glcpp-parse.y" { (yyval.ival) = ~ (yyvsp[(2) - (2)].ival); @@ -2237,7 +2229,7 @@ yyreduce: case 47: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 404 "glcpp/glcpp-parse.y" { (yyval.ival) = - (yyvsp[(2) - (2)].ival); @@ -2246,7 +2238,7 @@ yyreduce: case 48: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 407 "glcpp/glcpp-parse.y" { (yyval.ival) = + (yyvsp[(2) - (2)].ival); @@ -2255,7 +2247,7 @@ yyreduce: case 49: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 410 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(2) - (3)].ival); @@ -2264,7 +2256,7 @@ yyreduce: case 50: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 416 "glcpp/glcpp-parse.y" { (yyval.string_list) = _string_list_create (parser); @@ -2275,7 +2267,7 @@ yyreduce: case 51: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 421 "glcpp/glcpp-parse.y" { (yyval.string_list) = (yyvsp[(1) - (3)].string_list); @@ -2286,14 +2278,14 @@ yyreduce: case 52: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 429 "glcpp/glcpp-parse.y" { (yyval.token_list) = NULL; ;} break; case 54: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 434 "glcpp/glcpp-parse.y" { yyerror (& (yylsp[(1) - (2)]), parser, "Invalid tokens after #"); @@ -2302,14 +2294,14 @@ yyreduce: case 55: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 440 "glcpp/glcpp-parse.y" { (yyval.token_list) = NULL; ;} break; case 58: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 446 "glcpp/glcpp-parse.y" { glcpp_warning(&(yylsp[(1) - (1)]), parser, "extra tokens at end of directive"); @@ -2318,7 +2310,7 @@ yyreduce: case 59: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 453 "glcpp/glcpp-parse.y" { int v = hash_table_find (parser->defines, (yyvsp[(2) - (2)].str)) ? 1 : 0; @@ -2328,7 +2320,7 @@ yyreduce: case 60: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 457 "glcpp/glcpp-parse.y" { int v = hash_table_find (parser->defines, (yyvsp[(3) - (4)].str)) ? 1 : 0; @@ -2338,7 +2330,7 @@ yyreduce: case 62: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 466 "glcpp/glcpp-parse.y" { parser->space_tokens = 1; @@ -2350,7 +2342,7 @@ yyreduce: case 63: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 472 "glcpp/glcpp-parse.y" { (yyval.token_list) = (yyvsp[(1) - (2)].token_list); @@ -2361,7 +2353,7 @@ yyreduce: case 64: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 480 "glcpp/glcpp-parse.y" { parser->space_tokens = 1; @@ -2373,7 +2365,7 @@ yyreduce: case 65: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 486 "glcpp/glcpp-parse.y" { (yyval.token_list) = (yyvsp[(1) - (2)].token_list); @@ -2384,7 +2376,7 @@ yyreduce: case 66: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 494 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_str (parser, IDENTIFIER, (yyvsp[(1) - (1)].str)); @@ -2394,7 +2386,7 @@ yyreduce: case 67: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 498 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_str (parser, INTEGER_STRING, (yyvsp[(1) - (1)].str)); @@ -2404,7 +2396,7 @@ yyreduce: case 68: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 502 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_ival (parser, (yyvsp[(1) - (1)].ival), (yyvsp[(1) - (1)].ival)); @@ -2414,7 +2406,7 @@ yyreduce: case 69: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 506 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_str (parser, OTHER, (yyvsp[(1) - (1)].str)); @@ -2424,7 +2416,7 @@ yyreduce: case 70: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 510 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_ival (parser, SPACE, SPACE); @@ -2434,225 +2426,225 @@ yyreduce: case 71: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 517 "glcpp/glcpp-parse.y" { (yyval.ival) = '['; ;} break; case 72: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 518 "glcpp/glcpp-parse.y" { (yyval.ival) = ']'; ;} break; case 73: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 519 "glcpp/glcpp-parse.y" { (yyval.ival) = '('; ;} break; case 74: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 520 "glcpp/glcpp-parse.y" { (yyval.ival) = ')'; ;} break; case 75: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 521 "glcpp/glcpp-parse.y" { (yyval.ival) = '{'; ;} break; case 76: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 522 "glcpp/glcpp-parse.y" { (yyval.ival) = '}'; ;} break; case 77: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 523 "glcpp/glcpp-parse.y" { (yyval.ival) = '.'; ;} break; case 78: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 524 "glcpp/glcpp-parse.y" { (yyval.ival) = '&'; ;} break; case 79: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 525 "glcpp/glcpp-parse.y" { (yyval.ival) = '*'; ;} break; case 80: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 526 "glcpp/glcpp-parse.y" { (yyval.ival) = '+'; ;} break; case 81: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 527 "glcpp/glcpp-parse.y" { (yyval.ival) = '-'; ;} break; case 82: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 528 "glcpp/glcpp-parse.y" { (yyval.ival) = '~'; ;} break; case 83: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 529 "glcpp/glcpp-parse.y" { (yyval.ival) = '!'; ;} break; case 84: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 530 "glcpp/glcpp-parse.y" { (yyval.ival) = '/'; ;} break; case 85: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 531 "glcpp/glcpp-parse.y" { (yyval.ival) = '%'; ;} break; case 86: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 532 "glcpp/glcpp-parse.y" { (yyval.ival) = LEFT_SHIFT; ;} break; case 87: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 533 "glcpp/glcpp-parse.y" { (yyval.ival) = RIGHT_SHIFT; ;} break; case 88: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 534 "glcpp/glcpp-parse.y" { (yyval.ival) = '<'; ;} break; case 89: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 535 "glcpp/glcpp-parse.y" { (yyval.ival) = '>'; ;} break; case 90: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 536 "glcpp/glcpp-parse.y" { (yyval.ival) = LESS_OR_EQUAL; ;} break; case 91: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 537 "glcpp/glcpp-parse.y" { (yyval.ival) = GREATER_OR_EQUAL; ;} break; case 92: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 538 "glcpp/glcpp-parse.y" { (yyval.ival) = EQUAL; ;} break; case 93: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 539 "glcpp/glcpp-parse.y" { (yyval.ival) = NOT_EQUAL; ;} break; case 94: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 540 "glcpp/glcpp-parse.y" { (yyval.ival) = '^'; ;} break; case 95: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 541 "glcpp/glcpp-parse.y" { (yyval.ival) = '|'; ;} break; case 96: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 542 "glcpp/glcpp-parse.y" { (yyval.ival) = AND; ;} break; case 97: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 543 "glcpp/glcpp-parse.y" { (yyval.ival) = OR; ;} break; case 98: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 544 "glcpp/glcpp-parse.y" { (yyval.ival) = ';'; ;} break; case 99: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 545 "glcpp/glcpp-parse.y" { (yyval.ival) = ','; ;} break; case 100: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 546 "glcpp/glcpp-parse.y" { (yyval.ival) = '='; ;} break; case 101: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 547 "glcpp/glcpp-parse.y" { (yyval.ival) = PASTE; ;} break; -/* Line 1464 of yacc.c */ -#line 2656 "glcpp/glcpp-parse.c" +/* Line 1455 of yacc.c */ +#line 2648 "glcpp/glcpp-parse.c" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -2724,7 +2716,7 @@ yyerrlab: #endif } - yyerror_range[1] = yylloc; + yyerror_range[0] = yylloc; if (yyerrstatus == 3) { @@ -2761,7 +2753,7 @@ yyerrorlab: if (/*CONSTCOND*/ 0) goto yyerrorlab; - yyerror_range[1] = yylsp[1-yylen]; + yyerror_range[0] = yylsp[1-yylen]; /* Do not reclaim the symbols of the rule which action triggered this YYERROR. */ YYPOPSTACK (yylen); @@ -2795,7 +2787,7 @@ yyerrlab1: if (yyssp == yyss) YYABORT; - yyerror_range[1] = *yylsp; + yyerror_range[0] = *yylsp; yydestruct ("Error: popping", yystos[yystate], yyvsp, yylsp, parser); YYPOPSTACK (1); @@ -2805,10 +2797,10 @@ yyerrlab1: *++yyvsp = yylval; - yyerror_range[2] = yylloc; + yyerror_range[1] = yylloc; /* Using YYLLOC is tempting, but would change the location of the lookahead. YYLOC is available though. */ - YYLLOC_DEFAULT (yyloc, yyerror_range, 2); + YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2); *++yylsp = yyloc; /* Shift the error token. */ @@ -2870,7 +2862,7 @@ yyreturn: -/* Line 1684 of yacc.c */ +/* Line 1675 of yacc.c */ #line 550 "glcpp/glcpp-parse.y" @@ -3419,6 +3411,9 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) if (extensions->ARB_fragment_coord_conventions) add_builtin_define(parser, "GL_ARB_fragment_coord_conventions", 1); + + if (extensions->ARB_explicit_attrib_location) + add_builtin_define(parser, "GL_ARB_explicit_attrib_location", 1); } language_version = 110; diff --git a/src/glsl/glcpp/glcpp-parse.h b/src/glsl/glcpp/glcpp-parse.h index 40556854f3..50758930e9 100644 --- a/src/glsl/glcpp/glcpp-parse.h +++ b/src/glsl/glcpp/glcpp-parse.h @@ -1,9 +1,10 @@ -/* A Bison parser, made by GNU Bison 2.4.3. */ + +/* A Bison parser, made by GNU Bison 2.4.1. */ /* Skeleton interface for Bison's Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - 2009, 2010 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by diff --git a/src/glsl/glcpp/glcpp-parse.y b/src/glsl/glcpp/glcpp-parse.y index 43513ebb66..b31a18f87d 100644 --- a/src/glsl/glcpp/glcpp-parse.y +++ b/src/glsl/glcpp/glcpp-parse.y @@ -1094,6 +1094,9 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) if (extensions->ARB_fragment_coord_conventions) add_builtin_define(parser, "GL_ARB_fragment_coord_conventions", 1); + + if (extensions->ARB_explicit_attrib_location) + add_builtin_define(parser, "GL_ARB_explicit_attrib_location", 1); } language_version = 110; diff --git a/src/glsl/glcpp/glcpp.c b/src/glsl/glcpp/glcpp.c index 8d1ced571b..062eb6b72d 100644 --- a/src/glsl/glcpp/glcpp.c +++ b/src/glsl/glcpp/glcpp.c @@ -29,9 +29,17 @@ #include <errno.h> #include "glcpp.h" #include "main/mtypes.h" +#include "main/shaderobj.h" extern int yydebug; +void +_mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr, + struct gl_shader *sh) +{ + *ptr = sh; +} + /* Read from fd until EOF and return a string of everything read. */ static char * diff --git a/src/glsl/glsl_lexer.cpp b/src/glsl/glsl_lexer.cpp index 7661bbe982..984f6877e6 100644 --- a/src/glsl/glsl_lexer.cpp +++ b/src/glsl/glsl_lexer.cpp @@ -54,7 +54,6 @@ typedef int flex_int32_t; typedef unsigned char flex_uint8_t; typedef unsigned short int flex_uint16_t; typedef unsigned int flex_uint32_t; -#endif /* ! C99 */ /* Limits of integral types. */ #ifndef INT8_MIN @@ -85,6 +84,8 @@ typedef unsigned int flex_uint32_t; #define UINT32_MAX (4294967295U) #endif +#endif /* ! C99 */ + #endif /* ! FLEXINT_H */ #ifdef __cplusplus @@ -158,7 +159,15 @@ typedef void* yyscan_t; /* Size of default input buffer. */ #ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else #define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ #endif /* The state buf must be large enough to hold one state per character in the main buffer. @@ -349,8 +358,8 @@ static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner ); *yy_cp = '\0'; \ yyg->yy_c_buf_p = yy_cp; -#define YY_NUM_RULES 183 -#define YY_END_OF_BUFFER 184 +#define YY_NUM_RULES 189 +#define YY_END_OF_BUFFER 190 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -358,86 +367,87 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[708] = +static yyconst flex_int16_t yy_accept[716] = { 0, - 0, 0, 15, 15, 0, 0, 184, 182, 1, 20, - 182, 182, 182, 182, 182, 182, 182, 182, 96, 94, - 182, 182, 182, 181, 182, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 182, 1, 182, 91, 183, - 15, 19, 183, 18, 16, 17, 13, 12, 1, 80, - 87, 81, 90, 84, 75, 86, 76, 93, 98, 85, - 99, 96, 0, 0, 101, 0, 94, 0, 77, 79, - 78, 0, 181, 83, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 28, 181, 181, 181, - - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 32, 181, 181, 56, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 92, 82, 1, 0, 0, - 2, 0, 0, 0, 0, 15, 14, 18, 17, 0, - 98, 97, 0, 99, 0, 100, 95, 88, 89, 181, - 104, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 31, 181, 181, 181, 181, 181, 181, 181, - - 181, 181, 181, 25, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 57, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 0, 0, 0, 0, 14, 0, 98, 0, - 97, 0, 99, 100, 181, 181, 23, 181, 181, 144, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 30, - 107, 181, 181, 181, 181, 63, 181, 181, 112, 126, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 123, 147, 44, 45, 46, 181, 181, 181, 181, - - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 110, 102, 181, 181, - 181, 181, 181, 181, 181, 41, 42, 43, 73, 181, - 181, 0, 0, 0, 0, 0, 97, 181, 181, 26, - 35, 36, 37, 181, 105, 181, 22, 181, 181, 181, - 181, 134, 135, 136, 181, 103, 181, 127, 24, 137, - 138, 139, 149, 131, 132, 133, 181, 181, 181, 58, - 129, 181, 181, 38, 39, 40, 181, 181, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 181, 124, 181, 181, 181, 181, 181, 181, 181, - - 181, 181, 181, 106, 181, 146, 181, 181, 29, 0, - 0, 0, 0, 153, 181, 181, 151, 181, 181, 181, - 125, 120, 156, 181, 181, 181, 181, 181, 181, 115, - 181, 181, 74, 47, 48, 49, 50, 51, 52, 53, - 54, 55, 181, 181, 181, 181, 130, 111, 181, 181, - 118, 34, 181, 181, 143, 64, 119, 72, 154, 113, - 181, 181, 181, 181, 181, 181, 181, 0, 0, 0, - 0, 181, 181, 181, 114, 33, 181, 181, 181, 181, - 181, 181, 157, 158, 159, 181, 181, 181, 181, 148, - 181, 181, 181, 181, 181, 181, 181, 181, 108, 181, - - 181, 181, 181, 181, 59, 181, 60, 181, 0, 0, - 0, 0, 0, 181, 61, 27, 121, 161, 162, 163, - 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 116, 181, 181, 181, 181, 181, 181, 181, 181, - 181, 109, 165, 166, 167, 181, 181, 128, 117, 0, - 0, 6, 0, 0, 0, 11, 3, 21, 181, 181, - 181, 181, 181, 181, 181, 181, 181, 160, 122, 62, - 145, 181, 152, 150, 180, 66, 67, 68, 181, 181, - 181, 181, 181, 181, 0, 0, 0, 0, 0, 0, - 181, 181, 181, 164, 181, 181, 181, 181, 181, 181, - - 181, 181, 181, 181, 181, 181, 181, 181, 181, 168, - 4, 0, 5, 0, 0, 0, 0, 0, 181, 181, - 181, 181, 181, 181, 181, 177, 181, 181, 181, 181, - 181, 181, 69, 181, 181, 181, 0, 0, 0, 181, - 181, 178, 169, 181, 170, 181, 181, 181, 181, 181, - 181, 181, 181, 181, 179, 0, 0, 171, 172, 175, - 176, 65, 181, 140, 181, 141, 155, 173, 174, 0, - 0, 181, 181, 181, 0, 0, 0, 70, 181, 71, - 0, 0, 0, 181, 0, 0, 0, 181, 0, 0, - 7, 0, 0, 181, 0, 8, 0, 0, 142, 0, - - 0, 0, 0, 9, 0, 10, 0 + 0, 0, 15, 15, 0, 0, 190, 188, 1, 20, + 188, 188, 188, 188, 188, 188, 188, 188, 102, 100, + 188, 188, 188, 187, 188, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 188, 1, 188, 97, 189, + 15, 19, 189, 18, 16, 17, 13, 12, 1, 84, + 93, 85, 96, 90, 79, 92, 80, 99, 104, 91, + 105, 102, 0, 0, 107, 0, 100, 88, 81, 83, + 82, 89, 187, 87, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 29, 187, 187, 187, + + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 33, 187, 187, 60, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 98, 86, 1, 0, + 0, 2, 0, 0, 0, 0, 15, 14, 18, 17, + 0, 104, 103, 0, 105, 0, 106, 101, 94, 95, + 187, 110, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 32, 187, 187, 187, 187, 187, 187, + + 187, 187, 187, 187, 25, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 61, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 0, 0, 0, 0, 14, + 0, 104, 0, 103, 0, 105, 106, 187, 187, 23, + 187, 187, 150, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 31, 113, 187, 187, 187, 187, 67, 187, + 187, 118, 132, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 129, 153, 48, 49, 50, 187, + + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 116, + 108, 187, 187, 26, 187, 187, 187, 187, 187, 187, + 45, 46, 47, 77, 187, 187, 0, 0, 0, 0, + 0, 103, 187, 187, 27, 36, 37, 38, 187, 111, + 187, 22, 187, 187, 187, 187, 140, 141, 142, 187, + 109, 187, 133, 24, 143, 144, 145, 155, 137, 138, + 139, 187, 187, 187, 62, 135, 187, 187, 39, 40, + 41, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 130, 187, 187, + + 187, 187, 187, 187, 187, 187, 187, 187, 112, 187, + 152, 42, 43, 44, 187, 187, 30, 0, 0, 0, + 0, 159, 187, 187, 157, 187, 187, 187, 131, 126, + 162, 187, 187, 187, 187, 187, 187, 121, 187, 187, + 78, 51, 52, 53, 54, 55, 56, 57, 58, 59, + 187, 187, 187, 187, 136, 117, 187, 187, 124, 35, + 187, 187, 149, 68, 125, 76, 160, 119, 187, 187, + 187, 187, 187, 187, 187, 0, 0, 0, 0, 187, + 187, 187, 120, 34, 187, 187, 187, 187, 187, 187, + 163, 164, 165, 187, 187, 187, 187, 154, 187, 187, + + 187, 187, 187, 187, 187, 187, 114, 187, 187, 187, + 187, 187, 63, 187, 64, 187, 0, 0, 0, 0, + 0, 187, 65, 28, 127, 167, 168, 169, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 122, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 115, + 171, 172, 173, 187, 187, 134, 123, 0, 0, 6, + 0, 0, 0, 11, 3, 21, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 166, 128, 66, 151, 187, + 158, 156, 186, 70, 71, 72, 187, 187, 187, 187, + 187, 187, 0, 0, 0, 0, 0, 0, 187, 187, + + 187, 170, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 174, 4, 0, + 5, 0, 0, 0, 0, 0, 187, 187, 187, 187, + 187, 187, 187, 183, 187, 187, 187, 187, 187, 187, + 73, 187, 187, 187, 0, 0, 0, 187, 187, 184, + 175, 187, 176, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 185, 0, 0, 177, 178, 181, 182, 69, + 187, 146, 187, 147, 161, 179, 180, 0, 0, 187, + 187, 187, 0, 0, 0, 74, 187, 75, 0, 0, + 0, 187, 0, 0, 0, 187, 0, 0, 7, 0, + + 0, 187, 0, 8, 0, 0, 148, 0, 0, 0, + 0, 9, 0, 10, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -483,173 +493,175 @@ static yyconst flex_int32_t yy_meta[65] = 8, 7, 7, 1 } ; -static yyconst flex_int16_t yy_base[719] = +static yyconst flex_int16_t yy_base[727] = { 0, - 0, 63, 88, 0, 1076, 1075, 1077, 1080, 64, 1080, - 1051, 1050, 59, 1049, 58, 60, 58, 1048, 139, 187, - 47, 1047, 56, 0, 1034, 121, 110, 137, 138, 134, - 163, 1017, 173, 177, 115, 149, 140, 1011, 159, 121, - 187, 194, 194, 172, 1022, 171, 249, 240, 1042, 1080, - 250, 1080, 1051, 241, 1080, 0, 1080, 1080, 262, 1080, - 1080, 1080, 1080, 1080, 1080, 1080, 1080, 1080, 236, 1080, - 238, 187, 286, 303, 1080, 0, 0, 1040, 1080, 1080, - 1080, 1039, 0, 1080, 1006, 1011, 1004, 1007, 1016, 1015, - 1001, 1004, 1016, 35, 1010, 997, 994, 1008, 994, 991, - - 991, 997, 215, 232, 991, 1002, 987, 993, 997, 998, - 0, 989, 1000, 234, 995, 975, 226, 979, 993, 983, - 119, 976, 234, 989, 991, 973, 969, 977, 974, 963, - 972, 256, 970, 976, 971, 974, 962, 965, 967, 245, - 970, 961, 974, 227, 967, 1080, 1080, 308, 294, 324, - 1080, 952, 965, 956, 967, 329, 0, 338, 0, 368, - 1080, 303, 379, 1080, 386, 393, 0, 1080, 1080, 962, - 0, 953, 957, 967, 964, 947, 946, 946, 950, 216, - 961, 958, 958, 956, 953, 944, 951, 937, 935, 948, - 933, 950, 0, 947, 934, 942, 939, 943, 944, 937, - - 934, 922, 921, 935, 938, 935, 922, 929, 919, 320, - 925, 928, 918, 926, 914, 918, 909, 924, 914, 905, - 924, 907, 905, 916, 905, 900, 898, 912, 897, 899, - 896, 908, 907, 910, 288, 901, 895, 884, 331, 903, - 905, 893, 885, 889, 901, 884, 0, 400, 410, 427, - 1080, 439, 446, 1080, 879, 890, 0, 887, 343, 0, - 880, 878, 880, 875, 884, 872, 890, 878, 346, 0, - 0, 872, 883, 882, 882, 0, 866, 350, 0, 0, - 868, 353, 876, 877, 867, 861, 860, 861, 860, 357, - 856, 0, 0, 852, 851, 850, 852, 853, 858, 852, - - 848, 862, 857, 856, 855, 846, 849, 849, 841, 844, - 839, 848, 853, 838, 851, 841, 0, 0, 848, 844, - 835, 835, 841, 840, 837, 0, 0, 0, 0, 826, - 839, 838, 837, 834, 822, 453, 463, 834, 836, 0, - 0, 0, 0, 822, 0, 822, 0, 821, 822, 816, - 827, 0, 0, 0, 817, 0, 813, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 824, 469, 823, 0, - 0, 821, 817, 0, 0, 0, 806, 415, 432, 473, - 811, 807, 813, 803, 801, 815, 799, 799, 813, 801, - 813, 808, 0, 806, 803, 807, 790, 792, 799, 805, - - 800, 799, 786, 0, 788, 0, 787, 791, 0, 785, - 834, 784, 787, 0, 775, 785, 0, 773, 773, 787, - 0, 789, 0, 482, 797, 796, 795, 766, 765, 0, - 783, 782, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 766, 780, 766, 763, 0, 0, 769, 768, - 0, 0, 766, 758, 0, 0, 0, 0, 0, 0, - 755, 767, 485, 759, 766, 763, 757, 750, 503, 766, - 751, 746, 760, 758, 0, 0, 750, 769, 768, 767, - 738, 737, 301, 481, 0, 750, 753, 751, 739, 0, - 749, 746, 745, 734, 733, 732, 509, 741, 0, 753, - - 752, 751, 722, 721, 0, 736, 0, 734, 729, 515, - 527, 773, 722, 730, 0, 0, 0, 745, 744, 0, - 726, 729, 713, 721, 711, 719, 720, 720, 719, 704, - 717, 0, 718, 706, 705, 701, 725, 724, 723, 694, - 693, 0, 723, 722, 0, 704, 707, 0, 0, 693, - 537, 1080, 561, 0, 567, 340, 1080, 0, 690, 689, - 699, 699, 686, 701, 684, 699, 694, 0, 0, 0, - 0, 679, 0, 0, 0, 700, 389, 700, 689, 692, - 676, 675, 685, 685, 675, 529, 589, 474, 683, 671, - 669, 668, 679, 0, 682, 678, 680, 676, 662, 669, - - 669, 671, 667, 669, 667, 667, 654, 653, 664, 0, - 1080, 531, 1080, 596, 0, 616, 666, 648, 665, 664, - 647, 635, 643, 633, 634, 0, 627, 646, 635, 607, - 604, 601, 0, 604, 603, 586, 533, 572, 580, 564, - 563, 0, 0, 564, 0, 540, 554, 552, 516, 530, - 505, 486, 453, 450, 0, 461, 443, 0, 0, 0, - 0, 0, 400, 406, 385, 0, 0, 0, 0, 343, - 389, 319, 267, 249, 487, 341, 235, 0, 200, 0, - 507, 498, 184, 157, 150, 564, 559, 136, 565, 591, - 1080, 593, 550, 112, 594, 1080, 569, 576, 0, 123, - - 619, 621, 637, 1080, 638, 1080, 1080, 648, 653, 658, - 663, 665, 667, 673, 680, 685, 690, 695 + 0, 63, 88, 0, 1084, 1083, 1085, 1088, 64, 1088, + 1059, 1058, 59, 1057, 58, 60, 58, 1056, 139, 187, + 47, 1055, 56, 0, 1042, 121, 110, 137, 138, 134, + 163, 1025, 173, 177, 115, 149, 140, 1019, 159, 121, + 187, 194, 194, 172, 1030, 171, 253, 240, 1050, 1088, + 250, 1088, 1059, 244, 1088, 0, 1088, 1088, 265, 1088, + 1088, 1088, 1088, 1088, 1088, 1088, 1088, 1088, 241, 1088, + 243, 187, 286, 303, 1088, 0, 0, 1048, 1088, 1088, + 1088, 1047, 0, 1088, 1014, 1019, 1012, 1015, 1024, 1023, + 1009, 1012, 1024, 35, 1018, 1005, 1002, 1016, 1002, 999, + + 999, 1005, 218, 238, 999, 1010, 995, 1001, 1005, 1006, + 0, 997, 1008, 239, 1003, 983, 218, 987, 1001, 991, + 119, 984, 240, 997, 999, 981, 977, 985, 982, 971, + 980, 258, 978, 984, 979, 982, 970, 973, 258, 224, + 979, 982, 969, 982, 264, 975, 1088, 1088, 329, 324, + 334, 1088, 960, 973, 964, 975, 330, 0, 322, 0, + 333, 1088, 316, 378, 1088, 385, 392, 0, 1088, 1088, + 970, 0, 961, 965, 975, 972, 955, 954, 954, 958, + 300, 969, 966, 966, 964, 961, 952, 959, 945, 943, + 956, 941, 958, 0, 955, 942, 950, 947, 951, 952, + + 945, 942, 930, 929, 943, 946, 943, 930, 937, 927, + 343, 933, 936, 926, 934, 922, 926, 917, 932, 922, + 913, 932, 915, 913, 924, 913, 908, 906, 920, 905, + 907, 904, 916, 915, 918, 899, 320, 908, 902, 912, + 890, 350, 909, 911, 899, 891, 895, 907, 890, 0, + 399, 409, 426, 1088, 438, 445, 1088, 885, 896, 0, + 893, 361, 0, 886, 884, 886, 881, 890, 878, 896, + 884, 367, 0, 0, 878, 889, 888, 888, 0, 872, + 414, 0, 0, 874, 431, 882, 883, 873, 867, 866, + 867, 866, 450, 862, 0, 0, 858, 857, 856, 858, + + 859, 864, 858, 854, 868, 863, 862, 861, 852, 855, + 855, 847, 850, 845, 854, 859, 844, 857, 847, 0, + 0, 854, 850, 0, 841, 841, 847, 846, 453, 843, + 0, 0, 0, 0, 832, 845, 844, 843, 840, 828, + 462, 474, 840, 842, 0, 0, 0, 0, 828, 0, + 828, 0, 827, 828, 822, 833, 0, 0, 0, 823, + 0, 819, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 830, 457, 829, 0, 0, 827, 823, 0, 0, + 0, 812, 479, 482, 485, 817, 813, 819, 809, 807, + 821, 805, 805, 819, 807, 819, 814, 0, 812, 809, + + 813, 796, 798, 805, 811, 806, 805, 792, 0, 794, + 0, 0, 0, 0, 793, 797, 0, 791, 840, 790, + 793, 0, 781, 791, 0, 779, 779, 793, 0, 795, + 0, 491, 803, 802, 801, 772, 771, 0, 789, 788, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 772, 786, 772, 769, 0, 0, 775, 774, 0, 0, + 772, 764, 0, 0, 0, 0, 0, 0, 761, 773, + 494, 765, 772, 769, 763, 756, 512, 772, 757, 752, + 766, 764, 0, 0, 756, 775, 774, 773, 744, 743, + 331, 480, 0, 756, 759, 757, 745, 0, 755, 752, + + 751, 740, 739, 738, 507, 747, 0, 759, 758, 757, + 728, 727, 0, 742, 0, 740, 735, 485, 535, 779, + 728, 736, 0, 0, 0, 751, 750, 0, 732, 735, + 719, 727, 717, 725, 726, 726, 725, 710, 723, 0, + 724, 712, 711, 707, 731, 730, 729, 700, 699, 0, + 729, 728, 0, 710, 713, 0, 0, 699, 542, 1088, + 563, 0, 569, 525, 1088, 0, 696, 695, 705, 705, + 692, 707, 690, 705, 700, 0, 0, 0, 0, 685, + 0, 0, 0, 706, 337, 706, 695, 698, 682, 681, + 691, 691, 681, 514, 590, 373, 689, 677, 675, 674, + + 685, 0, 688, 684, 686, 682, 668, 675, 675, 677, + 673, 675, 673, 673, 660, 659, 670, 0, 1088, 420, + 1088, 597, 0, 617, 672, 654, 671, 670, 653, 645, + 653, 643, 651, 0, 640, 659, 656, 650, 647, 644, + 0, 639, 609, 592, 537, 588, 598, 582, 581, 0, + 0, 569, 0, 567, 583, 560, 544, 527, 491, 487, + 390, 378, 0, 392, 384, 0, 0, 0, 0, 0, + 339, 330, 275, 0, 0, 0, 0, 249, 265, 241, + 242, 222, 380, 541, 213, 0, 200, 0, 545, 497, + 184, 157, 150, 566, 568, 136, 593, 594, 1088, 619, + + 571, 112, 595, 1088, 572, 578, 0, 123, 621, 630, + 639, 1088, 640, 1088, 1088, 650, 655, 660, 665, 667, + 669, 675, 682, 687, 692, 697 } ; -static yyconst flex_int16_t yy_def[719] = +static yyconst flex_int16_t yy_def[727] = { 0, - 707, 1, 707, 3, 708, 708, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 709, 707, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 710, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 711, 707, - 712, 19, 707, 707, 707, 713, 20, 707, 707, 707, - 707, 707, 709, 707, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 714, 707, 710, 707, - 707, 712, 707, 707, 707, 707, 713, 707, 707, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 707, 707, 707, 707, 714, 707, 707, 707, - 707, 707, 707, 707, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 707, 707, 707, 707, 707, 707, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - - 709, 709, 709, 709, 709, 709, 709, 709, 709, 707, - 707, 707, 707, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 707, 707, 707, - 707, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - - 709, 709, 709, 709, 709, 709, 709, 709, 707, 715, - 707, 707, 707, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 707, - 707, 707, 707, 716, 707, 707, 707, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 707, 717, 707, 716, 707, 707, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 707, 707, 707, 707, 718, 707, 707, 707, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 718, 707, 707, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, - 709, 709, 709, 709, 709, 707, 707, 709, 709, 709, - 709, 709, 709, 709, 709, 709, 709, 709, 709, 707, - 707, 709, 709, 709, 707, 707, 707, 709, 709, 709, - 707, 707, 707, 709, 707, 707, 707, 709, 707, 707, - 707, 707, 707, 709, 707, 707, 707, 707, 709, 707, - - 707, 707, 707, 707, 707, 707, 0, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707 + 715, 1, 715, 3, 716, 716, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 717, 715, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 718, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 719, 715, + 720, 19, 715, 715, 715, 721, 20, 715, 715, 715, + 715, 715, 717, 715, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 722, 715, 718, + 715, 715, 720, 715, 715, 715, 715, 721, 715, 715, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 715, 715, 715, 715, 722, + 715, 715, 715, 715, 715, 715, 715, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 715, 715, 715, 715, + 715, 715, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 715, 715, 715, + 715, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 715, 715, 715, 715, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 715, 723, 715, 715, + 715, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 715, 715, 715, + 715, 724, 715, 715, 715, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 715, 725, 715, 724, 715, 715, 717, 717, + + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 715, 715, + 715, 715, 726, 715, 715, 715, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 726, 715, 715, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 715, 715, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 715, 715, 717, + 717, 717, 715, 715, 715, 717, 717, 717, 715, 715, + 715, 717, 715, 715, 715, 717, 715, 715, 715, 715, + + 715, 717, 715, 715, 715, 715, 717, 715, 715, 715, + 715, 715, 715, 715, 0, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715 } ; -static yyconst flex_int16_t yy_nxt[1145] = +static yyconst flex_int16_t yy_nxt[1153] = { 0, 8, 9, 10, 9, 11, 8, 12, 13, 8, 8, 14, 15, 16, 17, 18, 19, 20, 20, 20, 20, @@ -659,7 +671,7 @@ static yyconst flex_int16_t yy_nxt[1145] = 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 24, 24, 24, 46, 47, 59, 62, 59, 48, 65, 78, 79, 67, 69, 69, 69, 69, 69, 69, 69, - 81, 82, 66, 63, 68, 179, 180, 49, 50, 51, + 81, 82, 66, 63, 68, 180, 181, 49, 50, 51, 52, 51, 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, 53, 50, 54, 54, 54, 54, 54, 54, @@ -668,118 +680,119 @@ static yyconst flex_int16_t yy_nxt[1145] = 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 50, 71, 116, 72, 72, 72, 72, 72, 72, - 73, 85, 88, 126, 89, 213, 702, 117, 90, 74, - 75, 699, 214, 127, 76, 91, 86, 87, 120, 92, - 95, 74, 75, 99, 96, 100, 93, 118, 694, 94, - 97, 119, 121, 689, 101, 146, 98, 123, 688, 76, + 73, 85, 88, 126, 89, 214, 710, 117, 90, 74, + 75, 707, 215, 127, 76, 91, 86, 87, 120, 92, + 95, 74, 75, 99, 96, 100, 93, 118, 702, 94, + 97, 119, 121, 697, 101, 147, 98, 123, 696, 76, 71, 102, 77, 77, 77, 77, 77, 77, 77, 103, - 142, 108, 104, 124, 143, 105, 125, 74, 75, 109, - 111, 106, 707, 112, 144, 128, 687, 113, 114, 74, - 75, 110, 129, 130, 147, 115, 135, 131, 684, 136, - 139, 150, 151, 132, 133, 140, 134, 707, 137, 141, - 148, 156, 59, 156, 149, 138, 158, 158, 158, 158, - 158, 158, 158, 59, 189, 59, 160, 161, 163, 164, - 191, 264, 265, 240, 216, 190, 241, 208, 160, 161, - 163, 164, 152, 201, 192, 209, 202, 203, 217, 153, - 204, 235, 205, 154, 226, 150, 151, 683, 155, 71, - - 236, 73, 73, 73, 73, 73, 73, 73, 680, 148, - 227, 59, 679, 149, 165, 165, 74, 75, 166, 166, - 166, 166, 166, 166, 166, 150, 151, 523, 74, 75, - 156, 321, 156, 250, 251, 524, 152, 294, 295, 296, - 322, 556, 681, 153, 675, 250, 251, 154, 326, 327, - 328, 676, 155, 158, 158, 158, 158, 158, 158, 158, - 341, 342, 343, 352, 353, 354, 152, 360, 361, 362, - 364, 365, 366, 153, 374, 375, 376, 154, 678, 248, - 248, 589, 155, 249, 249, 249, 249, 249, 249, 249, - 252, 252, 590, 682, 253, 253, 253, 253, 253, 253, - - 253, 166, 166, 166, 166, 166, 166, 166, 166, 166, - 166, 166, 166, 166, 166, 249, 249, 249, 249, 249, - 249, 249, 602, 603, 254, 249, 249, 249, 249, 249, - 249, 249, 434, 435, 436, 677, 254, 674, 336, 336, - 673, 161, 337, 337, 337, 337, 337, 337, 337, 437, - 438, 439, 672, 161, 253, 253, 253, 253, 253, 253, - 253, 253, 253, 253, 253, 253, 253, 253, 337, 337, - 337, 337, 337, 337, 337, 551, 552, 164, 337, 337, - 337, 337, 337, 337, 337, 425, 426, 427, 675, 164, - 440, 441, 442, 671, 251, 676, 428, 429, 478, 479, - - 480, 500, 501, 502, 469, 670, 251, 525, 681, 481, - 482, 669, 503, 504, 668, 526, 551, 552, 510, 511, - 511, 511, 511, 511, 511, 537, 538, 539, 551, 552, - 612, 613, 612, 613, 612, 613, 540, 541, 551, 552, - 667, 685, 555, 555, 555, 555, 555, 555, 555, 686, - 554, 697, 586, 587, 587, 587, 587, 587, 587, 682, - 692, 666, 551, 552, 615, 690, 695, 693, 551, 552, - 697, 665, 664, 691, 696, 554, 553, 553, 553, 553, - 553, 553, 555, 555, 555, 555, 555, 555, 555, 615, - 612, 613, 690, 663, 692, 695, 662, 612, 613, 661, - - 691, 693, 698, 696, 616, 616, 616, 616, 616, 616, - 616, 614, 614, 614, 614, 614, 614, 612, 613, 700, - 703, 698, 705, 660, 659, 658, 657, 701, 704, 656, - 706, 616, 616, 616, 616, 616, 616, 616, 703, 705, - 655, 654, 653, 652, 651, 650, 704, 706, 57, 57, - 57, 57, 57, 57, 57, 57, 83, 83, 83, 83, - 83, 159, 159, 159, 159, 159, 69, 69, 162, 162, - 167, 167, 167, 247, 247, 649, 247, 247, 247, 247, - 247, 553, 553, 553, 648, 647, 646, 553, 588, 588, - 588, 614, 614, 614, 645, 644, 643, 614, 637, 637, - - 637, 642, 641, 640, 639, 638, 636, 635, 634, 633, - 632, 631, 630, 629, 628, 627, 626, 625, 624, 623, - 622, 621, 620, 619, 618, 617, 611, 610, 609, 608, - 607, 606, 605, 604, 601, 600, 599, 598, 597, 596, - 595, 594, 593, 592, 591, 585, 584, 583, 582, 581, - 580, 579, 578, 577, 576, 575, 574, 573, 572, 571, - 570, 569, 568, 567, 566, 565, 564, 563, 562, 561, - 560, 559, 558, 557, 556, 550, 549, 548, 547, 546, - 545, 544, 543, 542, 536, 535, 534, 533, 532, 531, - 530, 529, 528, 527, 522, 521, 520, 519, 518, 517, - - 516, 515, 514, 513, 512, 509, 508, 507, 506, 505, - 499, 498, 497, 496, 495, 494, 493, 492, 491, 490, - 489, 488, 487, 486, 485, 484, 483, 477, 476, 475, - 474, 473, 472, 471, 470, 469, 468, 467, 466, 465, - 464, 463, 462, 461, 460, 459, 458, 457, 456, 455, - 454, 453, 452, 451, 450, 449, 448, 447, 446, 445, - 444, 443, 433, 432, 431, 430, 424, 423, 422, 421, - 420, 419, 418, 417, 416, 415, 414, 413, 412, 411, - 410, 409, 408, 407, 406, 405, 404, 403, 402, 401, - 400, 399, 398, 397, 396, 395, 394, 393, 392, 391, - - 390, 389, 388, 387, 386, 385, 384, 383, 382, 381, - 380, 379, 378, 377, 373, 372, 371, 370, 369, 368, - 367, 363, 359, 358, 357, 356, 355, 351, 350, 349, - 348, 347, 346, 345, 344, 340, 339, 338, 335, 334, - 333, 332, 331, 330, 329, 325, 324, 323, 320, 319, - 318, 317, 316, 315, 314, 313, 312, 311, 310, 309, - 308, 307, 306, 305, 304, 303, 302, 301, 300, 299, - 298, 297, 293, 292, 291, 290, 289, 288, 287, 286, - 285, 284, 283, 282, 281, 280, 279, 278, 277, 276, - 275, 274, 273, 272, 271, 270, 269, 268, 267, 266, - - 263, 262, 261, 260, 259, 258, 257, 256, 255, 246, - 245, 244, 243, 242, 239, 238, 237, 234, 233, 232, - 231, 230, 229, 228, 225, 224, 223, 222, 221, 220, - 219, 218, 215, 212, 211, 210, 207, 206, 200, 199, - 198, 197, 196, 195, 194, 193, 188, 187, 186, 185, - 184, 183, 182, 181, 178, 177, 176, 175, 174, 173, - 172, 171, 170, 169, 168, 157, 80, 145, 122, 107, - 84, 80, 70, 64, 61, 60, 707, 58, 58, 7, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707 + 143, 108, 104, 124, 144, 105, 125, 74, 75, 109, + 111, 106, 715, 112, 145, 128, 695, 113, 114, 74, + 75, 110, 129, 130, 148, 115, 135, 131, 692, 136, + 139, 151, 152, 132, 133, 140, 134, 715, 137, 141, + 683, 157, 142, 157, 149, 138, 59, 684, 150, 159, + 159, 159, 159, 159, 159, 159, 59, 190, 59, 209, + 237, 161, 162, 164, 165, 691, 192, 210, 191, 238, + 217, 688, 153, 161, 162, 164, 165, 687, 202, 154, + 193, 203, 204, 155, 218, 205, 227, 206, 156, 71, + + 686, 73, 73, 73, 73, 73, 73, 73, 235, 236, + 243, 685, 228, 244, 166, 166, 74, 75, 167, 167, + 167, 167, 167, 167, 167, 151, 152, 682, 74, 75, + 149, 157, 59, 157, 150, 151, 152, 159, 159, 159, + 159, 159, 159, 159, 251, 251, 253, 254, 252, 252, + 252, 252, 252, 252, 252, 267, 268, 531, 253, 254, + 297, 298, 299, 325, 681, 532, 153, 331, 332, 333, + 610, 611, 326, 154, 559, 560, 153, 155, 346, 347, + 348, 683, 156, 154, 357, 358, 359, 155, 684, 255, + 255, 680, 156, 256, 256, 256, 256, 256, 256, 256, + + 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, + 167, 167, 167, 167, 252, 252, 252, 252, 252, 252, + 252, 620, 621, 257, 252, 252, 252, 252, 252, 252, + 252, 365, 366, 367, 679, 257, 678, 341, 341, 677, + 162, 342, 342, 342, 342, 342, 342, 342, 369, 370, + 371, 676, 162, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 379, 380, 381, + 412, 413, 414, 433, 434, 435, 165, 342, 342, 342, + 342, 342, 342, 342, 436, 437, 559, 560, 165, 342, + 342, 342, 342, 342, 342, 342, 442, 443, 444, 445, + + 446, 447, 448, 449, 450, 254, 533, 486, 487, 488, + 508, 509, 510, 477, 534, 620, 621, 254, 489, 490, + 562, 511, 512, 545, 546, 547, 564, 518, 519, 519, + 519, 519, 519, 519, 548, 549, 559, 560, 620, 621, + 693, 675, 689, 559, 560, 562, 689, 674, 694, 623, + 563, 563, 563, 563, 563, 563, 563, 594, 595, 595, + 595, 595, 595, 595, 559, 560, 597, 698, 673, 700, + 559, 560, 705, 705, 623, 699, 701, 598, 561, 561, + 561, 561, 561, 561, 563, 563, 563, 563, 563, 563, + 563, 620, 621, 690, 703, 698, 703, 690, 620, 621, + + 672, 671, 704, 699, 704, 624, 624, 624, 624, 624, + 624, 624, 622, 622, 622, 622, 622, 622, 620, 621, + 700, 708, 711, 706, 706, 670, 669, 701, 668, 709, + 712, 713, 624, 624, 624, 624, 624, 624, 624, 714, + 711, 713, 667, 666, 665, 664, 663, 662, 712, 714, + 57, 57, 57, 57, 57, 57, 57, 57, 83, 83, + 83, 83, 83, 160, 160, 160, 160, 160, 69, 69, + 163, 163, 168, 168, 168, 250, 250, 661, 250, 250, + 250, 250, 250, 561, 561, 561, 660, 659, 658, 561, + 596, 596, 596, 622, 622, 622, 657, 656, 655, 622, + + 645, 645, 645, 654, 653, 652, 651, 650, 649, 648, + 647, 646, 644, 643, 642, 641, 640, 639, 638, 637, + 636, 635, 634, 633, 632, 631, 630, 629, 628, 627, + 626, 625, 619, 618, 617, 616, 615, 614, 613, 612, + 609, 608, 607, 606, 605, 604, 603, 602, 601, 600, + 599, 593, 592, 591, 590, 589, 588, 587, 586, 585, + 584, 583, 582, 581, 580, 579, 578, 577, 576, 575, + 574, 573, 572, 571, 570, 569, 568, 567, 566, 565, + 564, 558, 557, 556, 555, 554, 553, 552, 551, 550, + 544, 543, 542, 541, 540, 539, 538, 537, 536, 535, + + 530, 529, 528, 527, 526, 525, 524, 523, 522, 521, + 520, 517, 516, 515, 514, 513, 507, 506, 505, 504, + 503, 502, 501, 500, 499, 498, 497, 496, 495, 494, + 493, 492, 491, 485, 484, 483, 482, 481, 480, 479, + 478, 477, 476, 475, 474, 473, 472, 471, 470, 469, + 468, 467, 466, 465, 464, 463, 462, 461, 460, 459, + 458, 457, 456, 455, 454, 453, 452, 451, 441, 440, + 439, 438, 432, 431, 430, 429, 428, 427, 426, 425, + 424, 423, 422, 421, 420, 419, 418, 417, 416, 415, + 411, 410, 409, 408, 407, 406, 405, 404, 403, 402, + + 401, 400, 399, 398, 397, 396, 395, 394, 393, 392, + 391, 390, 389, 388, 387, 386, 385, 384, 383, 382, + 378, 377, 376, 375, 374, 373, 372, 368, 364, 363, + 362, 361, 360, 356, 355, 354, 353, 352, 351, 350, + 349, 345, 344, 343, 340, 339, 338, 337, 336, 335, + 334, 330, 329, 328, 327, 324, 323, 322, 321, 320, + 319, 318, 317, 316, 315, 314, 313, 312, 311, 310, + 309, 308, 307, 306, 305, 304, 303, 302, 301, 300, + 296, 295, 294, 293, 292, 291, 290, 289, 288, 287, + 286, 285, 284, 283, 282, 281, 280, 279, 278, 277, + + 276, 275, 274, 273, 272, 271, 270, 269, 266, 265, + 264, 263, 262, 261, 260, 259, 258, 249, 248, 247, + 246, 245, 242, 241, 240, 239, 234, 233, 232, 231, + 230, 229, 226, 225, 224, 223, 222, 221, 220, 219, + 216, 213, 212, 211, 208, 207, 201, 200, 199, 198, + 197, 196, 195, 194, 189, 188, 187, 186, 185, 184, + 183, 182, 179, 178, 177, 176, 175, 174, 173, 172, + 171, 170, 169, 158, 80, 146, 122, 107, 84, 80, + 70, 64, 61, 60, 715, 58, 58, 7, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715 } ; -static yyconst flex_int16_t yy_chk[1145] = +static yyconst flex_int16_t yy_chk[1153] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -798,115 +811,116 @@ static yyconst flex_int16_t yy_chk[1145] = 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 19, 35, 19, 19, 19, 19, 19, 19, - 19, 26, 27, 40, 27, 121, 700, 35, 27, 19, - 19, 694, 121, 40, 19, 28, 26, 26, 37, 28, - 29, 19, 19, 30, 29, 30, 28, 36, 688, 28, - 29, 36, 37, 685, 30, 46, 29, 39, 684, 19, + 19, 26, 27, 40, 27, 121, 708, 35, 27, 19, + 19, 702, 121, 40, 19, 28, 26, 26, 37, 28, + 29, 19, 19, 30, 29, 30, 28, 36, 696, 28, + 29, 36, 37, 693, 30, 46, 29, 39, 692, 19, 20, 31, 20, 20, 20, 20, 20, 20, 20, 31, 44, 33, 31, 39, 44, 31, 39, 20, 20, 33, - 34, 31, 72, 34, 44, 41, 683, 34, 34, 20, - 20, 33, 41, 41, 46, 34, 42, 41, 679, 42, + 34, 31, 72, 34, 44, 41, 691, 34, 34, 20, + 20, 33, 41, 41, 46, 34, 42, 41, 687, 42, 43, 48, 48, 41, 41, 43, 41, 72, 42, 43, - 47, 51, 47, 51, 47, 42, 54, 54, 54, 54, - 54, 54, 54, 59, 103, 59, 69, 69, 71, 71, - 104, 180, 180, 144, 123, 103, 144, 117, 69, 69, - 71, 71, 48, 114, 104, 117, 114, 114, 123, 48, - 114, 140, 114, 48, 132, 149, 149, 677, 48, 73, - - 140, 73, 73, 73, 73, 73, 73, 73, 674, 148, - 132, 148, 673, 148, 74, 74, 73, 73, 74, 74, - 74, 74, 74, 74, 74, 150, 150, 483, 73, 73, - 156, 235, 156, 162, 162, 483, 149, 210, 210, 210, - 235, 556, 676, 149, 670, 162, 162, 149, 239, 239, - 239, 670, 149, 158, 158, 158, 158, 158, 158, 158, - 259, 259, 259, 269, 269, 269, 150, 278, 278, 278, - 282, 282, 282, 150, 290, 290, 290, 150, 672, 160, - 160, 556, 150, 160, 160, 160, 160, 160, 160, 160, - 163, 163, 556, 676, 163, 163, 163, 163, 163, 163, - - 163, 165, 165, 165, 165, 165, 165, 165, 166, 166, - 166, 166, 166, 166, 166, 248, 248, 248, 248, 248, - 248, 248, 577, 577, 166, 249, 249, 249, 249, 249, - 249, 249, 378, 378, 378, 671, 166, 665, 250, 250, - 664, 249, 250, 250, 250, 250, 250, 250, 250, 379, - 379, 379, 663, 249, 252, 252, 252, 252, 252, 252, - 252, 253, 253, 253, 253, 253, 253, 253, 336, 336, - 336, 336, 336, 336, 336, 588, 588, 253, 337, 337, - 337, 337, 337, 337, 337, 368, 368, 368, 675, 253, - 380, 380, 380, 657, 337, 675, 368, 368, 424, 424, - - 424, 463, 463, 463, 469, 656, 337, 484, 681, 424, - 424, 654, 463, 463, 653, 484, 510, 510, 469, 469, - 469, 469, 469, 469, 469, 497, 497, 497, 511, 511, - 586, 586, 612, 612, 637, 637, 497, 497, 551, 551, - 652, 682, 511, 511, 511, 511, 511, 511, 511, 682, - 510, 693, 551, 551, 551, 551, 551, 551, 551, 681, - 687, 651, 553, 553, 586, 686, 689, 687, 555, 555, - 697, 650, 649, 686, 689, 510, 553, 553, 553, 553, - 553, 553, 555, 555, 555, 555, 555, 555, 555, 586, - 587, 587, 690, 648, 692, 695, 647, 614, 614, 646, - - 690, 692, 693, 695, 587, 587, 587, 587, 587, 587, - 587, 614, 614, 614, 614, 614, 614, 616, 616, 698, - 701, 697, 702, 644, 641, 640, 639, 698, 701, 638, - 702, 616, 616, 616, 616, 616, 616, 616, 703, 705, - 636, 635, 634, 632, 631, 630, 703, 705, 708, 708, - 708, 708, 708, 708, 708, 708, 709, 709, 709, 709, - 709, 710, 710, 710, 710, 710, 711, 711, 712, 712, - 713, 713, 713, 714, 714, 629, 714, 714, 714, 714, - 714, 715, 715, 715, 628, 627, 625, 715, 716, 716, - 716, 717, 717, 717, 624, 623, 622, 717, 718, 718, - - 718, 621, 620, 619, 618, 617, 609, 608, 607, 606, - 605, 604, 603, 602, 601, 600, 599, 598, 597, 596, - 595, 593, 592, 591, 590, 589, 585, 584, 583, 582, - 581, 580, 579, 578, 576, 572, 567, 566, 565, 564, - 563, 562, 561, 560, 559, 550, 547, 546, 544, 543, - 541, 540, 539, 538, 537, 536, 535, 534, 533, 531, - 530, 529, 528, 527, 526, 525, 524, 523, 522, 521, - 519, 518, 514, 513, 512, 509, 508, 506, 504, 503, - 502, 501, 500, 498, 496, 495, 494, 493, 492, 491, - 489, 488, 487, 486, 482, 481, 480, 479, 478, 477, - - 474, 473, 472, 471, 470, 468, 467, 466, 465, 464, - 462, 461, 454, 453, 450, 449, 446, 445, 444, 443, - 432, 431, 429, 428, 427, 426, 425, 422, 420, 419, - 418, 416, 415, 413, 412, 411, 410, 408, 407, 405, - 403, 402, 401, 400, 399, 398, 397, 396, 395, 394, - 392, 391, 390, 389, 388, 387, 386, 385, 384, 383, - 382, 381, 377, 373, 372, 369, 367, 357, 355, 351, - 350, 349, 348, 346, 344, 339, 338, 335, 334, 333, - 332, 331, 330, 325, 324, 323, 322, 321, 320, 319, - 316, 315, 314, 313, 312, 311, 310, 309, 308, 307, - - 306, 305, 304, 303, 302, 301, 300, 299, 298, 297, - 296, 295, 294, 291, 289, 288, 287, 286, 285, 284, - 283, 281, 277, 275, 274, 273, 272, 268, 267, 266, - 265, 264, 263, 262, 261, 258, 256, 255, 246, 245, - 244, 243, 242, 241, 240, 238, 237, 236, 234, 233, - 232, 231, 230, 229, 228, 227, 226, 225, 224, 223, - 222, 221, 220, 219, 218, 217, 216, 215, 214, 213, - 212, 211, 209, 208, 207, 206, 205, 204, 203, 202, - 201, 200, 199, 198, 197, 196, 195, 194, 192, 191, - 190, 189, 188, 187, 186, 185, 184, 183, 182, 181, - - 179, 178, 177, 176, 175, 174, 173, 172, 170, 155, - 154, 153, 152, 145, 143, 142, 141, 139, 138, 137, - 136, 135, 134, 133, 131, 130, 129, 128, 127, 126, - 125, 124, 122, 120, 119, 118, 116, 115, 113, 112, - 110, 109, 108, 107, 106, 105, 102, 101, 100, 99, - 98, 97, 96, 95, 93, 92, 91, 90, 89, 88, - 87, 86, 85, 82, 78, 53, 49, 45, 38, 32, - 25, 22, 18, 14, 12, 11, 7, 6, 5, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707, 707, 707, 707, 707, 707, 707, - 707, 707, 707, 707 + 678, 51, 43, 51, 47, 42, 47, 678, 47, 54, + 54, 54, 54, 54, 54, 54, 59, 103, 59, 117, + 140, 69, 69, 71, 71, 685, 104, 117, 103, 140, + 123, 682, 48, 69, 69, 71, 71, 681, 114, 48, + 104, 114, 114, 48, 123, 114, 132, 114, 48, 73, + + 680, 73, 73, 73, 73, 73, 73, 73, 139, 139, + 145, 679, 132, 145, 74, 74, 73, 73, 74, 74, + 74, 74, 74, 74, 74, 150, 150, 673, 73, 73, + 149, 157, 149, 157, 149, 151, 151, 159, 159, 159, + 159, 159, 159, 159, 161, 161, 163, 163, 161, 161, + 161, 161, 161, 161, 161, 181, 181, 491, 163, 163, + 211, 211, 211, 237, 672, 491, 150, 242, 242, 242, + 585, 585, 237, 150, 596, 596, 151, 150, 262, 262, + 262, 683, 150, 151, 272, 272, 272, 151, 683, 164, + 164, 671, 151, 164, 164, 164, 164, 164, 164, 164, + + 166, 166, 166, 166, 166, 166, 166, 167, 167, 167, + 167, 167, 167, 167, 251, 251, 251, 251, 251, 251, + 251, 620, 620, 167, 252, 252, 252, 252, 252, 252, + 252, 281, 281, 281, 665, 167, 664, 253, 253, 662, + 252, 253, 253, 253, 253, 253, 253, 253, 285, 285, + 285, 661, 252, 255, 255, 255, 255, 255, 255, 255, + 256, 256, 256, 256, 256, 256, 256, 293, 293, 293, + 329, 329, 329, 373, 373, 373, 256, 341, 341, 341, + 341, 341, 341, 341, 373, 373, 518, 518, 256, 342, + 342, 342, 342, 342, 342, 342, 383, 383, 383, 384, + + 384, 384, 385, 385, 385, 342, 492, 432, 432, 432, + 471, 471, 471, 477, 492, 594, 594, 342, 432, 432, + 518, 471, 471, 505, 505, 505, 564, 477, 477, 477, + 477, 477, 477, 477, 505, 505, 519, 519, 645, 645, + 690, 660, 684, 559, 559, 518, 689, 659, 690, 594, + 519, 519, 519, 519, 519, 519, 519, 559, 559, 559, + 559, 559, 559, 559, 561, 561, 564, 694, 658, 695, + 563, 563, 701, 705, 594, 694, 695, 564, 561, 561, + 561, 561, 561, 561, 563, 563, 563, 563, 563, 563, + 563, 595, 595, 684, 697, 698, 703, 689, 622, 622, + + 657, 656, 697, 698, 703, 595, 595, 595, 595, 595, + 595, 595, 622, 622, 622, 622, 622, 622, 624, 624, + 700, 706, 709, 701, 705, 655, 654, 700, 652, 706, + 709, 710, 624, 624, 624, 624, 624, 624, 624, 710, + 711, 713, 649, 648, 647, 646, 644, 643, 711, 713, + 716, 716, 716, 716, 716, 716, 716, 716, 717, 717, + 717, 717, 717, 718, 718, 718, 718, 718, 719, 719, + 720, 720, 721, 721, 721, 722, 722, 642, 722, 722, + 722, 722, 722, 723, 723, 723, 640, 639, 638, 723, + 724, 724, 724, 725, 725, 725, 637, 636, 635, 725, + + 726, 726, 726, 633, 632, 631, 630, 629, 628, 627, + 626, 625, 617, 616, 615, 614, 613, 612, 611, 610, + 609, 608, 607, 606, 605, 604, 603, 601, 600, 599, + 598, 597, 593, 592, 591, 590, 589, 588, 587, 586, + 584, 580, 575, 574, 573, 572, 571, 570, 569, 568, + 567, 558, 555, 554, 552, 551, 549, 548, 547, 546, + 545, 544, 543, 542, 541, 539, 538, 537, 536, 535, + 534, 533, 532, 531, 530, 529, 527, 526, 522, 521, + 520, 517, 516, 514, 512, 511, 510, 509, 508, 506, + 504, 503, 502, 501, 500, 499, 497, 496, 495, 494, + + 490, 489, 488, 487, 486, 485, 482, 481, 480, 479, + 478, 476, 475, 474, 473, 472, 470, 469, 462, 461, + 458, 457, 454, 453, 452, 451, 440, 439, 437, 436, + 435, 434, 433, 430, 428, 427, 426, 424, 423, 421, + 420, 419, 418, 416, 415, 410, 408, 407, 406, 405, + 404, 403, 402, 401, 400, 399, 397, 396, 395, 394, + 393, 392, 391, 390, 389, 388, 387, 386, 382, 378, + 377, 374, 372, 362, 360, 356, 355, 354, 353, 351, + 349, 344, 343, 340, 339, 338, 337, 336, 335, 330, + 328, 327, 326, 325, 323, 322, 319, 318, 317, 316, + + 315, 314, 313, 312, 311, 310, 309, 308, 307, 306, + 305, 304, 303, 302, 301, 300, 299, 298, 297, 294, + 292, 291, 290, 289, 288, 287, 286, 284, 280, 278, + 277, 276, 275, 271, 270, 269, 268, 267, 266, 265, + 264, 261, 259, 258, 249, 248, 247, 246, 245, 244, + 243, 241, 240, 239, 238, 236, 235, 234, 233, 232, + 231, 230, 229, 228, 227, 226, 225, 224, 223, 222, + 221, 220, 219, 218, 217, 216, 215, 214, 213, 212, + 210, 209, 208, 207, 206, 205, 204, 203, 202, 201, + 200, 199, 198, 197, 196, 195, 193, 192, 191, 190, + + 189, 188, 187, 186, 185, 184, 183, 182, 180, 179, + 178, 177, 176, 175, 174, 173, 171, 156, 155, 154, + 153, 146, 144, 143, 142, 141, 138, 137, 136, 135, + 134, 133, 131, 130, 129, 128, 127, 126, 125, 124, + 122, 120, 119, 118, 116, 115, 113, 112, 110, 109, + 108, 107, 106, 105, 102, 101, 100, 99, 98, 97, + 96, 95, 93, 92, 91, 90, 89, 88, 87, 86, + 85, 82, 78, 53, 49, 45, 38, 32, 25, 22, + 18, 14, 12, 11, 7, 6, 5, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, + 715, 715 } ; /* The intent behind this definition is that it'll catch @@ -986,7 +1000,7 @@ static yyconst flex_int16_t yy_chk[1145] = } \ } while (0) -#line 990 "glsl_lexer.cpp" +#line 1004 "glsl_lexer.cpp" #define INITIAL 0 #define PP 1 @@ -1113,7 +1127,12 @@ static int input (yyscan_t yyscanner ); /* Amount of stuff to slurp up with each read. */ #ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else #define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ #endif /* Copy whatever the last rule matched to the standard output. */ @@ -1121,7 +1140,7 @@ static int input (yyscan_t yyscanner ); /* This used to be an fputs(), but since the string might contain NUL's, * we now use fwrite(). */ -#define ECHO fwrite( yytext, yyleng, 1, yyout ) +#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0) #endif /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, @@ -1132,7 +1151,7 @@ static int input (yyscan_t yyscanner ); if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ { \ int c = '*'; \ - int n; \ + size_t n; \ for ( n = 0; n < max_size && \ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ @@ -1223,7 +1242,7 @@ YY_DECL #line 86 "glsl_lexer.lpp" -#line 1227 "glsl_lexer.cpp" +#line 1246 "glsl_lexer.cpp" yylval = yylval_param; @@ -1281,13 +1300,13 @@ yy_match: while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 708 ) + if ( yy_current_state >= 716 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; ++yy_cp; } - while ( yy_current_state != 707 ); + while ( yy_current_state != 715 ); yy_cp = yyg->yy_last_accepting_cpos; yy_current_state = yyg->yy_last_accepting_state; @@ -1492,249 +1511,270 @@ return INT_TOK; YY_BREAK case 26: YY_RULE_SETUP -#line 165 "glsl_lexer.lpp" -return BREAK; +#line 164 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(130, UINT_TOK); YY_BREAK case 27: YY_RULE_SETUP #line 166 "glsl_lexer.lpp" -return CONTINUE; +return BREAK; YY_BREAK case 28: YY_RULE_SETUP #line 167 "glsl_lexer.lpp" -return DO; +return CONTINUE; YY_BREAK case 29: YY_RULE_SETUP #line 168 "glsl_lexer.lpp" -return WHILE; +return DO; YY_BREAK case 30: YY_RULE_SETUP #line 169 "glsl_lexer.lpp" -return ELSE; +return WHILE; YY_BREAK case 31: YY_RULE_SETUP #line 170 "glsl_lexer.lpp" -return FOR; +return ELSE; YY_BREAK case 32: YY_RULE_SETUP #line 171 "glsl_lexer.lpp" -return IF; +return FOR; YY_BREAK case 33: YY_RULE_SETUP #line 172 "glsl_lexer.lpp" -return DISCARD; +return IF; YY_BREAK case 34: YY_RULE_SETUP #line 173 "glsl_lexer.lpp" -return RETURN; +return DISCARD; YY_BREAK case 35: YY_RULE_SETUP -#line 175 "glsl_lexer.lpp" -return BVEC2; +#line 174 "glsl_lexer.lpp" +return RETURN; YY_BREAK case 36: YY_RULE_SETUP #line 176 "glsl_lexer.lpp" -return BVEC3; +return BVEC2; YY_BREAK case 37: YY_RULE_SETUP #line 177 "glsl_lexer.lpp" -return BVEC4; +return BVEC3; YY_BREAK case 38: YY_RULE_SETUP #line 178 "glsl_lexer.lpp" -return IVEC2; +return BVEC4; YY_BREAK case 39: YY_RULE_SETUP #line 179 "glsl_lexer.lpp" -return IVEC3; +return IVEC2; YY_BREAK case 40: YY_RULE_SETUP #line 180 "glsl_lexer.lpp" -return IVEC4; +return IVEC3; YY_BREAK case 41: YY_RULE_SETUP #line 181 "glsl_lexer.lpp" -return VEC2; +return IVEC4; YY_BREAK case 42: YY_RULE_SETUP #line 182 "glsl_lexer.lpp" -return VEC3; +TOKEN_OR_IDENTIFIER(130, UVEC2); YY_BREAK case 43: YY_RULE_SETUP #line 183 "glsl_lexer.lpp" -return VEC4; +TOKEN_OR_IDENTIFIER(130, UVEC3); YY_BREAK case 44: YY_RULE_SETUP #line 184 "glsl_lexer.lpp" -return MAT2X2; +TOKEN_OR_IDENTIFIER(130, UVEC4); YY_BREAK case 45: YY_RULE_SETUP #line 185 "glsl_lexer.lpp" -return MAT3X3; +return VEC2; YY_BREAK case 46: YY_RULE_SETUP #line 186 "glsl_lexer.lpp" -return MAT4X4; +return VEC3; YY_BREAK case 47: YY_RULE_SETUP #line 187 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT2X2); +return VEC4; YY_BREAK case 48: YY_RULE_SETUP #line 188 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT2X3); +return MAT2X2; YY_BREAK case 49: YY_RULE_SETUP #line 189 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT2X4); +return MAT3X3; YY_BREAK case 50: YY_RULE_SETUP #line 190 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT3X2); +return MAT4X4; YY_BREAK case 51: YY_RULE_SETUP #line 191 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT3X3); +TOKEN_OR_IDENTIFIER(120, MAT2X2); YY_BREAK case 52: YY_RULE_SETUP #line 192 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT3X4); +TOKEN_OR_IDENTIFIER(120, MAT2X3); YY_BREAK case 53: YY_RULE_SETUP #line 193 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT4X2); +TOKEN_OR_IDENTIFIER(120, MAT2X4); YY_BREAK case 54: YY_RULE_SETUP #line 194 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT4X3); +TOKEN_OR_IDENTIFIER(120, MAT3X2); YY_BREAK case 55: YY_RULE_SETUP #line 195 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, MAT4X4); +TOKEN_OR_IDENTIFIER(120, MAT3X3); YY_BREAK case 56: YY_RULE_SETUP -#line 197 "glsl_lexer.lpp" -return IN_TOK; +#line 196 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(120, MAT3X4); YY_BREAK case 57: YY_RULE_SETUP -#line 198 "glsl_lexer.lpp" -return OUT_TOK; +#line 197 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(120, MAT4X2); YY_BREAK case 58: YY_RULE_SETUP -#line 199 "glsl_lexer.lpp" -return INOUT_TOK; +#line 198 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(120, MAT4X3); YY_BREAK case 59: YY_RULE_SETUP -#line 200 "glsl_lexer.lpp" -return UNIFORM; +#line 199 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(120, MAT4X4); YY_BREAK case 60: YY_RULE_SETUP #line 201 "glsl_lexer.lpp" -return VARYING; +return IN_TOK; YY_BREAK case 61: YY_RULE_SETUP #line 202 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(120, CENTROID); +return OUT_TOK; YY_BREAK case 62: YY_RULE_SETUP #line 203 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER_ES(120, INVARIANT); +return INOUT_TOK; YY_BREAK case 63: YY_RULE_SETUP -#line 205 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER_ES(130, FLAT); +#line 204 "glsl_lexer.lpp" +return UNIFORM; YY_BREAK case 64: YY_RULE_SETUP -#line 206 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(130, SMOOTH); +#line 205 "glsl_lexer.lpp" +return VARYING; YY_BREAK case 65: YY_RULE_SETUP -#line 207 "glsl_lexer.lpp" -TOKEN_OR_IDENTIFIER(130, NOPERSPECTIVE); +#line 206 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(120, CENTROID); YY_BREAK case 66: YY_RULE_SETUP -#line 209 "glsl_lexer.lpp" -return SAMPLER1D; +#line 207 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER_ES(120, INVARIANT); YY_BREAK case 67: YY_RULE_SETUP -#line 210 "glsl_lexer.lpp" -return SAMPLER2D; +#line 209 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER_ES(130, FLAT); YY_BREAK case 68: YY_RULE_SETUP -#line 211 "glsl_lexer.lpp" -return SAMPLER3D; +#line 210 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(130, SMOOTH); YY_BREAK case 69: YY_RULE_SETUP -#line 212 "glsl_lexer.lpp" -return SAMPLERCUBE; +#line 211 "glsl_lexer.lpp" +TOKEN_OR_IDENTIFIER(130, NOPERSPECTIVE); YY_BREAK case 70: YY_RULE_SETUP #line 213 "glsl_lexer.lpp" -return SAMPLER1DSHADOW; +return SAMPLER1D; YY_BREAK case 71: YY_RULE_SETUP #line 214 "glsl_lexer.lpp" -return SAMPLER2DSHADOW; +return SAMPLER2D; YY_BREAK case 72: YY_RULE_SETUP -#line 216 "glsl_lexer.lpp" -return STRUCT; +#line 215 "glsl_lexer.lpp" +return SAMPLER3D; YY_BREAK case 73: YY_RULE_SETUP +#line 216 "glsl_lexer.lpp" +return SAMPLERCUBE; + YY_BREAK +case 74: +YY_RULE_SETUP #line 217 "glsl_lexer.lpp" +return SAMPLER1DSHADOW; + YY_BREAK +case 75: +YY_RULE_SETUP +#line 218 "glsl_lexer.lpp" +return SAMPLER2DSHADOW; + YY_BREAK +case 76: +YY_RULE_SETUP +#line 220 "glsl_lexer.lpp" +return STRUCT; + YY_BREAK +case 77: +YY_RULE_SETUP +#line 221 "glsl_lexer.lpp" return VOID_TOK; YY_BREAK -case 74: +case 78: YY_RULE_SETUP -#line 219 "glsl_lexer.lpp" +#line 223 "glsl_lexer.lpp" { if ((yyextra->language_version >= 140) + || yyextra->ARB_explicit_attrib_location_enable || (yyextra->ARB_fragment_coord_conventions_enable)){ return LAYOUT_TOK; } else { @@ -1743,572 +1783,582 @@ YY_RULE_SETUP } } YY_BREAK -case 75: +case 79: YY_RULE_SETUP -#line 229 "glsl_lexer.lpp" +#line 234 "glsl_lexer.lpp" return INC_OP; YY_BREAK -case 76: +case 80: YY_RULE_SETUP -#line 230 "glsl_lexer.lpp" +#line 235 "glsl_lexer.lpp" return DEC_OP; YY_BREAK -case 77: +case 81: YY_RULE_SETUP -#line 231 "glsl_lexer.lpp" +#line 236 "glsl_lexer.lpp" return LE_OP; YY_BREAK -case 78: +case 82: YY_RULE_SETUP -#line 232 "glsl_lexer.lpp" +#line 237 "glsl_lexer.lpp" return GE_OP; YY_BREAK -case 79: +case 83: YY_RULE_SETUP -#line 233 "glsl_lexer.lpp" +#line 238 "glsl_lexer.lpp" return EQ_OP; YY_BREAK -case 80: +case 84: YY_RULE_SETUP -#line 234 "glsl_lexer.lpp" +#line 239 "glsl_lexer.lpp" return NE_OP; YY_BREAK -case 81: +case 85: YY_RULE_SETUP -#line 235 "glsl_lexer.lpp" +#line 240 "glsl_lexer.lpp" return AND_OP; YY_BREAK -case 82: +case 86: YY_RULE_SETUP -#line 236 "glsl_lexer.lpp" +#line 241 "glsl_lexer.lpp" return OR_OP; YY_BREAK -case 83: +case 87: YY_RULE_SETUP -#line 237 "glsl_lexer.lpp" +#line 242 "glsl_lexer.lpp" return XOR_OP; YY_BREAK -case 84: +case 88: YY_RULE_SETUP -#line 239 "glsl_lexer.lpp" +#line 243 "glsl_lexer.lpp" +return LEFT_OP; + YY_BREAK +case 89: +YY_RULE_SETUP +#line 244 "glsl_lexer.lpp" +return RIGHT_OP; + YY_BREAK +case 90: +YY_RULE_SETUP +#line 246 "glsl_lexer.lpp" return MUL_ASSIGN; YY_BREAK -case 85: +case 91: YY_RULE_SETUP -#line 240 "glsl_lexer.lpp" +#line 247 "glsl_lexer.lpp" return DIV_ASSIGN; YY_BREAK -case 86: +case 92: YY_RULE_SETUP -#line 241 "glsl_lexer.lpp" +#line 248 "glsl_lexer.lpp" return ADD_ASSIGN; YY_BREAK -case 87: +case 93: YY_RULE_SETUP -#line 242 "glsl_lexer.lpp" +#line 249 "glsl_lexer.lpp" return MOD_ASSIGN; YY_BREAK -case 88: +case 94: YY_RULE_SETUP -#line 243 "glsl_lexer.lpp" +#line 250 "glsl_lexer.lpp" return LEFT_ASSIGN; YY_BREAK -case 89: +case 95: YY_RULE_SETUP -#line 244 "glsl_lexer.lpp" +#line 251 "glsl_lexer.lpp" return RIGHT_ASSIGN; YY_BREAK -case 90: +case 96: YY_RULE_SETUP -#line 245 "glsl_lexer.lpp" +#line 252 "glsl_lexer.lpp" return AND_ASSIGN; YY_BREAK -case 91: +case 97: YY_RULE_SETUP -#line 246 "glsl_lexer.lpp" +#line 253 "glsl_lexer.lpp" return XOR_ASSIGN; YY_BREAK -case 92: +case 98: YY_RULE_SETUP -#line 247 "glsl_lexer.lpp" +#line 254 "glsl_lexer.lpp" return OR_ASSIGN; YY_BREAK -case 93: +case 99: YY_RULE_SETUP -#line 248 "glsl_lexer.lpp" +#line 255 "glsl_lexer.lpp" return SUB_ASSIGN; YY_BREAK -case 94: +case 100: YY_RULE_SETUP -#line 250 "glsl_lexer.lpp" +#line 257 "glsl_lexer.lpp" { yylval->n = strtol(yytext, NULL, 10); return INTCONSTANT; } YY_BREAK -case 95: +case 101: YY_RULE_SETUP -#line 254 "glsl_lexer.lpp" +#line 261 "glsl_lexer.lpp" { yylval->n = strtol(yytext + 2, NULL, 16); return INTCONSTANT; } YY_BREAK -case 96: +case 102: YY_RULE_SETUP -#line 258 "glsl_lexer.lpp" +#line 265 "glsl_lexer.lpp" { yylval->n = strtol(yytext, NULL, 8); return INTCONSTANT; } YY_BREAK -case 97: +case 103: YY_RULE_SETUP -#line 263 "glsl_lexer.lpp" +#line 270 "glsl_lexer.lpp" { yylval->real = strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK -case 98: +case 104: YY_RULE_SETUP -#line 267 "glsl_lexer.lpp" +#line 274 "glsl_lexer.lpp" { yylval->real = strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK -case 99: +case 105: YY_RULE_SETUP -#line 271 "glsl_lexer.lpp" +#line 278 "glsl_lexer.lpp" { yylval->real = strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK -case 100: +case 106: YY_RULE_SETUP -#line 275 "glsl_lexer.lpp" +#line 282 "glsl_lexer.lpp" { yylval->real = strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK -case 101: +case 107: YY_RULE_SETUP -#line 279 "glsl_lexer.lpp" +#line 286 "glsl_lexer.lpp" { yylval->real = strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK -case 102: +case 108: YY_RULE_SETUP -#line 284 "glsl_lexer.lpp" +#line 291 "glsl_lexer.lpp" { yylval->n = 1; return BOOLCONSTANT; } YY_BREAK -case 103: +case 109: YY_RULE_SETUP -#line 288 "glsl_lexer.lpp" +#line 295 "glsl_lexer.lpp" { yylval->n = 0; return BOOLCONSTANT; } YY_BREAK /* Reserved words in GLSL 1.10. */ -case 104: +case 110: YY_RULE_SETUP -#line 295 "glsl_lexer.lpp" +#line 302 "glsl_lexer.lpp" RESERVED_WORD(999, ASM); YY_BREAK -case 105: +case 111: YY_RULE_SETUP -#line 296 "glsl_lexer.lpp" +#line 303 "glsl_lexer.lpp" RESERVED_WORD(999, CLASS); YY_BREAK -case 106: +case 112: YY_RULE_SETUP -#line 297 "glsl_lexer.lpp" +#line 304 "glsl_lexer.lpp" RESERVED_WORD(999, UNION); YY_BREAK -case 107: +case 113: YY_RULE_SETUP -#line 298 "glsl_lexer.lpp" +#line 305 "glsl_lexer.lpp" RESERVED_WORD(999, ENUM); YY_BREAK -case 108: +case 114: YY_RULE_SETUP -#line 299 "glsl_lexer.lpp" +#line 306 "glsl_lexer.lpp" RESERVED_WORD(999, TYPEDEF); YY_BREAK -case 109: +case 115: YY_RULE_SETUP -#line 300 "glsl_lexer.lpp" +#line 307 "glsl_lexer.lpp" RESERVED_WORD(999, TEMPLATE); YY_BREAK -case 110: +case 116: YY_RULE_SETUP -#line 301 "glsl_lexer.lpp" +#line 308 "glsl_lexer.lpp" RESERVED_WORD(999, THIS); YY_BREAK -case 111: +case 117: YY_RULE_SETUP -#line 302 "glsl_lexer.lpp" +#line 309 "glsl_lexer.lpp" RESERVED_WORD(999, PACKED_TOK); YY_BREAK -case 112: +case 118: YY_RULE_SETUP -#line 303 "glsl_lexer.lpp" +#line 310 "glsl_lexer.lpp" RESERVED_WORD(999, GOTO); YY_BREAK -case 113: +case 119: YY_RULE_SETUP -#line 304 "glsl_lexer.lpp" +#line 311 "glsl_lexer.lpp" RESERVED_WORD(130, SWITCH); YY_BREAK -case 114: +case 120: YY_RULE_SETUP -#line 305 "glsl_lexer.lpp" +#line 312 "glsl_lexer.lpp" RESERVED_WORD(130, DEFAULT); YY_BREAK -case 115: +case 121: YY_RULE_SETUP -#line 306 "glsl_lexer.lpp" +#line 313 "glsl_lexer.lpp" RESERVED_WORD(999, INLINE_TOK); YY_BREAK -case 116: +case 122: YY_RULE_SETUP -#line 307 "glsl_lexer.lpp" +#line 314 "glsl_lexer.lpp" RESERVED_WORD(999, NOINLINE); YY_BREAK -case 117: +case 123: YY_RULE_SETUP -#line 308 "glsl_lexer.lpp" +#line 315 "glsl_lexer.lpp" RESERVED_WORD(999, VOLATILE); YY_BREAK -case 118: +case 124: YY_RULE_SETUP -#line 309 "glsl_lexer.lpp" +#line 316 "glsl_lexer.lpp" RESERVED_WORD(999, PUBLIC_TOK); YY_BREAK -case 119: +case 125: YY_RULE_SETUP -#line 310 "glsl_lexer.lpp" +#line 317 "glsl_lexer.lpp" RESERVED_WORD(999, STATIC); YY_BREAK -case 120: +case 126: YY_RULE_SETUP -#line 311 "glsl_lexer.lpp" +#line 318 "glsl_lexer.lpp" RESERVED_WORD(999, EXTERN); YY_BREAK -case 121: +case 127: YY_RULE_SETUP -#line 312 "glsl_lexer.lpp" +#line 319 "glsl_lexer.lpp" RESERVED_WORD(999, EXTERNAL); YY_BREAK -case 122: +case 128: YY_RULE_SETUP -#line 313 "glsl_lexer.lpp" +#line 320 "glsl_lexer.lpp" RESERVED_WORD(999, INTERFACE); YY_BREAK -case 123: +case 129: YY_RULE_SETUP -#line 314 "glsl_lexer.lpp" +#line 321 "glsl_lexer.lpp" RESERVED_WORD(999, LONG_TOK); YY_BREAK -case 124: +case 130: YY_RULE_SETUP -#line 315 "glsl_lexer.lpp" +#line 322 "glsl_lexer.lpp" RESERVED_WORD(999, SHORT_TOK); YY_BREAK -case 125: +case 131: YY_RULE_SETUP -#line 316 "glsl_lexer.lpp" +#line 323 "glsl_lexer.lpp" RESERVED_WORD(999, DOUBLE_TOK); YY_BREAK -case 126: +case 132: YY_RULE_SETUP -#line 317 "glsl_lexer.lpp" +#line 324 "glsl_lexer.lpp" RESERVED_WORD(999, HALF); YY_BREAK -case 127: +case 133: YY_RULE_SETUP -#line 318 "glsl_lexer.lpp" +#line 325 "glsl_lexer.lpp" RESERVED_WORD(999, FIXED_TOK); YY_BREAK -case 128: +case 134: YY_RULE_SETUP -#line 319 "glsl_lexer.lpp" +#line 326 "glsl_lexer.lpp" RESERVED_WORD(999, UNSIGNED); YY_BREAK -case 129: +case 135: YY_RULE_SETUP -#line 320 "glsl_lexer.lpp" +#line 327 "glsl_lexer.lpp" RESERVED_WORD(999, INPUT_TOK); YY_BREAK -case 130: +case 136: YY_RULE_SETUP -#line 321 "glsl_lexer.lpp" +#line 328 "glsl_lexer.lpp" RESERVED_WORD(999, OUTPUT); YY_BREAK -case 131: +case 137: YY_RULE_SETUP -#line 322 "glsl_lexer.lpp" +#line 329 "glsl_lexer.lpp" RESERVED_WORD(999, HVEC2); YY_BREAK -case 132: +case 138: YY_RULE_SETUP -#line 323 "glsl_lexer.lpp" +#line 330 "glsl_lexer.lpp" RESERVED_WORD(999, HVEC3); YY_BREAK -case 133: +case 139: YY_RULE_SETUP -#line 324 "glsl_lexer.lpp" +#line 331 "glsl_lexer.lpp" RESERVED_WORD(999, HVEC4); YY_BREAK -case 134: +case 140: YY_RULE_SETUP -#line 325 "glsl_lexer.lpp" +#line 332 "glsl_lexer.lpp" RESERVED_WORD(999, DVEC2); YY_BREAK -case 135: +case 141: YY_RULE_SETUP -#line 326 "glsl_lexer.lpp" +#line 333 "glsl_lexer.lpp" RESERVED_WORD(999, DVEC3); YY_BREAK -case 136: +case 142: YY_RULE_SETUP -#line 327 "glsl_lexer.lpp" +#line 334 "glsl_lexer.lpp" RESERVED_WORD(999, DVEC4); YY_BREAK -case 137: +case 143: YY_RULE_SETUP -#line 328 "glsl_lexer.lpp" +#line 335 "glsl_lexer.lpp" RESERVED_WORD(999, FVEC2); YY_BREAK -case 138: +case 144: YY_RULE_SETUP -#line 329 "glsl_lexer.lpp" +#line 336 "glsl_lexer.lpp" RESERVED_WORD(999, FVEC3); YY_BREAK -case 139: +case 145: YY_RULE_SETUP -#line 330 "glsl_lexer.lpp" +#line 337 "glsl_lexer.lpp" RESERVED_WORD(999, FVEC4); YY_BREAK -case 140: +case 146: YY_RULE_SETUP -#line 331 "glsl_lexer.lpp" +#line 338 "glsl_lexer.lpp" return SAMPLER2DRECT; YY_BREAK -case 141: +case 147: YY_RULE_SETUP -#line 332 "glsl_lexer.lpp" +#line 339 "glsl_lexer.lpp" RESERVED_WORD(999, SAMPLER3DRECT); YY_BREAK -case 142: +case 148: YY_RULE_SETUP -#line 333 "glsl_lexer.lpp" +#line 340 "glsl_lexer.lpp" return SAMPLER2DRECTSHADOW; YY_BREAK -case 143: +case 149: YY_RULE_SETUP -#line 334 "glsl_lexer.lpp" +#line 341 "glsl_lexer.lpp" RESERVED_WORD(999, SIZEOF); YY_BREAK -case 144: +case 150: YY_RULE_SETUP -#line 335 "glsl_lexer.lpp" +#line 342 "glsl_lexer.lpp" RESERVED_WORD(999, CAST); YY_BREAK -case 145: +case 151: YY_RULE_SETUP -#line 336 "glsl_lexer.lpp" +#line 343 "glsl_lexer.lpp" RESERVED_WORD(999, NAMESPACE); YY_BREAK -case 146: +case 152: YY_RULE_SETUP -#line 337 "glsl_lexer.lpp" +#line 344 "glsl_lexer.lpp" RESERVED_WORD(999, USING); YY_BREAK /* Additional reserved words in GLSL 1.20. */ -case 147: +case 153: YY_RULE_SETUP -#line 340 "glsl_lexer.lpp" +#line 347 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER_ES(120, LOWP); YY_BREAK -case 148: +case 154: YY_RULE_SETUP -#line 341 "glsl_lexer.lpp" +#line 348 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER_ES(120, MEDIUMP); YY_BREAK -case 149: +case 155: YY_RULE_SETUP -#line 342 "glsl_lexer.lpp" +#line 349 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER_ES(120, HIGHP); YY_BREAK -case 150: +case 156: YY_RULE_SETUP -#line 343 "glsl_lexer.lpp" +#line 350 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER_ES(120, PRECISION); YY_BREAK /* Additional reserved words in GLSL 1.30. */ -case 151: +case 157: YY_RULE_SETUP -#line 346 "glsl_lexer.lpp" +#line 353 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, COMMON); YY_BREAK -case 152: +case 158: YY_RULE_SETUP -#line 347 "glsl_lexer.lpp" +#line 354 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, PARTITION); YY_BREAK -case 153: +case 159: YY_RULE_SETUP -#line 348 "glsl_lexer.lpp" +#line 355 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, ACTIVE); YY_BREAK -case 154: +case 160: YY_RULE_SETUP -#line 349 "glsl_lexer.lpp" +#line 356 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER_ES(130, SUPERP); YY_BREAK -case 155: +case 161: YY_RULE_SETUP -#line 350 "glsl_lexer.lpp" +#line 357 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, SAMPLERBUFFER); YY_BREAK -case 156: +case 162: YY_RULE_SETUP -#line 351 "glsl_lexer.lpp" +#line 358 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, FILTER); YY_BREAK -case 157: +case 163: YY_RULE_SETUP -#line 352 "glsl_lexer.lpp" +#line 359 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE1D); YY_BREAK -case 158: +case 164: YY_RULE_SETUP -#line 353 "glsl_lexer.lpp" +#line 360 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE2D); YY_BREAK -case 159: +case 165: YY_RULE_SETUP -#line 354 "glsl_lexer.lpp" +#line 361 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE3D); YY_BREAK -case 160: +case 166: YY_RULE_SETUP -#line 355 "glsl_lexer.lpp" +#line 362 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGECUBE); YY_BREAK -case 161: +case 167: YY_RULE_SETUP -#line 356 "glsl_lexer.lpp" +#line 363 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGE1D); YY_BREAK -case 162: +case 168: YY_RULE_SETUP -#line 357 "glsl_lexer.lpp" +#line 364 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGE2D); YY_BREAK -case 163: +case 169: YY_RULE_SETUP -#line 358 "glsl_lexer.lpp" +#line 365 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGE3D); YY_BREAK -case 164: +case 170: YY_RULE_SETUP -#line 359 "glsl_lexer.lpp" +#line 366 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGECUBE); YY_BREAK -case 165: +case 171: YY_RULE_SETUP -#line 360 "glsl_lexer.lpp" +#line 367 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGE1D); YY_BREAK -case 166: +case 172: YY_RULE_SETUP -#line 361 "glsl_lexer.lpp" +#line 368 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGE2D); YY_BREAK -case 167: +case 173: YY_RULE_SETUP -#line 362 "glsl_lexer.lpp" +#line 369 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGE3D); YY_BREAK -case 168: +case 174: YY_RULE_SETUP -#line 363 "glsl_lexer.lpp" +#line 370 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGECUBE); YY_BREAK -case 169: +case 175: YY_RULE_SETUP -#line 364 "glsl_lexer.lpp" +#line 371 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE1DARRAY); YY_BREAK -case 170: +case 176: YY_RULE_SETUP -#line 365 "glsl_lexer.lpp" +#line 372 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE2DARRAY); YY_BREAK -case 171: +case 177: YY_RULE_SETUP -#line 366 "glsl_lexer.lpp" +#line 373 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGE1DARRAY); YY_BREAK -case 172: +case 178: YY_RULE_SETUP -#line 367 "glsl_lexer.lpp" +#line 374 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGE2DARRAY); YY_BREAK -case 173: +case 179: YY_RULE_SETUP -#line 368 "glsl_lexer.lpp" +#line 375 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGE1DARRAY); YY_BREAK -case 174: +case 180: YY_RULE_SETUP -#line 369 "glsl_lexer.lpp" +#line 376 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGE2DARRAY); YY_BREAK -case 175: +case 181: YY_RULE_SETUP -#line 370 "glsl_lexer.lpp" +#line 377 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE1DSHADOW); YY_BREAK -case 176: +case 182: YY_RULE_SETUP -#line 371 "glsl_lexer.lpp" +#line 378 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGE2DSHADOW); YY_BREAK -case 177: +case 183: YY_RULE_SETUP -#line 372 "glsl_lexer.lpp" +#line 379 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IMAGEBUFFER); YY_BREAK -case 178: +case 184: YY_RULE_SETUP -#line 373 "glsl_lexer.lpp" +#line 380 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, IIMAGEBUFFER); YY_BREAK -case 179: +case 185: YY_RULE_SETUP -#line 374 "glsl_lexer.lpp" +#line 381 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, UIMAGEBUFFER); YY_BREAK -case 180: +case 186: YY_RULE_SETUP -#line 375 "glsl_lexer.lpp" +#line 382 "glsl_lexer.lpp" TOKEN_OR_IDENTIFIER(130, ROW_MAJOR); YY_BREAK -case 181: +case 187: YY_RULE_SETUP -#line 377 "glsl_lexer.lpp" +#line 384 "glsl_lexer.lpp" { struct _mesa_glsl_parse_state *state = yyextra; void *ctx = state; @@ -2316,17 +2366,17 @@ YY_RULE_SETUP return IDENTIFIER; } YY_BREAK -case 182: +case 188: YY_RULE_SETUP -#line 384 "glsl_lexer.lpp" +#line 391 "glsl_lexer.lpp" { return yytext[0]; } YY_BREAK -case 183: +case 189: YY_RULE_SETUP -#line 386 "glsl_lexer.lpp" +#line 393 "glsl_lexer.lpp" ECHO; YY_BREAK -#line 2330 "glsl_lexer.cpp" +#line 2380 "glsl_lexer.cpp" case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(PP): case YY_STATE_EOF(PRAGMA): @@ -2624,7 +2674,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 708 ) + if ( yy_current_state >= 716 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -2653,11 +2703,11 @@ static int yy_get_next_buffer (yyscan_t yyscanner) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 708 ) + if ( yy_current_state >= 716 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; - yy_is_jam = (yy_current_state == 707); + yy_is_jam = (yy_current_state == 715); return yy_is_jam ? 0 : yy_current_state; } @@ -3062,8 +3112,8 @@ YY_BUFFER_STATE _mesa_glsl__scan_string (yyconst char * yystr , yyscan_t yyscann /** Setup the input buffer state to scan the given bytes. The next call to _mesa_glsl_lex() will * scan from a @e copy of @a bytes. - * @param bytes the byte buffer to scan - * @param len the number of bytes in the buffer pointed to by @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. * @param yyscanner The scanner object. * @return the newly allocated buffer state object. */ @@ -3469,7 +3519,7 @@ void _mesa_glsl_free (void * ptr , yyscan_t yyscanner) #define YYTABLES_NAME "yytables" -#line 386 "glsl_lexer.lpp" +#line 393 "glsl_lexer.lpp" diff --git a/src/glsl/glsl_lexer.lpp b/src/glsl/glsl_lexer.lpp index ed3cb251a1..c0778a656a 100644 --- a/src/glsl/glsl_lexer.lpp +++ b/src/glsl/glsl_lexer.lpp @@ -161,6 +161,7 @@ const return CONST_TOK; bool return BOOL_TOK; float return FLOAT_TOK; int return INT_TOK; +uint TOKEN_OR_IDENTIFIER(130, UINT_TOK); break return BREAK; continue return CONTINUE; @@ -178,6 +179,9 @@ bvec4 return BVEC4; ivec2 return IVEC2; ivec3 return IVEC3; ivec4 return IVEC4; +uvec2 TOKEN_OR_IDENTIFIER(130, UVEC2); +uvec3 TOKEN_OR_IDENTIFIER(130, UVEC3); +uvec4 TOKEN_OR_IDENTIFIER(130, UVEC4); vec2 return VEC2; vec3 return VEC3; vec4 return VEC4; @@ -218,6 +222,7 @@ void return VOID_TOK; layout { if ((yyextra->language_version >= 140) + || yyextra->ARB_explicit_attrib_location_enable || (yyextra->ARB_fragment_coord_conventions_enable)){ return LAYOUT_TOK; } else { @@ -235,6 +240,8 @@ layout { && return AND_OP; \|\| return OR_OP; "^^" return XOR_OP; +"<<" return LEFT_OP; +">>" return RIGHT_OP; \*= return MUL_ASSIGN; \/= return DIV_ASSIGN; diff --git a/src/glsl/glsl_parser.cpp b/src/glsl/glsl_parser.cpp index 301c221892..c876f39e4e 100644 --- a/src/glsl/glsl_parser.cpp +++ b/src/glsl/glsl_parser.cpp @@ -1,9 +1,10 @@ -/* A Bison parser, made by GNU Bison 2.4.3. */ + +/* A Bison parser, made by GNU Bison 2.4.1. */ /* Skeleton implementation for Bison's Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - 2009, 2010 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -45,7 +46,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.4.3" +#define YYBISON_VERSION "2.4.1" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -113,7 +114,7 @@ /* Line 189 of yacc.c */ -#line 117 "glsl_parser.cpp" +#line 118 "glsl_parser.cpp" /* Enabling traces. */ #ifndef YYDEBUG @@ -344,10 +345,7 @@ typedef union YYSTYPE float real; char *identifier; - union { - struct ast_type_qualifier q; - unsigned i; - } type_qualifier; + struct ast_type_qualifier type_qualifier; ast_node *node; ast_type_specifier *type_specifier; @@ -374,7 +372,7 @@ typedef union YYSTYPE /* Line 214 of yacc.c */ -#line 378 "glsl_parser.cpp" +#line 376 "glsl_parser.cpp" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ @@ -399,7 +397,7 @@ typedef struct YYLTYPE /* Line 264 of yacc.c */ -#line 403 "glsl_parser.cpp" +#line 401 "glsl_parser.cpp" #ifdef short # undef short @@ -449,7 +447,7 @@ typedef short int yytype_int16; #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ -# if defined YYENABLE_NLS && YYENABLE_NLS +# if YYENABLE_NLS # if ENABLE_NLS # include <libintl.h> /* INFRINGES ON USER NAME SPACE */ # define YY_(msgid) dgettext ("bison-runtime", msgid) @@ -616,16 +614,16 @@ union yyalloc /* YYFINAL -- State number of the termination state. */ #define YYFINAL 5 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 4005 +#define YYLAST 3692 /* YYNTOKENS -- Number of terminals. */ #define YYNTOKENS 215 /* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 88 +#define YYNNTS 87 /* YYNRULES -- Number of rules. */ -#define YYNRULES 274 +#define YYNRULES 278 /* YYNRULES -- Number of states. */ -#define YYNSTATES 409 +#define YYNSTATES 413 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 @@ -702,21 +700,21 @@ static const yytype_uint16 yyprhs[] = 280, 285, 288, 290, 292, 295, 299, 303, 306, 312, 316, 319, 323, 326, 327, 329, 331, 333, 335, 337, 341, 347, 354, 362, 371, 377, 379, 382, 387, 393, - 400, 408, 413, 416, 418, 421, 422, 424, 429, 431, - 435, 437, 439, 441, 443, 445, 447, 450, 453, 455, - 457, 460, 463, 466, 468, 471, 474, 476, 478, 481, - 483, 487, 492, 494, 496, 498, 500, 502, 504, 506, - 508, 510, 512, 514, 516, 518, 520, 522, 524, 526, - 528, 530, 532, 534, 536, 538, 540, 542, 544, 546, - 548, 550, 552, 554, 556, 558, 560, 562, 564, 566, - 568, 570, 572, 574, 576, 578, 580, 582, 584, 586, - 588, 590, 592, 594, 596, 598, 600, 602, 604, 606, - 612, 617, 619, 622, 626, 628, 632, 634, 639, 641, - 643, 645, 647, 649, 651, 653, 655, 657, 659, 661, - 664, 668, 670, 672, 675, 679, 681, 684, 686, 689, - 695, 699, 701, 703, 708, 714, 718, 721, 727, 735, - 742, 744, 746, 748, 749, 752, 756, 759, 762, 765, - 769, 772, 774, 776, 778 + 400, 408, 413, 416, 418, 421, 426, 428, 432, 434, + 438, 440, 442, 444, 446, 448, 450, 453, 455, 458, + 461, 465, 467, 469, 471, 473, 476, 478, 480, 483, + 486, 488, 490, 493, 495, 499, 504, 506, 508, 510, + 512, 514, 516, 518, 520, 522, 524, 526, 528, 530, + 532, 534, 536, 538, 540, 542, 544, 546, 548, 550, + 552, 554, 556, 558, 560, 562, 564, 566, 568, 570, + 572, 574, 576, 578, 580, 582, 584, 586, 588, 590, + 592, 594, 596, 598, 600, 602, 604, 606, 608, 610, + 612, 614, 616, 618, 624, 629, 631, 634, 638, 640, + 644, 646, 651, 653, 655, 657, 659, 661, 663, 665, + 667, 669, 671, 673, 676, 680, 682, 684, 687, 691, + 693, 696, 698, 701, 707, 711, 713, 715, 720, 726, + 730, 733, 739, 747, 754, 756, 758, 760, 761, 764, + 768, 771, 774, 777, 781, 784, 786, 788, 790 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ @@ -725,14 +723,14 @@ static const yytype_int16 yyrhs[] = 216, 0, -1, -1, 218, 220, 217, 222, -1, -1, 109, 78, 113, -1, 116, 113, -1, 117, 113, -1, 118, 113, -1, 119, 113, -1, -1, 220, 221, -1, - 110, 76, 112, 76, 113, -1, 301, -1, 222, 301, + 110, 76, 112, 76, 113, -1, 300, -1, 222, 300, -1, 76, -1, 223, -1, 78, -1, 79, -1, 77, -1, 80, -1, 191, 250, 192, -1, 224, -1, 225, 193, 226, 194, -1, 227, -1, 225, 195, 76, -1, 225, 84, -1, 225, 85, -1, 250, -1, 228, -1, 229, -1, 225, 195, 229, -1, 231, 192, -1, 230, 192, -1, 232, 74, -1, 232, -1, 232, 248, -1, - 231, 196, 248, -1, 233, 191, -1, 272, -1, 76, + 231, 196, 248, -1, 233, 191, -1, 271, -1, 76, -1, 81, -1, 225, -1, 84, 234, -1, 85, 234, -1, 235, 234, -1, 197, -1, 198, -1, 199, -1, 200, -1, 234, -1, 236, 201, 234, -1, 236, 202, @@ -750,90 +748,91 @@ static const yytype_int16 yyrhs[] = 96, -1, 95, -1, 102, -1, 97, -1, 98, -1, 99, -1, 100, -1, 101, -1, 248, -1, 250, 196, 248, -1, 247, -1, 253, 212, -1, 261, 212, -1, - 108, 276, 273, 212, -1, 254, 192, -1, 256, -1, + 108, 275, 272, 212, -1, 254, 192, -1, 256, -1, 255, -1, 256, 258, -1, 255, 196, 258, -1, 263, - 76, 191, -1, 272, 76, -1, 272, 76, 193, 251, - 194, -1, 269, 259, 257, -1, 259, 257, -1, 269, + 76, 191, -1, 271, 76, -1, 271, 76, 193, 251, + 194, -1, 268, 259, 257, -1, 259, 257, -1, 268, 259, 260, -1, 259, 260, -1, -1, 33, -1, 34, - -1, 35, -1, 272, -1, 262, -1, 261, 196, 76, + -1, 35, -1, 271, -1, 262, -1, 261, 196, 76, -1, 261, 196, 76, 193, 194, -1, 261, 196, 76, 193, 251, 194, -1, 261, 196, 76, 193, 194, 211, - 282, -1, 261, 196, 76, 193, 251, 194, 211, 282, - -1, 261, 196, 76, 211, 282, -1, 263, -1, 263, + 281, -1, 261, 196, 76, 193, 251, 194, 211, 281, + -1, 261, 196, 76, 211, 281, -1, 263, -1, 263, 76, -1, 263, 76, 193, 194, -1, 263, 76, 193, - 251, 194, -1, 263, 76, 193, 194, 211, 282, -1, - 263, 76, 193, 251, 194, 211, 282, -1, 263, 76, - 211, 282, -1, 103, 76, -1, 272, -1, 270, 272, - -1, -1, 265, -1, 120, 191, 266, 192, -1, 267, - -1, 266, 196, 267, -1, 76, -1, 40, -1, 39, - -1, 38, -1, 4, -1, 271, -1, 268, 270, -1, - 103, 270, -1, 4, -1, 3, -1, 264, 37, -1, - 32, 37, -1, 264, 33, -1, 34, -1, 32, 33, - -1, 32, 34, -1, 36, -1, 273, -1, 276, 273, - -1, 274, -1, 274, 193, 194, -1, 274, 193, 251, - 194, -1, 275, -1, 277, -1, 76, -1, 74, -1, - 6, -1, 7, -1, 8, -1, 5, -1, 29, -1, - 30, -1, 31, -1, 20, -1, 21, -1, 22, -1, - 23, -1, 24, -1, 25, -1, 26, -1, 27, -1, - 28, -1, 41, -1, 42, -1, 43, -1, 44, -1, - 45, -1, 46, -1, 47, -1, 48, -1, 49, -1, - 50, -1, 51, -1, 154, -1, 52, -1, 53, -1, - 54, -1, 55, -1, 156, -1, 56, -1, 57, -1, - 58, -1, 59, -1, 60, -1, 61, -1, 62, -1, - 63, -1, 64, -1, 65, -1, 66, -1, 67, -1, - 68, -1, 69, -1, 70, -1, 71, -1, 72, -1, - 106, -1, 105, -1, 104, -1, 73, 76, 213, 278, - 214, -1, 73, 213, 278, 214, -1, 279, -1, 278, - 279, -1, 272, 280, 212, -1, 281, -1, 280, 196, - 281, -1, 76, -1, 76, 193, 251, 194, -1, 248, - -1, 252, -1, 286, -1, 285, -1, 283, -1, 290, - -1, 291, -1, 294, -1, 295, -1, 296, -1, 300, - -1, 213, 214, -1, 213, 289, 214, -1, 288, -1, - 285, -1, 213, 214, -1, 213, 289, 214, -1, 284, - -1, 289, 284, -1, 212, -1, 250, 212, -1, 14, - 191, 250, 192, 292, -1, 284, 12, 284, -1, 284, - -1, 250, -1, 263, 76, 211, 282, -1, 17, 191, - 250, 192, 286, -1, 18, 250, 210, -1, 19, 210, - -1, 75, 191, 293, 192, 287, -1, 11, 284, 75, - 191, 250, 192, 212, -1, 13, 191, 297, 299, 192, - 287, -1, 290, -1, 283, -1, 293, -1, -1, 298, - 212, -1, 298, 212, 250, -1, 10, 212, -1, 9, - 212, -1, 16, 212, -1, 16, 250, 212, -1, 15, - 212, -1, 302, -1, 252, -1, 219, -1, 253, 288, - -1 + 251, 194, -1, 263, 76, 193, 194, 211, 281, -1, + 263, 76, 193, 251, 194, 211, 281, -1, 263, 76, + 211, 281, -1, 103, 76, -1, 271, -1, 269, 271, + -1, 120, 191, 265, 192, -1, 266, -1, 265, 196, + 266, -1, 76, -1, 76, 211, 78, -1, 40, -1, + 39, -1, 38, -1, 4, -1, 270, -1, 264, -1, + 264, 270, -1, 267, -1, 267, 270, -1, 103, 270, + -1, 103, 267, 270, -1, 103, -1, 4, -1, 3, + -1, 37, -1, 32, 37, -1, 33, -1, 34, -1, + 32, 33, -1, 32, 34, -1, 36, -1, 272, -1, + 275, 272, -1, 273, -1, 273, 193, 194, -1, 273, + 193, 251, 194, -1, 274, -1, 276, -1, 76, -1, + 74, -1, 6, -1, 7, -1, 8, -1, 5, -1, + 29, -1, 30, -1, 31, -1, 20, -1, 21, -1, + 22, -1, 23, -1, 24, -1, 25, -1, 26, -1, + 27, -1, 28, -1, 41, -1, 42, -1, 43, -1, + 44, -1, 45, -1, 46, -1, 47, -1, 48, -1, + 49, -1, 50, -1, 51, -1, 154, -1, 52, -1, + 53, -1, 54, -1, 55, -1, 156, -1, 56, -1, + 57, -1, 58, -1, 59, -1, 60, -1, 61, -1, + 62, -1, 63, -1, 64, -1, 65, -1, 66, -1, + 67, -1, 68, -1, 69, -1, 70, -1, 71, -1, + 72, -1, 106, -1, 105, -1, 104, -1, 73, 76, + 213, 277, 214, -1, 73, 213, 277, 214, -1, 278, + -1, 277, 278, -1, 271, 279, 212, -1, 280, -1, + 279, 196, 280, -1, 76, -1, 76, 193, 251, 194, + -1, 248, -1, 252, -1, 285, -1, 284, -1, 282, + -1, 289, -1, 290, -1, 293, -1, 294, -1, 295, + -1, 299, -1, 213, 214, -1, 213, 288, 214, -1, + 287, -1, 284, -1, 213, 214, -1, 213, 288, 214, + -1, 283, -1, 288, 283, -1, 212, -1, 250, 212, + -1, 14, 191, 250, 192, 291, -1, 283, 12, 283, + -1, 283, -1, 250, -1, 263, 76, 211, 281, -1, + 17, 191, 250, 192, 285, -1, 18, 250, 210, -1, + 19, 210, -1, 75, 191, 292, 192, 286, -1, 11, + 283, 75, 191, 250, 192, 212, -1, 13, 191, 296, + 298, 192, 286, -1, 289, -1, 282, -1, 292, -1, + -1, 297, 212, -1, 297, 212, 250, -1, 10, 212, + -1, 9, 212, -1, 16, 212, -1, 16, 250, 212, + -1, 15, 212, -1, 301, -1, 252, -1, 219, -1, + 253, 287, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 214, 214, 213, 220, 222, 242, 243, 244, 245, - 248, 250, 254, 263, 271, 282, 286, 293, 300, 307, - 314, 321, 328, 329, 335, 339, 346, 352, 361, 365, - 369, 370, 379, 380, 384, 385, 389, 395, 407, 411, - 417, 424, 435, 436, 442, 448, 458, 459, 460, 461, - 465, 466, 472, 478, 487, 488, 494, 503, 504, 510, - 519, 520, 526, 532, 538, 547, 548, 554, 563, 564, - 573, 574, 583, 584, 593, 594, 603, 604, 613, 614, - 623, 624, 633, 634, 643, 644, 645, 646, 647, 648, - 649, 650, 651, 652, 653, 657, 661, 677, 681, 685, - 689, 703, 707, 708, 712, 717, 725, 736, 746, 761, - 768, 773, 784, 796, 797, 798, 799, 803, 807, 808, - 817, 826, 835, 844, 853, 866, 877, 886, 895, 904, - 913, 922, 931, 945, 952, 963, 964, 968, 975, 976, - 983, 1017, 1018, 1019, 1023, 1027, 1028, 1032, 1040, 1041, - 1042, 1043, 1044, 1045, 1046, 1047, 1048, 1052, 1053, 1061, - 1062, 1068, 1077, 1083, 1089, 1098, 1099, 1100, 1101, 1102, - 1103, 1104, 1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, - 1113, 1114, 1115, 1116, 1117, 1118, 1119, 1120, 1121, 1122, - 1123, 1124, 1125, 1126, 1127, 1128, 1129, 1130, 1131, 1132, - 1133, 1134, 1135, 1136, 1137, 1138, 1139, 1140, 1141, 1142, - 1143, 1144, 1145, 1146, 1147, 1148, 1152, 1163, 1174, 1188, - 1194, 1203, 1208, 1216, 1231, 1236, 1244, 1250, 1259, 1263, - 1269, 1270, 1274, 1275, 1276, 1277, 1278, 1279, 1280, 1284, - 1290, 1299, 1300, 1304, 1310, 1319, 1329, 1341, 1347, 1356, - 1365, 1370, 1378, 1382, 1396, 1400, 1401, 1405, 1412, 1419, - 1429, 1430, 1434, 1436, 1442, 1447, 1456, 1462, 1468, 1474, - 1480, 1489, 1490, 1491, 1495 + 0, 211, 211, 210, 217, 219, 239, 240, 241, 242, + 245, 247, 251, 260, 268, 279, 283, 290, 297, 304, + 311, 318, 325, 326, 332, 336, 343, 349, 358, 362, + 366, 367, 376, 377, 381, 382, 386, 392, 404, 408, + 414, 421, 432, 433, 439, 445, 455, 456, 457, 458, + 462, 463, 469, 475, 484, 485, 491, 500, 501, 507, + 516, 517, 523, 529, 535, 544, 545, 551, 560, 561, + 570, 571, 580, 581, 590, 591, 600, 601, 610, 611, + 620, 621, 630, 631, 640, 641, 642, 643, 644, 645, + 646, 647, 648, 649, 650, 654, 658, 674, 678, 682, + 686, 700, 704, 705, 709, 714, 722, 733, 743, 758, + 765, 770, 781, 794, 797, 802, 807, 816, 820, 821, + 830, 839, 848, 857, 866, 879, 890, 899, 908, 917, + 926, 935, 944, 958, 965, 976, 983, 984, 1003, 1032, + 1073, 1078, 1083, 1091, 1099, 1100, 1101, 1106, 1107, 1112, + 1117, 1123, 1131, 1136, 1141, 1146, 1152, 1157, 1162, 1167, + 1172, 1180, 1181, 1189, 1190, 1196, 1205, 1211, 1217, 1226, + 1227, 1228, 1229, 1230, 1231, 1232, 1233, 1234, 1235, 1236, + 1237, 1238, 1239, 1240, 1241, 1242, 1243, 1244, 1245, 1246, + 1247, 1248, 1249, 1250, 1251, 1252, 1253, 1254, 1255, 1256, + 1257, 1258, 1259, 1260, 1261, 1262, 1263, 1264, 1265, 1266, + 1267, 1268, 1269, 1270, 1271, 1272, 1273, 1274, 1275, 1276, + 1280, 1291, 1302, 1316, 1322, 1331, 1336, 1344, 1359, 1364, + 1372, 1378, 1387, 1391, 1397, 1398, 1402, 1403, 1404, 1405, + 1406, 1407, 1408, 1412, 1418, 1427, 1428, 1432, 1438, 1447, + 1457, 1469, 1475, 1484, 1493, 1498, 1506, 1510, 1524, 1528, + 1529, 1533, 1540, 1547, 1557, 1558, 1562, 1564, 1570, 1575, + 1584, 1590, 1596, 1602, 1608, 1617, 1618, 1619, 1623 }; #endif @@ -899,14 +898,13 @@ static const char *const yytname[] = "function_header", "parameter_declarator", "parameter_declaration", "parameter_qualifier", "parameter_type_specifier", "init_declarator_list", "single_declaration", "fully_specified_type", - "opt_layout_qualifier", "layout_qualifier", "layout_qualifier_id_list", - "layout_qualifier_id", "interpolation_qualifier", - "parameter_type_qualifier", "type_qualifier", "storage_qualifier", - "type_specifier", "type_specifier_no_prec", "type_specifier_nonarray", - "basic_type_specifier_nonarray", "precision_qualifier", - "struct_specifier", "struct_declaration_list", "struct_declaration", - "struct_declarator_list", "struct_declarator", "initializer", - "declaration_statement", "statement", "simple_statement", + "layout_qualifier", "layout_qualifier_id_list", "layout_qualifier_id", + "interpolation_qualifier", "parameter_type_qualifier", "type_qualifier", + "storage_qualifier", "type_specifier", "type_specifier_no_prec", + "type_specifier_nonarray", "basic_type_specifier_nonarray", + "precision_qualifier", "struct_specifier", "struct_declaration_list", + "struct_declaration", "struct_declarator_list", "struct_declarator", + "initializer", "declaration_statement", "statement", "simple_statement", "compound_statement", "statement_no_new_scope", "compound_statement_no_new_scope", "statement_list", "expression_statement", "selection_statement", @@ -963,21 +961,21 @@ static const yytype_uint16 yyr1[] = 252, 253, 254, 254, 255, 255, 256, 257, 257, 258, 258, 258, 258, 259, 259, 259, 259, 260, 261, 261, 261, 261, 261, 261, 261, 262, 262, 262, 262, 262, - 262, 262, 262, 263, 263, 264, 264, 265, 266, 266, - 267, 268, 268, 268, 269, 270, 270, 270, 271, 271, - 271, 271, 271, 271, 271, 271, 271, 272, 272, 273, - 273, 273, 274, 274, 274, 275, 275, 275, 275, 275, - 275, 275, 275, 275, 275, 275, 275, 275, 275, 275, - 275, 275, 275, 275, 275, 275, 275, 275, 275, 275, - 275, 275, 275, 275, 275, 275, 275, 275, 275, 275, - 275, 275, 275, 275, 275, 275, 275, 275, 275, 275, - 275, 275, 275, 275, 275, 275, 276, 276, 276, 277, - 277, 278, 278, 279, 280, 280, 281, 281, 282, 283, - 284, 284, 285, 285, 285, 285, 285, 285, 285, 286, - 286, 287, 287, 288, 288, 289, 289, 290, 290, 291, - 292, 292, 293, 293, 294, 295, 295, 296, 296, 296, - 297, 297, 298, 298, 299, 299, 300, 300, 300, 300, - 300, 301, 301, 301, 302 + 262, 262, 262, 263, 263, 264, 265, 265, 266, 266, + 267, 267, 267, 268, 269, 269, 269, 269, 269, 269, + 269, 269, 270, 270, 270, 270, 270, 270, 270, 270, + 270, 271, 271, 272, 272, 272, 273, 273, 273, 274, + 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, + 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, + 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, + 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, + 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, + 275, 275, 275, 276, 276, 277, 277, 278, 279, 279, + 280, 280, 281, 282, 283, 283, 284, 284, 284, 284, + 284, 284, 284, 285, 285, 286, 286, 287, 287, 288, + 288, 289, 289, 290, 291, 291, 292, 292, 293, 294, + 294, 295, 295, 295, 296, 296, 297, 297, 298, 298, + 299, 299, 299, 299, 299, 300, 300, 300, 301 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ @@ -996,21 +994,21 @@ static const yytype_uint8 yyr2[] = 4, 2, 1, 1, 2, 3, 3, 2, 5, 3, 2, 3, 2, 0, 1, 1, 1, 1, 1, 3, 5, 6, 7, 8, 5, 1, 2, 4, 5, 6, - 7, 4, 2, 1, 2, 0, 1, 4, 1, 3, - 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, - 2, 2, 2, 1, 2, 2, 1, 1, 2, 1, - 3, 4, 1, 1, 1, 1, 1, 1, 1, 1, + 7, 4, 2, 1, 2, 4, 1, 3, 1, 3, + 1, 1, 1, 1, 1, 1, 2, 1, 2, 2, + 3, 1, 1, 1, 1, 2, 1, 1, 2, 2, + 1, 1, 2, 1, 3, 4, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, - 4, 1, 2, 3, 1, 3, 1, 4, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, - 3, 1, 1, 2, 3, 1, 2, 1, 2, 5, - 3, 1, 1, 4, 5, 3, 2, 5, 7, 6, - 1, 1, 1, 0, 2, 3, 2, 2, 2, 3, - 2, 1, 1, 1, 2 + 1, 1, 1, 5, 4, 1, 2, 3, 1, 3, + 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 2, 3, 1, 1, 2, 3, 1, + 2, 1, 2, 5, 3, 1, 1, 4, 5, 3, + 2, 5, 7, 6, 1, 1, 1, 0, 2, 3, + 2, 2, 2, 3, 2, 1, 1, 1, 2 }; /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state @@ -1018,622 +1016,551 @@ static const yytype_uint8 yyr2[] = means the default is an error. */ static const yytype_uint16 yydefact[] = { - 4, 0, 0, 10, 0, 1, 2, 5, 0, 135, - 11, 0, 149, 148, 169, 166, 167, 168, 173, 174, - 175, 176, 177, 178, 179, 180, 181, 170, 171, 172, - 0, 153, 156, 143, 142, 141, 182, 183, 184, 185, - 186, 187, 188, 189, 190, 191, 192, 194, 195, 196, - 197, 199, 200, 201, 202, 203, 204, 205, 206, 207, - 208, 209, 210, 211, 212, 213, 214, 215, 0, 165, - 164, 135, 218, 217, 216, 0, 0, 0, 0, 0, - 0, 193, 198, 273, 135, 272, 0, 0, 103, 113, - 0, 118, 125, 0, 136, 135, 0, 145, 133, 157, - 159, 162, 0, 163, 13, 271, 0, 154, 155, 151, - 0, 0, 132, 135, 147, 0, 6, 7, 8, 9, - 0, 14, 98, 135, 274, 101, 113, 144, 114, 115, - 116, 104, 0, 113, 0, 99, 126, 152, 150, 146, - 134, 0, 158, 0, 0, 0, 0, 221, 0, 140, - 0, 138, 0, 0, 135, 0, 0, 0, 0, 0, - 0, 0, 0, 15, 19, 17, 18, 20, 41, 0, - 0, 0, 46, 47, 48, 49, 247, 135, 243, 16, - 22, 42, 24, 29, 30, 0, 0, 35, 0, 50, - 0, 54, 57, 60, 65, 68, 70, 72, 74, 76, - 78, 80, 82, 95, 0, 229, 0, 133, 232, 245, - 231, 230, 135, 233, 234, 235, 236, 237, 238, 105, - 110, 112, 117, 0, 119, 106, 0, 0, 160, 50, - 97, 0, 39, 12, 0, 226, 0, 224, 220, 222, - 100, 137, 0, 267, 266, 0, 135, 0, 270, 268, - 0, 0, 0, 256, 135, 43, 44, 0, 239, 135, - 26, 27, 0, 0, 33, 32, 0, 165, 36, 38, - 85, 86, 88, 87, 90, 91, 92, 93, 94, 89, - 84, 0, 45, 0, 0, 0, 0, 0, 0, 0, + 4, 0, 0, 10, 0, 1, 2, 5, 0, 0, + 11, 0, 153, 152, 173, 170, 171, 172, 177, 178, + 179, 180, 181, 182, 183, 184, 185, 174, 175, 176, + 0, 156, 157, 160, 154, 142, 141, 140, 186, 187, + 188, 189, 190, 191, 192, 193, 194, 195, 196, 198, + 199, 200, 201, 203, 204, 205, 206, 207, 208, 209, + 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, + 0, 169, 168, 151, 222, 221, 220, 0, 0, 0, + 0, 0, 0, 197, 202, 277, 3, 276, 0, 0, + 103, 113, 0, 118, 125, 145, 147, 0, 144, 133, + 161, 163, 166, 0, 167, 13, 275, 0, 158, 159, + 155, 0, 0, 132, 0, 149, 0, 6, 7, 8, + 9, 0, 14, 98, 0, 278, 101, 113, 143, 114, + 115, 116, 104, 0, 113, 0, 99, 126, 146, 148, + 134, 0, 162, 0, 0, 0, 0, 225, 150, 0, + 138, 0, 136, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 15, 19, 17, 18, 20, 41, + 0, 0, 0, 46, 47, 48, 49, 251, 0, 247, + 16, 22, 42, 24, 29, 30, 0, 0, 35, 0, + 50, 0, 54, 57, 60, 65, 68, 70, 72, 74, + 76, 78, 80, 82, 95, 0, 233, 0, 133, 236, + 249, 235, 234, 0, 237, 238, 239, 240, 241, 242, + 105, 110, 112, 117, 0, 119, 106, 0, 0, 164, + 50, 97, 0, 39, 12, 0, 230, 0, 228, 224, + 226, 100, 0, 135, 0, 271, 270, 0, 0, 0, + 274, 272, 0, 0, 0, 260, 0, 43, 44, 0, + 243, 0, 26, 27, 0, 0, 33, 32, 0, 169, + 36, 38, 85, 86, 88, 87, 90, 91, 92, 93, + 94, 89, 84, 0, 45, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 248, 244, 246, 107, 109, 111, - 0, 0, 127, 0, 228, 131, 161, 219, 0, 0, - 223, 139, 0, 261, 260, 135, 0, 269, 0, 255, - 252, 0, 0, 21, 240, 0, 28, 25, 31, 37, - 83, 51, 52, 53, 55, 56, 58, 59, 63, 64, - 61, 62, 66, 67, 69, 71, 73, 75, 77, 79, - 0, 96, 0, 120, 0, 124, 0, 128, 0, 225, - 0, 262, 0, 0, 135, 0, 0, 135, 23, 0, - 0, 0, 121, 129, 0, 227, 0, 264, 135, 251, - 249, 254, 0, 242, 257, 241, 81, 108, 122, 0, - 130, 0, 265, 259, 135, 253, 123, 258, 250 + 0, 0, 0, 0, 0, 0, 252, 248, 250, 107, + 109, 111, 0, 0, 127, 0, 232, 131, 165, 223, + 0, 0, 227, 139, 137, 0, 265, 264, 267, 0, + 273, 0, 259, 151, 256, 0, 0, 21, 244, 0, + 28, 25, 31, 37, 83, 51, 52, 53, 55, 56, + 58, 59, 63, 64, 61, 62, 66, 67, 69, 71, + 73, 75, 77, 79, 0, 96, 0, 120, 0, 124, + 0, 128, 0, 229, 0, 266, 0, 0, 0, 0, + 0, 0, 23, 0, 0, 0, 121, 129, 0, 231, + 0, 268, 0, 255, 253, 258, 0, 246, 261, 245, + 81, 108, 122, 0, 130, 0, 269, 263, 0, 257, + 123, 262, 254 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { - -1, 2, 9, 3, 83, 6, 10, 84, 179, 180, - 181, 335, 182, 183, 184, 185, 186, 187, 188, 189, - 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, - 200, 201, 202, 203, 281, 204, 231, 205, 206, 87, - 88, 89, 220, 131, 132, 221, 90, 91, 92, 93, - 94, 150, 151, 95, 133, 96, 97, 232, 99, 100, - 101, 102, 103, 146, 147, 236, 237, 315, 208, 209, - 210, 211, 394, 395, 212, 213, 214, 390, 332, 215, - 216, 217, 325, 372, 373, 218, 104, 105 + -1, 2, 9, 3, 85, 6, 10, 86, 180, 181, + 182, 339, 183, 184, 185, 186, 187, 188, 189, 190, + 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, + 201, 202, 203, 204, 283, 205, 232, 206, 207, 89, + 90, 91, 221, 132, 133, 222, 92, 93, 94, 95, + 151, 152, 96, 134, 97, 98, 233, 100, 101, 102, + 103, 104, 146, 147, 237, 238, 317, 209, 210, 211, + 212, 398, 399, 213, 214, 215, 394, 336, 216, 217, + 218, 328, 376, 377, 219, 105, 106 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ -#define YYPACT_NINF -329 +#define YYPACT_NINF -360 static const yytype_int16 yypact[] = { - -58, -22, 72, -329, -28, -329, -15, -329, 22, 3589, - -329, -4, -329, -329, -329, -329, -329, -329, -329, -329, - -329, -329, -329, -329, -329, -329, -329, -329, -329, -329, - 44, -329, -329, -329, -329, -329, -329, -329, -329, -329, - -329, -329, -329, -329, -329, -329, -329, -329, -329, -329, - -329, -329, -329, -329, -329, -329, -329, -329, -329, -329, - -329, -329, -329, -329, -329, -329, -329, -329, -72, -329, - -329, 6, -329, -329, -329, 14, -8, 9, 11, 26, - -64, -329, -329, -329, 3470, -329, -159, -23, -12, -2, - -149, -329, 105, 57, -329, 140, 3777, -329, -329, -329, - 15, -329, 3849, -329, -329, -329, 131, -329, -329, -329, - -3, 3777, -329, 140, -329, 3849, -329, -329, -329, -329, - 133, -329, -329, 383, -329, -329, 32, -329, -329, -329, - -329, -329, 3777, 158, 135, -329, -150, -329, -329, -329, - -329, 2565, -329, 100, 3777, 141, 1954, -329, 4, -329, - -95, -329, 7, 8, 1231, 27, 31, 12, 2186, 37, - 3108, 13, 39, -59, -329, -329, -329, -329, -329, 3108, - 3108, 3108, -329, -329, -329, -329, -329, 595, -329, -329, - -329, -55, -329, -329, -329, 41, -92, 3289, 40, -75, - 3108, -7, -118, 51, -74, 109, 28, 29, 30, 145, - 147, -84, -329, -329, -148, -329, 34, 49, -329, -329, - -329, -329, 807, -329, -329, -329, -329, -329, -329, -329, - -329, -329, 166, 3777, -143, -329, 2746, 3108, -329, -329, - -329, 53, -329, -329, 2070, 55, -139, -329, -329, -329, - -329, -329, 133, -329, -329, 174, 1640, 3108, -329, -329, - -138, 3108, -134, -329, 2384, -329, -329, -81, -329, 1019, - -329, -329, 3108, 3705, -329, -329, 3108, 61, -329, -329, - -329, -329, -329, -329, -329, -329, -329, -329, -329, -329, - -329, 3108, -329, 3108, 3108, 3108, 3108, 3108, 3108, 3108, - 3108, 3108, 3108, 3108, 3108, 3108, 3108, 3108, 3108, 3108, - 3108, 3108, 3108, 3108, -329, -329, -329, 62, -329, -329, - 2927, 3108, 43, 63, -329, -329, -329, -329, 3108, 141, - -329, -329, 65, -329, -329, 1838, -80, -329, -79, -329, - 66, 182, 69, -329, -329, 70, 66, 74, -329, -329, - -329, -329, -329, -329, -7, -7, -118, -118, 51, 51, - 51, 51, -74, -74, 109, 28, 29, 30, 145, 147, - -127, -329, 3108, 52, 75, -329, 3108, 59, 77, -329, - 3108, -329, 54, 76, 1231, 60, 64, 1442, -329, 3108, - 78, 3108, 67, -329, 3108, -329, -50, 3108, 1442, 262, - -329, -329, 3108, -329, -329, -329, -329, -329, -329, 3108, - -329, 71, 66, -329, 1231, -329, -329, -329, -329 + -54, -53, 37, -360, -26, -360, -5, -360, 73, 3276, + -360, 63, -360, -360, -360, -360, -360, -360, -360, -360, + -360, -360, -360, -360, -360, -360, -360, -360, -360, -360, + 105, -360, -360, -360, -360, -360, -360, -360, -360, -360, + -360, -360, -360, -360, -360, -360, -360, -360, -360, -360, + -360, -360, -360, -360, -360, -360, -360, -360, -360, -360, + -360, -360, -360, -360, -360, -360, -360, -360, -360, -360, + -69, -360, -360, 42, -360, -360, -360, -74, 65, 79, + 83, 85, 16, -360, -360, -360, 3276, -360, -99, 9, + 13, 5, -152, -360, 134, 17, 17, 3464, -360, -360, + -360, 18, -360, 3536, -360, -360, -360, 136, -360, -360, + -360, 0, 3464, -360, 17, -360, 3536, -360, -360, -360, + -360, 138, -360, -360, 387, -360, -360, 24, -360, -360, + -360, -360, -360, 3464, 149, 141, -360, -150, -360, -360, + -360, 2371, -360, 106, 3464, 144, 1760, -360, -360, 11, + 14, -144, -360, 12, 20, 1235, 30, 31, 22, 1992, + 38, 2914, 26, 46, -59, -360, -360, -360, -360, -360, + 2914, 2914, 2914, -360, -360, -360, -360, -360, 599, -360, + -360, -360, -70, -360, -360, -360, 36, -56, 3095, 47, + -30, 2914, -8, -113, 39, -76, 45, 34, 23, 35, + 154, 153, -79, -360, -360, -123, -360, 41, 55, -360, + -360, -360, -360, 811, -360, -360, -360, -360, -360, -360, + -360, -360, -360, 172, 3464, -164, -360, 2552, 2914, -360, + -360, -360, 56, -360, -360, 1876, 58, -110, -360, -360, + -360, -360, 171, -360, 138, -360, -360, 179, 1644, 2914, + -360, -360, -101, 2914, -90, -360, 2190, -360, -360, -51, + -360, 1023, -360, -360, 2914, 3392, -360, -360, 2914, 64, + -360, -360, -360, -360, -360, -360, -360, -360, -360, -360, + -360, -360, -360, 2914, -360, 2914, 2914, 2914, 2914, 2914, + 2914, 2914, 2914, 2914, 2914, 2914, 2914, 2914, 2914, 2914, + 2914, 2914, 2914, 2914, 2914, 2914, -360, -360, -360, 62, + -360, -360, 2733, 2914, 48, 66, -360, -360, -360, -360, + 2914, 144, -360, -360, -360, 67, -360, -360, 2190, -49, + -360, -22, -360, 238, 68, 187, 74, -360, -360, 71, + 68, 76, -360, -360, -360, -360, -360, -360, -8, -8, + -113, -113, 39, 39, 39, 39, -76, -76, 45, 34, + 23, 35, 154, 153, -84, -360, 2914, 57, 75, -360, + 2914, 69, 87, -360, 2914, -360, 70, 91, 1235, 72, + 78, 1446, -360, 2914, 90, 2914, 81, -360, 2914, -360, + -16, 2914, 1446, 267, -360, -360, 2914, -360, -360, -360, + -360, -360, -360, 2914, -360, 82, 68, -360, 1235, -360, + -360, -360, -360 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -329, -329, -329, -329, -329, -329, -329, -329, -329, -329, - -329, -329, -329, -329, 16, -329, -329, -329, -329, -135, - -329, -87, -83, -104, -93, -20, -16, -21, -13, -11, - -17, -329, -133, -99, -329, -155, -189, 2, 5, -329, - -329, -329, 68, 161, 155, 73, -329, -329, -215, -329, - -329, -329, 48, -329, -329, -43, -329, -9, -31, -329, - -329, 217, -329, 150, -131, -329, -24, -140, 56, -153, - -328, -78, -90, 213, 124, 58, -329, -329, -19, -329, - -329, -329, -329, -329, -329, -329, 219, -329 + -360, -360, -360, -360, -360, -360, -360, -360, -360, -360, + -360, -360, -360, -360, 25, -360, -360, -360, -360, -135, + -360, -89, -88, -104, -91, -11, -6, -4, -3, -7, + -2, -360, -133, -97, -360, -156, -193, 4, 10, -360, + -360, -360, 80, 170, 166, 84, -360, -360, -229, -360, + -360, 59, -71, -360, -360, -72, -9, 1, -360, -360, + 225, -360, 161, -128, -360, -14, -287, 61, -151, -359, + -68, -82, 224, 135, 77, -360, -360, -13, -360, -360, + -360, -360, -360, -360, -360, 228, -360 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which number is the opposite. If zero, do what YYDEFACT says. If YYTABLE_NINF, syntax error. */ -#define YYTABLE_NINF -264 +#define YYTABLE_NINF -169 static const yytype_int16 yytable[] = { - 98, 245, 127, 250, 110, 252, 229, 301, 230, 12, - 13, 85, 290, 291, 86, 239, 257, -164, 270, 271, - 272, 273, 274, 275, 276, 277, 278, 279, 114, 260, - 261, 128, 129, 130, 255, 256, 127, 313, 30, 331, - 31, 225, 32, 226, 33, 34, 35, 134, 303, 393, - 310, 1, 139, 122, 123, 282, 4, 319, 303, 306, - 393, 227, 303, 135, 304, 128, 129, 130, 311, 303, - 114, 142, 5, 320, 327, 98, 329, 107, 108, 286, - 287, 109, 112, 379, 148, 7, 85, 140, 268, 86, - 137, 229, 326, 230, 138, 8, 328, 241, 11, 330, - 265, 242, 145, 239, 266, 116, 306, 336, 106, 113, - 331, 333, 374, 375, 207, 303, 303, 303, 72, 73, - 74, 364, 117, 222, 118, 302, 80, 120, 314, 368, - 292, 293, -40, 288, 289, 145, 280, 145, 262, 119, - 263, 111, 401, 12, 13, 207, 303, 360, 341, 342, - 343, 229, 229, 229, 229, 229, 229, 229, 229, 229, - 229, 229, 229, 229, 229, 229, 229, 339, 207, 125, - 330, 365, 30, 380, 31, 229, 32, 230, 33, 34, - 35, 136, 340, 229, 126, 230, 348, 349, 350, 351, - -102, 128, 129, 130, 283, 284, 285, 294, 295, 344, - 345, 352, 353, 207, 361, 346, 347, 143, 141, 149, - 144, 224, 314, 233, 222, 386, 240, 235, 246, 243, - 244, 389, 247, 253, 248, 145, 383, 229, 251, 230, - 254, 269, 402, 264, 296, 299, 297, 207, 298, 300, - -39, 398, 307, 113, 400, 207, 122, 316, 318, 322, - 207, 408, 405, -34, 366, 362, 370, 367, 376, 406, - 80, 377, 303, 381, 378, -40, 387, 314, 388, 382, - 384, 385, 397, 177, 404, 392, 354, 356, 399, 338, - 396, 355, 314, 407, 359, 314, 357, 219, 223, 358, - 321, 308, 115, 314, 234, 369, 309, 391, 403, 124, - 314, 259, 323, 121, 324, 0, 371, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 207, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 207, 0, 0, 207, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 207, - 0, 0, 0, 0, 0, 0, 12, 13, 14, 15, - 16, 17, 152, 153, 154, 207, 155, 156, 157, 158, - 159, 160, 161, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 0, 31, 0, 32, - 0, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, - 62, 63, 64, 65, 66, 67, 68, 69, 162, 163, - 164, 165, 166, 167, 168, 0, 0, 169, 170, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 71, 72, 73, 74, - 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 80, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 81, 0, 82, + 99, 115, 114, 252, 247, 254, 230, 111, 231, 128, + 292, 293, 303, 87, 262, 263, 259, -168, 240, 88, + 12, 13, 397, 138, 139, 4, 369, 335, 128, 312, + 74, 75, 76, 397, 315, 257, 258, 5, 129, 130, + 131, 226, 148, 227, 135, 12, 13, 313, 243, 30, + 31, 32, 244, 33, 34, 1, 284, 129, 130, 131, + 136, 228, 308, 272, 273, 274, 275, 276, 277, 278, + 279, 280, 281, 305, 30, 31, 32, 99, 33, 34, + 35, 36, 37, 387, 288, 289, 321, 7, 140, 306, + 87, 270, 230, 329, 231, 305, 88, 331, 402, 335, + 334, 404, 322, 145, 142, 8, 305, 240, 340, 409, + 308, 330, 305, 123, 124, 208, 410, 149, 113, 368, + 332, 290, 291, 264, 223, 265, 383, 372, 294, 295, + 304, 316, -40, 296, 297, 145, 267, 145, 108, 109, + 268, 337, 110, 378, 112, 305, 208, 305, 364, 11, + 345, 346, 347, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 208, + 379, 343, 334, 384, 305, 107, 405, 230, 117, 231, + 305, 282, 129, 130, 131, 230, 344, 231, 352, 353, + 354, 355, 118, 285, 286, 287, 119, -102, 120, 348, + 349, 126, 350, 351, 208, 356, 357, 121, 365, 127, + 137, 141, 143, 144, 150, 223, 316, 225, 390, 234, + 236, 248, 249, 241, 245, 242, 145, 393, 266, 253, + 299, 230, 246, 231, 250, 406, 255, 256, 271, 208, + 298, 12, 13, 300, 301, 302, -39, 208, 309, 323, + 318, 320, 208, 123, 325, 366, -34, 412, 374, 370, + 371, 115, 114, 380, 305, 382, 381, -40, 385, 386, + 30, 31, 32, 316, 33, 34, 35, 36, 37, 408, + 388, 389, 391, 392, 401, 178, 400, 358, 316, 396, + 342, 316, 403, 359, 411, 362, 360, 220, 361, 316, + 224, 363, 116, 324, 310, 235, 316, 373, 311, 326, + 407, 395, 125, 261, 122, 375, 0, 0, 0, 208, + 0, 0, 0, 0, 0, 327, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 171, 0, 0, 0, 0, 0, - 172, 173, 174, 175, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 176, 177, 178, 12, 13, - 14, 15, 16, 17, 152, 153, 154, 0, 155, 156, - 157, 158, 159, 160, 161, 18, 19, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 29, 30, 0, 31, - 0, 32, 0, 33, 34, 35, 36, 37, 38, 39, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 208, + 0, 0, 208, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 208, 0, 0, 0, 0, 0, 0, + 12, 13, 14, 15, 16, 17, 153, 154, 155, 208, + 156, 157, 158, 159, 160, 161, 162, 18, 19, 20, + 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, + 31, 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, - 162, 163, 164, 165, 166, 167, 168, 0, 0, 169, - 170, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 71, 72, - 73, 74, 0, 75, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 80, 0, 0, 0, 0, + 70, 71, 163, 164, 165, 166, 167, 168, 169, 0, + 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 73, 74, 75, 76, 0, 77, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 81, - 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 171, 0, 0, 0, - 0, 0, 172, 173, 174, 175, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 176, 177, 258, - 12, 13, 14, 15, 16, 17, 152, 153, 154, 0, - 155, 156, 157, 158, 159, 160, 161, 18, 19, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, - 0, 31, 0, 32, 0, 33, 34, 35, 36, 37, + 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 172, 0, + 0, 0, 0, 0, 173, 174, 175, 176, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 177, + 178, 179, 12, 13, 14, 15, 16, 17, 153, 154, + 155, 0, 156, 157, 158, 159, 160, 161, 162, 18, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, 30, 31, 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, - 68, 69, 162, 163, 164, 165, 166, 167, 168, 0, - 0, 169, 170, 0, 0, 0, 0, 0, 0, 0, + 68, 69, 70, 71, 163, 164, 165, 166, 167, 168, + 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 71, 72, 73, 74, 0, 75, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 80, 0, 0, + 0, 0, 73, 74, 75, 76, 0, 77, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 171, 0, - 0, 0, 0, 0, 172, 173, 174, 175, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 176, - 177, 305, 12, 13, 14, 15, 16, 17, 152, 153, - 154, 0, 155, 156, 157, 158, 159, 160, 161, 18, - 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, - 29, 30, 0, 31, 0, 32, 0, 33, 34, 35, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 172, 0, 0, 0, 0, 0, 173, 174, 175, 176, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 177, 178, 260, 12, 13, 14, 15, 16, 17, + 153, 154, 155, 0, 156, 157, 158, 159, 160, 161, + 162, 18, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 30, 31, 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 69, 162, 163, 164, 165, 166, 167, - 168, 0, 0, 169, 170, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 71, 72, 73, 74, 0, 75, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 80, + 66, 67, 68, 69, 70, 71, 163, 164, 165, 166, + 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 73, 74, 75, 76, 0, 77, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 171, 0, 0, 0, 0, 0, 172, 173, 174, 175, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 176, 177, 334, 12, 13, 14, 15, 16, 17, - 152, 153, 154, 0, 155, 156, 157, 158, 159, 160, - 161, 18, 19, 20, 21, 22, 23, 24, 25, 26, - 27, 28, 29, 30, 0, 31, 0, 32, 0, 33, + 0, 0, 172, 0, 0, 0, 0, 0, 173, 174, + 175, 176, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 177, 178, 307, 12, 13, 14, 15, + 16, 17, 153, 154, 155, 0, 156, 157, 158, 159, + 160, 161, 162, 18, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, - 64, 65, 66, 67, 68, 69, 162, 163, 164, 165, - 166, 167, 168, 0, 0, 169, 170, 0, 0, 0, + 64, 65, 66, 67, 68, 69, 70, 71, 163, 164, + 165, 166, 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 71, 72, 73, 74, 0, 75, + 0, 0, 0, 0, 0, 0, 73, 74, 75, 76, + 0, 77, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 172, 0, 0, 0, 0, 0, + 173, 174, 175, 176, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 177, 178, 338, 12, 13, + 14, 15, 16, 17, 153, 154, 155, 0, 156, 157, + 158, 159, 160, 161, 162, 18, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, + 0, 33, 34, 35, 36, 37, 38, 39, 40, 41, + 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, + 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, + 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, + 163, 164, 165, 166, 167, 168, 169, 0, 0, 170, + 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 73, 74, + 75, 76, 0, 77, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 171, 0, 0, 0, 0, 0, 172, 173, - 174, 175, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 176, 177, 12, 13, 14, 15, 16, - 17, 152, 153, 154, 0, 155, 156, 157, 158, 159, - 160, 161, 18, 19, 20, 21, 22, 23, 24, 25, - 26, 27, 28, 29, 30, 0, 31, 0, 32, 0, - 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, - 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, - 63, 64, 65, 66, 67, 68, 69, 162, 163, 164, - 165, 166, 167, 168, 0, 0, 169, 170, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 71, 72, 73, 74, 0, - 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 80, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 83, + 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 171, 0, 0, 0, 0, 0, 172, - 173, 174, 175, 12, 13, 14, 15, 16, 17, 0, - 0, 0, 0, 0, 176, 123, 0, 0, 0, 0, - 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 28, 29, 30, 0, 31, 0, 32, 0, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 0, 163, 164, 165, 166, - 167, 168, 0, 0, 169, 170, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 172, 0, 0, 0, + 0, 0, 173, 174, 175, 176, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 177, 178, 12, + 13, 14, 15, 16, 17, 153, 154, 155, 0, 156, + 157, 158, 159, 160, 161, 162, 18, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, + 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, + 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, + 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, + 71, 163, 164, 165, 166, 167, 168, 169, 0, 0, + 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 73, + 74, 75, 76, 0, 77, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 71, 72, 73, 74, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 172, 0, 0, + 0, 0, 0, 173, 174, 175, 176, 12, 13, 14, + 15, 16, 17, 0, 0, 0, 0, 0, 177, 124, + 0, 0, 0, 0, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 0, + 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, + 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, + 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, + 63, 64, 65, 66, 67, 68, 69, 70, 71, 0, + 164, 165, 166, 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 73, 74, 75, + 76, 0, 77, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 82, 14, 15, 16, 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 171, 0, 0, 0, 0, 0, 172, 173, 174, - 175, 12, 13, 14, 15, 16, 17, 0, 0, 0, - 0, 0, 176, 0, 0, 0, 0, 0, 18, 19, - 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, - 30, 0, 31, 0, 32, 0, 33, 34, 35, 36, - 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 0, 0, 0, 0, 0, 0, 83, 0, + 84, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, - 67, 68, 69, 0, 163, 164, 165, 166, 167, 168, - 0, 0, 169, 170, 0, 0, 0, 0, 0, 0, + 67, 68, 69, 70, 71, 172, 72, 0, 0, 0, + 0, 173, 174, 175, 176, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 177, 0, 0, 0, + 0, 0, 0, 0, 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 113, 72, 73, 74, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 80, 14, - 15, 16, 17, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 18, 19, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 0, 0, 0, 0, - 0, 0, 81, 0, 82, 36, 37, 38, 39, 40, + 0, 14, 15, 16, 17, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 18, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 0, 0, + 0, 0, 0, 0, 83, 0, 84, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, - 61, 62, 63, 64, 65, 66, 67, 68, 69, 171, - 70, 0, 0, 0, 0, 172, 173, 174, 175, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -263, 0, 0, 0, 0, 0, 0, 0, 72, 73, - 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 14, 15, 16, 17, 0, + 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, + 71, 0, 72, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 28, 29, 0, 0, 0, 0, 0, 0, 81, 0, - 82, 36, 37, 38, 39, 40, 41, 42, 43, 44, + 0, 0, 0, 0, 239, 0, 0, 0, 0, 0, + 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 14, 15, 16, + 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 18, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 0, 0, 0, 0, 0, 0, + 83, 0, 84, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 0, 70, 0, 0, 0, + 65, 66, 67, 68, 69, 70, 71, 0, 164, 165, + 166, 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 238, 0, - 0, 0, 0, 0, 72, 73, 74, 0, 0, 0, + 319, 0, 0, 0, 0, 0, 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 14, 15, 16, 17, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 18, 19, 20, 21, - 22, 23, 24, 25, 26, 27, 28, 29, 0, 0, - 0, 0, 0, 0, 81, 0, 82, 36, 37, 38, - 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, - 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, - 69, 0, 163, 164, 165, 166, 167, 168, 0, 0, - 169, 170, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 317, 0, 0, 0, 0, 0, - 72, 73, 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 171, 0, 0, - 0, 0, 0, 172, 173, 174, 175, 12, 13, 14, - 15, 16, 17, 0, 0, 0, 0, 0, 249, 0, - 0, 0, 0, 0, 18, 19, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 30, 0, 31, 0, - 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, - 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, - 61, 62, 63, 64, 65, 66, 67, 68, 69, 0, - 163, 164, 165, 166, 167, 168, 0, 0, 169, 170, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 113, 72, 73, - 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 80, 0, 0, 0, 0, 0, + 0, 0, 0, 172, 0, 0, 0, 0, 0, 173, + 174, 175, 176, 12, 13, 14, 15, 16, 17, 0, + 0, 0, 0, 0, 251, 0, 0, 0, 0, 0, + 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 30, 31, 32, 0, 33, 34, 35, 36, + 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, + 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, + 67, 68, 69, 70, 71, 0, 164, 165, 166, 167, + 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 333, 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 14, 15, 16, 17, 0, 171, 0, 0, 0, 0, - 0, 172, 173, 174, 175, 18, 19, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 29, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 36, 37, 38, 39, - 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, - 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, - 0, 163, 164, 165, 166, 167, 168, 0, 0, 169, - 170, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 72, - 73, 74, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 14, 15, 16, 17, + 0, 172, 0, 0, 0, 0, 0, 173, 174, 175, + 176, 18, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 38, 39, 40, 41, 42, 43, 44, 45, + 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, + 66, 67, 68, 69, 70, 71, 0, 164, 165, 166, + 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 81, - 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 14, 15, 16, 17, 0, 171, 0, 0, 228, - 0, 0, 172, 173, 174, 175, 18, 19, 20, 21, - 22, 23, 24, 25, 26, 27, 28, 29, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 36, 37, 38, - 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, - 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, - 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, - 69, 0, 163, 164, 165, 166, 167, 168, 0, 0, - 169, 170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 72, 73, 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 14, 15, 16, + 17, 0, 172, 0, 0, 229, 0, 0, 173, 174, + 175, 176, 18, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 38, 39, 40, 41, 42, 43, 44, + 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, + 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, + 65, 66, 67, 68, 69, 70, 71, 0, 164, 165, + 166, 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 14, 15, 16, 17, 0, 171, 0, 0, - 312, 0, 0, 172, 173, 174, 175, 18, 19, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 36, 37, - 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, - 68, 69, 0, 163, 164, 165, 166, 167, 168, 0, - 0, 169, 170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 72, 73, 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 14, 15, + 16, 17, 0, 172, 0, 0, 314, 0, 0, 173, + 174, 175, 176, 18, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 38, 39, 40, 41, 42, 43, + 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, 65, 66, 67, 68, 69, 70, 71, 0, 164, + 165, 166, 167, 168, 169, 0, 0, 170, 171, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 74, 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 14, 15, 16, 17, 0, 171, 0, - 0, 363, 0, 0, 172, 173, 174, 175, 18, 19, - 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 36, - 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, - 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, - 67, 68, 69, 0, 163, 164, 165, 166, 167, 168, - 0, 0, 169, 170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 72, 73, 74, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, + 15, 16, 17, 0, 172, 0, 0, 367, 0, 0, + 173, 174, 175, 176, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 38, 39, 40, 41, 42, + 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, + 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, + 63, 64, 65, 66, 67, 68, 69, 70, 71, 0, + 164, 165, 166, 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 74, 75, + 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 14, 15, 16, 17, 0, 171, - 0, 0, 0, 0, 0, 172, 173, 174, 175, 18, - 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, - 29, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 267, 0, 163, 164, 165, 166, 167, - 168, 0, 0, 169, 170, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 83, 0, + 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 72, 73, 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 14, 15, 16, 17, 0, 172, 0, 0, 0, 0, + 0, 173, 174, 175, 176, 18, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 38, 39, 40, 41, + 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, + 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, + 62, 63, 64, 65, 66, 67, 68, 69, 70, 269, + 0, 164, 165, 166, 167, 168, 169, 0, 0, 170, + 171, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 74, + 75, 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 81, 0, 82, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 83, + 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, + 13, 14, 15, 16, 17, 0, 172, 0, 0, 0, + 0, 0, 173, 174, 175, 176, 18, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, + 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, + 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, + 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, + 71, 0, 72, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -3, 0, 0, 12, 13, 14, 15, 16, 17, 0, - 171, 0, 0, 0, 0, 0, 172, 173, 174, 175, - 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 28, 29, 30, 0, 31, 0, 32, 0, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 73, + 74, 75, 76, 0, 77, 0, 0, 0, 0, 0, + 0, 0, 78, 79, 80, 81, 82, 14, 15, 16, + 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 18, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 0, 0, 0, 0, 0, 0, + 83, 0, 84, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 0, 70, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 71, 72, 73, 74, 0, 75, 0, - 0, 0, 0, 0, 0, 0, 76, 77, 78, 79, - 80, 0, 12, 13, 14, 15, 16, 17, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, - 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, - 29, 30, 0, 31, 81, 32, 82, 33, 34, 35, - 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 69, 0, 70, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 71, 72, 73, 74, 0, 75, 0, 0, - 0, 0, 0, 0, 0, 76, 77, 78, 79, 80, - 14, 15, 16, 17, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 18, 19, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 29, 0, 0, 0, - 0, 0, 0, 81, 0, 82, 36, 37, 38, 39, - 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, - 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, - 0, 337, 14, 15, 16, 17, 168, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 18, 19, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 72, - 73, 74, 0, 0, 0, 0, 0, 0, 36, 37, - 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, - 68, 69, 0, 70, 14, 15, 16, 17, 0, 81, - 0, 82, 0, 0, 0, 0, 0, 0, 0, 18, - 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, - 29, 72, 73, 74, 0, 0, 0, 0, 0, 0, - 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 69, 0, 70, 0, 0, 0, 0, - 0, 81, 0, 82, 0, 0, 0, 0, 0, 0, + 65, 66, 67, 68, 69, 70, 71, 0, 341, 14, + 15, 16, 17, 169, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 74, 75, 76, 0, + 0, 0, 0, 0, 0, 38, 39, 40, 41, 42, + 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, + 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, + 63, 64, 65, 66, 67, 68, 69, 70, 71, 0, + 72, 14, 15, 16, 17, 0, 83, 0, 84, 0, + 0, 0, 0, 0, 0, 0, 18, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 74, 75, + 76, 0, 0, 0, 0, 0, 0, 38, 39, 40, + 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, + 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, + 71, 0, 72, 0, 0, 0, 0, 0, 83, 0, + 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 81, 0, 82 + 83, 0, 84 }; static const yytype_int16 yycheck[] = { - 9, 154, 4, 158, 76, 160, 141, 91, 141, 3, - 4, 9, 86, 87, 9, 146, 171, 76, 93, 94, - 95, 96, 97, 98, 99, 100, 101, 102, 71, 84, - 85, 33, 34, 35, 169, 170, 4, 226, 32, 254, - 34, 191, 36, 193, 38, 39, 40, 196, 196, 377, - 193, 109, 95, 212, 213, 190, 78, 196, 196, 212, - 388, 211, 196, 212, 212, 33, 34, 35, 211, 196, - 113, 102, 0, 212, 212, 84, 210, 33, 34, 197, - 198, 37, 76, 210, 115, 113, 84, 96, 187, 84, - 33, 226, 247, 226, 37, 110, 251, 192, 76, 254, - 192, 196, 111, 234, 196, 113, 259, 262, 112, 103, - 325, 192, 192, 192, 123, 196, 196, 196, 104, 105, - 106, 310, 113, 132, 113, 209, 120, 191, 227, 318, - 204, 205, 191, 82, 83, 144, 211, 146, 193, 113, - 195, 213, 192, 3, 4, 154, 196, 302, 283, 284, + 9, 73, 73, 159, 155, 161, 141, 76, 141, 4, + 86, 87, 91, 9, 84, 85, 172, 76, 146, 9, + 3, 4, 381, 95, 96, 78, 313, 256, 4, 193, + 104, 105, 106, 392, 227, 170, 171, 0, 33, 34, + 35, 191, 114, 193, 196, 3, 4, 211, 192, 32, + 33, 34, 196, 36, 37, 109, 191, 33, 34, 35, + 212, 211, 213, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, 196, 32, 33, 34, 86, 36, 37, + 38, 39, 40, 370, 197, 198, 196, 113, 97, 212, + 86, 188, 227, 249, 227, 196, 86, 253, 385, 328, + 256, 388, 212, 112, 103, 110, 196, 235, 264, 396, + 261, 212, 196, 212, 213, 124, 403, 116, 76, 312, + 210, 82, 83, 193, 133, 195, 210, 320, 204, 205, + 209, 228, 191, 88, 89, 144, 192, 146, 33, 34, + 196, 192, 37, 192, 213, 196, 155, 196, 304, 76, 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, - 295, 296, 297, 298, 299, 300, 301, 266, 177, 192, - 325, 311, 32, 362, 34, 310, 36, 310, 38, 39, - 40, 76, 281, 318, 196, 318, 290, 291, 292, 293, - 192, 33, 34, 35, 201, 202, 203, 88, 89, 286, - 287, 294, 295, 212, 303, 288, 289, 76, 193, 76, - 213, 76, 311, 113, 223, 370, 212, 76, 191, 212, - 212, 374, 191, 210, 212, 234, 366, 362, 191, 362, - 191, 191, 387, 192, 206, 90, 207, 246, 208, 92, - 191, 381, 76, 103, 384, 254, 212, 194, 193, 75, - 259, 404, 392, 192, 211, 193, 191, 194, 76, 399, - 120, 192, 196, 211, 194, 191, 212, 366, 192, 194, - 211, 194, 194, 213, 12, 211, 296, 298, 211, 263, - 379, 297, 381, 212, 301, 384, 299, 126, 133, 300, - 242, 223, 75, 392, 144, 319, 223, 375, 388, 86, - 399, 177, 246, 84, 246, -1, 325, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 325, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 178, + 192, 268, 328, 366, 196, 112, 192, 312, 113, 312, + 196, 211, 33, 34, 35, 320, 283, 320, 292, 293, + 294, 295, 113, 201, 202, 203, 113, 192, 113, 288, + 289, 192, 290, 291, 213, 296, 297, 191, 305, 196, + 76, 193, 76, 213, 76, 224, 313, 76, 374, 113, + 76, 191, 191, 212, 212, 211, 235, 378, 192, 191, + 207, 366, 212, 366, 212, 391, 210, 191, 191, 248, + 206, 3, 4, 208, 90, 92, 191, 256, 76, 78, + 194, 193, 261, 212, 75, 193, 192, 408, 191, 211, + 194, 333, 333, 76, 196, 194, 192, 191, 211, 194, + 32, 33, 34, 370, 36, 37, 38, 39, 40, 12, + 211, 194, 212, 192, 194, 213, 383, 298, 385, 211, + 265, 388, 211, 299, 212, 302, 300, 127, 301, 396, + 134, 303, 77, 244, 224, 144, 403, 321, 224, 248, + 392, 379, 88, 178, 86, 328, -1, -1, -1, 328, + -1, -1, -1, -1, -1, 248, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 374, -1, -1, 377, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 388, - -1, -1, -1, -1, -1, -1, 3, 4, 5, 6, - 7, 8, 9, 10, 11, 404, 13, 14, 15, 16, - 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, - 27, 28, 29, 30, 31, 32, -1, 34, -1, 36, - -1, 38, 39, 40, 41, 42, 43, 44, 45, 46, - 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, - 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, - 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, - 77, 78, 79, 80, 81, -1, -1, 84, 85, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 103, 104, 105, 106, - -1, 108, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 120, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 154, -1, 156, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 191, -1, -1, -1, -1, -1, - 197, 198, 199, 200, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 212, 213, 214, 3, 4, - 5, 6, 7, 8, 9, 10, 11, -1, 13, 14, - 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, 32, -1, 34, - -1, 36, -1, 38, 39, 40, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - 75, 76, 77, 78, 79, 80, 81, -1, -1, 84, - 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 103, 104, - 105, 106, -1, 108, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 120, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 154, - -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 191, -1, -1, -1, - -1, -1, 197, 198, 199, 200, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 212, 213, 214, - 3, 4, 5, 6, 7, 8, 9, 10, 11, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 378, + -1, -1, 381, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 392, -1, -1, -1, -1, -1, -1, + 3, 4, 5, 6, 7, 8, 9, 10, 11, 408, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, - -1, 34, -1, 36, -1, 38, 39, 40, 41, 42, + 33, 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, @@ -1654,7 +1581,7 @@ static const yytype_int16 yycheck[] = 213, 214, 3, 4, 5, 6, 7, 8, 9, 10, 11, -1, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, - 31, 32, -1, 34, -1, 36, -1, 38, 39, 40, + 31, 32, 33, 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, @@ -1675,7 +1602,7 @@ static const yytype_int16 yycheck[] = -1, 212, 213, 214, 3, 4, 5, 6, 7, 8, 9, 10, 11, -1, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, - 29, 30, 31, 32, -1, 34, -1, 36, -1, 38, + 29, 30, 31, 32, 33, 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, @@ -1693,79 +1620,90 @@ static const yytype_int16 yycheck[] = -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 191, -1, -1, -1, -1, -1, 197, 198, 199, 200, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 212, 213, 3, 4, 5, 6, 7, - 8, 9, 10, 11, -1, 13, 14, 15, 16, 17, - 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, - 28, 29, 30, 31, 32, -1, 34, -1, 36, -1, - 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, - 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, - 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, - 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, + -1, -1, -1, 212, 213, 214, 3, 4, 5, 6, + 7, 8, 9, 10, 11, -1, 13, 14, 15, 16, + 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 30, 31, 32, 33, 34, -1, 36, + 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, + 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, + 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, + 77, 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 103, 104, 105, 106, -1, - 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 120, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 103, 104, 105, 106, + -1, 108, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 120, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 154, -1, 156, -1, + -1, -1, -1, -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 191, -1, -1, -1, -1, -1, 197, - 198, 199, 200, 3, 4, 5, 6, 7, 8, -1, - -1, -1, -1, -1, 212, 213, -1, -1, -1, -1, - 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, - 30, 31, 32, -1, 34, -1, 36, -1, 38, 39, - 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, - 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, - 70, 71, 72, 73, 74, -1, 76, 77, 78, 79, - 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, + -1, -1, -1, -1, 191, -1, -1, -1, -1, -1, + 197, 198, 199, 200, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 212, 213, 214, 3, 4, + 5, 6, 7, 8, 9, 10, 11, -1, 13, 14, + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, + -1, 36, 37, 38, 39, 40, 41, 42, 43, 44, + 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, + 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, + 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, + 75, 76, 77, 78, 79, 80, 81, -1, -1, 84, + 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 103, 104, + 105, 106, -1, 108, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 120, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 103, 104, 105, 106, -1, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 120, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 154, + -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 191, -1, -1, -1, + -1, -1, 197, 198, 199, 200, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 212, 213, 3, + 4, 5, 6, 7, 8, 9, 10, 11, -1, 13, + 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, + 74, 75, 76, 77, 78, 79, 80, 81, -1, -1, + 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 103, + 104, 105, 106, -1, 108, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 120, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 191, -1, -1, -1, -1, -1, 197, 198, 199, - 200, 3, 4, 5, 6, 7, 8, -1, -1, -1, - -1, -1, 212, -1, -1, -1, -1, -1, 20, 21, - 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, - 32, -1, 34, -1, 36, -1, 38, 39, 40, 41, - 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, - 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, - 72, 73, 74, -1, 76, 77, 78, 79, 80, 81, - -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, + 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 103, 104, 105, 106, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 120, 5, - 6, 7, 8, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 191, -1, -1, + -1, -1, -1, 197, 198, 199, 200, 3, 4, 5, + 6, 7, 8, -1, -1, -1, -1, -1, 212, 213, -1, -1, -1, -1, 20, 21, 22, 23, 24, 25, - 26, 27, 28, 29, 30, 31, -1, -1, -1, -1, - -1, -1, 154, -1, 156, 41, 42, 43, 44, 45, + 26, 27, 28, 29, 30, 31, 32, 33, 34, -1, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 69, 70, 71, 72, 73, 74, 191, - 76, -1, -1, -1, -1, 197, 198, 199, 200, -1, + 66, 67, 68, 69, 70, 71, 72, 73, 74, -1, + 76, 77, 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 212, -1, -1, -1, -1, -1, -1, -1, 104, 105, - 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 5, 6, 7, 8, -1, + -1, -1, -1, -1, -1, -1, -1, 103, 104, 105, + 106, -1, 108, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 120, 5, 6, 7, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, -1, -1, -1, -1, -1, -1, 154, -1, 156, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, - 70, 71, 72, 73, 74, -1, 76, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 214, -1, + 70, 71, 72, 73, 74, 191, 76, -1, -1, -1, + -1, 197, 198, 199, 200, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 212, -1, -1, -1, -1, -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 5, 6, 7, 8, -1, -1, -1, -1, -1, @@ -1775,181 +1713,181 @@ static const yytype_int16 yycheck[] = 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, - 74, -1, 76, 77, 78, 79, 80, 81, -1, -1, - 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, + 74, -1, 76, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 214, -1, -1, -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5, 6, 7, + 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 30, 31, -1, -1, -1, -1, -1, -1, + 154, -1, 156, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, + 68, 69, 70, 71, 72, 73, 74, -1, 76, 77, + 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 214, -1, -1, -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 191, -1, -1, - -1, -1, -1, 197, 198, 199, 200, 3, 4, 5, - 6, 7, 8, -1, -1, -1, -1, -1, 212, -1, - -1, -1, -1, -1, 20, 21, 22, 23, 24, 25, - 26, 27, 28, 29, 30, 31, 32, -1, 34, -1, - 36, -1, 38, 39, 40, 41, 42, 43, 44, 45, - 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, - 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, - 66, 67, 68, 69, 70, 71, 72, 73, 74, -1, - 76, 77, 78, 79, 80, 81, -1, -1, 84, 85, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 103, 104, 105, - 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 120, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 154, -1, - 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 191, -1, -1, -1, -1, -1, 197, + 198, 199, 200, 3, 4, 5, 6, 7, 8, -1, + -1, -1, -1, -1, 212, -1, -1, -1, -1, -1, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, + 30, 31, 32, 33, 34, -1, 36, 37, 38, 39, + 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, + 70, 71, 72, 73, 74, -1, 76, 77, 78, 79, + 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 5, 6, 7, 8, -1, 191, -1, -1, -1, -1, - -1, 197, 198, 199, 200, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - -1, 76, 77, 78, 79, 80, 81, -1, -1, 84, - 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 104, - 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 103, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 120, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 154, - -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 5, 6, 7, 8, -1, 191, -1, -1, 194, - -1, -1, 197, 198, 199, 200, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 30, 31, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 41, 42, 43, - 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, - 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, - 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, - 74, -1, 76, 77, 78, 79, 80, 81, -1, -1, - 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 5, 6, 7, 8, + -1, 191, -1, -1, -1, -1, -1, 197, 198, 199, + 200, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, 30, 31, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 41, 42, 43, 44, 45, 46, 47, 48, + 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, + 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, + 69, 70, 71, 72, 73, 74, -1, 76, 77, 78, + 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 5, 6, 7, 8, -1, 191, -1, -1, - 194, -1, -1, 197, 198, 199, 200, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 29, 30, 31, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 41, 42, - 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, - 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, - 73, 74, -1, 76, 77, 78, 79, 80, 81, -1, - -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5, 6, 7, + 8, -1, 191, -1, -1, 194, -1, -1, 197, 198, + 199, 200, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 30, 31, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, + 68, 69, 70, 71, 72, 73, 74, -1, 76, 77, + 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 5, 6, 7, 8, -1, 191, -1, - -1, 194, -1, -1, 197, 198, 199, 200, 20, 21, - 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 41, - 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, - 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, - 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, - 72, 73, 74, -1, 76, 77, 78, 79, 80, 81, - -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 5, 6, + 7, 8, -1, 191, -1, -1, 194, -1, -1, 197, + 198, 199, 200, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 30, 31, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 41, 42, 43, 44, 45, 46, + 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, + 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, + 67, 68, 69, 70, 71, 72, 73, 74, -1, 76, + 77, 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 5, 6, 7, 8, -1, 191, - -1, -1, -1, -1, -1, 197, 198, 199, 200, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, - 31, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, - 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, - 71, 72, 73, 74, -1, 76, 77, 78, 79, 80, - 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 5, + 6, 7, 8, -1, 191, -1, -1, 194, -1, -1, + 197, 198, 199, 200, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 41, 42, 43, 44, 45, + 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, + 66, 67, 68, 69, 70, 71, 72, 73, 74, -1, + 76, 77, 78, 79, 80, 81, -1, -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 104, 105, 106, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 104, 105, + 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 154, -1, + 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 5, 6, 7, 8, -1, 191, -1, -1, -1, -1, + -1, 197, 198, 199, 200, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 41, 42, 43, 44, + 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, + 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, + 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, + -1, 76, 77, 78, 79, 80, 81, -1, -1, 84, + 85, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 104, + 105, 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 0, -1, -1, 3, 4, 5, 6, 7, 8, -1, - 191, -1, -1, -1, -1, -1, 197, 198, 199, 200, - 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, - 30, 31, 32, -1, 34, -1, 36, -1, 38, 39, - 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, - 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, - 70, 71, 72, 73, 74, -1, 76, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 103, 104, 105, 106, -1, 108, -1, - -1, -1, -1, -1, -1, -1, 116, 117, 118, 119, - 120, -1, 3, 4, 5, 6, 7, 8, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, - 31, 32, -1, 34, 154, 36, 156, 38, 39, 40, - 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, - 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, - 71, 72, 73, 74, -1, 76, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 154, + -1, 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3, + 4, 5, 6, 7, 8, -1, 191, -1, -1, -1, + -1, -1, 197, 198, 199, 200, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, + 74, -1, 76, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 103, 104, 105, 106, -1, 108, -1, -1, - -1, -1, -1, -1, -1, 116, 117, 118, 119, 120, - 5, 6, 7, 8, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, -1, -1, -1, - -1, -1, -1, 154, -1, 156, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - -1, 76, 5, 6, 7, 8, 81, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 29, 30, 31, 104, - 105, 106, -1, -1, -1, -1, -1, -1, 41, 42, - 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, - 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, - 73, 74, -1, 76, 5, 6, 7, 8, -1, 154, - -1, 156, -1, -1, -1, -1, -1, -1, -1, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, - 31, 104, 105, 106, -1, -1, -1, -1, -1, -1, - 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, - 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, - 71, 72, 73, 74, -1, 76, -1, -1, -1, -1, - -1, 154, -1, 156, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 103, + 104, 105, 106, -1, 108, -1, -1, -1, -1, -1, + -1, -1, 116, 117, 118, 119, 120, 5, 6, 7, + 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 30, 31, -1, -1, -1, -1, -1, -1, + 154, -1, 156, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, + 68, 69, 70, 71, 72, 73, 74, -1, 76, 5, + 6, 7, 8, 81, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, 104, 105, 106, -1, + -1, -1, -1, -1, -1, 41, 42, 43, 44, 45, + 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, + 66, 67, 68, 69, 70, 71, 72, 73, 74, -1, + 76, 5, 6, 7, 8, -1, 154, -1, 156, -1, + -1, -1, -1, -1, -1, -1, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 104, 105, + 106, -1, -1, -1, -1, -1, -1, 41, 42, 43, + 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, + 74, -1, 76, -1, -1, -1, -1, -1, 154, -1, + 156, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 154, -1, 156 + 154, -1, 156 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing @@ -1959,44 +1897,45 @@ static const yytype_uint16 yystos[] = 0, 109, 216, 218, 78, 0, 220, 113, 110, 217, 221, 76, 3, 4, 5, 6, 7, 8, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, - 32, 34, 36, 38, 39, 40, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - 76, 103, 104, 105, 106, 108, 116, 117, 118, 119, - 120, 154, 156, 219, 222, 252, 253, 254, 255, 256, - 261, 262, 263, 264, 265, 268, 270, 271, 272, 273, - 274, 275, 276, 277, 301, 302, 112, 33, 34, 37, - 76, 213, 76, 103, 270, 276, 113, 113, 113, 113, - 191, 301, 212, 213, 288, 192, 196, 4, 33, 34, - 35, 258, 259, 269, 196, 212, 76, 33, 37, 270, - 272, 193, 273, 76, 213, 272, 278, 279, 273, 76, - 266, 267, 9, 10, 11, 13, 14, 15, 16, 17, - 18, 19, 75, 76, 77, 78, 79, 80, 81, 84, - 85, 191, 197, 198, 199, 200, 212, 213, 214, 223, - 224, 225, 227, 228, 229, 230, 231, 232, 233, 234, - 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, - 245, 246, 247, 248, 250, 252, 253, 272, 283, 284, - 285, 286, 289, 290, 291, 294, 295, 296, 300, 258, - 257, 260, 272, 259, 76, 191, 193, 211, 194, 234, - 247, 251, 272, 113, 278, 76, 280, 281, 214, 279, - 212, 192, 196, 212, 212, 284, 191, 191, 212, 212, - 250, 191, 250, 210, 191, 234, 234, 250, 214, 289, - 84, 85, 193, 195, 192, 192, 196, 74, 248, 191, - 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, - 211, 249, 234, 201, 202, 203, 197, 198, 82, 83, - 86, 87, 204, 205, 88, 89, 206, 207, 208, 90, - 92, 91, 209, 196, 212, 214, 284, 76, 257, 260, - 193, 211, 194, 251, 248, 282, 194, 214, 193, 196, - 212, 267, 75, 283, 290, 297, 250, 212, 250, 210, - 250, 263, 293, 192, 214, 226, 250, 76, 229, 248, - 248, 234, 234, 234, 236, 236, 237, 237, 238, 238, - 238, 238, 239, 239, 240, 241, 242, 243, 244, 245, - 250, 248, 193, 194, 251, 282, 211, 194, 251, 281, - 191, 293, 298, 299, 192, 192, 76, 192, 194, 210, - 251, 211, 194, 282, 211, 194, 250, 212, 192, 284, - 292, 286, 211, 285, 287, 288, 248, 194, 282, 211, - 282, 192, 250, 287, 12, 282, 282, 212, 284 + 32, 33, 34, 36, 37, 38, 39, 40, 41, 42, + 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, + 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, + 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, + 73, 74, 76, 103, 104, 105, 106, 108, 116, 117, + 118, 119, 120, 154, 156, 219, 222, 252, 253, 254, + 255, 256, 261, 262, 263, 264, 267, 269, 270, 271, + 272, 273, 274, 275, 276, 300, 301, 112, 33, 34, + 37, 76, 213, 76, 267, 270, 275, 113, 113, 113, + 113, 191, 300, 212, 213, 287, 192, 196, 4, 33, + 34, 35, 258, 259, 268, 196, 212, 76, 270, 270, + 271, 193, 272, 76, 213, 271, 277, 278, 270, 272, + 76, 265, 266, 9, 10, 11, 13, 14, 15, 16, + 17, 18, 19, 75, 76, 77, 78, 79, 80, 81, + 84, 85, 191, 197, 198, 199, 200, 212, 213, 214, + 223, 224, 225, 227, 228, 229, 230, 231, 232, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 246, 247, 248, 250, 252, 253, 271, 282, + 283, 284, 285, 288, 289, 290, 293, 294, 295, 299, + 258, 257, 260, 271, 259, 76, 191, 193, 211, 194, + 234, 247, 251, 271, 113, 277, 76, 279, 280, 214, + 278, 212, 211, 192, 196, 212, 212, 283, 191, 191, + 212, 212, 250, 191, 250, 210, 191, 234, 234, 250, + 214, 288, 84, 85, 193, 195, 192, 192, 196, 74, + 248, 191, 93, 94, 95, 96, 97, 98, 99, 100, + 101, 102, 211, 249, 234, 201, 202, 203, 197, 198, + 82, 83, 86, 87, 204, 205, 88, 89, 206, 207, + 208, 90, 92, 91, 209, 196, 212, 214, 283, 76, + 257, 260, 193, 211, 194, 251, 248, 281, 194, 214, + 193, 196, 212, 78, 266, 75, 282, 289, 296, 250, + 212, 250, 210, 103, 250, 263, 292, 192, 214, 226, + 250, 76, 229, 248, 248, 234, 234, 234, 236, 236, + 237, 237, 238, 238, 238, 238, 239, 239, 240, 241, + 242, 243, 244, 245, 250, 248, 193, 194, 251, 281, + 211, 194, 251, 280, 191, 292, 297, 298, 192, 192, + 76, 192, 194, 210, 251, 211, 194, 281, 211, 194, + 250, 212, 192, 283, 291, 285, 211, 284, 286, 287, + 248, 194, 281, 211, 281, 192, 250, 286, 12, 281, + 281, 212, 283 }; #define yyerrok (yyerrstatus = 0) @@ -2011,18 +1950,9 @@ static const yytype_uint16 yystos[] = /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. However, - YYFAIL appears to be in use. Nevertheless, it is formally deprecated - in Bison 2.4.2's NEWS entry, where a plan to phase it out is - discussed. */ + Once GCC version 2 has supplanted version 1, this can go. */ #define YYFAIL goto yyerrlab -#if defined YYFAIL - /* This is here to suppress warnings from the GCC cpp's - -Wunused-macros. Normally we don't worry about that warning, but - some users do, and we want to make it easy for users to remove - YYFAIL uses, which will produce warnings from Bison 2.5. */ -#endif #define YYRECOVERING() (!!yyerrstatus) @@ -2079,7 +2009,7 @@ while (YYID (0)) we won't break user code: when these are the locations we know. */ #ifndef YY_LOCATION_PRINT -# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL +# if YYLTYPE_IS_TRIVIAL # define YY_LOCATION_PRINT(File, Loc) \ fprintf (File, "%d.%d-%d.%d", \ (Loc).first_line, (Loc).first_column, \ @@ -2621,7 +2551,7 @@ YYLTYPE yylloc; YYLTYPE *yylsp; /* The locations where the error started and ended. */ - YYLTYPE yyerror_range[3]; + YYLTYPE yyerror_range[2]; YYSIZE_T yystacksize; @@ -2668,7 +2598,7 @@ YYLTYPE yylloc; yyvsp = yyvs; yylsp = yyls; -#if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL +#if YYLTYPE_IS_TRIVIAL /* Initialize the default location before parsing starts. */ yylloc.first_line = yylloc.last_line = 1; yylloc.first_column = yylloc.last_column = 1; @@ -2676,7 +2606,7 @@ YYLTYPE yylloc; /* User initialization code. */ -/* Line 1251 of yacc.c */ +/* Line 1242 of yacc.c */ #line 41 "glsl_parser.ypp" { yylloc.first_line = 1; @@ -2686,8 +2616,8 @@ YYLTYPE yylloc; yylloc.source = 0; } -/* Line 1251 of yacc.c */ -#line 2691 "glsl_parser.cpp" +/* Line 1242 of yacc.c */ +#line 2621 "glsl_parser.cpp" yylsp[0] = yylloc; goto yysetstate; @@ -2874,8 +2804,8 @@ yyreduce: { case 2: -/* Line 1464 of yacc.c */ -#line 214 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 211 "glsl_parser.ypp" { _mesa_glsl_initialize_types(state); ;} @@ -2883,8 +2813,8 @@ yyreduce: case 5: -/* Line 1464 of yacc.c */ -#line 223 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 220 "glsl_parser.ypp" { switch ((yyvsp[(2) - (3)].n)) { case 100: @@ -2905,8 +2835,8 @@ yyreduce: case 12: -/* Line 1464 of yacc.c */ -#line 255 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 252 "glsl_parser.ypp" { if (!_mesa_glsl_process_extension((yyvsp[(2) - (5)].identifier), & (yylsp[(2) - (5)]), (yyvsp[(4) - (5)].identifier), & (yylsp[(4) - (5)]), state)) { YYERROR; @@ -2916,8 +2846,8 @@ yyreduce: case 13: -/* Line 1464 of yacc.c */ -#line 264 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 261 "glsl_parser.ypp" { /* FINISHME: The NULL test is only required because 'precision' * FINISHME: statements are not yet supported. @@ -2929,8 +2859,8 @@ yyreduce: case 14: -/* Line 1464 of yacc.c */ -#line 272 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 269 "glsl_parser.ypp" { /* FINISHME: The NULL test is only required because 'precision' * FINISHME: statements are not yet supported. @@ -2942,8 +2872,8 @@ yyreduce: case 16: -/* Line 1464 of yacc.c */ -#line 287 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 284 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_identifier, NULL, NULL, NULL); @@ -2954,8 +2884,8 @@ yyreduce: case 17: -/* Line 1464 of yacc.c */ -#line 294 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 291 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_int_constant, NULL, NULL, NULL); @@ -2966,8 +2896,8 @@ yyreduce: case 18: -/* Line 1464 of yacc.c */ -#line 301 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 298 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_uint_constant, NULL, NULL, NULL); @@ -2978,8 +2908,8 @@ yyreduce: case 19: -/* Line 1464 of yacc.c */ -#line 308 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 305 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_float_constant, NULL, NULL, NULL); @@ -2990,8 +2920,8 @@ yyreduce: case 20: -/* Line 1464 of yacc.c */ -#line 315 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 312 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_bool_constant, NULL, NULL, NULL); @@ -3002,8 +2932,8 @@ yyreduce: case 21: -/* Line 1464 of yacc.c */ -#line 322 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 319 "glsl_parser.ypp" { (yyval.expression) = (yyvsp[(2) - (3)].expression); ;} @@ -3011,8 +2941,8 @@ yyreduce: case 23: -/* Line 1464 of yacc.c */ -#line 330 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 327 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_array_index, (yyvsp[(1) - (4)].expression), (yyvsp[(3) - (4)].expression), NULL); @@ -3022,8 +2952,8 @@ yyreduce: case 24: -/* Line 1464 of yacc.c */ -#line 336 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 333 "glsl_parser.ypp" { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} @@ -3031,8 +2961,8 @@ yyreduce: case 25: -/* Line 1464 of yacc.c */ -#line 340 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 337 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_field_selection, (yyvsp[(1) - (3)].expression), NULL, NULL); @@ -3043,8 +2973,8 @@ yyreduce: case 26: -/* Line 1464 of yacc.c */ -#line 347 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 344 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_post_inc, (yyvsp[(1) - (2)].expression), NULL, NULL); @@ -3054,8 +2984,8 @@ yyreduce: case 27: -/* Line 1464 of yacc.c */ -#line 353 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 350 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_post_dec, (yyvsp[(1) - (2)].expression), NULL, NULL); @@ -3065,8 +2995,8 @@ yyreduce: case 31: -/* Line 1464 of yacc.c */ -#line 371 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 368 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_field_selection, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression), NULL); @@ -3076,8 +3006,8 @@ yyreduce: case 36: -/* Line 1464 of yacc.c */ -#line 390 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 387 "glsl_parser.ypp" { (yyval.expression) = (yyvsp[(1) - (2)].expression); (yyval.expression)->set_location(yylloc); @@ -3087,8 +3017,8 @@ yyreduce: case 37: -/* Line 1464 of yacc.c */ -#line 396 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 393 "glsl_parser.ypp" { (yyval.expression) = (yyvsp[(1) - (3)].expression); (yyval.expression)->set_location(yylloc); @@ -3098,8 +3028,8 @@ yyreduce: case 39: -/* Line 1464 of yacc.c */ -#line 412 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 409 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_function_expression((yyvsp[(1) - (1)].type_specifier)); @@ -3109,8 +3039,8 @@ yyreduce: case 40: -/* Line 1464 of yacc.c */ -#line 418 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 415 "glsl_parser.ypp" { void *ctx = state; ast_expression *callee = new(ctx) ast_expression((yyvsp[(1) - (1)].identifier)); @@ -3121,8 +3051,8 @@ yyreduce: case 41: -/* Line 1464 of yacc.c */ -#line 425 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 422 "glsl_parser.ypp" { void *ctx = state; ast_expression *callee = new(ctx) ast_expression((yyvsp[(1) - (1)].identifier)); @@ -3133,8 +3063,8 @@ yyreduce: case 43: -/* Line 1464 of yacc.c */ -#line 437 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 434 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_pre_inc, (yyvsp[(2) - (2)].expression), NULL, NULL); @@ -3144,8 +3074,8 @@ yyreduce: case 44: -/* Line 1464 of yacc.c */ -#line 443 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 440 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_pre_dec, (yyvsp[(2) - (2)].expression), NULL, NULL); @@ -3155,8 +3085,8 @@ yyreduce: case 45: -/* Line 1464 of yacc.c */ -#line 449 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 446 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression((yyvsp[(1) - (2)].n), (yyvsp[(2) - (2)].expression), NULL, NULL); @@ -3166,36 +3096,36 @@ yyreduce: case 46: -/* Line 1464 of yacc.c */ -#line 458 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 455 "glsl_parser.ypp" { (yyval.n) = ast_plus; ;} break; case 47: -/* Line 1464 of yacc.c */ -#line 459 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 456 "glsl_parser.ypp" { (yyval.n) = ast_neg; ;} break; case 48: -/* Line 1464 of yacc.c */ -#line 460 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 457 "glsl_parser.ypp" { (yyval.n) = ast_logic_not; ;} break; case 49: -/* Line 1464 of yacc.c */ -#line 461 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 458 "glsl_parser.ypp" { (yyval.n) = ast_bit_not; ;} break; case 51: -/* Line 1464 of yacc.c */ -#line 467 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 464 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_mul, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3205,8 +3135,8 @@ yyreduce: case 52: -/* Line 1464 of yacc.c */ -#line 473 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 470 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_div, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3216,8 +3146,8 @@ yyreduce: case 53: -/* Line 1464 of yacc.c */ -#line 479 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 476 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_mod, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3227,8 +3157,8 @@ yyreduce: case 55: -/* Line 1464 of yacc.c */ -#line 489 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 486 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_add, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3238,8 +3168,8 @@ yyreduce: case 56: -/* Line 1464 of yacc.c */ -#line 495 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 492 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_sub, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3249,8 +3179,8 @@ yyreduce: case 58: -/* Line 1464 of yacc.c */ -#line 505 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 502 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_lshift, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3260,8 +3190,8 @@ yyreduce: case 59: -/* Line 1464 of yacc.c */ -#line 511 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 508 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_rshift, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3271,8 +3201,8 @@ yyreduce: case 61: -/* Line 1464 of yacc.c */ -#line 521 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 518 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_less, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3282,8 +3212,8 @@ yyreduce: case 62: -/* Line 1464 of yacc.c */ -#line 527 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 524 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_greater, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3293,8 +3223,8 @@ yyreduce: case 63: -/* Line 1464 of yacc.c */ -#line 533 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 530 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_lequal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3304,8 +3234,8 @@ yyreduce: case 64: -/* Line 1464 of yacc.c */ -#line 539 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 536 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_gequal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3315,8 +3245,8 @@ yyreduce: case 66: -/* Line 1464 of yacc.c */ -#line 549 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 546 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_equal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3326,8 +3256,8 @@ yyreduce: case 67: -/* Line 1464 of yacc.c */ -#line 555 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 552 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_nequal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3337,8 +3267,8 @@ yyreduce: case 69: -/* Line 1464 of yacc.c */ -#line 565 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 562 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_bit_or, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3348,8 +3278,8 @@ yyreduce: case 71: -/* Line 1464 of yacc.c */ -#line 575 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 572 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_bit_xor, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3359,8 +3289,8 @@ yyreduce: case 73: -/* Line 1464 of yacc.c */ -#line 585 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 582 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_bit_or, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3370,8 +3300,8 @@ yyreduce: case 75: -/* Line 1464 of yacc.c */ -#line 595 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 592 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_logic_and, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3381,8 +3311,8 @@ yyreduce: case 77: -/* Line 1464 of yacc.c */ -#line 605 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 602 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_logic_xor, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3392,8 +3322,8 @@ yyreduce: case 79: -/* Line 1464 of yacc.c */ -#line 615 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 612 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_logic_or, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3403,8 +3333,8 @@ yyreduce: case 81: -/* Line 1464 of yacc.c */ -#line 625 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 622 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_conditional, (yyvsp[(1) - (5)].expression), (yyvsp[(3) - (5)].expression), (yyvsp[(5) - (5)].expression)); @@ -3414,8 +3344,8 @@ yyreduce: case 83: -/* Line 1464 of yacc.c */ -#line 635 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 632 "glsl_parser.ypp" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression((yyvsp[(2) - (3)].n), (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression), NULL); @@ -3425,85 +3355,85 @@ yyreduce: case 84: -/* Line 1464 of yacc.c */ -#line 643 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 640 "glsl_parser.ypp" { (yyval.n) = ast_assign; ;} break; case 85: -/* Line 1464 of yacc.c */ -#line 644 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 641 "glsl_parser.ypp" { (yyval.n) = ast_mul_assign; ;} break; case 86: -/* Line 1464 of yacc.c */ -#line 645 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 642 "glsl_parser.ypp" { (yyval.n) = ast_div_assign; ;} break; case 87: -/* Line 1464 of yacc.c */ -#line 646 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 643 "glsl_parser.ypp" { (yyval.n) = ast_mod_assign; ;} break; case 88: -/* Line 1464 of yacc.c */ -#line 647 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 644 "glsl_parser.ypp" { (yyval.n) = ast_add_assign; ;} break; case 89: -/* Line 1464 of yacc.c */ -#line 648 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 645 "glsl_parser.ypp" { (yyval.n) = ast_sub_assign; ;} break; case 90: -/* Line 1464 of yacc.c */ -#line 649 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 646 "glsl_parser.ypp" { (yyval.n) = ast_ls_assign; ;} break; case 91: -/* Line 1464 of yacc.c */ -#line 650 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 647 "glsl_parser.ypp" { (yyval.n) = ast_rs_assign; ;} break; case 92: -/* Line 1464 of yacc.c */ -#line 651 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 648 "glsl_parser.ypp" { (yyval.n) = ast_and_assign; ;} break; case 93: -/* Line 1464 of yacc.c */ -#line 652 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 649 "glsl_parser.ypp" { (yyval.n) = ast_xor_assign; ;} break; case 94: -/* Line 1464 of yacc.c */ -#line 653 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 650 "glsl_parser.ypp" { (yyval.n) = ast_or_assign; ;} break; case 95: -/* Line 1464 of yacc.c */ -#line 658 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 655 "glsl_parser.ypp" { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} @@ -3511,8 +3441,8 @@ yyreduce: case 96: -/* Line 1464 of yacc.c */ -#line 662 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 659 "glsl_parser.ypp" { void *ctx = state; if ((yyvsp[(1) - (3)].expression)->oper != ast_sequence) { @@ -3529,8 +3459,8 @@ yyreduce: case 98: -/* Line 1464 of yacc.c */ -#line 682 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 679 "glsl_parser.ypp" { (yyval.node) = (yyvsp[(1) - (2)].function); ;} @@ -3538,8 +3468,8 @@ yyreduce: case 99: -/* Line 1464 of yacc.c */ -#line 686 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 683 "glsl_parser.ypp" { (yyval.node) = (yyvsp[(1) - (2)].declarator_list); ;} @@ -3547,8 +3477,8 @@ yyreduce: case 100: -/* Line 1464 of yacc.c */ -#line 690 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 687 "glsl_parser.ypp" { if (((yyvsp[(3) - (4)].type_specifier)->type_specifier != ast_float) && ((yyvsp[(3) - (4)].type_specifier)->type_specifier != ast_int)) { @@ -3563,8 +3493,8 @@ yyreduce: case 104: -/* Line 1464 of yacc.c */ -#line 713 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 710 "glsl_parser.ypp" { (yyval.function) = (yyvsp[(1) - (2)].function); (yyval.function)->parameters.push_tail(& (yyvsp[(2) - (2)].parameter_declarator)->link); @@ -3573,8 +3503,8 @@ yyreduce: case 105: -/* Line 1464 of yacc.c */ -#line 718 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 715 "glsl_parser.ypp" { (yyval.function) = (yyvsp[(1) - (3)].function); (yyval.function)->parameters.push_tail(& (yyvsp[(3) - (3)].parameter_declarator)->link); @@ -3583,8 +3513,8 @@ yyreduce: case 106: -/* Line 1464 of yacc.c */ -#line 726 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 723 "glsl_parser.ypp" { void *ctx = state; (yyval.function) = new(ctx) ast_function(); @@ -3596,8 +3526,8 @@ yyreduce: case 107: -/* Line 1464 of yacc.c */ -#line 737 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 734 "glsl_parser.ypp" { void *ctx = state; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); @@ -3611,8 +3541,8 @@ yyreduce: case 108: -/* Line 1464 of yacc.c */ -#line 747 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 744 "glsl_parser.ypp" { void *ctx = state; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); @@ -3628,88 +3558,100 @@ yyreduce: case 109: -/* Line 1464 of yacc.c */ -#line 762 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 759 "glsl_parser.ypp" { - (yyvsp[(1) - (3)].type_qualifier).i |= (yyvsp[(2) - (3)].type_qualifier).i; + (yyvsp[(1) - (3)].type_qualifier).flags.i |= (yyvsp[(2) - (3)].type_qualifier).flags.i; (yyval.parameter_declarator) = (yyvsp[(3) - (3)].parameter_declarator); - (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (3)].type_qualifier).q; + (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (3)].type_qualifier); ;} break; case 110: -/* Line 1464 of yacc.c */ -#line 769 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 766 "glsl_parser.ypp" { (yyval.parameter_declarator) = (yyvsp[(2) - (2)].parameter_declarator); - (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (2)].type_qualifier).q; + (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (2)].type_qualifier); ;} break; case 111: -/* Line 1464 of yacc.c */ -#line 774 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 771 "glsl_parser.ypp" { void *ctx = state; - (yyvsp[(1) - (3)].type_qualifier).i |= (yyvsp[(2) - (3)].type_qualifier).i; + (yyvsp[(1) - (3)].type_qualifier).flags.i |= (yyvsp[(2) - (3)].type_qualifier).flags.i; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); (yyval.parameter_declarator)->set_location(yylloc); (yyval.parameter_declarator)->type = new(ctx) ast_fully_specified_type(); - (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (3)].type_qualifier).q; + (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (3)].type_qualifier); (yyval.parameter_declarator)->type->specifier = (yyvsp[(3) - (3)].type_specifier); ;} break; case 112: -/* Line 1464 of yacc.c */ -#line 785 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 782 "glsl_parser.ypp" { void *ctx = state; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); (yyval.parameter_declarator)->set_location(yylloc); (yyval.parameter_declarator)->type = new(ctx) ast_fully_specified_type(); - (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (2)].type_qualifier).q; + (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (2)].type_qualifier); (yyval.parameter_declarator)->type->specifier = (yyvsp[(2) - (2)].type_specifier); ;} break; case 113: -/* Line 1464 of yacc.c */ -#line 796 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; ;} +/* Line 1455 of yacc.c */ +#line 794 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + ;} break; case 114: -/* Line 1464 of yacc.c */ -#line 797 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.in = 1; ;} +/* Line 1455 of yacc.c */ +#line 798 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.in = 1; + ;} break; case 115: -/* Line 1464 of yacc.c */ -#line 798 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.out = 1; ;} +/* Line 1455 of yacc.c */ +#line 803 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.out = 1; + ;} break; case 116: -/* Line 1464 of yacc.c */ -#line 799 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.in = 1; (yyval.type_qualifier).q.out = 1; ;} +/* Line 1455 of yacc.c */ +#line 808 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.in = 1; + (yyval.type_qualifier).flags.q.out = 1; + ;} break; case 119: -/* Line 1464 of yacc.c */ -#line 809 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 822 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (3)].identifier), false, NULL, NULL); @@ -3722,8 +3664,8 @@ yyreduce: case 120: -/* Line 1464 of yacc.c */ -#line 818 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 831 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (5)].identifier), true, NULL, NULL); @@ -3736,8 +3678,8 @@ yyreduce: case 121: -/* Line 1464 of yacc.c */ -#line 827 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 840 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (6)].identifier), true, (yyvsp[(5) - (6)].expression), NULL); @@ -3750,8 +3692,8 @@ yyreduce: case 122: -/* Line 1464 of yacc.c */ -#line 836 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 849 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (7)].identifier), true, NULL, (yyvsp[(7) - (7)].expression)); @@ -3764,8 +3706,8 @@ yyreduce: case 123: -/* Line 1464 of yacc.c */ -#line 845 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 858 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (8)].identifier), true, (yyvsp[(5) - (8)].expression), (yyvsp[(8) - (8)].expression)); @@ -3778,8 +3720,8 @@ yyreduce: case 124: -/* Line 1464 of yacc.c */ -#line 854 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 867 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (5)].identifier), false, NULL, (yyvsp[(5) - (5)].expression)); @@ -3792,8 +3734,8 @@ yyreduce: case 125: -/* Line 1464 of yacc.c */ -#line 867 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 880 "glsl_parser.ypp" { void *ctx = state; if ((yyvsp[(1) - (1)].fully_specified_type)->specifier->type_specifier != ast_struct) { @@ -3808,8 +3750,8 @@ yyreduce: case 126: -/* Line 1464 of yacc.c */ -#line 878 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 891 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (2)].identifier), false, NULL, NULL); @@ -3822,8 +3764,8 @@ yyreduce: case 127: -/* Line 1464 of yacc.c */ -#line 887 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 900 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (4)].identifier), true, NULL, NULL); @@ -3836,8 +3778,8 @@ yyreduce: case 128: -/* Line 1464 of yacc.c */ -#line 896 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 909 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (5)].identifier), true, (yyvsp[(4) - (5)].expression), NULL); @@ -3850,8 +3792,8 @@ yyreduce: case 129: -/* Line 1464 of yacc.c */ -#line 905 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 918 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (6)].identifier), true, NULL, (yyvsp[(6) - (6)].expression)); @@ -3864,8 +3806,8 @@ yyreduce: case 130: -/* Line 1464 of yacc.c */ -#line 914 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 927 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (7)].identifier), true, (yyvsp[(4) - (7)].expression), (yyvsp[(7) - (7)].expression)); @@ -3878,8 +3820,8 @@ yyreduce: case 131: -/* Line 1464 of yacc.c */ -#line 923 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 936 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (4)].identifier), false, NULL, (yyvsp[(4) - (4)].expression)); @@ -3892,8 +3834,8 @@ yyreduce: case 132: -/* Line 1464 of yacc.c */ -#line 932 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 945 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (2)].identifier), false, NULL, NULL); @@ -3908,8 +3850,8 @@ yyreduce: case 133: -/* Line 1464 of yacc.c */ -#line 946 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 959 "glsl_parser.ypp" { void *ctx = state; (yyval.fully_specified_type) = new(ctx) ast_fully_specified_type(); @@ -3920,202 +3862,320 @@ yyreduce: case 134: -/* Line 1464 of yacc.c */ -#line 953 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 966 "glsl_parser.ypp" { void *ctx = state; (yyval.fully_specified_type) = new(ctx) ast_fully_specified_type(); (yyval.fully_specified_type)->set_location(yylloc); - (yyval.fully_specified_type)->qualifier = (yyvsp[(1) - (2)].type_qualifier).q; + (yyval.fully_specified_type)->qualifier = (yyvsp[(1) - (2)].type_qualifier); (yyval.fully_specified_type)->specifier = (yyvsp[(2) - (2)].type_specifier); ;} break; case 135: -/* Line 1464 of yacc.c */ -#line 963 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; ;} - break; - - case 137: - -/* Line 1464 of yacc.c */ -#line 969 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 977 "glsl_parser.ypp" { (yyval.type_qualifier) = (yyvsp[(3) - (4)].type_qualifier); ;} break; - case 139: + case 137: -/* Line 1464 of yacc.c */ -#line 977 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 985 "glsl_parser.ypp" { - (yyval.type_qualifier).i = (yyvsp[(1) - (3)].type_qualifier).i | (yyvsp[(3) - (3)].type_qualifier).i; + if (((yyvsp[(1) - (3)].type_qualifier).flags.i & (yyvsp[(3) - (3)].type_qualifier).flags.i) != 0) { + _mesa_glsl_error(& (yylsp[(3) - (3)]), state, + "duplicate layout qualifiers used\n"); + YYERROR; + } + + (yyval.type_qualifier).flags.i = (yyvsp[(1) - (3)].type_qualifier).flags.i | (yyvsp[(3) - (3)].type_qualifier).flags.i; + + if ((yyvsp[(1) - (3)].type_qualifier).flags.q.explicit_location) + (yyval.type_qualifier).location = (yyvsp[(1) - (3)].type_qualifier).location; + + if ((yyvsp[(3) - (3)].type_qualifier).flags.q.explicit_location) + (yyval.type_qualifier).location = (yyvsp[(3) - (3)].type_qualifier).location; ;} break; - case 140: + case 138: -/* Line 1464 of yacc.c */ -#line 984 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1004 "glsl_parser.ypp" { - (yyval.type_qualifier).i = 0; + bool got_one = false; - if (state->ARB_fragment_coord_conventions_enable) { - bool got_one = false; + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + if (state->ARB_fragment_coord_conventions_enable) { if (strcmp((yyvsp[(1) - (1)].identifier), "origin_upper_left") == 0) { got_one = true; - (yyval.type_qualifier).q.origin_upper_left = 1; + (yyval.type_qualifier).flags.q.origin_upper_left = 1; } else if (strcmp((yyvsp[(1) - (1)].identifier), "pixel_center_integer") == 0) { got_one = true; - (yyval.type_qualifier).q.pixel_center_integer = 1; - } - - if (state->ARB_fragment_coord_conventions_warn && got_one) { - _mesa_glsl_warning(& (yylsp[(1) - (1)]), state, - "GL_ARB_fragment_coord_conventions layout " - "identifier `%s' used\n", (yyvsp[(1) - (1)].identifier)); + (yyval.type_qualifier).flags.q.pixel_center_integer = 1; } } /* If the identifier didn't match any known layout identifiers, * emit an error. */ - if ((yyval.type_qualifier).i == 0) { + if (!got_one) { _mesa_glsl_error(& (yylsp[(1) - (1)]), state, "unrecognized layout identifier " "`%s'\n", (yyvsp[(1) - (1)].identifier)); YYERROR; + } else if (state->ARB_fragment_coord_conventions_warn) { + _mesa_glsl_warning(& (yylsp[(1) - (1)]), state, + "GL_ARB_fragment_coord_conventions layout " + "identifier `%s' used\n", (yyvsp[(1) - (1)].identifier)); } ;} break; - case 141: + case 139: + +/* Line 1455 of yacc.c */ +#line 1033 "glsl_parser.ypp" + { + bool got_one = false; + + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + + if (state->ARB_explicit_attrib_location_enable) { + /* FINISHME: Handle 'index' once GL_ARB_blend_func_exteneded and + * FINISHME: GLSL 1.30 (or later) are supported. + */ + if (strcmp("location", (yyvsp[(1) - (3)].identifier)) == 0) { + got_one = true; + + (yyval.type_qualifier).flags.q.explicit_location = 1; + + if ((yyvsp[(3) - (3)].n) >= 0) { + (yyval.type_qualifier).location = (yyvsp[(3) - (3)].n); + } else { + _mesa_glsl_error(& (yylsp[(3) - (3)]), state, + "invalid location %d specified\n", (yyvsp[(3) - (3)].n)); + YYERROR; + } + } + } -/* Line 1464 of yacc.c */ -#line 1017 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.smooth = 1; ;} + /* If the identifier didn't match any known layout identifiers, + * emit an error. + */ + if (!got_one) { + _mesa_glsl_error(& (yylsp[(1) - (3)]), state, "unrecognized layout identifier " + "`%s'\n", (yyvsp[(1) - (3)].identifier)); + YYERROR; + } else if (state->ARB_explicit_attrib_location_warn) { + _mesa_glsl_warning(& (yylsp[(1) - (3)]), state, + "GL_ARB_explicit_attrib_location layout " + "identifier `%s' used\n", (yyvsp[(1) - (3)].identifier)); + } + ;} break; - case 142: + case 140: -/* Line 1464 of yacc.c */ -#line 1018 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.flat = 1; ;} +/* Line 1455 of yacc.c */ +#line 1074 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.smooth = 1; + ;} break; - case 143: + case 141: -/* Line 1464 of yacc.c */ -#line 1019 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.noperspective = 1; ;} +/* Line 1455 of yacc.c */ +#line 1079 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.flat = 1; + ;} break; - case 144: + case 142: -/* Line 1464 of yacc.c */ -#line 1023 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.constant = 1; ;} +/* Line 1455 of yacc.c */ +#line 1084 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.noperspective = 1; + ;} break; - case 146: + case 143: -/* Line 1464 of yacc.c */ -#line 1029 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1092 "glsl_parser.ypp" { - (yyval.type_qualifier).i = (yyvsp[(1) - (2)].type_qualifier).i | (yyvsp[(2) - (2)].type_qualifier).i; + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.constant = 1; ;} break; - case 147: + case 146: -/* Line 1464 of yacc.c */ -#line 1033 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1102 "glsl_parser.ypp" { - (yyval.type_qualifier) = (yyvsp[(2) - (2)].type_qualifier); - (yyval.type_qualifier).q.invariant = 1; + (yyval.type_qualifier) = (yyvsp[(1) - (2)].type_qualifier); + (yyval.type_qualifier).flags.i |= (yyvsp[(2) - (2)].type_qualifier).flags.i; ;} break; case 148: -/* Line 1464 of yacc.c */ -#line 1040 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.constant = 1; ;} +/* Line 1455 of yacc.c */ +#line 1108 "glsl_parser.ypp" + { + (yyval.type_qualifier) = (yyvsp[(1) - (2)].type_qualifier); + (yyval.type_qualifier).flags.i |= (yyvsp[(2) - (2)].type_qualifier).flags.i; + ;} break; case 149: -/* Line 1464 of yacc.c */ -#line 1041 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.attribute = 1; ;} +/* Line 1455 of yacc.c */ +#line 1113 "glsl_parser.ypp" + { + (yyval.type_qualifier) = (yyvsp[(2) - (2)].type_qualifier); + (yyval.type_qualifier).flags.q.invariant = 1; + ;} break; case 150: -/* Line 1464 of yacc.c */ -#line 1042 "glsl_parser.ypp" - { (yyval.type_qualifier).i = (yyvsp[(1) - (2)].type_qualifier).i; (yyval.type_qualifier).q.varying = 1; ;} +/* Line 1455 of yacc.c */ +#line 1118 "glsl_parser.ypp" + { + (yyval.type_qualifier) = (yyvsp[(2) - (3)].type_qualifier); + (yyval.type_qualifier).flags.i |= (yyvsp[(3) - (3)].type_qualifier).flags.i; + (yyval.type_qualifier).flags.q.invariant = 1; + ;} break; case 151: -/* Line 1464 of yacc.c */ -#line 1043 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.centroid = 1; (yyval.type_qualifier).q.varying = 1; ;} +/* Line 1455 of yacc.c */ +#line 1124 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.invariant = 1; + ;} break; case 152: -/* Line 1464 of yacc.c */ -#line 1044 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.in = 1; ;} +/* Line 1455 of yacc.c */ +#line 1132 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.constant = 1; + ;} break; case 153: -/* Line 1464 of yacc.c */ -#line 1045 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.out = 1; ;} +/* Line 1455 of yacc.c */ +#line 1137 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.attribute = 1; + ;} break; case 154: -/* Line 1464 of yacc.c */ -#line 1046 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.centroid = 1; (yyval.type_qualifier).q.in = 1; ;} +/* Line 1455 of yacc.c */ +#line 1142 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.varying = 1; + ;} break; case 155: -/* Line 1464 of yacc.c */ -#line 1047 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.centroid = 1; (yyval.type_qualifier).q.out = 1; ;} +/* Line 1455 of yacc.c */ +#line 1147 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.centroid = 1; + (yyval.type_qualifier).flags.q.varying = 1; + ;} break; case 156: -/* Line 1464 of yacc.c */ -#line 1048 "glsl_parser.ypp" - { (yyval.type_qualifier).i = 0; (yyval.type_qualifier).q.uniform = 1; ;} +/* Line 1455 of yacc.c */ +#line 1153 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.in = 1; + ;} + break; + + case 157: + +/* Line 1455 of yacc.c */ +#line 1158 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.out = 1; + ;} break; case 158: -/* Line 1464 of yacc.c */ -#line 1054 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1163 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.centroid = 1; (yyval.type_qualifier).flags.q.in = 1; + ;} + break; + + case 159: + +/* Line 1455 of yacc.c */ +#line 1168 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.centroid = 1; (yyval.type_qualifier).flags.q.out = 1; + ;} + break; + + case 160: + +/* Line 1455 of yacc.c */ +#line 1173 "glsl_parser.ypp" + { + memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); + (yyval.type_qualifier).flags.q.uniform = 1; + ;} + break; + + case 162: + +/* Line 1455 of yacc.c */ +#line 1182 "glsl_parser.ypp" { (yyval.type_specifier) = (yyvsp[(2) - (2)].type_specifier); (yyval.type_specifier)->precision = (yyvsp[(1) - (2)].n); ;} break; - case 160: + case 164: -/* Line 1464 of yacc.c */ -#line 1063 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1191 "glsl_parser.ypp" { (yyval.type_specifier) = (yyvsp[(1) - (3)].type_specifier); (yyval.type_specifier)->is_array = true; @@ -4123,10 +4183,10 @@ yyreduce: ;} break; - case 161: + case 165: -/* Line 1464 of yacc.c */ -#line 1069 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1197 "glsl_parser.ypp" { (yyval.type_specifier) = (yyvsp[(1) - (4)].type_specifier); (yyval.type_specifier)->is_array = true; @@ -4134,10 +4194,10 @@ yyreduce: ;} break; - case 162: + case 166: -/* Line 1464 of yacc.c */ -#line 1078 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1206 "glsl_parser.ypp" { void *ctx = state; (yyval.type_specifier) = new(ctx) ast_type_specifier((yyvsp[(1) - (1)].n)); @@ -4145,10 +4205,10 @@ yyreduce: ;} break; - case 163: + case 167: -/* Line 1464 of yacc.c */ -#line 1084 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1212 "glsl_parser.ypp" { void *ctx = state; (yyval.type_specifier) = new(ctx) ast_type_specifier((yyvsp[(1) - (1)].struct_specifier)); @@ -4156,10 +4216,10 @@ yyreduce: ;} break; - case 164: + case 168: -/* Line 1464 of yacc.c */ -#line 1090 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1218 "glsl_parser.ypp" { void *ctx = state; (yyval.type_specifier) = new(ctx) ast_type_specifier((yyvsp[(1) - (1)].identifier)); @@ -4167,367 +4227,367 @@ yyreduce: ;} break; - case 165: + case 169: -/* Line 1464 of yacc.c */ -#line 1098 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1226 "glsl_parser.ypp" { (yyval.n) = ast_void; ;} break; - case 166: + case 170: -/* Line 1464 of yacc.c */ -#line 1099 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1227 "glsl_parser.ypp" { (yyval.n) = ast_float; ;} break; - case 167: + case 171: -/* Line 1464 of yacc.c */ -#line 1100 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1228 "glsl_parser.ypp" { (yyval.n) = ast_int; ;} break; - case 168: + case 172: -/* Line 1464 of yacc.c */ -#line 1101 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1229 "glsl_parser.ypp" { (yyval.n) = ast_uint; ;} break; - case 169: + case 173: -/* Line 1464 of yacc.c */ -#line 1102 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1230 "glsl_parser.ypp" { (yyval.n) = ast_bool; ;} break; - case 170: + case 174: -/* Line 1464 of yacc.c */ -#line 1103 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1231 "glsl_parser.ypp" { (yyval.n) = ast_vec2; ;} break; - case 171: + case 175: -/* Line 1464 of yacc.c */ -#line 1104 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1232 "glsl_parser.ypp" { (yyval.n) = ast_vec3; ;} break; - case 172: + case 176: -/* Line 1464 of yacc.c */ -#line 1105 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1233 "glsl_parser.ypp" { (yyval.n) = ast_vec4; ;} break; - case 173: + case 177: -/* Line 1464 of yacc.c */ -#line 1106 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1234 "glsl_parser.ypp" { (yyval.n) = ast_bvec2; ;} break; - case 174: + case 178: -/* Line 1464 of yacc.c */ -#line 1107 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1235 "glsl_parser.ypp" { (yyval.n) = ast_bvec3; ;} break; - case 175: + case 179: -/* Line 1464 of yacc.c */ -#line 1108 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1236 "glsl_parser.ypp" { (yyval.n) = ast_bvec4; ;} break; - case 176: + case 180: -/* Line 1464 of yacc.c */ -#line 1109 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1237 "glsl_parser.ypp" { (yyval.n) = ast_ivec2; ;} break; - case 177: + case 181: -/* Line 1464 of yacc.c */ -#line 1110 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1238 "glsl_parser.ypp" { (yyval.n) = ast_ivec3; ;} break; - case 178: + case 182: -/* Line 1464 of yacc.c */ -#line 1111 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1239 "glsl_parser.ypp" { (yyval.n) = ast_ivec4; ;} break; - case 179: + case 183: -/* Line 1464 of yacc.c */ -#line 1112 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1240 "glsl_parser.ypp" { (yyval.n) = ast_uvec2; ;} break; - case 180: + case 184: -/* Line 1464 of yacc.c */ -#line 1113 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1241 "glsl_parser.ypp" { (yyval.n) = ast_uvec3; ;} break; - case 181: + case 185: -/* Line 1464 of yacc.c */ -#line 1114 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1242 "glsl_parser.ypp" { (yyval.n) = ast_uvec4; ;} break; - case 182: + case 186: -/* Line 1464 of yacc.c */ -#line 1115 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1243 "glsl_parser.ypp" { (yyval.n) = ast_mat2; ;} break; - case 183: + case 187: -/* Line 1464 of yacc.c */ -#line 1116 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1244 "glsl_parser.ypp" { (yyval.n) = ast_mat2x3; ;} break; - case 184: + case 188: -/* Line 1464 of yacc.c */ -#line 1117 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1245 "glsl_parser.ypp" { (yyval.n) = ast_mat2x4; ;} break; - case 185: + case 189: -/* Line 1464 of yacc.c */ -#line 1118 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1246 "glsl_parser.ypp" { (yyval.n) = ast_mat3x2; ;} break; - case 186: + case 190: -/* Line 1464 of yacc.c */ -#line 1119 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1247 "glsl_parser.ypp" { (yyval.n) = ast_mat3; ;} break; - case 187: + case 191: -/* Line 1464 of yacc.c */ -#line 1120 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1248 "glsl_parser.ypp" { (yyval.n) = ast_mat3x4; ;} break; - case 188: + case 192: -/* Line 1464 of yacc.c */ -#line 1121 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1249 "glsl_parser.ypp" { (yyval.n) = ast_mat4x2; ;} break; - case 189: + case 193: -/* Line 1464 of yacc.c */ -#line 1122 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1250 "glsl_parser.ypp" { (yyval.n) = ast_mat4x3; ;} break; - case 190: + case 194: -/* Line 1464 of yacc.c */ -#line 1123 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1251 "glsl_parser.ypp" { (yyval.n) = ast_mat4; ;} break; - case 191: + case 195: -/* Line 1464 of yacc.c */ -#line 1124 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1252 "glsl_parser.ypp" { (yyval.n) = ast_sampler1d; ;} break; - case 192: + case 196: -/* Line 1464 of yacc.c */ -#line 1125 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1253 "glsl_parser.ypp" { (yyval.n) = ast_sampler2d; ;} break; - case 193: + case 197: -/* Line 1464 of yacc.c */ -#line 1126 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1254 "glsl_parser.ypp" { (yyval.n) = ast_sampler2drect; ;} break; - case 194: + case 198: -/* Line 1464 of yacc.c */ -#line 1127 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1255 "glsl_parser.ypp" { (yyval.n) = ast_sampler3d; ;} break; - case 195: + case 199: -/* Line 1464 of yacc.c */ -#line 1128 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1256 "glsl_parser.ypp" { (yyval.n) = ast_samplercube; ;} break; - case 196: + case 200: -/* Line 1464 of yacc.c */ -#line 1129 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1257 "glsl_parser.ypp" { (yyval.n) = ast_sampler1dshadow; ;} break; - case 197: + case 201: -/* Line 1464 of yacc.c */ -#line 1130 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1258 "glsl_parser.ypp" { (yyval.n) = ast_sampler2dshadow; ;} break; - case 198: + case 202: -/* Line 1464 of yacc.c */ -#line 1131 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1259 "glsl_parser.ypp" { (yyval.n) = ast_sampler2drectshadow; ;} break; - case 199: + case 203: -/* Line 1464 of yacc.c */ -#line 1132 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1260 "glsl_parser.ypp" { (yyval.n) = ast_samplercubeshadow; ;} break; - case 200: + case 204: -/* Line 1464 of yacc.c */ -#line 1133 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1261 "glsl_parser.ypp" { (yyval.n) = ast_sampler1darray; ;} break; - case 201: + case 205: -/* Line 1464 of yacc.c */ -#line 1134 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1262 "glsl_parser.ypp" { (yyval.n) = ast_sampler2darray; ;} break; - case 202: + case 206: -/* Line 1464 of yacc.c */ -#line 1135 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1263 "glsl_parser.ypp" { (yyval.n) = ast_sampler1darrayshadow; ;} break; - case 203: + case 207: -/* Line 1464 of yacc.c */ -#line 1136 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1264 "glsl_parser.ypp" { (yyval.n) = ast_sampler2darrayshadow; ;} break; - case 204: + case 208: -/* Line 1464 of yacc.c */ -#line 1137 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1265 "glsl_parser.ypp" { (yyval.n) = ast_isampler1d; ;} break; - case 205: + case 209: -/* Line 1464 of yacc.c */ -#line 1138 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1266 "glsl_parser.ypp" { (yyval.n) = ast_isampler2d; ;} break; - case 206: + case 210: -/* Line 1464 of yacc.c */ -#line 1139 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1267 "glsl_parser.ypp" { (yyval.n) = ast_isampler3d; ;} break; - case 207: + case 211: -/* Line 1464 of yacc.c */ -#line 1140 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1268 "glsl_parser.ypp" { (yyval.n) = ast_isamplercube; ;} break; - case 208: + case 212: -/* Line 1464 of yacc.c */ -#line 1141 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1269 "glsl_parser.ypp" { (yyval.n) = ast_isampler1darray; ;} break; - case 209: + case 213: -/* Line 1464 of yacc.c */ -#line 1142 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1270 "glsl_parser.ypp" { (yyval.n) = ast_isampler2darray; ;} break; - case 210: + case 214: -/* Line 1464 of yacc.c */ -#line 1143 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1271 "glsl_parser.ypp" { (yyval.n) = ast_usampler1d; ;} break; - case 211: + case 215: -/* Line 1464 of yacc.c */ -#line 1144 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1272 "glsl_parser.ypp" { (yyval.n) = ast_usampler2d; ;} break; - case 212: + case 216: -/* Line 1464 of yacc.c */ -#line 1145 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1273 "glsl_parser.ypp" { (yyval.n) = ast_usampler3d; ;} break; - case 213: + case 217: -/* Line 1464 of yacc.c */ -#line 1146 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1274 "glsl_parser.ypp" { (yyval.n) = ast_usamplercube; ;} break; - case 214: + case 218: -/* Line 1464 of yacc.c */ -#line 1147 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1275 "glsl_parser.ypp" { (yyval.n) = ast_usampler1darray; ;} break; - case 215: + case 219: -/* Line 1464 of yacc.c */ -#line 1148 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1276 "glsl_parser.ypp" { (yyval.n) = ast_usampler2darray; ;} break; - case 216: + case 220: -/* Line 1464 of yacc.c */ -#line 1152 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1280 "glsl_parser.ypp" { if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& (yylsp[(1) - (1)]), state, @@ -4541,10 +4601,10 @@ yyreduce: ;} break; - case 217: + case 221: -/* Line 1464 of yacc.c */ -#line 1163 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1291 "glsl_parser.ypp" { if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& (yylsp[(1) - (1)]), state, @@ -4558,10 +4618,10 @@ yyreduce: ;} break; - case 218: + case 222: -/* Line 1464 of yacc.c */ -#line 1174 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1302 "glsl_parser.ypp" { if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& (yylsp[(1) - (1)]), state, @@ -4575,10 +4635,10 @@ yyreduce: ;} break; - case 219: + case 223: -/* Line 1464 of yacc.c */ -#line 1189 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1317 "glsl_parser.ypp" { void *ctx = state; (yyval.struct_specifier) = new(ctx) ast_struct_specifier((yyvsp[(2) - (5)].identifier), (yyvsp[(4) - (5)].node)); @@ -4586,10 +4646,10 @@ yyreduce: ;} break; - case 220: + case 224: -/* Line 1464 of yacc.c */ -#line 1195 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1323 "glsl_parser.ypp" { void *ctx = state; (yyval.struct_specifier) = new(ctx) ast_struct_specifier(NULL, (yyvsp[(3) - (4)].node)); @@ -4597,30 +4657,30 @@ yyreduce: ;} break; - case 221: + case 225: -/* Line 1464 of yacc.c */ -#line 1204 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1332 "glsl_parser.ypp" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].declarator_list); (yyvsp[(1) - (1)].declarator_list)->link.self_link(); ;} break; - case 222: + case 226: -/* Line 1464 of yacc.c */ -#line 1209 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1337 "glsl_parser.ypp" { (yyval.node) = (ast_node *) (yyvsp[(1) - (2)].node); (yyval.node)->link.insert_before(& (yyvsp[(2) - (2)].declarator_list)->link); ;} break; - case 223: + case 227: -/* Line 1464 of yacc.c */ -#line 1217 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1345 "glsl_parser.ypp" { void *ctx = state; ast_fully_specified_type *type = new(ctx) ast_fully_specified_type(); @@ -4634,30 +4694,30 @@ yyreduce: ;} break; - case 224: + case 228: -/* Line 1464 of yacc.c */ -#line 1232 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1360 "glsl_parser.ypp" { (yyval.declaration) = (yyvsp[(1) - (1)].declaration); (yyvsp[(1) - (1)].declaration)->link.self_link(); ;} break; - case 225: + case 229: -/* Line 1464 of yacc.c */ -#line 1237 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1365 "glsl_parser.ypp" { (yyval.declaration) = (yyvsp[(1) - (3)].declaration); (yyval.declaration)->link.insert_before(& (yyvsp[(3) - (3)].declaration)->link); ;} break; - case 226: + case 230: -/* Line 1464 of yacc.c */ -#line 1245 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1373 "glsl_parser.ypp" { void *ctx = state; (yyval.declaration) = new(ctx) ast_declaration((yyvsp[(1) - (1)].identifier), false, NULL, NULL); @@ -4665,10 +4725,10 @@ yyreduce: ;} break; - case 227: + case 231: -/* Line 1464 of yacc.c */ -#line 1251 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1379 "glsl_parser.ypp" { void *ctx = state; (yyval.declaration) = new(ctx) ast_declaration((yyvsp[(1) - (4)].identifier), true, (yyvsp[(3) - (4)].expression), NULL); @@ -4676,31 +4736,31 @@ yyreduce: ;} break; - case 230: + case 234: -/* Line 1464 of yacc.c */ -#line 1269 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1397 "glsl_parser.ypp" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].compound_statement); ;} break; - case 235: + case 239: -/* Line 1464 of yacc.c */ -#line 1277 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1405 "glsl_parser.ypp" { (yyval.node) = NULL; ;} break; - case 236: + case 240: -/* Line 1464 of yacc.c */ -#line 1278 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1406 "glsl_parser.ypp" { (yyval.node) = NULL; ;} break; - case 239: + case 243: -/* Line 1464 of yacc.c */ -#line 1285 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1413 "glsl_parser.ypp" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(true, NULL); @@ -4708,10 +4768,10 @@ yyreduce: ;} break; - case 240: + case 244: -/* Line 1464 of yacc.c */ -#line 1291 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1419 "glsl_parser.ypp" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(true, (yyvsp[(2) - (3)].node)); @@ -4719,17 +4779,17 @@ yyreduce: ;} break; - case 241: + case 245: -/* Line 1464 of yacc.c */ -#line 1299 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1427 "glsl_parser.ypp" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].compound_statement); ;} break; - case 243: + case 247: -/* Line 1464 of yacc.c */ -#line 1305 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1433 "glsl_parser.ypp" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(false, NULL); @@ -4737,10 +4797,10 @@ yyreduce: ;} break; - case 244: + case 248: -/* Line 1464 of yacc.c */ -#line 1311 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1439 "glsl_parser.ypp" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(false, (yyvsp[(2) - (3)].node)); @@ -4748,10 +4808,10 @@ yyreduce: ;} break; - case 245: + case 249: -/* Line 1464 of yacc.c */ -#line 1320 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1448 "glsl_parser.ypp" { if ((yyvsp[(1) - (1)].node) == NULL) { _mesa_glsl_error(& (yylsp[(1) - (1)]), state, "<nil> statement\n"); @@ -4763,10 +4823,10 @@ yyreduce: ;} break; - case 246: + case 250: -/* Line 1464 of yacc.c */ -#line 1330 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1458 "glsl_parser.ypp" { if ((yyvsp[(2) - (2)].node) == NULL) { _mesa_glsl_error(& (yylsp[(2) - (2)]), state, "<nil> statement\n"); @@ -4777,10 +4837,10 @@ yyreduce: ;} break; - case 247: + case 251: -/* Line 1464 of yacc.c */ -#line 1342 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1470 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_expression_statement(NULL); @@ -4788,10 +4848,10 @@ yyreduce: ;} break; - case 248: + case 252: -/* Line 1464 of yacc.c */ -#line 1348 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1476 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_expression_statement((yyvsp[(1) - (2)].expression)); @@ -4799,10 +4859,10 @@ yyreduce: ;} break; - case 249: + case 253: -/* Line 1464 of yacc.c */ -#line 1357 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1485 "glsl_parser.ypp" { (yyval.node) = new(state) ast_selection_statement((yyvsp[(3) - (5)].expression), (yyvsp[(5) - (5)].selection_rest_statement).then_statement, (yyvsp[(5) - (5)].selection_rest_statement).else_statement); @@ -4810,39 +4870,39 @@ yyreduce: ;} break; - case 250: + case 254: -/* Line 1464 of yacc.c */ -#line 1366 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1494 "glsl_parser.ypp" { (yyval.selection_rest_statement).then_statement = (yyvsp[(1) - (3)].node); (yyval.selection_rest_statement).else_statement = (yyvsp[(3) - (3)].node); ;} break; - case 251: + case 255: -/* Line 1464 of yacc.c */ -#line 1371 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1499 "glsl_parser.ypp" { (yyval.selection_rest_statement).then_statement = (yyvsp[(1) - (1)].node); (yyval.selection_rest_statement).else_statement = NULL; ;} break; - case 252: + case 256: -/* Line 1464 of yacc.c */ -#line 1379 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1507 "glsl_parser.ypp" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].expression); ;} break; - case 253: + case 257: -/* Line 1464 of yacc.c */ -#line 1383 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1511 "glsl_parser.ypp" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (4)].identifier), false, NULL, (yyvsp[(4) - (4)].expression)); @@ -4855,10 +4915,10 @@ yyreduce: ;} break; - case 257: + case 261: -/* Line 1464 of yacc.c */ -#line 1406 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1534 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_iteration_statement(ast_iteration_statement::ast_while, @@ -4867,10 +4927,10 @@ yyreduce: ;} break; - case 258: + case 262: -/* Line 1464 of yacc.c */ -#line 1413 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1541 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_iteration_statement(ast_iteration_statement::ast_do_while, @@ -4879,10 +4939,10 @@ yyreduce: ;} break; - case 259: + case 263: -/* Line 1464 of yacc.c */ -#line 1420 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1548 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_iteration_statement(ast_iteration_statement::ast_for, @@ -4891,39 +4951,39 @@ yyreduce: ;} break; - case 263: + case 267: -/* Line 1464 of yacc.c */ -#line 1436 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1564 "glsl_parser.ypp" { (yyval.node) = NULL; ;} break; - case 264: + case 268: -/* Line 1464 of yacc.c */ -#line 1443 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1571 "glsl_parser.ypp" { (yyval.for_rest_statement).cond = (yyvsp[(1) - (2)].node); (yyval.for_rest_statement).rest = NULL; ;} break; - case 265: + case 269: -/* Line 1464 of yacc.c */ -#line 1448 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1576 "glsl_parser.ypp" { (yyval.for_rest_statement).cond = (yyvsp[(1) - (3)].node); (yyval.for_rest_statement).rest = (yyvsp[(3) - (3)].expression); ;} break; - case 266: + case 270: -/* Line 1464 of yacc.c */ -#line 1457 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1585 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_continue, NULL); @@ -4931,10 +4991,10 @@ yyreduce: ;} break; - case 267: + case 271: -/* Line 1464 of yacc.c */ -#line 1463 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1591 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_break, NULL); @@ -4942,10 +5002,10 @@ yyreduce: ;} break; - case 268: + case 272: -/* Line 1464 of yacc.c */ -#line 1469 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1597 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_return, NULL); @@ -4953,10 +5013,10 @@ yyreduce: ;} break; - case 269: + case 273: -/* Line 1464 of yacc.c */ -#line 1475 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1603 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_return, (yyvsp[(2) - (3)].expression)); @@ -4964,10 +5024,10 @@ yyreduce: ;} break; - case 270: + case 274: -/* Line 1464 of yacc.c */ -#line 1481 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1609 "glsl_parser.ypp" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_discard, NULL); @@ -4975,31 +5035,31 @@ yyreduce: ;} break; - case 271: + case 275: -/* Line 1464 of yacc.c */ -#line 1489 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1617 "glsl_parser.ypp" { (yyval.node) = (yyvsp[(1) - (1)].function_definition); ;} break; - case 272: + case 276: -/* Line 1464 of yacc.c */ -#line 1490 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1618 "glsl_parser.ypp" { (yyval.node) = (yyvsp[(1) - (1)].node); ;} break; - case 273: + case 277: -/* Line 1464 of yacc.c */ -#line 1491 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1619 "glsl_parser.ypp" { (yyval.node) = NULL; ;} break; - case 274: + case 278: -/* Line 1464 of yacc.c */ -#line 1496 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1624 "glsl_parser.ypp" { void *ctx = state; (yyval.function_definition) = new(ctx) ast_function_definition(); @@ -5011,8 +5071,8 @@ yyreduce: -/* Line 1464 of yacc.c */ -#line 5016 "glsl_parser.cpp" +/* Line 1455 of yacc.c */ +#line 5076 "glsl_parser.cpp" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -5084,7 +5144,7 @@ yyerrlab: #endif } - yyerror_range[1] = yylloc; + yyerror_range[0] = yylloc; if (yyerrstatus == 3) { @@ -5121,7 +5181,7 @@ yyerrorlab: if (/*CONSTCOND*/ 0) goto yyerrorlab; - yyerror_range[1] = yylsp[1-yylen]; + yyerror_range[0] = yylsp[1-yylen]; /* Do not reclaim the symbols of the rule which action triggered this YYERROR. */ YYPOPSTACK (yylen); @@ -5155,7 +5215,7 @@ yyerrlab1: if (yyssp == yyss) YYABORT; - yyerror_range[1] = *yylsp; + yyerror_range[0] = *yylsp; yydestruct ("Error: popping", yystos[yystate], yyvsp, yylsp, state); YYPOPSTACK (1); @@ -5165,10 +5225,10 @@ yyerrlab1: *++yyvsp = yylval; - yyerror_range[2] = yylloc; + yyerror_range[1] = yylloc; /* Using YYLLOC is tempting, but would change the location of the lookahead. YYLOC is available though. */ - YYLLOC_DEFAULT (yyloc, yyerror_range, 2); + YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2); *++yylsp = yyloc; /* Shift the error token. */ diff --git a/src/glsl/glsl_parser.h b/src/glsl/glsl_parser.h index 4a780375bf..9bb6ae6299 100644 --- a/src/glsl/glsl_parser.h +++ b/src/glsl/glsl_parser.h @@ -1,9 +1,10 @@ -/* A Bison parser, made by GNU Bison 2.4.3. */ + +/* A Bison parser, made by GNU Bison 2.4.1. */ /* Skeleton interface for Bison's Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - 2009, 2010 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -235,17 +236,14 @@ typedef union YYSTYPE { -/* Line 1685 of yacc.c */ +/* Line 1676 of yacc.c */ #line 52 "glsl_parser.ypp" int n; float real; char *identifier; - union { - struct ast_type_qualifier q; - unsigned i; - } type_qualifier; + struct ast_type_qualifier type_qualifier; ast_node *node; ast_type_specifier *type_specifier; @@ -271,8 +269,8 @@ typedef union YYSTYPE -/* Line 1685 of yacc.c */ -#line 276 "glsl_parser.h" +/* Line 1676 of yacc.c */ +#line 274 "glsl_parser.h" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ diff --git a/src/glsl/glsl_parser.ypp b/src/glsl/glsl_parser.ypp index 0df1e480ce..ed18179beb 100644 --- a/src/glsl/glsl_parser.ypp +++ b/src/glsl/glsl_parser.ypp @@ -54,10 +54,7 @@ float real; char *identifier; - union { - struct ast_type_qualifier q; - unsigned i; - } type_qualifier; + struct ast_type_qualifier type_qualifier; ast_node *node; ast_type_specifier *type_specifier; @@ -139,7 +136,7 @@ %type <type_qualifier> type_qualifier %type <type_qualifier> storage_qualifier %type <type_qualifier> interpolation_qualifier -%type <type_qualifier> opt_layout_qualifier layout_qualifier +%type <type_qualifier> layout_qualifier %type <type_qualifier> layout_qualifier_id_list layout_qualifier_id %type <type_specifier> type_specifier %type <type_specifier> type_specifier_no_prec @@ -760,25 +757,25 @@ parameter_declarator: parameter_declaration: parameter_type_qualifier parameter_qualifier parameter_declarator { - $1.i |= $2.i; + $1.flags.i |= $2.flags.i; $$ = $3; - $$->type->qualifier = $1.q; + $$->type->qualifier = $1; } | parameter_qualifier parameter_declarator { $$ = $2; - $$->type->qualifier = $1.q; + $$->type->qualifier = $1; } | parameter_type_qualifier parameter_qualifier parameter_type_specifier { void *ctx = state; - $1.i |= $2.i; + $1.flags.i |= $2.flags.i; $$ = new(ctx) ast_parameter_declarator(); $$->set_location(yylloc); $$->type = new(ctx) ast_fully_specified_type(); - $$->type->qualifier = $1.q; + $$->type->qualifier = $1; $$->type->specifier = $3; } | parameter_qualifier parameter_type_specifier @@ -787,16 +784,32 @@ parameter_declaration: $$ = new(ctx) ast_parameter_declarator(); $$->set_location(yylloc); $$->type = new(ctx) ast_fully_specified_type(); - $$->type->qualifier = $1.q; + $$->type->qualifier = $1; $$->type->specifier = $2; } ; parameter_qualifier: - /* empty */ { $$.i = 0; } - | IN_TOK { $$.i = 0; $$.q.in = 1; } - | OUT_TOK { $$.i = 0; $$.q.out = 1; } - | INOUT_TOK { $$.i = 0; $$.q.in = 1; $$.q.out = 1; } + /* empty */ + { + memset(& $$, 0, sizeof($$)); + } + | IN_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.in = 1; + } + | OUT_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.out = 1; + } + | INOUT_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.in = 1; + $$.flags.q.out = 1; + } ; parameter_type_specifier: @@ -954,16 +967,11 @@ fully_specified_type: void *ctx = state; $$ = new(ctx) ast_fully_specified_type(); $$->set_location(yylloc); - $$->qualifier = $1.q; + $$->qualifier = $1; $$->specifier = $2; } ; -opt_layout_qualifier: - { $$.i = 0; } - | layout_qualifier - ; - layout_qualifier: LAYOUT_TOK '(' layout_qualifier_id_list ')' { @@ -975,77 +983,197 @@ layout_qualifier_id_list: layout_qualifier_id | layout_qualifier_id_list ',' layout_qualifier_id { - $$.i = $1.i | $3.i; + if (($1.flags.i & $3.flags.i) != 0) { + _mesa_glsl_error(& @3, state, + "duplicate layout qualifiers used\n"); + YYERROR; + } + + $$.flags.i = $1.flags.i | $3.flags.i; + + if ($1.flags.q.explicit_location) + $$.location = $1.location; + + if ($3.flags.q.explicit_location) + $$.location = $3.location; } ; layout_qualifier_id: IDENTIFIER { - $$.i = 0; + bool got_one = false; - if (state->ARB_fragment_coord_conventions_enable) { - bool got_one = false; + memset(& $$, 0, sizeof($$)); + if (state->ARB_fragment_coord_conventions_enable) { if (strcmp($1, "origin_upper_left") == 0) { got_one = true; - $$.q.origin_upper_left = 1; + $$.flags.q.origin_upper_left = 1; } else if (strcmp($1, "pixel_center_integer") == 0) { got_one = true; - $$.q.pixel_center_integer = 1; + $$.flags.q.pixel_center_integer = 1; } + } - if (state->ARB_fragment_coord_conventions_warn && got_one) { - _mesa_glsl_warning(& @1, state, - "GL_ARB_fragment_coord_conventions layout " - "identifier `%s' used\n", $1); + /* If the identifier didn't match any known layout identifiers, + * emit an error. + */ + if (!got_one) { + _mesa_glsl_error(& @1, state, "unrecognized layout identifier " + "`%s'\n", $1); + YYERROR; + } else if (state->ARB_fragment_coord_conventions_warn) { + _mesa_glsl_warning(& @1, state, + "GL_ARB_fragment_coord_conventions layout " + "identifier `%s' used\n", $1); + } + } + | IDENTIFIER '=' INTCONSTANT + { + bool got_one = false; + + memset(& $$, 0, sizeof($$)); + + if (state->ARB_explicit_attrib_location_enable) { + /* FINISHME: Handle 'index' once GL_ARB_blend_func_exteneded and + * FINISHME: GLSL 1.30 (or later) are supported. + */ + if (strcmp("location", $1) == 0) { + got_one = true; + + $$.flags.q.explicit_location = 1; + + if ($3 >= 0) { + $$.location = $3; + } else { + _mesa_glsl_error(& @3, state, + "invalid location %d specified\n", $3); + YYERROR; + } } } /* If the identifier didn't match any known layout identifiers, * emit an error. */ - if ($$.i == 0) { + if (!got_one) { _mesa_glsl_error(& @1, state, "unrecognized layout identifier " "`%s'\n", $1); YYERROR; + } else if (state->ARB_explicit_attrib_location_warn) { + _mesa_glsl_warning(& @1, state, + "GL_ARB_explicit_attrib_location layout " + "identifier `%s' used\n", $1); } } ; interpolation_qualifier: - SMOOTH { $$.i = 0; $$.q.smooth = 1; } - | FLAT { $$.i = 0; $$.q.flat = 1; } - | NOPERSPECTIVE { $$.i = 0; $$.q.noperspective = 1; } + SMOOTH + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.smooth = 1; + } + | FLAT + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.flat = 1; + } + | NOPERSPECTIVE + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.noperspective = 1; + } ; parameter_type_qualifier: - CONST_TOK { $$.i = 0; $$.q.constant = 1; } + CONST_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.constant = 1; + } ; type_qualifier: storage_qualifier - | interpolation_qualifier type_qualifier + | layout_qualifier + | layout_qualifier storage_qualifier { - $$.i = $1.i | $2.i; + $$ = $1; + $$.flags.i |= $2.flags.i; } - | INVARIANT type_qualifier + | interpolation_qualifier + | interpolation_qualifier storage_qualifier + { + $$ = $1; + $$.flags.i |= $2.flags.i; + } + | INVARIANT storage_qualifier + { + $$ = $2; + $$.flags.q.invariant = 1; + } + | INVARIANT interpolation_qualifier storage_qualifier { $$ = $2; - $$.q.invariant = 1; + $$.flags.i |= $3.flags.i; + $$.flags.q.invariant = 1; + } + | INVARIANT + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.invariant = 1; } ; storage_qualifier: - CONST_TOK { $$.i = 0; $$.q.constant = 1; } - | ATTRIBUTE { $$.i = 0; $$.q.attribute = 1; } - | opt_layout_qualifier VARYING { $$.i = $1.i; $$.q.varying = 1; } - | CENTROID VARYING { $$.i = 0; $$.q.centroid = 1; $$.q.varying = 1; } - | opt_layout_qualifier IN_TOK { $$.i = 0; $$.q.in = 1; } - | OUT_TOK { $$.i = 0; $$.q.out = 1; } - | CENTROID IN_TOK { $$.i = 0; $$.q.centroid = 1; $$.q.in = 1; } - | CENTROID OUT_TOK { $$.i = 0; $$.q.centroid = 1; $$.q.out = 1; } - | UNIFORM { $$.i = 0; $$.q.uniform = 1; } + CONST_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.constant = 1; + } + | ATTRIBUTE + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.attribute = 1; + } + | VARYING + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.varying = 1; + } + | CENTROID VARYING + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.centroid = 1; + $$.flags.q.varying = 1; + } + | IN_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.in = 1; + } + | OUT_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.out = 1; + } + | CENTROID IN_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.centroid = 1; $$.flags.q.in = 1; + } + | CENTROID OUT_TOK + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.centroid = 1; $$.flags.q.out = 1; + } + | UNIFORM + { + memset(& $$, 0, sizeof($$)); + $$.flags.q.uniform = 1; + } ; type_specifier: diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp index 4ac062b42c..3b9877ec0e 100644 --- a/src/glsl/glsl_parser_extras.cpp +++ b/src/glsl/glsl_parser_extras.cpp @@ -27,7 +27,7 @@ extern "C" { #include <talloc.h> -#include "main/core.h" /* for struct __GLcontextRec */ +#include "main/core.h" /* for struct gl_context */ } #include "ast.h" @@ -36,7 +36,7 @@ extern "C" { #include "ir_optimization.h" #include "loop_analysis.h" -_mesa_glsl_parse_state::_mesa_glsl_parse_state(struct __GLcontextRec *ctx, +_mesa_glsl_parse_state::_mesa_glsl_parse_state(struct gl_context *ctx, GLenum target, void *mem_ctx) { switch (target) { @@ -181,6 +181,13 @@ _mesa_glsl_process_extension(const char *name, YYLTYPE *name_locp, state->ARB_draw_buffers_enable = (ext_mode != extension_disable); state->ARB_draw_buffers_warn = (ext_mode == extension_warn); } + } else if (strcmp(name, "GL_ARB_explicit_attrib_location") == 0) { + state->ARB_explicit_attrib_location_enable = + (ext_mode != extension_disable); + state->ARB_explicit_attrib_location_warn = + (ext_mode == extension_warn); + + unsupported = !state->extensions->ARB_explicit_attrib_location; } else if (strcmp(name, "GL_ARB_fragment_coord_conventions") == 0) { state->ARB_fragment_coord_conventions_enable = (ext_mode != extension_disable); @@ -196,6 +203,14 @@ _mesa_glsl_process_extension(const char *name, YYLTYPE *name_locp, state->EXT_texture_array_warn = (ext_mode == extension_warn); unsupported = !state->extensions->EXT_texture_array; + } else if (strcmp(name, "GL_ARB_shader_stencil_export") == 0) { + if (state->target != fragment_shader) { + unsupported = true; + } else { + state->ARB_shader_stencil_export_enable = (ext_mode != extension_disable); + state->ARB_shader_stencil_export_warn = (ext_mode == extension_warn); + unsupported = !state->extensions->ARB_shader_stencil_export; + } } else { unsupported = true; } @@ -219,37 +234,37 @@ _mesa_glsl_process_extension(const char *name, YYLTYPE *name_locp, void _mesa_ast_type_qualifier_print(const struct ast_type_qualifier *q) { - if (q->constant) + if (q->flags.q.constant) printf("const "); - if (q->invariant) + if (q->flags.q.invariant) printf("invariant "); - if (q->attribute) + if (q->flags.q.attribute) printf("attribute "); - if (q->varying) + if (q->flags.q.varying) printf("varying "); - if (q->in && q->out) + if (q->flags.q.in && q->flags.q.out) printf("inout "); else { - if (q->in) + if (q->flags.q.in) printf("in "); - if (q->out) + if (q->flags.q.out) printf("out "); } - if (q->centroid) + if (q->flags.q.centroid) printf("centroid "); - if (q->uniform) + if (q->flags.q.uniform) printf("uniform "); - if (q->smooth) + if (q->flags.q.smooth) printf("smooth "); - if (q->flat) + if (q->flags.q.flat) printf("flat "); - if (q->noperspective) + if (q->flags.q.noperspective) printf("noperspective "); } @@ -680,6 +695,11 @@ ast_struct_specifier::print(void) const ast_struct_specifier::ast_struct_specifier(char *identifier, ast_node *declarator_list) { + if (identifier == NULL) { + static unsigned anon_count = 1; + identifier = talloc_asprintf(this, "#anon_struct_%04x", anon_count); + anon_count++; + } name = identifier; this->declarations.push_degenerate_list_at_head(&declarator_list->link); } diff --git a/src/glsl/glsl_parser_extras.h b/src/glsl/glsl_parser_extras.h index ddc2138b76..1f039e9f1b 100644 --- a/src/glsl/glsl_parser_extras.h +++ b/src/glsl/glsl_parser_extras.h @@ -41,10 +41,10 @@ enum _mesa_glsl_parser_targets { ir_shader }; -struct __GLcontextRec; +struct gl_context; struct _mesa_glsl_parse_state { - _mesa_glsl_parse_state(struct __GLcontextRec *ctx, GLenum target, + _mesa_glsl_parse_state(struct gl_context *ctx, GLenum target, void *mem_ctx); /* Callers of this talloc-based new need not call delete. It's @@ -125,12 +125,16 @@ struct _mesa_glsl_parse_state { /*@{*/ unsigned ARB_draw_buffers_enable:1; unsigned ARB_draw_buffers_warn:1; + unsigned ARB_explicit_attrib_location_enable:1; + unsigned ARB_explicit_attrib_location_warn:1; unsigned ARB_fragment_coord_conventions_enable:1; unsigned ARB_fragment_coord_conventions_warn:1; unsigned ARB_texture_rectangle_enable:1; unsigned ARB_texture_rectangle_warn:1; unsigned EXT_texture_array_enable:1; unsigned EXT_texture_array_warn:1; + unsigned ARB_shader_stencil_export_enable:1; + unsigned ARB_shader_stencil_export_warn:1; /*@}*/ /** Extensions supported by the OpenGL implementation. */ diff --git a/src/glsl/glsl_types.h b/src/glsl/glsl_types.h index 4f7d2f74af..dccab0a60d 100644 --- a/src/glsl/glsl_types.h +++ b/src/glsl/glsl_types.h @@ -149,6 +149,8 @@ struct glsl_type { static const glsl_type *const int_type; static const glsl_type *const ivec4_type; static const glsl_type *const uint_type; + static const glsl_type *const uvec2_type; + static const glsl_type *const uvec3_type; static const glsl_type *const uvec4_type; static const glsl_type *const float_type; static const glsl_type *const vec2_type; diff --git a/src/glsl/ir.cpp b/src/glsl/ir.cpp index 7cc55d40b7..87e78eee05 100644 --- a/src/glsl/ir.cpp +++ b/src/glsl/ir.cpp @@ -55,6 +55,9 @@ update_rhs_swizzle(ir_swizzle_mask &m, unsigned from, unsigned to) void ir_assignment::set_lhs(ir_rvalue *lhs) { + void *mem_ctx = this; + bool swizzled = false; + while (lhs != NULL) { ir_swizzle *swiz = lhs->as_swizzle(); @@ -82,7 +85,21 @@ ir_assignment::set_lhs(ir_rvalue *lhs) this->write_mask = write_mask; lhs = swiz->val; - this->rhs = new(this) ir_swizzle(this->rhs, rhs_swiz); + this->rhs = new(mem_ctx) ir_swizzle(this->rhs, rhs_swiz); + swizzled = true; + } + + if (swizzled) { + /* Now, RHS channels line up with the LHS writemask. Collapse it + * to just the channels that will be written. + */ + ir_swizzle_mask rhs_swiz = { 0, 0, 0, 0, 0, 0 }; + int rhs_chan = 0; + for (int i = 0; i < 4; i++) { + if (write_mask & (1 << i)) + update_rhs_swizzle(rhs_swiz, i, rhs_chan++); + } + this->rhs = new(mem_ctx) ir_swizzle(this->rhs, rhs_swiz); } assert((lhs == NULL) || lhs->as_dereference()); @@ -122,6 +139,16 @@ ir_assignment::ir_assignment(ir_dereference *lhs, ir_rvalue *rhs, this->rhs = rhs; this->lhs = lhs; this->write_mask = write_mask; + + if (lhs->type->is_scalar() || lhs->type->is_vector()) { + int lhs_components = 0; + for (int i = 0; i < 4; i++) { + if (write_mask & (1 << i)) + lhs_components++; + } + + assert(lhs_components == this->rhs->type->vector_elements); + } } ir_assignment::ir_assignment(ir_rvalue *lhs, ir_rvalue *rhs, @@ -189,6 +216,7 @@ ir_expression::get_num_operands(ir_expression_operation op) 1, /* ir_unop_ceil */ 1, /* ir_unop_floor */ 1, /* ir_unop_fract */ + 1, /* ir_unop_round_even */ 1, /* ir_unop_sin */ 1, /* ir_unop_cos */ @@ -261,6 +289,7 @@ static const char *const operator_strs[] = { "ceil", "floor", "fract", + "round_even", "sin", "cos", "dFdx", @@ -1044,6 +1073,7 @@ ir_variable::ir_variable(const struct glsl_type *type, const char *name, this->ir_type = ir_type_variable; this->type = type; this->name = talloc_strdup(this, name); + this->explicit_location = false; this->location = -1; this->warn_extension = NULL; this->constant_value = NULL; diff --git a/src/glsl/ir.h b/src/glsl/ir.h index b3b15bb08e..06198e4f3f 100644 --- a/src/glsl/ir.h +++ b/src/glsl/ir.h @@ -41,7 +41,31 @@ extern "C" { #define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0])) #endif +/** + * \defgroup IR Intermediate representation nodes + * + * @{ + */ + +/** + * Class tags + * + * Each concrete class derived from \c ir_instruction has a value in this + * enumerant. The value for the type is stored in \c ir_instruction::ir_type + * by the constructor. While using type tags is not very C++, it is extremely + * convenient. For example, during debugging you can simply inspect + * \c ir_instruction::ir_type to find out the actual type of the object. + * + * In addition, it is possible to use a switch-statement based on \c + * \c ir_instruction::ir_type to select different behavior for different object + * types. For functions that have only slight differences for several object + * types, this allows writing very straightforward, readable code. + */ enum ir_node_type { + /** + * Zero is unused so that the IR validator can detect cases where + * \c ir_instruction::ir_type has not been initialized. + */ ir_type_unset, ir_type_variable, ir_type_assignment, @@ -156,9 +180,12 @@ protected: }; +/** + * Variable storage classes + */ enum ir_variable_mode { - ir_var_auto = 0, - ir_var_uniform, + ir_var_auto = 0, /**< Function local variables and globals. */ + ir_var_uniform, /**< Variable declared as a uniform. */ ir_var_in, ir_var_out, ir_var_inout, @@ -209,6 +236,9 @@ public: */ unsigned component_slots() const; + /** + * Delcared name of the variable + */ const char *name; /** @@ -218,11 +248,28 @@ public: */ unsigned max_array_access; + /** + * Is the variable read-only? + * + * This is set for variables declared as \c const, shader inputs, + * and uniforms. + */ unsigned read_only:1; unsigned centroid:1; unsigned invariant:1; + /** + * Storage class of the variable. + * + * \sa ir_variable_mode + */ unsigned mode:3; + + /** + * Interpolation mode for shader inputs / outputs + * + * \sa ir_variable_interpolation + */ unsigned interpolation:2; /** @@ -233,9 +280,22 @@ public: */ unsigned array_lvalue:1; - /* ARB_fragment_coord_conventions */ + /** + * \name ARB_fragment_coord_conventions + * @{ + */ unsigned origin_upper_left:1; unsigned pixel_center_integer:1; + /*@}*/ + + /** + * Was the location explicitly set in the shader? + * + * If the location is explicitly set in the shader, it \b cannot be changed + * by the linker or by the API (e.g., calls to \c glBindAttribLocation have + * no effect). + */ + unsigned explicit_location:1; /** * Storage location of the base of this variable @@ -595,6 +655,14 @@ public: * For non-vector types in the LHS, this field will be zero. For vector * types, a bit will be set for each component that is written. Note that * for \c vec2 and \c vec3 types only the lower bits will ever be set. + * + * A partially-set write mask means that each enabled channel gets + * the value from a consecutive channel of the rhs. For example, + * to write just .xyw of gl_FrontColor with color: + * + * (assign (constant bool (1)) (xyw) + * (var_ref gl_FragColor) + * (swiz xyw (var_ref color))) */ unsigned write_mask:4; }; @@ -632,6 +700,7 @@ enum ir_expression_operation { ir_unop_ceil, ir_unop_floor, ir_unop_fract, + ir_unop_round_even, /*@}*/ /** @@ -668,7 +737,8 @@ enum ir_expression_operation { ir_binop_mod, /** - * \name Binary comparison operators + * \name Binary comparison operators which return a boolean vector. + * The type of both operands must be equal. */ /*@{*/ ir_binop_less, @@ -724,9 +794,22 @@ public: virtual ir_expression *clone(void *mem_ctx, struct hash_table *ht) const; + /** + * Attempt to constant-fold the expression + * + * If the expression cannot be constant folded, this method will return + * \c NULL. + */ virtual ir_constant *constant_expression_value(); + /** + * Determine the number of operands used by an expression + */ static unsigned int get_num_operands(ir_expression_operation); + + /** + * Determine the number of operands used by an expression + */ unsigned int get_num_operands() const { return get_num_operands(operation); @@ -813,6 +896,9 @@ public: return callee->function_name(); } + /** + * Get the function signature bound to this function call + */ ir_function_signature *get_callee() { return callee; @@ -977,11 +1063,11 @@ public: * Texture sampling opcodes used in ir_texture */ enum ir_texture_opcode { - ir_tex, /* Regular texture look-up */ - ir_txb, /* Texture look-up with LOD bias */ - ir_txl, /* Texture look-up with explicit LOD */ - ir_txd, /* Texture look-up with partial derivatvies */ - ir_txf /* Texel fetch with explicit LOD */ + ir_tex, /**< Regular texture look-up */ + ir_txb, /**< Texture look-up with LOD bias */ + ir_txl, /**< Texture look-up with explicit LOD */ + ir_txd, /**< Texture look-up with partial derivatvies */ + ir_txf /**< Texel fetch with explicit LOD */ }; @@ -1384,9 +1470,17 @@ private: ir_constant(void); }; +/*@}*/ + +/** + * Apply a visitor to each IR node in a list + */ void visit_exec_list(exec_list *list, ir_visitor *visitor); +/** + * Validate invariants on each IR node in a list + */ void validate_ir_tree(exec_list *instructions); /** diff --git a/src/glsl/ir_clone.cpp b/src/glsl/ir_clone.cpp index 18543a35aa..a3cc8dbc97 100644 --- a/src/glsl/ir_clone.cpp +++ b/src/glsl/ir_clone.cpp @@ -51,6 +51,9 @@ ir_variable::clone(void *mem_ctx, struct hash_table *ht) const var->warn_extension = this->warn_extension; var->origin_upper_left = this->origin_upper_left; var->pixel_center_integer = this->pixel_center_integer; + var->explicit_location = this->explicit_location; + if (this->explicit_location) + var->location = this->location; if (this->constant_value) var->constant_value = this->constant_value->clone(mem_ctx, ht); diff --git a/src/glsl/ir_constant_expression.cpp b/src/glsl/ir_constant_expression.cpp index ec0e26de18..048c020c83 100644 --- a/src/glsl/ir_constant_expression.cpp +++ b/src/glsl/ir_constant_expression.cpp @@ -100,6 +100,21 @@ ir_expression::constant_expression_value() } switch (this->operation) { + case ir_unop_bit_not: + switch (op[0]->type->base_type) { + case GLSL_TYPE_INT: + for (unsigned c = 0; c < components; c++) + data.i[c] = ~ op[0]->value.i[c]; + break; + case GLSL_TYPE_UINT: + for (unsigned c = 0; c < components; c++) + data.u[c] = ~ op[0]->value.u[c]; + break; + default: + assert(0); + } + break; + case ir_unop_logic_not: assert(op[0]->type->base_type == GLSL_TYPE_BOOL); for (unsigned c = 0; c < op[0]->type->components(); c++) @@ -623,36 +638,41 @@ ir_expression::constant_expression_value() } break; case ir_binop_equal: - switch (op[0]->type->base_type) { - case GLSL_TYPE_UINT: - data.b[0] = op[0]->value.u[0] == op[1]->value.u[0]; - break; - case GLSL_TYPE_INT: - data.b[0] = op[0]->value.i[0] == op[1]->value.i[0]; - break; - case GLSL_TYPE_FLOAT: - data.b[0] = op[0]->value.f[0] == op[1]->value.f[0]; - break; - default: - assert(0); + assert(op[0]->type == op[1]->type); + for (unsigned c = 0; c < components; c++) { + switch (op[0]->type->base_type) { + case GLSL_TYPE_UINT: + data.b[c] = op[0]->value.u[c] == op[1]->value.u[c]; + break; + case GLSL_TYPE_INT: + data.b[c] = op[0]->value.i[c] == op[1]->value.i[c]; + break; + case GLSL_TYPE_FLOAT: + data.b[c] = op[0]->value.f[c] == op[1]->value.f[c]; + break; + default: + assert(0); + } } break; case ir_binop_nequal: - switch (op[0]->type->base_type) { - case GLSL_TYPE_UINT: - data.b[0] = op[0]->value.u[0] != op[1]->value.u[0]; - break; - case GLSL_TYPE_INT: - data.b[0] = op[0]->value.i[0] != op[1]->value.i[0]; - break; - case GLSL_TYPE_FLOAT: - data.b[0] = op[0]->value.f[0] != op[1]->value.f[0]; - break; - default: - assert(0); + assert(op[0]->type != op[1]->type); + for (unsigned c = 0; c < components; c++) { + switch (op[0]->type->base_type) { + case GLSL_TYPE_UINT: + data.b[c] = op[0]->value.u[c] != op[1]->value.u[c]; + break; + case GLSL_TYPE_INT: + data.b[c] = op[0]->value.i[c] != op[1]->value.i[c]; + break; + case GLSL_TYPE_FLOAT: + data.b[c] = op[0]->value.f[c] != op[1]->value.f[c]; + break; + default: + assert(0); + } } break; - case ir_binop_all_equal: data.b[0] = op[0]->has_value(op[1]); break; @@ -660,6 +680,108 @@ ir_expression::constant_expression_value() data.b[0] = !op[0]->has_value(op[1]); break; + case ir_binop_lshift: + for (unsigned c = 0, c0 = 0, c1 = 0; + c < components; + c0 += c0_inc, c1 += c1_inc, c++) { + + if (op[0]->type->base_type == GLSL_TYPE_INT && + op[1]->type->base_type == GLSL_TYPE_INT) { + data.i[c] = op[0]->value.i[c0] << op[1]->value.i[c1]; + + } else if (op[0]->type->base_type == GLSL_TYPE_INT && + op[1]->type->base_type == GLSL_TYPE_UINT) { + data.i[c] = op[0]->value.i[c0] << op[1]->value.u[c1]; + + } else if (op[0]->type->base_type == GLSL_TYPE_UINT && + op[1]->type->base_type == GLSL_TYPE_INT) { + data.u[c] = op[0]->value.u[c0] << op[1]->value.i[c1]; + + } else if (op[0]->type->base_type == GLSL_TYPE_UINT && + op[1]->type->base_type == GLSL_TYPE_UINT) { + data.u[c] = op[0]->value.u[c0] << op[1]->value.u[c1]; + } + } + break; + + case ir_binop_rshift: + for (unsigned c = 0, c0 = 0, c1 = 0; + c < components; + c0 += c0_inc, c1 += c1_inc, c++) { + + if (op[0]->type->base_type == GLSL_TYPE_INT && + op[1]->type->base_type == GLSL_TYPE_INT) { + data.i[c] = op[0]->value.i[c0] >> op[1]->value.i[c1]; + + } else if (op[0]->type->base_type == GLSL_TYPE_INT && + op[1]->type->base_type == GLSL_TYPE_UINT) { + data.i[c] = op[0]->value.i[c0] >> op[1]->value.u[c1]; + + } else if (op[0]->type->base_type == GLSL_TYPE_UINT && + op[1]->type->base_type == GLSL_TYPE_INT) { + data.u[c] = op[0]->value.u[c0] >> op[1]->value.i[c1]; + + } else if (op[0]->type->base_type == GLSL_TYPE_UINT && + op[1]->type->base_type == GLSL_TYPE_UINT) { + data.u[c] = op[0]->value.u[c0] >> op[1]->value.u[c1]; + } + } + break; + + case ir_binop_bit_and: + for (unsigned c = 0, c0 = 0, c1 = 0; + c < components; + c0 += c0_inc, c1 += c1_inc, c++) { + + switch (op[0]->type->base_type) { + case GLSL_TYPE_INT: + data.i[c] = op[0]->value.i[c0] & op[1]->value.i[c1]; + break; + case GLSL_TYPE_UINT: + data.u[c] = op[0]->value.u[c0] & op[1]->value.u[c1]; + break; + default: + assert(0); + } + } + break; + + case ir_binop_bit_or: + for (unsigned c = 0, c0 = 0, c1 = 0; + c < components; + c0 += c0_inc, c1 += c1_inc, c++) { + + switch (op[0]->type->base_type) { + case GLSL_TYPE_INT: + data.i[c] = op[0]->value.i[c0] | op[1]->value.i[c1]; + break; + case GLSL_TYPE_UINT: + data.u[c] = op[0]->value.u[c0] | op[1]->value.u[c1]; + break; + default: + assert(0); + } + } + break; + + case ir_binop_bit_xor: + for (unsigned c = 0, c0 = 0, c1 = 0; + c < components; + c0 += c0_inc, c1 += c1_inc, c++) { + + switch (op[0]->type->base_type) { + case GLSL_TYPE_INT: + data.i[c] = op[0]->value.i[c0] ^ op[1]->value.i[c1]; + break; + case GLSL_TYPE_UINT: + data.u[c] = op[0]->value.u[c0] ^ op[1]->value.u[c1]; + break; + default: + assert(0); + } + } + break; + default: /* FINISHME: Should handle all expression types. */ return NULL; @@ -746,7 +868,7 @@ ir_dereference_array::constant_expression_value() */ const unsigned mat_idx = column * column_type->vector_elements; - ir_constant_data data; + ir_constant_data data = { { 0 } }; switch (column_type->base_type) { case GLSL_TYPE_UINT: diff --git a/src/glsl/ir_constant_propagation.cpp b/src/glsl/ir_constant_propagation.cpp index f7a0599f42..5d875b7be0 100644 --- a/src/glsl/ir_constant_propagation.cpp +++ b/src/glsl/ir_constant_propagation.cpp @@ -1,5 +1,5 @@ /* - * Constantright © 2010 Intel Corporation + * Copyright © 2010 Intel Corporation * * Permission is hereby granted, free of charge, to any person obtaining a * constant of this software and associated documentation files (the "Software"), @@ -168,18 +168,26 @@ ir_constant_propagation_visitor::handle_rvalue(ir_rvalue **rvalue) if (!found) return; + int rhs_channel = 0; + for (int j = 0; j < 4; j++) { + if (j == channel) + break; + if (found->write_mask & (1 << j)) + rhs_channel++; + } + switch (type->base_type) { case GLSL_TYPE_FLOAT: - data.f[i] = found->constant->value.f[channel]; + data.f[i] = found->constant->value.f[rhs_channel]; break; case GLSL_TYPE_INT: - data.i[i] = found->constant->value.i[channel]; + data.i[i] = found->constant->value.i[rhs_channel]; break; case GLSL_TYPE_UINT: - data.u[i] = found->constant->value.u[channel]; + data.u[i] = found->constant->value.u[rhs_channel]; break; case GLSL_TYPE_BOOL: - data.b[i] = found->constant->value.b[channel]; + data.b[i] = found->constant->value.b[rhs_channel]; break; default: assert(!"not reached"); diff --git a/src/glsl/ir_function_inlining.cpp b/src/glsl/ir_function_inlining.cpp index 874602c84f..147c1824c1 100644 --- a/src/glsl/ir_function_inlining.cpp +++ b/src/glsl/ir_function_inlining.cpp @@ -153,6 +153,13 @@ ir_call::generate_inline(ir_instruction *next_ir) } else { parameters[i] = sig_param->clone(ctx, ht); parameters[i]->mode = ir_var_auto; + + /* Remove the read-only decoration becuase we're going to write + * directly to this variable. If the cloned variable is left + * read-only and the inlined function is inside a loop, the loop + * analysis code will get confused. + */ + parameters[i]->read_only = false; next_ir->insert_before(parameters[i]); } diff --git a/src/glsl/ir_mat_op_to_vec.cpp b/src/glsl/ir_mat_op_to_vec.cpp index c32ca88b0f..244fe48928 100644 --- a/src/glsl/ir_mat_op_to_vec.cpp +++ b/src/glsl/ir_mat_op_to_vec.cpp @@ -310,14 +310,11 @@ ir_mat_op_to_vec_visitor::do_equal_mat_mat(ir_variable *result_var, new(this->mem_ctx) ir_expression(ir_binop_any_nequal, glsl_type::bool_type, op0, op1); - ir_rvalue *const swiz = - new(this->mem_ctx) ir_swizzle(cmp, i, i, i, i, columns); - ir_dereference *const lhs = new(this->mem_ctx) ir_dereference_variable(tmp_bvec); ir_assignment *const assign = - new(this->mem_ctx) ir_assignment(lhs, swiz, NULL, (1U << i)); + new(this->mem_ctx) ir_assignment(lhs, cmp, NULL, (1U << i)); this->base_ir->insert_before(assign); } diff --git a/src/glsl/ir_noop_swizzle.cpp b/src/glsl/ir_noop_swizzle.cpp index b78c87b47f..0403dfa4e9 100644 --- a/src/glsl/ir_noop_swizzle.cpp +++ b/src/glsl/ir_noop_swizzle.cpp @@ -61,9 +61,9 @@ ir_noop_swizzle_visitor::handle_rvalue(ir_rvalue **rvalue) return; if (elems >= 2 && swiz->mask.y != 1) return; - if (elems >= 3 && swiz->mask.z != 1) + if (elems >= 3 && swiz->mask.z != 2) return; - if (elems >= 4 && swiz->mask.w != 1) + if (elems >= 4 && swiz->mask.w != 3) return; this->progress = true; diff --git a/src/glsl/ir_optimization.h b/src/glsl/ir_optimization.h index 6a37e167fe..ffdc66b9f7 100644 --- a/src/glsl/ir_optimization.h +++ b/src/glsl/ir_optimization.h @@ -44,6 +44,7 @@ bool do_div_to_mul_rcp(exec_list *instructions); bool do_explog_to_explog2(exec_list *instructions); bool do_function_inlining(exec_list *instructions); bool do_lower_jumps(exec_list *instructions, bool pull_out_jumps = true, bool lower_sub_return = true, bool lower_main_return = false, bool lower_continue = false, bool lower_break = false); +bool do_lower_texture_projection(exec_list *instructions); bool do_if_simplification(exec_list *instructions); bool do_if_to_cond_assign(exec_list *instructions); bool do_mat_op_to_vec(exec_list *instructions); diff --git a/src/glsl/ir_validate.cpp b/src/glsl/ir_validate.cpp index 58ab8aa58f..d22789f990 100644 --- a/src/glsl/ir_validate.cpp +++ b/src/glsl/ir_validate.cpp @@ -67,6 +67,7 @@ public: virtual ir_visitor_status visit_enter(ir_function_signature *ir); virtual ir_visitor_status visit_leave(ir_expression *ir); + virtual ir_visitor_status visit_leave(ir_swizzle *ir); virtual ir_visitor_status visit_enter(ir_assignment *ir); @@ -124,7 +125,8 @@ ir_validate::visit_leave(ir_loop *ir) " from: %p\n" " to: %p\n" " increment: %p\n", - ir->counter, ir->from, ir->to, ir->increment); + (void *) ir->counter, (void *) ir->from, (void *) ir->to, + (void *) ir->increment); abort(); } @@ -139,7 +141,8 @@ ir_validate::visit_leave(ir_loop *ir) " from: %p\n" " to: %p\n" " increment: %p\n", - ir->counter, ir->from, ir->to, ir->increment); + (void *) ir->counter, (void *) ir->from, (void *) ir->to, + (void *) ir->increment); abort(); } } @@ -264,6 +267,7 @@ ir_validate::visit_leave(ir_expression *ir) break; case ir_unop_trunc: + case ir_unop_round_even: case ir_unop_ceil: case ir_unop_floor: case ir_unop_fract: @@ -328,14 +332,31 @@ ir_validate::visit_leave(ir_expression *ir) case ir_binop_lshift: case ir_binop_rshift: + assert(ir->operands[0]->type->is_integer() && + ir->operands[1]->type->is_integer()); + if (ir->operands[0]->type->is_scalar()) { + assert(ir->operands[1]->type->is_scalar()); + } + if (ir->operands[0]->type->is_vector() && + ir->operands[1]->type->is_vector()) { + assert(ir->operands[0]->type->components() == + ir->operands[1]->type->components()); + } + assert(ir->type == ir->operands[0]->type); + break; + case ir_binop_bit_and: case ir_binop_bit_xor: case ir_binop_bit_or: - assert(ir->operands[0]->type == ir->operands[1]->type); - assert(ir->type == ir->operands[0]->type); - assert(ir->type->base_type == GLSL_TYPE_INT || - ir->type->base_type == GLSL_TYPE_UINT); - break; + assert(ir->operands[0]->type->base_type == + ir->operands[1]->type->base_type); + assert(ir->type->is_integer()); + if (ir->operands[0]->type->is_vector() && + ir->operands[1]->type->is_vector()) { + assert(ir->operands[0]->type->vector_elements == + ir->operands[1]->type->vector_elements); + } + break; case ir_binop_logic_and: case ir_binop_logic_xor: @@ -363,6 +384,23 @@ ir_validate::visit_leave(ir_expression *ir) } ir_visitor_status +ir_validate::visit_leave(ir_swizzle *ir) +{ + int chans[4] = {ir->mask.x, ir->mask.y, ir->mask.z, ir->mask.w}; + + for (unsigned int i = 0; i < ir->type->vector_elements; i++) { + if (chans[i] >= ir->val->type->vector_elements) { + printf("ir_swizzle @ %p specifies a channel not present " + "in the value.\n", (void *) ir); + ir->print(); + abort(); + } + } + + return visit_continue; +} + +ir_visitor_status ir_validate::visit(ir_variable *ir) { /* An ir_variable is the one thing that can (and will) appear multiple times @@ -389,14 +427,16 @@ ir_validate::visit_enter(ir_assignment *ir) abort(); } - /* Mask of fields that do not exist in the destination. These should - * not be written by the assignment. - */ - const unsigned invalid_mask = ~((1U << lhs->type->components()) - 1); + int lhs_components = 0; + for (int i = 0; i < 4; i++) { + if (ir->write_mask & (1 << i)) + lhs_components++; + } - if ((invalid_mask & ir->write_mask) != 0) { - printf("Assignment write mask enables invalid components for " - "type %s:\n", lhs->type->name); + if (lhs_components != ir->rhs->type->vector_elements) { + printf("Assignment count of LHS write mask channels enabled not\n" + "matching RHS vector size (%d LHS, %d RHS).\n", + lhs_components, ir->rhs->type->vector_elements); ir->print(); abort(); } diff --git a/src/glsl/ir_variable.cpp b/src/glsl/ir_variable.cpp index 3fed4d9e6e..f2c900f718 100644 --- a/src/glsl/ir_variable.cpp +++ b/src/glsl/ir_variable.cpp @@ -52,6 +52,7 @@ add_variable(const char *name, enum ir_variable_mode mode, int slot, } var->location = slot; + var->explicit_location = (slot >= 0); /* Once the variable is created an initialized, add it to the symbol table * and add the declaration to the IR stream. @@ -162,6 +163,9 @@ generate_110_uniforms(exec_list *instructions, state->Const.MaxTextureCoords); add_uniform(instructions, state, "gl_TextureMatrix", mat4_array_type); + add_uniform(instructions, state, "gl_TextureMatrixInverse", mat4_array_type); + add_uniform(instructions, state, "gl_TextureMatrixTranspose", mat4_array_type); + add_uniform(instructions, state, "gl_TextureMatrixInverseTranspose", mat4_array_type); add_uniform(instructions, state, "gl_DepthRange", state->symbols->get_type("gl_DepthRangeParameters")); @@ -418,6 +422,20 @@ generate_ARB_draw_buffers_variables(exec_list *instructions, } } +static void +generate_ARB_shader_stencil_export_variables(exec_list *instructions, + struct _mesa_glsl_parse_state *state, + bool warn) +{ + /* gl_FragStencilRefARB is only available in the fragment shader. + */ + ir_variable *const fd = + add_variable("gl_FragStencilRefARB", ir_var_out, FRAG_RESULT_STENCIL, + glsl_type::int_type, instructions, state->symbols); + + if (warn) + fd->warn_extension = "GL_ARB_shader_stencil_export"; +} static void generate_120_fs_variables(exec_list *instructions, @@ -467,6 +485,10 @@ initialize_fs_variables(exec_list *instructions, generate_130_fs_variables(instructions, state); break; } + + if (state->ARB_shader_stencil_export_enable) + generate_ARB_shader_stencil_export_variables(instructions, state, + state->ARB_shader_stencil_export_warn); } void diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index c2c662152e..64827da2f8 100644 --- a/src/glsl/linker.cpp +++ b/src/glsl/linker.cpp @@ -80,6 +80,10 @@ extern "C" { #include "linker.h" #include "ir_optimization.h" +extern "C" { +#include "main/shaderobj.h" +} + /** * Visitor that determines whether or not a variable is ever written. */ @@ -191,7 +195,7 @@ invalidate_variable_locations(gl_shader *sh, enum ir_variable_mode mode, /* Only assign locations for generic attributes / varyings / etc. */ - if (var->location >= generic_base) + if ((var->location >= generic_base) && !var->explicit_location) var->location = -1; } } @@ -321,6 +325,9 @@ cross_validate_globals(struct gl_shader_program *prog, */ glsl_symbol_table variables; for (unsigned i = 0; i < num_shaders; i++) { + if (shader_list[i] == NULL) + continue; + foreach_list(node, shader_list[i]->ir) { ir_variable *const var = ((ir_instruction *) node)->as_variable(); @@ -365,6 +372,19 @@ cross_validate_globals(struct gl_shader_program *prog, } } + if (var->explicit_location) { + if (existing->explicit_location + && (var->location != existing->location)) { + linker_error_printf(prog, "explicit locations for %s " + "`%s' have differing values\n", + mode_string(var), var->name); + return false; + } + + existing->location = var->location; + existing->explicit_location = true; + } + /* FINISHME: Handle non-constant initializers. */ if (var->constant_value != NULL) { @@ -407,7 +427,7 @@ bool cross_validate_uniforms(struct gl_shader_program *prog) { return cross_validate_globals(prog, prog->_LinkedShaders, - prog->_NumLinkedShaders, true); + MESA_SHADER_TYPES, true); } @@ -457,7 +477,7 @@ cross_validate_outputs_to_inputs(struct gl_shader_program *prog, */ if (input->type != output->type) { linker_error_printf(prog, - "%s shader output `%s' delcared as " + "%s shader output `%s' declared as " "type `%s', but %s shader input declared " "as type `%s'\n", producer_stage, output->name, @@ -706,7 +726,7 @@ get_main_function_signature(gl_shader *sh) * shader is returned. */ static struct gl_shader * -link_intrastage_shaders(GLcontext *ctx, +link_intrastage_shaders(struct gl_context *ctx, struct gl_shader_program *prog, struct gl_shader **shader_list, unsigned num_shaders) @@ -780,7 +800,7 @@ link_intrastage_shaders(GLcontext *ctx, return NULL; } - gl_shader *const linked = ctx->Driver.NewShader(NULL, 0, main->Type); + gl_shader *linked = ctx->Driver.NewShader(NULL, 0, main->Type); linked->ir = new(linked) exec_list; clone_ir_list(linked, linked->ir, main->ir); @@ -827,7 +847,11 @@ link_intrastage_shaders(GLcontext *ctx, assert(idx == num_linking_shaders); - link_function_calls(prog, linked, linking_shaders, num_linking_shaders); + if (!link_function_calls(prog, linked, linking_shaders, + num_linking_shaders)) { + ctx->Driver.DeleteShader(ctx, linked); + linked = NULL; + } free(linking_shaders); @@ -857,18 +881,26 @@ struct uniform_node { */ static void -update_uniform_array_sizes(struct gl_shader_program *prog) +update_array_sizes(struct gl_shader_program *prog) { - for (unsigned i = 0; i < prog->_NumLinkedShaders; i++) { + for (unsigned i = 0; i < MESA_SHADER_TYPES; i++) { + if (prog->_LinkedShaders[i] == NULL) + continue; + foreach_list(node, prog->_LinkedShaders[i]->ir) { ir_variable *const var = ((ir_instruction *) node)->as_variable(); - if ((var == NULL) || (var->mode != ir_var_uniform) || + if ((var == NULL) || (var->mode != ir_var_uniform && + var->mode != ir_var_in && + var->mode != ir_var_out) || !var->type->is_array()) continue; unsigned int size = var->max_array_access; - for (unsigned j = 0; j < prog->_NumLinkedShaders; j++) { + for (unsigned j = 0; j < MESA_SHADER_TYPES; j++) { + if (prog->_LinkedShaders[j] == NULL) + continue; + foreach_list(node2, prog->_LinkedShaders[j]->ir) { ir_variable *other_var = ((ir_instruction *) node2)->as_variable(); if (!other_var) @@ -880,6 +912,7 @@ update_uniform_array_sizes(struct gl_shader_program *prog) } } } + if (size + 1 != var->type->fields.array->length) { var->type = glsl_type::get_array_instance(var->type->fields.array, size + 1); @@ -979,9 +1012,10 @@ assign_uniform_locations(struct gl_shader_program *prog) hash_table_string_compare); void *mem_ctx = talloc_new(NULL); - update_uniform_array_sizes(prog); + for (unsigned i = 0; i < MESA_SHADER_TYPES; i++) { + if (prog->_LinkedShaders[i] == NULL) + continue; - for (unsigned i = 0; i < prog->_NumLinkedShaders; i++) { unsigned next_position = 0; foreach_list(node, prog->_LinkedShaders[i]->ir) { @@ -1185,6 +1219,24 @@ assign_attribute_locations(gl_shader_program *prog, unsigned max_attribute_index if ((var == NULL) || (var->mode != ir_var_in)) continue; + if (var->explicit_location) { + const unsigned slots = count_attribute_slots(var->type); + const unsigned use_mask = (1 << slots) - 1; + const int attr = var->location - VERT_ATTRIB_GENERIC0; + + if ((var->location >= (int)(max_attribute_index + VERT_ATTRIB_GENERIC0)) + || (var->location < 0)) { + linker_error_printf(prog, + "invalid explicit location %d specified for " + "`%s'\n", + (var->location < 0) ? var->location : attr, + var->name); + return false; + } else if (var->location >= VERT_ATTRIB_GENERIC0) { + used_locations |= (use_mask << attr); + } + } + /* The location was explicitly assigned, nothing to do here. */ if (var->location != -1) @@ -1354,7 +1406,7 @@ assign_varying_locations(struct gl_shader_program *prog, void -link_shaders(GLcontext *ctx, struct gl_shader_program *prog) +link_shaders(struct gl_context *ctx, struct gl_shader_program *prog) { prog->LinkStatus = false; prog->Validated = false; @@ -1413,13 +1465,15 @@ link_shaders(GLcontext *ctx, struct gl_shader_program *prog) prog->Version = max_version; - for (unsigned int i = 0; i < prog->_NumLinkedShaders; i++) { - ctx->Driver.DeleteShader(ctx, prog->_LinkedShaders[i]); + for (unsigned int i = 0; i < MESA_SHADER_TYPES; i++) { + if (prog->_LinkedShaders[i] != NULL) + ctx->Driver.DeleteShader(ctx, prog->_LinkedShaders[i]); + + prog->_LinkedShaders[i] = NULL; } /* Link all shaders for a particular stage and validate the result. */ - prog->_NumLinkedShaders = 0; if (num_vert_shaders > 0) { gl_shader *const sh = link_intrastage_shaders(ctx, prog, vert_shader_list, num_vert_shaders); @@ -1428,10 +1482,10 @@ link_shaders(GLcontext *ctx, struct gl_shader_program *prog) goto done; if (!validate_vertex_shader_executable(prog, sh)) - goto done; + goto done; - prog->_LinkedShaders[prog->_NumLinkedShaders] = sh; - prog->_NumLinkedShaders++; + _mesa_reference_shader(ctx, &prog->_LinkedShaders[MESA_SHADER_VERTEX], + sh); } if (num_frag_shaders > 0) { @@ -1442,10 +1496,10 @@ link_shaders(GLcontext *ctx, struct gl_shader_program *prog) goto done; if (!validate_fragment_shader_executable(prog, sh)) - goto done; + goto done; - prog->_LinkedShaders[prog->_NumLinkedShaders] = sh; - prog->_NumLinkedShaders++; + _mesa_reference_shader(ctx, &prog->_LinkedShaders[MESA_SHADER_FRAGMENT], + sh); } /* Here begins the inter-stage linking phase. Some initial validation is @@ -1453,14 +1507,26 @@ link_shaders(GLcontext *ctx, struct gl_shader_program *prog) * varyings. */ if (cross_validate_uniforms(prog)) { + unsigned prev; + + for (prev = 0; prev < MESA_SHADER_TYPES; prev++) { + if (prog->_LinkedShaders[prev] != NULL) + break; + } + /* Validate the inputs of each stage with the output of the preceeding * stage. */ - for (unsigned i = 1; i < prog->_NumLinkedShaders; i++) { + for (unsigned i = prev + 1; i < MESA_SHADER_TYPES; i++) { + if (prog->_LinkedShaders[i] == NULL) + continue; + if (!cross_validate_outputs_to_inputs(prog, - prog->_LinkedShaders[i - 1], + prog->_LinkedShaders[prev], prog->_LinkedShaders[i])) goto done; + + prev = i; } prog->LinkStatus = true; @@ -1470,30 +1536,49 @@ link_shaders(GLcontext *ctx, struct gl_shader_program *prog) * uniforms, and varyings. Later optimization could possibly make * some of that unused. */ - for (unsigned i = 0; i < prog->_NumLinkedShaders; i++) { + for (unsigned i = 0; i < MESA_SHADER_TYPES; i++) { + if (prog->_LinkedShaders[i] == NULL) + continue; + while (do_common_optimization(prog->_LinkedShaders[i]->ir, true, 32)) ; } + update_array_sizes(prog); + assign_uniform_locations(prog); - if (prog->_NumLinkedShaders && prog->_LinkedShaders[0]->Type == GL_VERTEX_SHADER) { + if (prog->_LinkedShaders[MESA_SHADER_VERTEX] != NULL) { /* FINISHME: The value of the max_attribute_index parameter is * FINISHME: implementation dependent based on the value of * FINISHME: GL_MAX_VERTEX_ATTRIBS. GL_MAX_VERTEX_ATTRIBS must be * FINISHME: at least 16, so hardcode 16 for now. */ - if (!assign_attribute_locations(prog, 16)) + if (!assign_attribute_locations(prog, 16)) { + prog->LinkStatus = false; goto done; + } - if (prog->_NumLinkedShaders == 1) - demote_unread_shader_outputs(prog->_LinkedShaders[0]); + if ((prog->_LinkedShaders[MESA_SHADER_GEOMETRY] == NULL) + && (prog->_LinkedShaders[MESA_SHADER_FRAGMENT] == NULL)) + demote_unread_shader_outputs(prog->_LinkedShaders[MESA_SHADER_VERTEX]); } - for (unsigned i = 1; i < prog->_NumLinkedShaders; i++) + unsigned prev; + for (prev = 0; prev < MESA_SHADER_TYPES; prev++) { + if (prog->_LinkedShaders[prev] != NULL) + break; + } + + for (unsigned i = prev + 1; i < MESA_SHADER_TYPES; i++) { + if (prog->_LinkedShaders[i] == NULL) + continue; + assign_varying_locations(prog, - prog->_LinkedShaders[i - 1], + prog->_LinkedShaders[prev], prog->_LinkedShaders[i]); + prev = i; + } /* FINISHME: Assign fragment shader output locations. */ diff --git a/src/glsl/loop_unroll.cpp b/src/glsl/loop_unroll.cpp index 90797bde37..11709587e2 100644 --- a/src/glsl/loop_unroll.cpp +++ b/src/glsl/loop_unroll.cpp @@ -67,7 +67,7 @@ loop_unroll_visitor::visit_leave(ir_loop *ir) /* Don't try to unroll loops that have zillions of iterations either. */ - if (iterations > max_iterations) + if (iterations > (int) max_iterations) return visit_continue; if (ls->num_loop_jumps > 1) diff --git a/src/glsl/lower_texture_projection.cpp b/src/glsl/lower_texture_projection.cpp new file mode 100644 index 0000000000..1fd26a7a2b --- /dev/null +++ b/src/glsl/lower_texture_projection.cpp @@ -0,0 +1,99 @@ +/* + * Copyright © 2010 Intel Corporation + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + +/** + * \file lower_texture_projection.cpp + * + * IR lower pass to perform the division of texture coordinates by the texture + * projector if present. + * + * Many GPUs have a texture sampling opcode that takes the projector + * and does the divide internally, thus the presence of the projector + * in the IR. For GPUs that don't, this saves the driver needing the + * logic for handling the divide. + * + * \author Eric Anholt <eric@anholt.net> + */ + +#include "ir.h" + +class lower_texture_projection_visitor : public ir_hierarchical_visitor { +public: + lower_texture_projection_visitor() + { + progress = false; + } + + ir_visitor_status visit_leave(ir_texture *ir); + + bool progress; +}; + +ir_visitor_status +lower_texture_projection_visitor::visit_leave(ir_texture *ir) +{ + if (!ir->projector) + return visit_continue; + + void *mem_ctx = talloc_parent(ir); + + ir_variable *var = new(mem_ctx) ir_variable(ir->projector->type, + "projector", ir_var_auto); + base_ir->insert_before(var); + ir_dereference *deref = new(mem_ctx) ir_dereference_variable(var); + ir_expression *expr = new(mem_ctx) ir_expression(ir_unop_rcp, + ir->projector->type, + ir->projector, + NULL); + ir_assignment *assign = new(mem_ctx) ir_assignment(deref, expr, NULL); + base_ir->insert_before(assign); + + deref = new(mem_ctx) ir_dereference_variable(var); + ir->coordinate = new(mem_ctx) ir_expression(ir_binop_mul, + ir->coordinate->type, + ir->coordinate, + deref); + + if (ir->shadow_comparitor) { + deref = new(mem_ctx) ir_dereference_variable(var); + ir->shadow_comparitor = new(mem_ctx) ir_expression(ir_binop_mul, + ir->shadow_comparitor->type, + ir->shadow_comparitor, + deref); + } + + ir->projector = NULL; + + progress = true; + return visit_continue; +} + +bool +do_lower_texture_projection(exec_list *instructions) +{ + lower_texture_projection_visitor v; + + visit_list_elements(&v, instructions); + + return v.progress; +} diff --git a/src/glsl/lower_variable_index_to_cond_assign.cpp b/src/glsl/lower_variable_index_to_cond_assign.cpp index 68f30ca0ef..5f0dd73113 100644 --- a/src/glsl/lower_variable_index_to_cond_assign.cpp +++ b/src/glsl/lower_variable_index_to_cond_assign.cpp @@ -117,7 +117,7 @@ struct switch_generator new(this->mem_ctx) ir_dereference_variable(index); if (comps) { - const ir_swizzle_mask m = { 0, 1, 2, 3, comps, false }; + const ir_swizzle_mask m = { 0, 0, 0, 0, comps, false }; broadcast_index = new(this->mem_ctx) ir_swizzle(broadcast_index, m); } diff --git a/src/glsl/main.cpp b/src/glsl/main.cpp index 94c14a58a7..08a44c96e5 100644 --- a/src/glsl/main.cpp +++ b/src/glsl/main.cpp @@ -38,12 +38,23 @@ #include "loop_analysis.h" extern "C" struct gl_shader * -_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type); +_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type); + +extern "C" void +_mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr, + struct gl_shader *sh); /* Copied from shader_api.c for the stand-alone compiler. */ +void +_mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr, + struct gl_shader *sh) +{ + *ptr = sh; +} + struct gl_shader * -_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type) +_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type) { struct gl_shader *shader; @@ -60,7 +71,7 @@ _mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type) } static void -initialize_context(GLcontext *ctx, gl_api api) +initialize_context(struct gl_context *ctx, gl_api api) { memset(ctx, 0, sizeof(*ctx)); @@ -160,7 +171,7 @@ const struct option compiler_opts[] = { }; void -compile_shader(GLcontext *ctx, struct gl_shader *shader) +compile_shader(struct gl_context *ctx, struct gl_shader *shader) { struct _mesa_glsl_parse_state *state = new(shader) _mesa_glsl_parse_state(ctx, shader->Type, shader); @@ -252,8 +263,8 @@ int main(int argc, char **argv) { int status = EXIT_SUCCESS; - GLcontext local_ctx; - GLcontext *ctx = &local_ctx; + struct gl_context local_ctx; + struct gl_context *ctx = &local_ctx; int c; int idx = 0; @@ -319,7 +330,7 @@ main(int argc, char **argv) printf("Info log for linking:\n%s\n", whole_program->InfoLog); } - for (unsigned i = 0; i < whole_program->_NumLinkedShaders; i++) + for (unsigned i = 0; i < MESA_SHADER_TYPES; i++) talloc_free(whole_program->_LinkedShaders[i]); talloc_free(whole_program); diff --git a/src/glsl/program.h b/src/glsl/program.h index 893169b6cc..db602fa9ec 100644 --- a/src/glsl/program.h +++ b/src/glsl/program.h @@ -24,4 +24,4 @@ #include "main/core.h" extern void -link_shaders(GLcontext *ctx, struct gl_shader_program *prog); +link_shaders(struct gl_context *ctx, struct gl_shader_program *prog); |