diff options
Diffstat (limited to 'src/glsl')
184 files changed, 10652 insertions, 7001 deletions
diff --git a/src/glsl/.gitignore b/src/glsl/.gitignore index 4c212313e4..dfbd572d89 100644 --- a/src/glsl/.gitignore +++ b/src/glsl/.gitignore @@ -1,2 +1,7 @@ glsl_compiler +glsl_lexer.cpp +glsl_parser.cpp +glsl_parser.h glsl_parser.output +builtin_function.cpp +builtin_compiler diff --git a/src/glsl/Android.mk b/src/glsl/Android.mk index a69943604c..f7f733b0b6 100644 --- a/src/glsl/Android.mk +++ b/src/glsl/Android.mk @@ -1,3 +1,5 @@ +# Android.mk for glsl + LOCAL_PATH := $(call my-dir) # from Makefile @@ -7,6 +9,8 @@ LIBGLCPP_SOURCES = \ glcpp/pp.c C_SOURCES = \ + strtod.c \ + ralloc.c \ $(LIBGLCPP_SOURCES) CXX_SOURCES = \ @@ -14,7 +18,6 @@ CXX_SOURCES = \ ast_function.cpp \ ast_to_hir.cpp \ ast_type.cpp \ - builtin_function.cpp \ glsl_lexer.cpp \ glsl_parser.cpp \ glsl_parser_extras.cpp \ @@ -59,6 +62,7 @@ CXX_SOURCES = \ opt_constant_propagation.cpp \ opt_constant_variable.cpp \ opt_copy_propagation.cpp \ + opt_copy_propagation_elements.cpp \ opt_dead_code.cpp \ opt_dead_code_local.cpp \ opt_dead_functions.cpp \ @@ -76,7 +80,8 @@ include $(CLEAR_VARS) LOCAL_SRC_FILES := \ $(C_SOURCES) \ - $(CXX_SOURCES) + $(CXX_SOURCES) \ + builtin_function.cpp LOCAL_CFLAGS := \ -DPTHREADS \ @@ -88,7 +93,6 @@ LOCAL_CFLAGS := \ LOCAL_C_INCLUDES := \ external/mesa/include \ external/mesa/src/mapi \ - external/mesa/src/talloc \ external/mesa/src/mesa LOCAL_MODULE := libmesa_glsl diff --git a/src/glsl/Makefile b/src/glsl/Makefile index 2674c6ec48..cd7c41a2ab 100644 --- a/src/glsl/Makefile +++ b/src/glsl/Makefile @@ -1,3 +1,4 @@ + #src/glsl/pp/Makefile TOP = ../.. @@ -13,9 +14,12 @@ LIBGLCPP_SOURCES = \ GLCPP_SOURCES = \ $(LIBGLCPP_SOURCES) \ + ralloc.c \ glcpp/glcpp.c C_SOURCES = \ + strtod.c \ + ralloc.c \ $(LIBGLCPP_SOURCES) CXX_SOURCES = \ @@ -23,7 +27,6 @@ CXX_SOURCES = \ ast_function.cpp \ ast_to_hir.cpp \ ast_type.cpp \ - builtin_function.cpp \ glsl_lexer.cpp \ glsl_parser.cpp \ glsl_parser_extras.cpp \ @@ -68,6 +71,7 @@ CXX_SOURCES = \ opt_constant_propagation.cpp \ opt_constant_variable.cpp \ opt_copy_propagation.cpp \ + opt_copy_propagation_elements.cpp \ opt_dead_code.cpp \ opt_dead_code_local.cpp \ opt_dead_functions.cpp \ @@ -82,8 +86,7 @@ CXX_SOURCES = \ s_expression.cpp LIBS = \ - $(TOP)/src/glsl/libglsl.a \ - $(TALLOC_LIBS) + $(TOP)/src/glsl/libglsl.a APPS = glsl_compiler glcpp/glcpp @@ -111,8 +114,10 @@ OBJECTS = \ $(C_SOURCES:.c=.o) \ $(CXX_SOURCES:.cpp=.o) +DRICORE_OBJ_DIR = obj-visible +OBJECTS_DRICORE = $(addprefix $(DRICORE_OBJ_DIR)/,$(OBJECTS)) + INCLUDES = \ - $(TALLOC_CFLAGS) \ -I. \ -I../mesa \ -I../mapi \ @@ -127,10 +132,16 @@ ALL_SOURCES = \ ##### TARGETS ##### -default: depend lib$(LIBNAME).a $(APPS) +default: depend lib$(LIBNAME).a $(APPS) $(DRICORE_GLSL_LIBS) -lib$(LIBNAME).a: $(OBJECTS) Makefile $(TOP)/src/glsl/Makefile.template - $(MKLIB) -cplusplus -o $(LIBNAME) -static $(OBJECTS) +$(TOP)/$(LIB_DIR)/libglsl.so: $(OBJECTS_DRICORE) builtin_function.o Makefile $(TOP)/src/glsl/Makefile.template + $(MKLIB) -o $@ -linker '$(CXX)' -ldflags '$(LDFLAGS)' \ + -cplusplus -noprefix \ + -install $(TOP)/$(LIB_DIR) -id $(INSTALL_LIB_DIR)/$@.dylib \ + $(OBJECTS_DRICORE) builtin_function.o + +lib$(LIBNAME).a: $(OBJECTS) builtin_function.o Makefile $(TOP)/src/glsl/Makefile.template + $(MKLIB) -cplusplus -o $(LIBNAME) -static $(OBJECTS) builtin_function.o depend: $(ALL_SOURCES) Makefile rm -f depend @@ -138,22 +149,33 @@ depend: $(ALL_SOURCES) Makefile $(MKDEP) $(MKDEP_OPTIONS) $(INCLUDES) $(ALL_SOURCES) 2> /dev/null # Remove .o and backup files -clean: - rm -f $(GLCPP_OBJECTS) $(GLSL2_OBJECTS) $(OBJECTS) lib$(LIBNAME).a depend depend.bak +clean: clean-dricore + rm -f $(GLCPP_OBJECTS) $(GLSL2_OBJECTS) $(OBJECTS) lib$(LIBNAME).a depend depend.bak builtin_function.cpp builtin_function.o builtin_stubs.o builtin_compiler -rm -f $(APPS) +clean-dricore: + -rm -f $(DRICORE_OBJ_DIR) $(TOP)/$(LIB_DIR)/libglsl.so libglsl.so + +ifneq (,$(DRICORE_GLSL_LIBS)) +DRICORE_INSTALL_TARGET = install-dricore +endif + # Dummy target -install: +install: $(DRICORE_INSTALL_TARGET) @echo -n "" +install-dricore: default + $(INSTALL) -d $(DESTDIR)$(DRI_DRIVER_INSTALL_DIR) + $(INSTALL) -m 755 $(DRICORE_GLSL_LIBS) $(DESTDIR)$(DRI_DRIVER_INSTALL_DIR) ##### RULES ##### -glsl_compiler: $(GLSL2_OBJECTS) libglsl.a - $(APP_CXX) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(GLSL2_OBJECTS) $(LIBS) -o $@ +glsl_compiler: $(GLSL2_OBJECTS) libglsl.a builtin_stubs.o + $(APP_CXX) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(GLSL2_OBJECTS) builtin_stubs.o $(LIBS) -o $@ -glcpp/glcpp: $(GLCPP_OBJECTS) libglsl.a - $(APP_CC) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(GLCPP_OBJECTS) $(LIBS) -o $@ +glcpp: glcpp/glcpp +glcpp/glcpp: $(GLCPP_OBJECTS) + $(APP_CC) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(GLCPP_OBJECTS) -o $@ .cpp.o: $(CXX) -c $(INCLUDES) $(CXXFLAGS) $(DEFINES) $< -o $@ @@ -161,10 +183,18 @@ glcpp/glcpp: $(GLCPP_OBJECTS) libglsl.a .c.o: $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@ -glsl_lexer.cpp: glsl_lexer.lpp +$(DRICORE_OBJ_DIR)/%.o : %.cpp + @mkdir -p $(dir $@) + $(CXX) -c $(INCLUDES) $(DRI_CXXFLAGS) $(DEFINES) $< -o $@ + +$(DRICORE_OBJ_DIR)/%.o : %.c + @mkdir -p $(dir $@) + $(CC) -c $(INCLUDES) $(DRI_CFLAGS) $(DEFINES) $< -o $@ + +glsl_lexer.cpp: glsl_lexer.ll flex --nounistd -o$@ $< -glsl_parser.cpp: glsl_parser.ypp +glsl_parser.cpp: glsl_parser.yy bison -v -o "$@" -p "_mesa_glsl_" --defines=glsl_parser.h $< glcpp/glcpp-lex.c: glcpp/glcpp-lex.l @@ -173,13 +203,11 @@ glcpp/glcpp-lex.c: glcpp/glcpp-lex.l glcpp/glcpp-parse.c: glcpp/glcpp-parse.y bison -v -o "$@" --defines=glcpp/glcpp-parse.h $< -builtins: builtin_function.cpp builtins/profiles/* builtins/ir/* builtins/tools/generate_builtins.py builtins/tools/texture_builtins.py - @echo Bootstrapping the compiler... - cp builtins/tools/builtin_function.cpp . - make glsl_compiler +builtin_compiler: $(GLSL2_OBJECTS) $(OBJECTS) builtin_stubs.o + $(APP_CXX) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(OBJECTS) $(GLSL2_OBJECTS) builtin_stubs.o -o $@ + +builtin_function.cpp: builtins/profiles/* builtins/ir/* builtins/tools/generate_builtins.py builtins/tools/texture_builtins.py builtin_compiler @echo Regenerating builtin_function.cpp... - $(PYTHON2) $(PYTHON_FLAGS) builtins/tools/generate_builtins.py > builtin_function.cpp - @echo Rebuilding the real compiler... - make glsl_compiler + $(PYTHON2) $(PYTHON_FLAGS) builtins/tools/generate_builtins.py ./builtin_compiler > builtin_function.cpp || rm -f builtin_function.cpp -include depend diff --git a/src/glsl/SConscript b/src/glsl/SConscript index b5b1728bee..c3255835fb 100644 --- a/src/glsl/SConscript +++ b/src/glsl/SConscript @@ -2,27 +2,44 @@ import common Import('*') +from sys import executable as python_cmd + env = env.Clone() env.Prepend(CPPPATH = [ + '#include', '#src/mapi', '#src/mesa', + '#src/glsl', + '#src/glsl/glcpp', ]) -if env['platform'] == 'windows': - env.Prepend(CPPPATH = ['#src/talloc']) +# Make glcpp/glcpp-parse.h and glsl_parser.h reacheable from the include path +env.Append(CPPPATH = [Dir('.').abspath]) + +env.Append(YACCFLAGS = '-d') + +parser_env = env.Clone() +parser_env.Append(YACCFLAGS = [ + '--defines=%s' % File('glsl_parser.h').abspath, + '-p', '_mesa_glsl_', +]) -sources = [ - 'glcpp/glcpp-lex.c', - 'glcpp/glcpp-parse.c', +glcpp_lexer = env.CFile('glcpp/glcpp-lex.c', 'glcpp/glcpp-lex.l') +glcpp_parser = env.CFile('glcpp/glcpp-parse.c', 'glcpp/glcpp-parse.y') +glsl_lexer = parser_env.CXXFile('glsl_lexer.cpp', 'glsl_lexer.ll') +glsl_parser = parser_env.CXXFile('glsl_parser.cpp', 'glsl_parser.yy') + +glsl_sources = [ + glcpp_lexer, + glcpp_parser[0], 'glcpp/pp.c', 'ast_expr.cpp', 'ast_function.cpp', 'ast_to_hir.cpp', 'ast_type.cpp', - 'builtin_function.cpp', - 'glsl_lexer.cpp', - 'glsl_parser.cpp', + glsl_lexer, + glsl_parser[0], 'glsl_parser_extras.cpp', 'glsl_types.cpp', 'glsl_symbol_table.cpp', @@ -64,6 +81,7 @@ sources = [ 'opt_constant_propagation.cpp', 'opt_constant_variable.cpp', 'opt_copy_propagation.cpp', + 'opt_copy_propagation_elements.cpp', 'opt_dead_code.cpp', 'opt_dead_code_local.cpp', 'opt_dead_functions.cpp', @@ -75,18 +93,71 @@ sources = [ 'opt_structure_splitting.cpp', 'opt_swizzle_swizzle.cpp', 'opt_tree_grafting.cpp', + 'ralloc.c', 's_expression.cpp', -] + 'strtod.c', +] + +if env['msvc']: + env.Prepend(CPPPATH = ['#/src/getopt']) + env.PrependUnique(LIBS = [getopt]) + +if env['crosscompile'] and env['platform'] != 'embedded': + Import('builtin_glsl_function') +else: + # Copy these files to avoid generation object files into src/mesa/program + env.Prepend(CPPPATH = ['#src/mesa/program']) + env.Command('hash_table.c', '#src/mesa/program/hash_table.c', Copy('$TARGET', '$SOURCE')) + env.Command('symbol_table.c', '#src/mesa/program/symbol_table.c', Copy('$TARGET', '$SOURCE')) + + main_obj = env.StaticObject('main.cpp') + + mesa_objs = env.StaticObject([ + 'hash_table.c', + 'symbol_table.c', + ]) + + builtin_compiler = env.Program( + target = 'builtin_compiler', + source = main_obj + glsl_sources + ['builtin_stubs.cpp'] + mesa_objs, + ) + + # SCons builtin dependency scanner doesn't detect that glsl_lexer.ll + # depends on glsl_parser.h + env.Depends(builtin_compiler, glsl_parser) + + builtin_glsl_function = env.CodeGenerate( + target = 'builtin_function.cpp', + script = 'builtins/tools/generate_builtins.py', + source = builtin_compiler, + command = python_cmd + ' $SCRIPT $SOURCE > $TARGET' + ) + + env.Depends(builtin_glsl_function, ['builtins/tools/generate_builtins.py', 'builtins/tools/texture_builtins.py'] + Glob('builtins/ir/*')) + + Export('builtin_glsl_function') + + if env['hostonly']: + Return() + + +glsl_sources += builtin_glsl_function glsl = env.ConvenienceLibrary( target = 'glsl', - source = sources, + source = glsl_sources, ) +# SCons builtin dependency scanner doesn't detect that glsl_lexer.ll depends on +# glsl_parser.h +env.Depends(glsl, glsl_parser) + Export('glsl') -# FIXME: We can't build the programs because there's a cyclic dependency between tis directory and src/mesa -Return() +# Skip building these programs as they will cause SCons error "Two environments +# with different actions were specified for the same target" +if env['crosscompile'] or env['platform'] == 'embedded': + Return() env = env.Clone() @@ -95,16 +166,16 @@ if env['platform'] == 'windows': 'user32', ]) -env.Prepend(LIBS = [glsl, talloc]) +env.Prepend(LIBS = [glsl]) -env.Program( +glsl2 = env.Program( target = 'glsl2', - source = [ - 'main.cpp', - ] + source = main_obj + mesa_objs, ) +env.Alias('glsl2', glsl2) -env.Program( - target = 'glcpp', - source = ['glcpp/glcpp.c'], +glcpp = env.Program( + target = 'glcpp/glcpp', + source = ['glcpp/glcpp.c'] + mesa_objs, ) +env.Alias('glcpp', glcpp) diff --git a/src/glsl/ast.h b/src/glsl/ast.h index 1420f234b6..878f48b207 100644 --- a/src/glsl/ast.h +++ b/src/glsl/ast.h @@ -49,23 +49,23 @@ struct YYLTYPE; */ class ast_node { public: - /* Callers of this talloc-based new need not call delete. It's - * easier to just talloc_free 'ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'ctx' (or any of its ancestors). */ static void* operator new(size_t size, void *ctx) { void *node; - node = talloc_zero_size(ctx, size); + node = rzalloc_size(ctx, size); assert(node != NULL); return node; } /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. */ + * ralloc_free in that case. */ static void operator delete(void *table) { - talloc_free(table); + ralloc_free(table); } /** @@ -129,7 +129,6 @@ protected: * be created. */ ast_node(void); - virtual ~ast_node() {} }; @@ -319,7 +318,8 @@ public: enum { - ast_precision_high = 0, /**< Default precision. */ + ast_precision_none = 0, /**< Absence of precision qualifier. */ + ast_precision_high, ast_precision_medium, ast_precision_low }; @@ -350,7 +350,19 @@ struct ast_type_qualifier { * qualifier is used. */ unsigned explicit_location:1; - } q; + + /** \name Layout qualifiers for GL_AMD_conservative_depth */ + /** \{ */ + unsigned depth_any:1; + unsigned depth_greater:1; + unsigned depth_less:1; + unsigned depth_unchanged:1; + /** \} */ + } + /** \brief Set of flags, accessed by name. */ + q; + + /** \brief Set of flags, accessed as a bitmask. */ unsigned i; } flags; @@ -361,6 +373,23 @@ struct ast_type_qualifier { * This field is only valid if \c explicit_location is set. */ unsigned location; + + /** + * Return true if and only if an interpolation qualifier is present. + */ + bool has_interpolation() const; + + /** + * \brief Return string representation of interpolation qualifier. + * + * If an interpolation qualifier is present, then return that qualifier's + * string representation. Otherwise, return null. For example, if the + * noperspective bit is set, then this returns "noperspective". + * + * If multiple interpolation qualifiers are somehow present, then the + * returned string is undefined but not null. + */ + const char *interpolation_string() const; }; class ast_struct_specifier : public ast_node { @@ -441,7 +470,8 @@ public: /** Construct a type specifier from a type name */ ast_type_specifier(const char *name) : type_specifier(ast_type_name), type_name(name), structure(NULL), - is_array(false), array_size(NULL), precision(ast_precision_high) + is_array(false), array_size(NULL), precision(ast_precision_none), + is_precision_statement(false) { /* empty */ } @@ -449,7 +479,8 @@ public: /** Construct a type specifier from a structure definition */ ast_type_specifier(ast_struct_specifier *s) : type_specifier(ast_struct), type_name(s->name), structure(s), - is_array(false), array_size(NULL), precision(ast_precision_high) + is_array(false), array_size(NULL), precision(ast_precision_none), + is_precision_statement(false) { /* empty */ } @@ -471,6 +502,8 @@ public: ast_expression *array_size; unsigned precision:2; + + bool is_precision_statement; }; @@ -581,25 +614,6 @@ private: }; -class ast_declaration_statement : public ast_node { -public: - ast_declaration_statement(void); - - enum { - ast_function, - ast_declaration, - ast_precision - } mode; - - union { - class ast_function *function; - ast_declarator_list *declarator; - ast_type_specifier *type; - ast_node *node; - } declaration; -}; - - class ast_expression_statement : public ast_node { public: ast_expression_statement(ast_expression *); diff --git a/src/glsl/ast_expr.cpp b/src/glsl/ast_expr.cpp index 4e83decb92..e624d11cf3 100644 --- a/src/glsl/ast_expr.cpp +++ b/src/glsl/ast_expr.cpp @@ -20,8 +20,7 @@ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> -#include <cassert> +#include <assert.h> #include "ast.h" const char * diff --git a/src/glsl/ast_function.cpp b/src/glsl/ast_function.cpp index 6ecf779c93..e5cb873395 100644 --- a/src/glsl/ast_function.cpp +++ b/src/glsl/ast_function.cpp @@ -66,7 +66,7 @@ process_parameters(exec_list *instructions, exec_list *actual_parameters, * formal or actual parameter list. Only the type is used. * * \return - * A talloced string representing the prototype of the function. + * A ralloced string representing the prototype of the function. */ char * prototype_string(const glsl_type *return_type, const char *name, @@ -75,19 +75,19 @@ prototype_string(const glsl_type *return_type, const char *name, char *str = NULL; if (return_type != NULL) - str = talloc_asprintf(str, "%s ", return_type->name); + str = ralloc_asprintf(NULL, "%s ", return_type->name); - str = talloc_asprintf_append(str, "%s(", name); + ralloc_asprintf_append(&str, "%s(", name); const char *comma = ""; foreach_list(node, parameters) { const ir_instruction *const param = (ir_instruction *) node; - str = talloc_asprintf_append(str, "%s%s", comma, param->type->name); + ralloc_asprintf_append(&str, "%s%s", comma, param->type->name); comma = ", "; } - str = talloc_strdup_append(str, ")"); + ralloc_strcat(&str, ")"); return str; } @@ -132,6 +132,9 @@ match_function_by_name(exec_list *instructions, const char *name, /* Verify that 'out' and 'inout' actual parameters are lvalues. This * isn't done in ir_function::matching_signature because that function * cannot generate the necessary diagnostics. + * + * Also, validate that 'const_in' formal parameters (an extension of our + * IR) correspond to ir_constant actual parameters. */ exec_list_iterator actual_iter = actual_parameters->iterator(); exec_list_iterator formal_iter = sig->parameters.iterator(); @@ -143,14 +146,35 @@ match_function_by_name(exec_list *instructions, const char *name, assert(actual != NULL); assert(formal != NULL); + if (formal->mode == ir_var_const_in && !actual->as_constant()) { + _mesa_glsl_error(loc, state, + "parameter `%s' must be a constant expression", + formal->name); + } + if ((formal->mode == ir_var_out) || (formal->mode == ir_var_inout)) { - if (! actual->is_lvalue()) { - /* FINISHME: Log a better diagnostic here. There is no way - * FINISHME: to tell the user which parameter is invalid. - */ - _mesa_glsl_error(loc, state, "`%s' parameter is not lvalue", - (formal->mode == ir_var_out) ? "out" : "inout"); + const char *mode = NULL; + switch (formal->mode) { + case ir_var_out: mode = "out"; break; + case ir_var_inout: mode = "inout"; break; + default: assert(false); break; + } + /* FIXME: 'loc' is incorrect (as of 2011-01-21). It is always + * FIXME: 0:0(0). + */ + if (actual->variable_referenced() + && actual->variable_referenced()->read_only) { + _mesa_glsl_error(loc, state, + "function parameter '%s %s' references the " + "read-only variable '%s'", + mode, formal->name, + actual->variable_referenced()->name); + + } else if (!actual->is_lvalue()) { + _mesa_glsl_error(loc, state, + "function parameter '%s %s' is not an lvalue", + mode, formal->name); } } @@ -173,7 +197,7 @@ match_function_by_name(exec_list *instructions, const char *name, ir_dereference_variable *deref; var = new(ctx) ir_variable(sig->return_type, - talloc_asprintf(ctx, "%s_retval", + ralloc_asprintf(ctx, "%s_retval", sig->function_name()), ir_var_temporary); instructions->push_tail(var); @@ -195,11 +219,11 @@ match_function_by_name(exec_list *instructions, const char *name, _mesa_glsl_error(loc, state, "no matching function for call to `%s'", str); - talloc_free(str); + ralloc_free(str); const char *prefix = "candidates are: "; - for (int i = -1; i < state->num_builtins_to_link; i++) { + for (int i = -1; i < (int) state->num_builtins_to_link; i++) { glsl_symbol_table *syms = i >= 0 ? state->builtins_to_link[i]->symbols : state->symbols; f = syms->get_function(name); @@ -211,7 +235,7 @@ match_function_by_name(exec_list *instructions, const char *name, str = prototype_string(sig->return_type, f->name, &sig->parameters); _mesa_glsl_error(loc, state, "%s%s\n", prefix, str); - talloc_free(str); + ralloc_free(str); prefix = " "; } @@ -232,7 +256,7 @@ match_function_by_name(exec_list *instructions, const char *name, static ir_rvalue * convert_component(ir_rvalue *src, const glsl_type *desired_type) { - void *ctx = talloc_parent(src); + void *ctx = ralloc_parent(src); const unsigned a = desired_type->base_type; const unsigned b = src->type->base_type; ir_expression *result = NULL; @@ -295,7 +319,7 @@ convert_component(ir_rvalue *src, const glsl_type *desired_type) static ir_rvalue * dereference_component(ir_rvalue *src, unsigned component) { - void *ctx = talloc_parent(src); + void *ctx = ralloc_parent(src); assert(component < src->type->components()); /* If the source is a constant, just create a new constant instead of a @@ -993,6 +1017,16 @@ ast_function_expression::hir(exec_list *instructions, const glsl_type *const constructor_type = type->glsl_type(& name, state); + /* constructor_type can be NULL if a variable with the same name as the + * structure has come into scope. + */ + if (constructor_type == NULL) { + _mesa_glsl_error(& loc, state, "unknown type `%s' (structure name " + "may be shadowed by a variable with the same name)", + type->type_name); + return ir_call::get_error_instruction(ctx); + } + /* Constructors for samplers are illegal. */ @@ -1022,6 +1056,57 @@ ast_function_expression::hir(exec_list *instructions, * correct order. These constructors follow essentially the same type * matching rules as functions. */ + if (constructor_type->is_record()) { + exec_list actual_parameters; + + process_parameters(instructions, &actual_parameters, + &this->expressions, state); + + exec_node *node = actual_parameters.head; + for (unsigned i = 0; i < constructor_type->length; i++) { + ir_rvalue *ir = (ir_rvalue *) node; + + if (node->is_tail_sentinel()) { + _mesa_glsl_error(&loc, state, + "insufficient parameters to constructor " + "for `%s'", + constructor_type->name); + return ir_call::get_error_instruction(ctx); + } + + if (apply_implicit_conversion(constructor_type->fields.structure[i].type, + ir, state)) { + node->replace_with(ir); + } else { + _mesa_glsl_error(&loc, state, + "parameter type mismatch in constructor " + "for `%s.%s' (%s vs %s)", + constructor_type->name, + constructor_type->fields.structure[i].name, + ir->type->name, + constructor_type->fields.structure[i].type->name); + return ir_call::get_error_instruction(ctx);; + } + + node = node->next; + } + + if (!node->is_tail_sentinel()) { + _mesa_glsl_error(&loc, state, "too many parameters in constructor " + "for `%s'", constructor_type->name); + return ir_call::get_error_instruction(ctx); + } + + ir_rvalue *const constant = + constant_record_constructor(constructor_type, &actual_parameters, + state); + + return (constant != NULL) + ? constant + : emit_inline_record_constructor(constructor_type, instructions, + &actual_parameters, state); + } + if (!constructor_type->is_numeric() && !constructor_type->is_boolean()) return ir_call::get_error_instruction(ctx); @@ -1197,54 +1282,6 @@ ast_function_expression::hir(exec_list *instructions, process_parameters(instructions, &actual_parameters, &this->expressions, state); - const glsl_type *const type = - state->symbols->get_type(id->primary_expression.identifier); - - if ((type != NULL) && type->is_record()) { - exec_node *node = actual_parameters.head; - for (unsigned i = 0; i < type->length; i++) { - ir_rvalue *ir = (ir_rvalue *) node; - - if (node->is_tail_sentinel()) { - _mesa_glsl_error(&loc, state, - "insufficient parameters to constructor " - "for `%s'", - type->name); - return ir_call::get_error_instruction(ctx); - } - - if (apply_implicit_conversion(type->fields.structure[i].type, ir, - state)) { - node->replace_with(ir); - } else { - _mesa_glsl_error(&loc, state, - "parameter type mismatch in constructor " - "for `%s.%s' (%s vs %s)", - type->name, - type->fields.structure[i].name, - ir->type->name, - type->fields.structure[i].type->name); - return ir_call::get_error_instruction(ctx);; - } - - node = node->next; - } - - if (!node->is_tail_sentinel()) { - _mesa_glsl_error(&loc, state, "too many parameters in constructor " - "for `%s'", type->name); - return ir_call::get_error_instruction(ctx); - } - - ir_rvalue *const constant = - constant_record_constructor(type, &actual_parameters, state); - - return (constant != NULL) - ? constant - : emit_inline_record_constructor(type, instructions, - &actual_parameters, state); - } - return match_function_by_name(instructions, id->primary_expression.identifier, & loc, &actual_parameters, state); diff --git a/src/glsl/ast_to_hir.cpp b/src/glsl/ast_to_hir.cpp index 1f4972cfca..cdb16fd492 100644 --- a/src/glsl/ast_to_hir.cpp +++ b/src/glsl/ast_to_hir.cpp @@ -60,7 +60,7 @@ void _mesa_ast_to_hir(exec_list *instructions, struct _mesa_glsl_parse_state *state) { _mesa_glsl_initialize_variables(instructions, state); - _mesa_glsl_initialize_functions(instructions, state); + _mesa_glsl_initialize_functions(state); state->symbols->language_version = state->language_version; @@ -435,6 +435,13 @@ modulus_result_type(const struct glsl_type *type_a, const struct glsl_type *type_b, struct _mesa_glsl_parse_state *state, YYLTYPE *loc) { + if (state->language_version < 130) { + _mesa_glsl_error(loc, state, + "operator '%%' is reserved in %s", + state->version_string); + return glsl_type::error_type; + } + /* From GLSL 1.50 spec, page 56: * "The operator modulus (%) operates on signed or unsigned integers or * integer vectors. The operand types must both be signed or both be @@ -596,28 +603,28 @@ shift_result_type(const struct glsl_type *type_a, */ ir_rvalue * validate_assignment(struct _mesa_glsl_parse_state *state, - const glsl_type *lhs_type, ir_rvalue *rhs) + const glsl_type *lhs_type, ir_rvalue *rhs, + bool is_initializer) { - const glsl_type *rhs_type = rhs->type; - /* If there is already some error in the RHS, just return it. Anything * else will lead to an avalanche of error message back to the user. */ - if (rhs_type->is_error()) + if (rhs->type->is_error()) return rhs; /* If the types are identical, the assignment can trivially proceed. */ - if (rhs_type == lhs_type) + if (rhs->type == lhs_type) return rhs; /* If the array element types are the same and the size of the LHS is zero, - * the assignment is okay. + * the assignment is okay for initializers embedded in variable + * declarations. * * Note: Whole-array assignments are not permitted in GLSL 1.10, but this * is handled by ir_dereference::is_lvalue. */ - if (lhs_type->is_array() && rhs->type->is_array() + if (is_initializer && lhs_type->is_array() && rhs->type->is_array() && (lhs_type->element_type() == rhs->type->element_type()) && (lhs_type->array_size() == 0)) { return rhs; @@ -625,8 +632,7 @@ validate_assignment(struct _mesa_glsl_parse_state *state, /* Check for implicit conversion in GLSL 1.20 */ if (apply_implicit_conversion(lhs_type, rhs, state)) { - rhs_type = rhs->type; - if (rhs_type == lhs_type) + if (rhs->type == lhs_type) return rhs; } @@ -635,14 +641,21 @@ validate_assignment(struct _mesa_glsl_parse_state *state, ir_rvalue * do_assignment(exec_list *instructions, struct _mesa_glsl_parse_state *state, - ir_rvalue *lhs, ir_rvalue *rhs, + ir_rvalue *lhs, ir_rvalue *rhs, bool is_initializer, YYLTYPE lhs_loc) { void *ctx = state; bool error_emitted = (lhs->type->is_error() || rhs->type->is_error()); if (!error_emitted) { - if (!lhs->is_lvalue()) { + if (lhs->variable_referenced() != NULL + && lhs->variable_referenced()->read_only) { + _mesa_glsl_error(&lhs_loc, state, + "assignment to read-only variable '%s'", + lhs->variable_referenced()->name); + error_emitted = true; + + } else if (!lhs->is_lvalue()) { _mesa_glsl_error(& lhs_loc, state, "non-lvalue in assignment"); error_emitted = true; } @@ -654,7 +667,8 @@ do_assignment(exec_list *instructions, struct _mesa_glsl_parse_state *state, } } - ir_rvalue *new_rhs = validate_assignment(state, lhs->type, rhs); + ir_rvalue *new_rhs = + validate_assignment(state, lhs->type, rhs, is_initializer); if (new_rhs == NULL) { _mesa_glsl_error(& lhs_loc, state, "type mismatch"); } else { @@ -715,7 +729,7 @@ do_assignment(exec_list *instructions, struct _mesa_glsl_parse_state *state, static ir_rvalue * get_lvalue_copy(exec_list *instructions, ir_rvalue *lvalue) { - void *ctx = talloc_parent(lvalue); + void *ctx = ralloc_parent(lvalue); ir_variable *var; var = new(ctx) ir_variable(lvalue->type, "_post_incdec_tmp", @@ -907,7 +921,7 @@ ast_expression::hir(exec_list *instructions, op[0] = this->subexpressions[0]->hir(instructions, state); op[1] = this->subexpressions[1]->hir(instructions, state); - result = do_assignment(instructions, state, op[0], op[1], + result = do_assignment(instructions, state, op[0], op[1], false, this->subexpressions[0]->get_location()); error_emitted = result->type->is_error(); type = result->type; @@ -1234,7 +1248,7 @@ ast_expression::hir(exec_list *instructions, op[0], op[1]); result = do_assignment(instructions, state, - op[0]->clone(ctx, NULL), temp_rhs, + op[0]->clone(ctx, NULL), temp_rhs, false, this->subexpressions[0]->get_location()); type = result->type; error_emitted = (op[0]->type->is_error()); @@ -1260,7 +1274,7 @@ ast_expression::hir(exec_list *instructions, op[0], op[1]); result = do_assignment(instructions, state, - op[0]->clone(ctx, NULL), temp_rhs, + op[0]->clone(ctx, NULL), temp_rhs, false, this->subexpressions[0]->get_location()); type = result->type; error_emitted = type->is_error(); @@ -1276,7 +1290,7 @@ ast_expression::hir(exec_list *instructions, ir_rvalue *temp_rhs = new(ctx) ir_expression(operations[this->oper], type, op[0], op[1]); result = do_assignment(instructions, state, op[0]->clone(ctx, NULL), - temp_rhs, + temp_rhs, false, this->subexpressions[0]->get_location()); error_emitted = op[0]->type->is_error() || op[1]->type->is_error(); break; @@ -1292,7 +1306,7 @@ ast_expression::hir(exec_list *instructions, ir_rvalue *temp_rhs = new(ctx) ir_expression(operations[this->oper], type, op[0], op[1]); result = do_assignment(instructions, state, op[0]->clone(ctx, NULL), - temp_rhs, + temp_rhs, false, this->subexpressions[0]->get_location()); error_emitted = op[0]->type->is_error() || op[1]->type->is_error(); break; @@ -1408,7 +1422,7 @@ ast_expression::hir(exec_list *instructions, op[0], op[1]); result = do_assignment(instructions, state, - op[0]->clone(ctx, NULL), temp_rhs, + op[0]->clone(ctx, NULL), temp_rhs, false, this->subexpressions[0]->get_location()); type = result->type; error_emitted = op[0]->type->is_error(); @@ -1437,7 +1451,7 @@ ast_expression::hir(exec_list *instructions, result = get_lvalue_copy(instructions, op[0]->clone(ctx, NULL)); (void)do_assignment(instructions, state, - op[0]->clone(ctx, NULL), temp_rhs, + op[0]->clone(ctx, NULL), temp_rhs, false, this->subexpressions[0]->get_location()); type = result->type; @@ -1567,18 +1581,38 @@ ast_expression::hir(exec_list *instructions, } } - /* From section 4.1.7 of the GLSL 1.30 spec: + /* From page 23 (29 of the PDF) of the GLSL 1.30 spec: + * * "Samplers aggregated into arrays within a shader (using square * brackets [ ]) can only be indexed with integral constant * expressions [...]." + * + * This restriction was added in GLSL 1.30. Shaders using earlier version + * of the language should not be rejected by the compiler front-end for + * using this construct. This allows useful things such as using a loop + * counter as the index to an array of samplers. If the loop in unrolled, + * the code should compile correctly. Instead, emit a warning. */ if (array->type->is_array() && array->type->element_type()->is_sampler() && const_index == NULL) { - _mesa_glsl_error(&loc, state, "sampler arrays can only be indexed " - "with constant expressions"); - error_emitted = true; + if (state->language_version == 100) { + _mesa_glsl_warning(&loc, state, + "sampler arrays indexed with non-constant " + "expressions is optional in GLSL ES 1.00"); + } else if (state->language_version < 130) { + _mesa_glsl_warning(&loc, state, + "sampler arrays indexed with non-constant " + "expressions is forbidden in GLSL 1.30 and " + "later"); + } else { + _mesa_glsl_error(&loc, state, + "sampler arrays indexed with non-constant " + "expressions is forbidden in GLSL 1.30 and " + "later"); + error_emitted = true; + } } if (error_emitted) @@ -1606,6 +1640,7 @@ ast_expression::hir(exec_list *instructions, result = new(ctx) ir_dereference_variable(var); if (var != NULL) { + var->used = true; type = result->type; } else { _mesa_glsl_error(& loc, state, "`%s' undeclared", @@ -1780,10 +1815,17 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, struct _mesa_glsl_parse_state *state, YYLTYPE *loc) { - if (qual->flags.q.invariant) - var->invariant = 1; + if (qual->flags.q.invariant) { + if (var->used) { + _mesa_glsl_error(loc, state, + "variable `%s' may not be redeclared " + "`invariant' after being used", + var->name); + } else { + var->invariant = 1; + } + } - /* FINISHME: Mark 'in' variables at global scope as read-only. */ if (qual->flags.q.constant || qual->flags.q.attribute || qual->flags.q.uniform || (qual->flags.q.varying && (state->target == fragment_shader))) @@ -1835,6 +1877,23 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, else if (qual->flags.q.uniform) var->mode = ir_var_uniform; + if (state->all_invariant && (state->current_function == NULL)) { + switch (state->target) { + case vertex_shader: + if (var->mode == ir_var_out) + var->invariant = true; + break; + case geometry_shader: + if ((var->mode == ir_var_in) || (var->mode == ir_var_out)) + var->invariant = true; + break; + case fragment_shader: + if (var->mode == ir_var_in) + var->invariant = true; + break; + } + } + if (qual->flags.q.flat) var->interpolation = ir_var_flat; else if (qual->flags.q.noperspective) @@ -1914,11 +1973,345 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual, } } + /* Does the declaration use the 'layout' keyword? + */ + const bool uses_layout = qual->flags.q.pixel_center_integer + || qual->flags.q.origin_upper_left + || qual->flags.q.explicit_location; + + /* Does the declaration use the deprecated 'attribute' or 'varying' + * keywords? + */ + const bool uses_deprecated_qualifier = qual->flags.q.attribute + || qual->flags.q.varying; + + /* Is the 'layout' keyword used with parameters that allow relaxed checking. + * Many implementations of GL_ARB_fragment_coord_conventions_enable and some + * implementations (only Mesa?) GL_ARB_explicit_attrib_location_enable + * allowed the layout qualifier to be used with 'varying' and 'attribute'. + * These extensions and all following extensions that add the 'layout' + * keyword have been modified to require the use of 'in' or 'out'. + * + * The following extension do not allow the deprecated keywords: + * + * GL_AMD_conservative_depth + * GL_ARB_gpu_shader5 + * GL_ARB_separate_shader_objects + * GL_ARB_tesselation_shader + * GL_ARB_transform_feedback3 + * GL_ARB_uniform_buffer_object + * + * It is unknown whether GL_EXT_shader_image_load_store or GL_NV_gpu_shader5 + * allow layout with the deprecated keywords. + */ + const bool relaxed_layout_qualifier_checking = + state->ARB_fragment_coord_conventions_enable; + + if (uses_layout && uses_deprecated_qualifier) { + if (relaxed_layout_qualifier_checking) { + _mesa_glsl_warning(loc, state, + "`layout' qualifier may not be used with " + "`attribute' or `varying'"); + } else { + _mesa_glsl_error(loc, state, + "`layout' qualifier may not be used with " + "`attribute' or `varying'"); + } + } + + /* Layout qualifiers for gl_FragDepth, which are enabled by extension + * AMD_conservative_depth. + */ + int depth_layout_count = qual->flags.q.depth_any + + qual->flags.q.depth_greater + + qual->flags.q.depth_less + + qual->flags.q.depth_unchanged; + if (depth_layout_count > 0 + && !state->AMD_conservative_depth_enable) { + _mesa_glsl_error(loc, state, + "extension GL_AMD_conservative_depth must be enabled " + "to use depth layout qualifiers"); + } else if (depth_layout_count > 0 + && strcmp(var->name, "gl_FragDepth") != 0) { + _mesa_glsl_error(loc, state, + "depth layout qualifiers can be applied only to " + "gl_FragDepth"); + } else if (depth_layout_count > 1 + && strcmp(var->name, "gl_FragDepth") == 0) { + _mesa_glsl_error(loc, state, + "at most one depth layout qualifier can be applied to " + "gl_FragDepth"); + } + if (qual->flags.q.depth_any) + var->depth_layout = ir_depth_layout_any; + else if (qual->flags.q.depth_greater) + var->depth_layout = ir_depth_layout_greater; + else if (qual->flags.q.depth_less) + var->depth_layout = ir_depth_layout_less; + else if (qual->flags.q.depth_unchanged) + var->depth_layout = ir_depth_layout_unchanged; + else + var->depth_layout = ir_depth_layout_none; + if (var->type->is_array() && state->language_version != 110) { var->array_lvalue = true; } } +/** + * Get the variable that is being redeclared by this declaration + * + * Semantic checks to verify the validity of the redeclaration are also + * performed. If semantic checks fail, compilation error will be emitted via + * \c _mesa_glsl_error, but a non-\c NULL pointer will still be returned. + * + * \returns + * A pointer to an existing variable in the current scope if the declaration + * is a redeclaration, \c NULL otherwise. + */ +ir_variable * +get_variable_being_redeclared(ir_variable *var, ast_declaration *decl, + struct _mesa_glsl_parse_state *state) +{ + /* Check if this declaration is actually a re-declaration, either to + * resize an array or add qualifiers to an existing variable. + * + * This is allowed for variables in the current scope, or when at + * global scope (for built-ins in the implicit outer scope). + */ + ir_variable *earlier = state->symbols->get_variable(decl->identifier); + if (earlier == NULL || + (state->current_function != NULL && + !state->symbols->name_declared_this_scope(decl->identifier))) { + return NULL; + } + + + YYLTYPE loc = decl->get_location(); + + /* From page 24 (page 30 of the PDF) of the GLSL 1.50 spec, + * + * "It is legal to declare an array without a size and then + * later re-declare the same name as an array of the same + * type and specify a size." + */ + if ((earlier->type->array_size() == 0) + && var->type->is_array() + && (var->type->element_type() == earlier->type->element_type())) { + /* FINISHME: This doesn't match the qualifiers on the two + * FINISHME: declarations. It's not 100% clear whether this is + * FINISHME: required or not. + */ + + /* From page 54 (page 60 of the PDF) of the GLSL 1.20 spec: + * + * "The size [of gl_TexCoord] can be at most + * gl_MaxTextureCoords." + */ + const unsigned size = unsigned(var->type->array_size()); + if ((strcmp("gl_TexCoord", var->name) == 0) + && (size > state->Const.MaxTextureCoords)) { + _mesa_glsl_error(& loc, state, "`gl_TexCoord' array size cannot " + "be larger than gl_MaxTextureCoords (%u)\n", + state->Const.MaxTextureCoords); + } else if ((size > 0) && (size <= earlier->max_array_access)) { + _mesa_glsl_error(& loc, state, "array size must be > %u due to " + "previous access", + earlier->max_array_access); + } + + earlier->type = var->type; + delete var; + var = NULL; + } else if (state->ARB_fragment_coord_conventions_enable + && strcmp(var->name, "gl_FragCoord") == 0 + && earlier->type == var->type + && earlier->mode == var->mode) { + /* Allow redeclaration of gl_FragCoord for ARB_fcc layout + * qualifiers. + */ + earlier->origin_upper_left = var->origin_upper_left; + earlier->pixel_center_integer = var->pixel_center_integer; + + /* According to section 4.3.7 of the GLSL 1.30 spec, + * the following built-in varaibles can be redeclared with an + * interpolation qualifier: + * * gl_FrontColor + * * gl_BackColor + * * gl_FrontSecondaryColor + * * gl_BackSecondaryColor + * * gl_Color + * * gl_SecondaryColor + */ + } else if (state->language_version >= 130 + && (strcmp(var->name, "gl_FrontColor") == 0 + || strcmp(var->name, "gl_BackColor") == 0 + || strcmp(var->name, "gl_FrontSecondaryColor") == 0 + || strcmp(var->name, "gl_BackSecondaryColor") == 0 + || strcmp(var->name, "gl_Color") == 0 + || strcmp(var->name, "gl_SecondaryColor") == 0) + && earlier->type == var->type + && earlier->mode == var->mode) { + earlier->interpolation = var->interpolation; + + /* Layout qualifiers for gl_FragDepth. */ + } else if (state->AMD_conservative_depth_enable + && strcmp(var->name, "gl_FragDepth") == 0 + && earlier->type == var->type + && earlier->mode == var->mode) { + + /** From the AMD_conservative_depth spec: + * Within any shader, the first redeclarations of gl_FragDepth + * must appear before any use of gl_FragDepth. + */ + if (earlier->used) { + _mesa_glsl_error(&loc, state, + "the first redeclaration of gl_FragDepth " + "must appear before any use of gl_FragDepth"); + } + + /* Prevent inconsistent redeclaration of depth layout qualifier. */ + if (earlier->depth_layout != ir_depth_layout_none + && earlier->depth_layout != var->depth_layout) { + _mesa_glsl_error(&loc, state, + "gl_FragDepth: depth layout is declared here " + "as '%s, but it was previously declared as " + "'%s'", + depth_layout_string(var->depth_layout), + depth_layout_string(earlier->depth_layout)); + } + + earlier->depth_layout = var->depth_layout; + + } else { + _mesa_glsl_error(&loc, state, "`%s' redeclared", decl->identifier); + } + + return earlier; +} + +/** + * Generate the IR for an initializer in a variable declaration + */ +ir_rvalue * +process_initializer(ir_variable *var, ast_declaration *decl, + ast_fully_specified_type *type, + exec_list *initializer_instructions, + struct _mesa_glsl_parse_state *state) +{ + ir_rvalue *result = NULL; + + YYLTYPE initializer_loc = decl->initializer->get_location(); + + /* From page 24 (page 30 of the PDF) of the GLSL 1.10 spec: + * + * "All uniform variables are read-only and are initialized either + * directly by an application via API commands, or indirectly by + * OpenGL." + */ + if ((state->language_version <= 110) + && (var->mode == ir_var_uniform)) { + _mesa_glsl_error(& initializer_loc, state, + "cannot initialize uniforms in GLSL 1.10"); + } + + if (var->type->is_sampler()) { + _mesa_glsl_error(& initializer_loc, state, + "cannot initialize samplers"); + } + + if ((var->mode == ir_var_in) && (state->current_function == NULL)) { + _mesa_glsl_error(& initializer_loc, state, + "cannot initialize %s shader input / %s", + _mesa_glsl_shader_target_name(state->target), + (state->target == vertex_shader) + ? "attribute" : "varying"); + } + + ir_dereference *const lhs = new(state) ir_dereference_variable(var); + ir_rvalue *rhs = decl->initializer->hir(initializer_instructions, + state); + + /* Calculate the constant value if this is a const or uniform + * declaration. + */ + if (type->qualifier.flags.q.constant + || type->qualifier.flags.q.uniform) { + ir_rvalue *new_rhs = validate_assignment(state, var->type, rhs, true); + if (new_rhs != NULL) { + rhs = new_rhs; + + ir_constant *constant_value = rhs->constant_expression_value(); + if (!constant_value) { + _mesa_glsl_error(& initializer_loc, state, + "initializer of %s variable `%s' must be a " + "constant expression", + (type->qualifier.flags.q.constant) + ? "const" : "uniform", + decl->identifier); + if (var->type->is_numeric()) { + /* Reduce cascading errors. */ + var->constant_value = ir_constant::zero(state, var->type); + } + } else { + rhs = constant_value; + var->constant_value = constant_value; + } + } else { + _mesa_glsl_error(&initializer_loc, state, + "initializer of type %s cannot be assigned to " + "variable of type %s", + rhs->type->name, var->type->name); + if (var->type->is_numeric()) { + /* Reduce cascading errors. */ + var->constant_value = ir_constant::zero(state, var->type); + } + } + } + + if (rhs && !rhs->type->is_error()) { + bool temp = var->read_only; + if (type->qualifier.flags.q.constant) + var->read_only = false; + + /* Never emit code to initialize a uniform. + */ + const glsl_type *initializer_type; + if (!type->qualifier.flags.q.uniform) { + result = do_assignment(initializer_instructions, state, + lhs, rhs, true, + type->get_location()); + initializer_type = result->type; + } else + initializer_type = rhs->type; + + /* If the declared variable is an unsized array, it must inherrit + * its full type from the initializer. A declaration such as + * + * uniform float a[] = float[](1.0, 2.0, 3.0, 3.0); + * + * becomes + * + * uniform float a[4] = float[](1.0, 2.0, 3.0, 3.0); + * + * The assignment generated in the if-statement (below) will also + * automatically handle this case for non-uniforms. + * + * If the declared variable is not an array, the types must + * already match exactly. As a result, the type assignment + * here can be done unconditionally. For non-uniforms the call + * to do_assignment can change the type of the initializer (via + * the implicit conversion rules). For uniforms the initializer + * must be a constant expression, and the type of that expression + * was validated above. + */ + var->type = initializer_type; + + var->read_only = temp; + } + + return result; +} ir_rvalue * ast_declarator_list::hir(exec_list *instructions, @@ -1971,6 +2364,11 @@ ast_declarator_list::hir(exec_list *instructions, _mesa_glsl_error(& loc, state, "`%s' cannot be marked invariant, fragment shader " "inputs only\n", decl->identifier); + } else if (earlier->used) { + _mesa_glsl_error(& loc, state, + "variable `%s' may not be redeclared " + "`invariant' after being used", + earlier->name); } else { earlier->invariant = true; } @@ -2040,20 +2438,23 @@ ast_declarator_list::hir(exec_list *instructions, * * Local variables can only use the qualifier const." * - * This is relaxed in GLSL 1.30. + * This is relaxed in GLSL 1.30. It is also relaxed by any extension + * that adds the 'layout' keyword. */ - if (state->language_version < 120) { + if ((state->language_version < 130) + && !state->ARB_explicit_attrib_location_enable + && !state->ARB_fragment_coord_conventions_enable) { 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); + "only valid for function parameters in %s.", + decl->identifier, state->version_string); } 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.", - decl->identifier); + "only valid for function parameters in %s.", + decl->identifier, state->version_string); } /* FINISHME: Test for other invalid qualifiers. */ } @@ -2109,6 +2510,8 @@ ast_declarator_list::hir(exec_list *instructions, mode, var->name, extra); } } else if (var->mode == ir_var_in) { + var->read_only = true; + if (state->target == vertex_shader) { bool error_emitted = false; @@ -2161,113 +2564,144 @@ ast_declarator_list::hir(exec_list *instructions, } } - /* Process the initializer and add its instructions to a temporary - * list. This list will be added to the instruction stream (below) after - * the declaration is added. This is done because in some cases (such as - * redeclarations) the declaration may not actually be added to the - * instruction stream. + /* Integer vertex outputs must be qualified with 'flat'. + * + * From section 4.3.6 of the GLSL 1.30 spec: + * "If a vertex output is a signed or unsigned integer or integer + * vector, then it must be qualified with the interpolation qualifier + * flat." */ - exec_list initializer_instructions; - if (decl->initializer != NULL) { - YYLTYPE initializer_loc = decl->initializer->get_location(); + if (state->language_version >= 130 + && state->target == vertex_shader + && state->current_function == NULL + && var->type->is_integer() + && var->mode == ir_var_out + && var->interpolation != ir_var_flat) { + + _mesa_glsl_error(&loc, state, "If a vertex output is an integer, " + "then it must be qualified with 'flat'"); + } - /* From page 24 (page 30 of the PDF) of the GLSL 1.10 spec: - * - * "All uniform variables are read-only and are initialized either - * directly by an application via API commands, or indirectly by - * OpenGL." - */ - if ((state->language_version <= 110) - && (var->mode == ir_var_uniform)) { - _mesa_glsl_error(& initializer_loc, state, - "cannot initialize uniforms in GLSL 1.10"); - } - if (var->type->is_sampler()) { - _mesa_glsl_error(& initializer_loc, state, - "cannot initialize samplers"); - } + /* Interpolation qualifiers cannot be applied to 'centroid' and + * 'centroid varying'. + * + * From page 29 (page 35 of the PDF) of the GLSL 1.30 spec: + * "interpolation qualifiers may only precede the qualifiers in, + * centroid in, out, or centroid out in a declaration. They do not apply + * to the deprecated storage qualifiers varying or centroid varying." + */ + if (state->language_version >= 130 + && this->type->qualifier.has_interpolation() + && this->type->qualifier.flags.q.varying) { + + const char *i = this->type->qualifier.interpolation_string(); + assert(i != NULL); + const char *s; + if (this->type->qualifier.flags.q.centroid) + s = "centroid varying"; + else + s = "varying"; + + _mesa_glsl_error(&loc, state, + "qualifier '%s' cannot be applied to the " + "deprecated storage qualifier '%s'", i, s); + } - if ((var->mode == ir_var_in) && (state->current_function == NULL)) { - _mesa_glsl_error(& initializer_loc, state, - "cannot initialize %s shader input / %s", - _mesa_glsl_shader_target_name(state->target), - (state->target == vertex_shader) - ? "attribute" : "varying"); - } - ir_dereference *const lhs = new(ctx) ir_dereference_variable(var); - ir_rvalue *rhs = decl->initializer->hir(&initializer_instructions, - state); + /* Interpolation qualifiers can only apply to vertex shader outputs and + * fragment shader inputs. + * + * From page 29 (page 35 of the PDF) of the GLSL 1.30 spec: + * "Outputs from a vertex shader (out) and inputs to a fragment + * shader (in) can be further qualified with one or more of these + * interpolation qualifiers" + */ + if (state->language_version >= 130 + && this->type->qualifier.has_interpolation()) { + + const char *i = this->type->qualifier.interpolation_string(); + assert(i != NULL); + + switch (state->target) { + case vertex_shader: + if (this->type->qualifier.flags.q.in) { + _mesa_glsl_error(&loc, state, + "qualifier '%s' cannot be applied to vertex " + "shader inputs", i); + } + break; + case fragment_shader: + if (this->type->qualifier.flags.q.out) { + _mesa_glsl_error(&loc, state, + "qualifier '%s' cannot be applied to fragment " + "shader outputs", i); + } + break; + default: + assert(0); + } + } - /* Calculate the constant value if this is a const or uniform - * declaration. - */ - 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; - - ir_constant *constant_value = rhs->constant_expression_value(); - if (!constant_value) { - _mesa_glsl_error(& initializer_loc, state, - "initializer of %s variable `%s' must be a " - "constant expression", - (this->type->qualifier.flags.q.constant) - ? "const" : "uniform", - decl->identifier); - if (var->type->is_numeric()) { - /* Reduce cascading errors. */ - var->constant_value = ir_constant::zero(ctx, var->type); - } - } else { - rhs = constant_value; - var->constant_value = constant_value; - } - } else { - _mesa_glsl_error(&initializer_loc, state, - "initializer of type %s cannot be assigned to " - "variable of type %s", - rhs->type->name, var->type->name); - if (var->type->is_numeric()) { - /* Reduce cascading errors. */ - var->constant_value = ir_constant::zero(ctx, var->type); - } - } - } - if (rhs && !rhs->type->is_error()) { - bool temp = var->read_only; - if (this->type->qualifier.flags.q.constant) - var->read_only = false; + /* From section 4.3.4 of the GLSL 1.30 spec: + * "It is an error to use centroid in in a vertex shader." + */ + if (state->language_version >= 130 + && this->type->qualifier.flags.q.centroid + && this->type->qualifier.flags.q.in + && state->target == vertex_shader) { - /* If the declared variable is an unsized array, it must inherrit - * its full type from the initializer. A declaration such as - * - * uniform float a[] = float[](1.0, 2.0, 3.0, 3.0); - * - * becomes - * - * uniform float a[4] = float[](1.0, 2.0, 3.0, 3.0); - * - * The assignment generated in the if-statement (below) will also - * automatically handle this case for non-uniforms. - * - * If the declared variable is not an array, the types must - * already match exactly. As a result, the type assignment - * here can be done unconditionally. - */ - var->type = rhs->type; + _mesa_glsl_error(&loc, state, + "'centroid in' cannot be used in a vertex shader"); + } - /* Never emit code to initialize a uniform. - */ - if (!this->type->qualifier.flags.q.uniform) - result = do_assignment(&initializer_instructions, state, - lhs, rhs, - this->get_location()); - var->read_only = temp; - } + + /* Precision qualifiers exists only in GLSL versions 1.00 and >= 1.30. + */ + if (this->type->specifier->precision != ast_precision_none + && state->language_version != 100 + && state->language_version < 130) { + + _mesa_glsl_error(&loc, state, + "precision qualifiers are supported only in GLSL ES " + "1.00, and GLSL 1.30 and later"); + } + + + /* Precision qualifiers only apply to floating point and integer types. + * + * From section 4.5.2 of the GLSL 1.30 spec: + * "Any floating point or any integer declaration can have the type + * preceded by one of these precision qualifiers [...] Literal + * constants do not have precision qualifiers. Neither do Boolean + * variables. + */ + if (this->type->specifier->precision != ast_precision_none + && !var->type->is_float() + && !var->type->is_integer() + && !(var->type->is_array() + && (var->type->fields.array->is_float() + || var->type->fields.array->is_integer()))) { + + _mesa_glsl_error(&loc, state, + "precision qualifiers apply only to floating point " + "and integer types"); + } + + /* Process the initializer and add its instructions to a temporary + * list. This list will be added to the instruction stream (below) after + * the declaration is added. This is done because in some cases (such as + * redeclarations) the declaration may not actually be added to the + * instruction stream. + */ + exec_list initializer_instructions; + ir_variable *earlier = get_variable_being_redeclared(var, decl, state); + + if (decl->initializer != NULL) { + result = process_initializer((earlier == NULL) ? var : earlier, + decl, this->type, + &initializer_instructions, state); } /* From page 23 (page 29 of the PDF) of the GLSL 1.10 spec: @@ -2278,115 +2712,54 @@ ast_declarator_list::hir(exec_list *instructions, */ if (this->type->qualifier.flags.q.constant && decl->initializer == NULL) { _mesa_glsl_error(& loc, state, - "const declaration of `%s' must be initialized"); + "const declaration of `%s' must be initialized", + decl->identifier); } - /* Check if this declaration is actually a re-declaration, either to - * resize an array or add qualifiers to an existing variable. - * - * This is allowed for variables in the current scope, or when at - * global scope (for built-ins in the implicit outer scope). + /* If the declaration is not a redeclaration, there are a few additional + * semantic checks that must be applied. In addition, variable that was + * created for the declaration should be added to the IR stream. */ - ir_variable *earlier = state->symbols->get_variable(decl->identifier); - if (earlier != NULL && (state->current_function == NULL || - state->symbols->name_declared_this_scope(decl->identifier))) { - - /* From page 24 (page 30 of the PDF) of the GLSL 1.50 spec, + if (earlier == NULL) { + /* From page 15 (page 21 of the PDF) of the GLSL 1.10 spec, * - * "It is legal to declare an array without a size and then - * later re-declare the same name as an array of the same - * type and specify a size." + * "Identifiers starting with "gl_" are reserved for use by + * OpenGL, and may not be declared in a shader as either a + * variable or a function." */ - if ((earlier->type->array_size() == 0) - && var->type->is_array() - && (var->type->element_type() == earlier->type->element_type())) { - /* FINISHME: This doesn't match the qualifiers on the two - * FINISHME: declarations. It's not 100% clear whether this is - * FINISHME: required or not. - */ - - /* From page 54 (page 60 of the PDF) of the GLSL 1.20 spec: - * - * "The size [of gl_TexCoord] can be at most - * gl_MaxTextureCoords." - */ - const unsigned size = unsigned(var->type->array_size()); - if ((strcmp("gl_TexCoord", var->name) == 0) - && (size > state->Const.MaxTextureCoords)) { - YYLTYPE loc = this->get_location(); - - _mesa_glsl_error(& loc, state, "`gl_TexCoord' array size cannot " - "be larger than gl_MaxTextureCoords (%u)\n", - state->Const.MaxTextureCoords); - } else if ((size > 0) && (size <= earlier->max_array_access)) { - YYLTYPE loc = this->get_location(); - - _mesa_glsl_error(& loc, state, "array size must be > %u due to " - "previous access", - earlier->max_array_access); - } + if (strncmp(decl->identifier, "gl_", 3) == 0) + _mesa_glsl_error(& loc, state, + "identifier `%s' uses reserved `gl_' prefix", + decl->identifier); - earlier->type = var->type; - delete var; - var = NULL; - } else if (state->ARB_fragment_coord_conventions_enable - && strcmp(var->name, "gl_FragCoord") == 0 - && earlier->type == var->type - && earlier->mode == var->mode) { - /* Allow redeclaration of gl_FragCoord for ARB_fcc layout - * qualifiers. - */ - earlier->origin_upper_left = var->origin_upper_left; - earlier->pixel_center_integer = var->pixel_center_integer; - } else { + /* Add the variable to the symbol table. Note that the initializer's + * IR was already processed earlier (though it hasn't been emitted + * yet), without the variable in scope. + * + * This differs from most C-like languages, but it follows the GLSL + * specification. From page 28 (page 34 of the PDF) of the GLSL 1.50 + * spec: + * + * "Within a declaration, the scope of a name starts immediately + * after the initializer if present or immediately after the name + * being declared if not." + */ + if (!state->symbols->add_variable(var)) { YYLTYPE loc = this->get_location(); - _mesa_glsl_error(&loc, state, "`%s' redeclared", decl->identifier); + _mesa_glsl_error(&loc, state, "name `%s' already taken in the " + "current scope", decl->identifier); + continue; } - continue; - } - - /* By now, we know it's a new variable declaration (we didn't hit the - * above "continue"). - * - * From page 15 (page 21 of the PDF) of the GLSL 1.10 spec, - * - * "Identifiers starting with "gl_" are reserved for use by - * OpenGL, and may not be declared in a shader as either a - * variable or a function." - */ - if (strncmp(decl->identifier, "gl_", 3) == 0) - _mesa_glsl_error(& loc, state, - "identifier `%s' uses reserved `gl_' prefix", - decl->identifier); - - /* Add the variable to the symbol table. Note that the initializer's - * IR was already processed earlier (though it hasn't been emitted yet), - * without the variable in scope. - * - * This differs from most C-like languages, but it follows the GLSL - * specification. From page 28 (page 34 of the PDF) of the GLSL 1.50 - * spec: - * - * "Within a declaration, the scope of a name starts immediately - * after the initializer if present or immediately after the name - * being declared if not." - */ - if (!state->symbols->add_variable(var)) { - YYLTYPE loc = this->get_location(); - _mesa_glsl_error(&loc, state, "name `%s' already taken in the " - "current scope", decl->identifier); - continue; + /* Push the variable declaration to the top. It means that all the + * variable declarations will appear in a funny last-to-first order, + * but otherwise we run into trouble if a function is prototyped, a + * global var is decled, then the function is defined with usage of + * the global var. See glslparsertest's CorrectModule.frag. + */ + instructions->push_head(var); } - /* Push the variable declaration to the top. It means that all - * the variable declarations will appear in a funny - * last-to-first order, but otherwise we run into trouble if a - * function is prototyped, a global var is decled, then the - * function is defined with usage of the global var. See - * glslparsertest's CorrectModule.frag. - */ - instructions->push_head(var); instructions->append_list(&initializer_instructions); } @@ -2749,27 +3122,26 @@ ast_jump_statement::hir(exec_list *instructions, assert(state->current_function); if (opt_return_value) { - if (state->current_function->return_type->base_type == - GLSL_TYPE_VOID) { - YYLTYPE loc = this->get_location(); - - _mesa_glsl_error(& loc, state, - "`return` with a value, in function `%s' " - "returning void", - state->current_function->function_name()); - } - ir_rvalue *const ret = opt_return_value->hir(instructions, state); - assert(ret != NULL); + + /* The value of the return type can be NULL if the shader says + * 'return foo();' and foo() is a function that returns void. + * + * NOTE: The GLSL spec doesn't say that this is an error. The type + * of the return value is void. If the return type of the function is + * also void, then this should compile without error. Seriously. + */ + const glsl_type *const ret_type = + (ret == NULL) ? glsl_type::void_type : ret->type; /* Implicit conversions are not allowed for return values. */ - if (state->current_function->return_type != ret->type) { + if (state->current_function->return_type != ret_type) { YYLTYPE loc = this->get_location(); _mesa_glsl_error(& loc, state, "`return' with wrong type %s, in function `%s' " "returning %s", - ret->type->name, + ret_type->name, state->current_function->function_name(), state->current_function->return_type->name); } @@ -2986,6 +3358,58 @@ ir_rvalue * ast_type_specifier::hir(exec_list *instructions, struct _mesa_glsl_parse_state *state) { + if (!this->is_precision_statement && this->structure == NULL) + return NULL; + + YYLTYPE loc = this->get_location(); + + if (this->precision != ast_precision_none + && state->language_version != 100 + && state->language_version < 130) { + _mesa_glsl_error(&loc, state, + "precision qualifiers exist only in " + "GLSL ES 1.00, and GLSL 1.30 and later"); + return NULL; + } + if (this->precision != ast_precision_none + && this->structure != NULL) { + _mesa_glsl_error(&loc, state, + "precision qualifiers do not apply to structures"); + return NULL; + } + + /* If this is a precision statement, check that the type to which it is + * applied is either float or int. + * + * From section 4.5.3 of the GLSL 1.30 spec: + * "The precision statement + * precision precision-qualifier type; + * can be used to establish a default precision qualifier. The type + * field can be either int or float [...]. Any other types or + * qualifiers will result in an error. + */ + if (this->is_precision_statement) { + assert(this->precision != ast_precision_none); + assert(this->structure == NULL); /* The check for structures was + * performed above. */ + if (this->is_array) { + _mesa_glsl_error(&loc, state, + "default precision statements do not apply to " + "arrays"); + return NULL; + } + if (this->type_specifier != ast_float + && this->type_specifier != ast_int) { + _mesa_glsl_error(&loc, state, + "default precision statements apply only to types " + "float and int"); + return NULL; + } + + /* FINISHME: Translate precision statements into IR. */ + return NULL; + } + if (this->structure != NULL) return this->structure->hir(instructions, state); @@ -3016,7 +3440,7 @@ ast_struct_specifier::hir(exec_list *instructions, * the types to HIR. This ensures that structure definitions embedded in * other structure definitions are processed. */ - glsl_struct_field *const fields = talloc_array(state, glsl_struct_field, + glsl_struct_field *const fields = ralloc_array(state, glsl_struct_field, decl_count); unsigned i = 0; @@ -3062,11 +3486,9 @@ ast_struct_specifier::hir(exec_list *instructions, if (!state->symbols->add_type(name, t)) { _mesa_glsl_error(& loc, state, "struct `%s' previously defined", name); } else { - - const glsl_type **s = (const glsl_type **) - realloc(state->user_structures, - sizeof(state->user_structures[0]) * - (state->num_user_structures + 1)); + const glsl_type **s = reralloc(state, state->user_structures, + const glsl_type *, + state->num_user_structures + 1); if (s != NULL) { s[state->num_user_structures] = t; state->user_structures = s; diff --git a/src/glsl/ast_type.cpp b/src/glsl/ast_type.cpp index b7488cf6e9..c680ae5f67 100644 --- a/src/glsl/ast_type.cpp +++ b/src/glsl/ast_type.cpp @@ -21,7 +21,6 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> #include "ast.h" extern "C" { #include "program/symbol_table.h" @@ -49,7 +48,8 @@ ast_type_specifier::print(void) const ast_type_specifier::ast_type_specifier(int specifier) : type_specifier(ast_types(specifier)), type_name(NULL), structure(NULL), - is_array(false), array_size(NULL), precision(ast_precision_high) + is_array(false), array_size(NULL), precision(ast_precision_none), + is_precision_statement(false) { static const char *const names[] = { "void", @@ -116,3 +116,23 @@ ast_fully_specified_type::has_qualifiers() const { return this->qualifier.flags.i != 0; } + +bool ast_type_qualifier::has_interpolation() const +{ + return this->flags.q.smooth + || this->flags.q.flat + || this->flags.q.noperspective; +} + +const char* +ast_type_qualifier::interpolation_string() const +{ + if (this->flags.q.smooth) + return "smooth"; + else if (this->flags.q.flat) + return "flat"; + else if (this->flags.q.noperspective) + return "noperspective"; + else + return NULL; +} diff --git a/src/glsl/builtin_function.cpp b/src/glsl/builtin_function.cpp index 631aeac12c..0371c70a54 100644 --- a/src/glsl/builtin_function.cpp +++ b/src/glsl/builtin_function.cpp @@ -37,6 +37,8 @@ read_builtins(GLenum target, const char *protos, const char **functions, unsigne { struct gl_context fakeCtx; fakeCtx.API = API_OPENGL; + fakeCtx.Const.GLSLVersion = 130; + fakeCtx.Extensions.ARB_ES2_compatibility = true; gl_shader *sh = _mesa_new_shader(NULL, 0, target); struct _mesa_glsl_parse_state *st = new(sh) _mesa_glsl_parse_state(&fakeCtx, target, sh); @@ -63,7 +65,7 @@ read_builtins(GLenum target, const char *protos, const char **functions, unsigne if (st->error) { printf("error reading builtin: %.35s ...\n", functions[i]); printf("Info log:\n%s\n", st->info_log); - talloc_free(sh); + ralloc_free(sh); return NULL; } } @@ -367,19 +369,19 @@ static const char builtin_atan[] = " (\n" " (declare () float r)\n" " (if (expression bool > (expression float abs (var_ref x)) (constant float (0.000100))) (\n" - " (assign (constant bool (1)) (x) (var_ref r) (call atan ((expression float / (var_ref y) (var_ref x)))))\n" + " (assign (x) (var_ref r) (call atan ((expression float / (var_ref y) (var_ref x)))))\n" " (if (expression bool < (var_ref x) (constant float (0.000000)) ) (\n" " (if (expression bool >= (var_ref y) (constant float (0.000000)) )\n" - " ((assign (constant bool (1)) (x) (var_ref r) (expression float + (var_ref r) (constant float (3.141593)))))\n" - " ((assign (constant bool (1)) (x) (var_ref r) (expression float - (var_ref r) (constant float (3.141593))))))\n" + " ((assign (x) (var_ref r) (expression float + (var_ref r) (constant float (3.141593)))))\n" + " ((assign (x) (var_ref r) (expression float - (var_ref r) (constant float (3.141593))))))\n" " )\n" " (\n" " ))\n" " )\n" " (\n" " (declare () float sgn)\n" - " (assign (constant bool (1)) (x) (var_ref sgn) (expression float sign (var_ref y)))\n" - " (assign (constant bool (1)) (x) (var_ref r) (expression float * (var_ref sgn) (constant float (1.5707965))))\n" + " (assign (x) (var_ref sgn) (expression float sign (var_ref y)))\n" + " (assign (x) (var_ref r) (expression float * (var_ref sgn) (constant float (1.5707965))))\n" " ))\n" "\n" " (return (var_ref r) )\n" @@ -392,10 +394,10 @@ static const char builtin_atan[] = " (declare (in) vec2 y)\n" " (declare (in) vec2 x))\n" " ((declare () vec2 r)\n" - " (assign (constant bool (1)) (x) (var_ref r)\n" + " (assign (x) (var_ref r)\n" " (call atan ((swiz x (var_ref y))\n" " (swiz x (var_ref x)))))\n" - " (assign (constant bool (1)) (y) (var_ref r)\n" + " (assign (y) (var_ref r)\n" " (call atan ((swiz y (var_ref y))\n" " (swiz y (var_ref x)))))\n" " (return (var_ref r))))\n" @@ -405,13 +407,13 @@ static const char builtin_atan[] = " (declare (in) vec3 y)\n" " (declare (in) vec3 x))\n" " ((declare () vec3 r)\n" - " (assign (constant bool (1)) (x) (var_ref r)\n" + " (assign (x) (var_ref r)\n" " (call atan ((swiz x (var_ref y))\n" " (swiz x (var_ref x)))))\n" - " (assign (constant bool (1)) (y) (var_ref r)\n" + " (assign (y) (var_ref r)\n" " (call atan ((swiz y (var_ref y))\n" " (swiz y (var_ref x)))))\n" - " (assign (constant bool (1)) (z) (var_ref r)\n" + " (assign (z) (var_ref r)\n" " (call atan ((swiz z (var_ref y))\n" " (swiz z (var_ref x)))))\n" " (return (var_ref r))))\n" @@ -421,16 +423,16 @@ static const char builtin_atan[] = " (declare (in) vec4 y)\n" " (declare (in) vec4 x))\n" " ((declare () vec4 r)\n" - " (assign (constant bool (1)) (x) (var_ref r)\n" + " (assign (x) (var_ref r)\n" " (call atan ((swiz x (var_ref y))\n" " (swiz x (var_ref x)))))\n" - " (assign (constant bool (1)) (y) (var_ref r)\n" + " (assign (y) (var_ref r)\n" " (call atan ((swiz y (var_ref y))\n" " (swiz y (var_ref x)))))\n" - " (assign (constant bool (1)) (z) (var_ref r)\n" + " (assign (z) (var_ref r)\n" " (call atan ((swiz z (var_ref y))\n" " (swiz z (var_ref x)))))\n" - " (assign (constant bool (1)) (w) (var_ref r)\n" + " (assign (w) (var_ref r)\n" " (call atan ((swiz w (var_ref y))\n" " (swiz w (var_ref x)))))\n" " (return (var_ref r)))))\n" @@ -807,7 +809,7 @@ static const char builtin_distance[] = " (declare (in) vec2 p0)\n" " (declare (in) vec2 p1))\n" " ((declare () vec2 p)\n" - " (assign (constant bool (1)) (xy) (var_ref p) (expression vec2 - (var_ref p0) (var_ref p1)))\n" + " (assign (xy) (var_ref p) (expression vec2 - (var_ref p0) (var_ref p1)))\n" " (return (expression float sqrt (expression float dot (var_ref p) (var_ref p))))))\n" "\n" " (signature float\n" @@ -815,7 +817,7 @@ static const char builtin_distance[] = " (declare (in) vec3 p0)\n" " (declare (in) vec3 p1))\n" " ((declare () vec3 p)\n" - " (assign (constant bool (1)) (xyz) (var_ref p) (expression vec3 - (var_ref p0) (var_ref p1)))\n" + " (assign (xyz) (var_ref p) (expression vec3 - (var_ref p0) (var_ref p1)))\n" " (return (expression float sqrt (expression float dot (var_ref p) (var_ref p))))))\n" "\n" " (signature float\n" @@ -823,7 +825,7 @@ static const char builtin_distance[] = " (declare (in) vec4 p0)\n" " (declare (in) vec4 p1))\n" " ((declare () vec4 p)\n" - " (assign (constant bool (1)) (xyzw) (var_ref p) (expression vec4 - (var_ref p0) (var_ref p1)))\n" + " (assign (xyzw) (var_ref p) (expression vec4 - (var_ref p0) (var_ref p1)))\n" " (return (expression float sqrt (expression float dot (var_ref p) (var_ref p))))))\n" "))\n" "" @@ -1448,8 +1450,8 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat2 x)\n" " (declare (in) mat2 y))\n" " ((declare () mat2 z)\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat3\n" @@ -1457,9 +1459,9 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat3 x)\n" " (declare (in) mat3 y))\n" " ((declare () mat3 z)\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat4\n" @@ -1467,10 +1469,10 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat4 x)\n" " (declare (in) mat4 y))\n" " ((declare () mat4 z)\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (3))) (expression vec4 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (3))) (expression vec4 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat2x3\n" @@ -1478,8 +1480,8 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat2x3 x)\n" " (declare (in) mat2x3 y))\n" " ((declare () mat2x3 z)\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat3x2\n" @@ -1487,9 +1489,9 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat3x2 x)\n" " (declare (in) mat3x2 y))\n" " ((declare () mat3x2 z)\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat2x4\n" @@ -1497,8 +1499,8 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat2x4 x)\n" " (declare (in) mat2x4 y))\n" " ((declare () mat2x4 z)\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat4x2\n" @@ -1506,10 +1508,10 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat4x2 x)\n" " (declare (in) mat4x2 y))\n" " ((declare () mat4x2 z)\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (3))) (expression vec2 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" + " (assign (xy) (array_ref (var_ref z) (constant int (3))) (expression vec2 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat3x4\n" @@ -1517,9 +1519,9 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat3x4 x)\n" " (declare (in) mat3x4 y))\n" " ((declare () mat3x4 z)\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" "(return (var_ref z))))\n" "\n" " (signature mat4x3\n" @@ -1527,10 +1529,10 @@ static const char builtin_matrixCompMult[] = " (declare (in) mat4x3 x)\n" " (declare (in) mat4x3 y))\n" " ((declare () mat4x3 z)\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (3))) (expression vec3 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2)))))\n" + " (assign (xyz) (array_ref (var_ref z) (constant int (3))) (expression vec3 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3)))))\n" "(return (var_ref z))))\n" "))\n" "" @@ -1939,9 +1941,8 @@ static const char builtin_modf[] = " (declare (in) float x)\n" " (declare (out) float i))\n" " ((declare () float t)\n" - " (assign (constant bool (1)) (x) (var_ref t)\n" - " (expression float trunc (var_ref x)))\n" - " (assign (constant bool (1)) (x) (var_ref i) (var_ref t))\n" + " (assign (x) (var_ref t) (expression float trunc (var_ref x)))\n" + " (assign (x) (var_ref i) (var_ref t))\n" " (return (expression float - (var_ref x) (var_ref t)))))\n" "\n" " (signature vec2\n" @@ -1949,9 +1950,8 @@ static const char builtin_modf[] = " (declare (in) vec2 x)\n" " (declare (out) vec2 i))\n" " ((declare () vec2 t)\n" - " (assign (constant bool (1)) (xy) (var_ref t)\n" - " (expression vec2 trunc (var_ref x)))\n" - " (assign (constant bool (1)) (xy) (var_ref i) (var_ref t))\n" + " (assign (xy) (var_ref t) (expression vec2 trunc (var_ref x)))\n" + " (assign (xy) (var_ref i) (var_ref t))\n" " (return (expression vec2 - (var_ref x) (var_ref t)))))\n" "\n" " (signature vec3\n" @@ -1959,9 +1959,8 @@ static const char builtin_modf[] = " (declare (in) vec3 x)\n" " (declare (out) vec3 i))\n" " ((declare () vec3 t)\n" - " (assign (constant bool (1)) (xyz) (var_ref t)\n" - " (expression vec3 trunc (var_ref x)))\n" - " (assign (constant bool (1)) (xyz) (var_ref i) (var_ref t))\n" + " (assign (xyz) (var_ref t) (expression vec3 trunc (var_ref x)))\n" + " (assign (xyz) (var_ref i) (var_ref t))\n" " (return (expression vec3 - (var_ref x) (var_ref t)))))\n" "\n" " (signature vec4\n" @@ -1969,9 +1968,8 @@ static const char builtin_modf[] = " (declare (in) vec4 x)\n" " (declare (out) vec4 i))\n" " ((declare () vec4 t)\n" - " (assign (constant bool (1)) (xyzw) (var_ref t)\n" - " (expression vec4 trunc (var_ref x)))\n" - " (assign (constant bool (1)) (xyzw) (var_ref i) (var_ref t))\n" + " (assign (xyzw) (var_ref t) (expression vec4 trunc (var_ref x)))\n" + " (assign (xyzw) (var_ref i) (var_ref t))\n" " (return (expression vec4 - (var_ref x) (var_ref t)))))\n" "))\n" "" @@ -2006,10 +2004,10 @@ static const char builtin_noise2[] = " (declare () float b)\n" " (declare () vec2 t)\n" "\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) (var_ref a))\n" - " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2020,10 +2018,10 @@ static const char builtin_noise2[] = " (declare () float b)\n" " (declare () vec2 t)\n" "\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) (var_ref a))\n" - " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0)))))\n" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2036,10 +2034,10 @@ static const char builtin_noise2[] = " (declare () float b)\n" " (declare () vec2 t)\n" "\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) (var_ref a))\n" - " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0)))))\n" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2052,10 +2050,10 @@ static const char builtin_noise2[] = " (declare () float b)\n" " (declare () vec2 t)\n" "\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) (var_ref a))\n" - " (assign (constant bool (1)) (y) (var_ref t) (var_ref b))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0)))))\n" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" " (return (var_ref t))\n" " ))\n" "))\n" @@ -2071,13 +2069,13 @@ static const char builtin_noise3[] = " (declare () float c)\n" " (declare () vec3 t)\n" "\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 c) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.0)))))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" + " (assign (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) (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" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" + " (assign (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2089,13 +2087,13 @@ static const char builtin_noise3[] = " (declare () float c)\n" " (declare () vec3 t)\n" "\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 c) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.0)))))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0)))))\n" + " (assign (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) (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" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" + " (assign (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2107,13 +2105,13 @@ static const char builtin_noise3[] = " (declare () float c)\n" " (declare () vec3 t)\n" "\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 c) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.0)))))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0)))))\n" + " (assign (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) (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" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" + " (assign (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "\n" @@ -2125,13 +2123,13 @@ static const char builtin_noise3[] = " (declare () float c)\n" " (declare () vec3 t)\n" "\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 c) (expression float noise (expression float + (var_ref p) (constant float (1559.0)))))\n" + " (assign (x) (var_ref a) (expression float noise (var_ref p)))\n" + " (assign (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0)))))\n" + " (assign (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) (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" + " (assign (x) (var_ref t) (var_ref a))\n" + " (assign (y) (var_ref t) (var_ref b))\n" + " (assign (z) (var_ref t) (var_ref c))\n" " (return (var_ref t))\n" " ))\n" "))\n" @@ -2149,17 +2147,17 @@ static const char builtin_noise4[] = " (declare () vec4 _r)\n" "\n" " (declare () vec4 _p)\n" - " (assign (constant bool (1)) (xyzw) (var_ref _p) (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.0))) )\n" + " (assign (xyzw) (var_ref _p) (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.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 vec4 + (var_ref p) (constant vec4 (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 vec4 + (var_ref _p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" + " (assign (x) (var_ref _x) (expression float noise(var_ref p)))\n" + " (assign (x) (var_ref _y) (expression float noise(expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0)))))\n" + " (assign (x) (var_ref _z) (expression float noise(var_ref _p)))\n" + " (assign (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) (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" + " (assign (x) (var_ref _r) (var_ref _x))\n" + " (assign (y) (var_ref _r) (var_ref _y))\n" + " (assign (z) (var_ref _r) (var_ref _z))\n" + " (assign (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "\n" @@ -2173,17 +2171,17 @@ static const char builtin_noise4[] = " (declare () vec4 _r)\n" "\n" " (declare () vec3 _p)\n" - " (assign (constant bool (1)) (xyz) (var_ref _p) (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.0))) )\n" + " (assign (xyz) (var_ref _p) (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.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 vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.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 vec3 + (var_ref _p) (constant vec3 (601.0 313.0 29.0)))))\n" + " (assign (x) (var_ref _x) (expression float noise(var_ref p)))\n" + " (assign (x) (var_ref _y) (expression float noise(expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0)))))\n" + " (assign (x) (var_ref _z) (expression float noise(var_ref _p)))\n" + " (assign (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) (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" + " (assign (x) (var_ref _r) (var_ref _x))\n" + " (assign (y) (var_ref _r) (var_ref _y))\n" + " (assign (z) (var_ref _r) (var_ref _z))\n" + " (assign (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "\n" @@ -2197,17 +2195,17 @@ static const char builtin_noise4[] = " (declare () vec4 _r)\n" "\n" " (declare () vec2 _p)\n" - " (assign (constant bool (1)) (xy) (var_ref _p) (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.0))) )\n" + " (assign (xy) (var_ref _p) (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.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 vec2 + (var_ref p) (constant vec2 (601.0 313.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 vec2 + (var_ref _p) (constant vec2 (601.0 313.0)))))\n" + " (assign (x) (var_ref _x) (expression float noise(var_ref p)))\n" + " (assign (x) (var_ref _y) (expression float noise(expression vec2 + (var_ref p) (constant vec2 (601.0 313.0)))))\n" + " (assign (x) (var_ref _z) (expression float noise(var_ref _p)))\n" + " (assign (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) (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" + " (assign (x) (var_ref _r) (var_ref _x))\n" + " (assign (y) (var_ref _r) (var_ref _y))\n" + " (assign (z) (var_ref _r) (var_ref _z))\n" + " (assign (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "\n" @@ -2221,17 +2219,17 @@ static const char builtin_noise4[] = " (declare () vec4 _r)\n" "\n" " (declare () float _p)\n" - " (assign (constant bool (1)) (x) (var_ref _p) (expression float + (var_ref p) (constant float (1559.0))) )\n" + " (assign (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" + " (assign (x) (var_ref _x) (expression float noise(var_ref p)))\n" + " (assign (x) (var_ref _y) (expression float noise(expression float + (var_ref p) (constant float (601.0 313.0 29.0 277.0)))))\n" + " (assign (x) (var_ref _z) (expression float noise(var_ref _p)))\n" + " (assign (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) (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" + " (assign (x) (var_ref _r) (var_ref _x))\n" + " (assign (y) (var_ref _r) (var_ref _y))\n" + " (assign (z) (var_ref _r) (var_ref _z))\n" + " (assign (w) (var_ref _r) (var_ref _w))\n" " (return (var_ref _r))\n" " ))\n" "))\n" @@ -2363,8 +2361,8 @@ static const char builtin_outerProduct[] = " (declare (in) vec2 u)\n" " (declare (in) vec2 v))\n" " ((declare () mat2 m)\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat2x3\n" @@ -2372,8 +2370,8 @@ static const char builtin_outerProduct[] = " (declare (in) vec3 u)\n" " (declare (in) vec2 v))\n" " ((declare () mat2x3 m)\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat2x4\n" @@ -2381,8 +2379,8 @@ static const char builtin_outerProduct[] = " (declare (in) vec4 u)\n" " (declare (in) vec2 v))\n" " ((declare () mat2x4 m)\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat3x2\n" @@ -2390,9 +2388,9 @@ static const char builtin_outerProduct[] = " (declare (in) vec2 u)\n" " (declare (in) vec3 v))\n" " ((declare () mat3x2 m)\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v))))\n" " (return (var_ref m))\n" " ))\n" "\n" @@ -2401,9 +2399,9 @@ static const char builtin_outerProduct[] = " (declare (in) vec3 u)\n" " (declare (in) vec3 v))\n" " ((declare () mat3 m)\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat3x4\n" @@ -2411,9 +2409,9 @@ static const char builtin_outerProduct[] = " (declare (in) vec4 u)\n" " (declare (in) vec3 v))\n" " ((declare () mat3x4 m)\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat4x2\n" @@ -2421,10 +2419,10 @@ static const char builtin_outerProduct[] = " (declare (in) vec2 u)\n" " (declare (in) vec4 v))\n" " ((declare () mat4x2 m)\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v))))\n" - " (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (3))) (expression vec2 * (var_ref u) (swiz w (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v))))\n" + " (assign (xy) (array_ref (var_ref m) (constant int (3))) (expression vec2 * (var_ref u) (swiz w (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat4x3\n" @@ -2432,10 +2430,10 @@ static const char builtin_outerProduct[] = " (declare (in) vec3 u)\n" " (declare (in) vec4 v))\n" " ((declare () mat4x3 m)\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v))))\n" - " (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (3))) (expression vec3 * (var_ref u) (swiz w (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v))))\n" + " (assign (xyz) (array_ref (var_ref m) (constant int (3))) (expression vec3 * (var_ref u) (swiz w (var_ref v))))\n" " (return (var_ref m))))\n" "\n" " (signature mat4\n" @@ -2443,10 +2441,10 @@ static const char builtin_outerProduct[] = " (declare (in) vec4 u)\n" " (declare (in) vec4 v))\n" " ((declare () mat4 m)\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v))))\n" - " (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (3))) (expression vec4 * (var_ref u) (swiz w (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v))))\n" + " (assign (xyzw) (array_ref (var_ref m) (constant int (3))) (expression vec4 * (var_ref u) (swiz w (var_ref v))))\n" " (return (var_ref m))))\n" "))\n" "" @@ -2572,7 +2570,7 @@ static const char builtin_refract[] = " (declare (in) float n)\n" " (declare (in) float eta))\n" " ((declare () float k)\n" - " (assign (constant bool (1)) (x) (var_ref k)\n" + " (assign (x) (var_ref k)\n" " (expression float - (constant float (1.0))\n" " (expression float * (var_ref eta)\n" " (expression float * (var_ref eta)\n" @@ -2597,7 +2595,7 @@ static const char builtin_refract[] = " (declare (in) vec2 n)\n" " (declare (in) float eta))\n" " ((declare () float k)\n" - " (assign (constant bool (1)) (x) (var_ref k)\n" + " (assign (x) (var_ref k)\n" " (expression float - (constant float (1.0))\n" " (expression float * (var_ref eta)\n" " (expression float * (var_ref eta)\n" @@ -2622,7 +2620,7 @@ static const char builtin_refract[] = " (declare (in) vec3 n)\n" " (declare (in) float eta))\n" " ((declare () float k)\n" - " (assign (constant bool (1)) (x) (var_ref k)\n" + " (assign (x) (var_ref k)\n" " (expression float - (constant float (1.0))\n" " (expression float * (var_ref eta)\n" " (expression float * (var_ref eta)\n" @@ -2647,7 +2645,7 @@ static const char builtin_refract[] = " (declare (in) vec4 n)\n" " (declare (in) float eta))\n" " ((declare () float k)\n" - " (assign (constant bool (1)) (x) (var_ref k)\n" + " (assign (x) (var_ref k)\n" " (expression float - (constant float (1.0))\n" " (expression float * (var_ref eta)\n" " (expression float * (var_ref eta)\n" @@ -2723,14 +2721,14 @@ static const char builtin_shadow1D[] = " (parameters\n" " (declare (in) sampler1DShadow sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DShadow sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -2741,14 +2739,14 @@ static const char builtin_shadow1DArray[] = " (parameters\n" " (declare (in) sampler1DArrayShadow sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DArrayShadow sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -2760,7 +2758,7 @@ static const char builtin_shadow1DArrayLod[] = " (declare (in) sampler1DArrayShadow sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" "\n" "))\n" "" @@ -2772,7 +2770,7 @@ static const char builtin_shadow1DLod[] = " (declare (in) sampler1DShadow sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" "\n" "))\n" "" @@ -2783,14 +2781,14 @@ static const char builtin_shadow1DProj[] = " (parameters\n" " (declare (in) sampler1DShadow sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DShadow sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -2802,7 +2800,7 @@ static const char builtin_shadow1DProjLod[] = " (declare (in) sampler1DShadow sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" "\n" "))\n" "" @@ -2813,14 +2811,14 @@ static const char builtin_shadow2D[] = " (parameters\n" " (declare (in) sampler2DShadow sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DShadow sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -2831,7 +2829,7 @@ static const char builtin_shadow2DArray[] = " (parameters\n" " (declare (in) sampler2DArrayShadow sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) 1 (swiz w (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz w (var_ref P)) ))))\n" "\n" "))\n" "" @@ -2843,7 +2841,7 @@ static const char builtin_shadow2DLod[] = " (declare (in) sampler2DShadow sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" "\n" "))\n" "" @@ -2854,14 +2852,14 @@ static const char builtin_shadow2DProj[] = " (parameters\n" " (declare (in) sampler2DShadow sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DShadow sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -2873,7 +2871,7 @@ static const char builtin_shadow2DProjLod[] = " (declare (in) sampler2DShadow sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" "\n" "))\n" "" @@ -2884,7 +2882,7 @@ static const char builtin_shadow2DRect[] = " (parameters\n" " (declare (in) sampler2DRectShadow sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) 1 (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" "\n" "))\n" "" @@ -2895,7 +2893,7 @@ static const char builtin_shadow2DRectProj[] = " (parameters\n" " (declare (in) sampler2DRectShadow sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" "\n" "))\n" "" @@ -3010,40 +3008,26 @@ static const char builtin_smoothstep[] = " (declare (in) float edge1)\n" " (declare (in) float x))\n" " ((declare () float t)\n" - "\n" - " (assign (constant bool (1)) (x) (var_ref t)\n" + " (assign (x) (var_ref t)\n" " (expression float max\n" " (expression float min\n" " (expression float / (expression float - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" " (constant float (1.0)))\n" " (constant float (0.0))))\n" - " (return (expression float * (var_ref t) (expression float * (var_ref t) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (var_ref t))))))))\n" - "\n" + " (return (expression float * (var_ref t) (expression float * (var_ref t) (expression float - (constant float (3.0)) (expression float * (constant float (2.0)) (var_ref t))))))))\n" " (signature vec2\n" " (parameters\n" " (declare (in) float edge0)\n" " (declare (in) float edge1)\n" " (declare (in) vec2 x))\n" " ((declare () vec2 t)\n" - " (declare () vec2 retval)\n" - "\n" - " (assign (constant bool (1)) (x) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz x (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" + " (assign (xy) (var_ref t)\n" + " (expression vec2 max\n" + " (expression vec2 min\n" + " (expression vec2 / (expression vec2 - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" " (constant float (1.0)))\n" " (constant float (0.0))))\n" - " (assign (constant bool (1)) (x) (var_ref retval) (expression float * (swiz x (var_ref t)) (expression float * (swiz x (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz x (var_ref t)))))))\n" - "\n" - " (assign (constant bool (1)) (y) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz y (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" - " (constant float (1.0)))\n" - " (constant float (0.0))))\n" - " (assign (constant bool (1)) (y) (var_ref retval) (expression float * (swiz y (var_ref t)) (expression float * (swiz y (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz y (var_ref t)))))))\n" - " (return (var_ref retval))\n" - " ))\n" + " (return (expression vec2 * (var_ref t) (expression vec2 * (var_ref t) (expression vec2 - (constant float (3.0)) (expression vec2 * (constant float (2.0)) (var_ref t))))))))\n" "\n" " (signature vec3\n" " (parameters\n" @@ -3051,33 +3035,13 @@ static const char builtin_smoothstep[] = " (declare (in) float edge1)\n" " (declare (in) vec3 x))\n" " ((declare () vec3 t)\n" - " (declare () vec3 retval)\n" - "\n" - " (assign (constant bool (1)) (x) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz x (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" + " (assign (xyz) (var_ref t)\n" + " (expression vec3 max\n" + " (expression vec3 min\n" + " (expression vec3 / (expression vec3 - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" " (constant float (1.0)))\n" " (constant float (0.0))))\n" - " (assign (constant bool (1)) (x) (var_ref retval) (expression float * (swiz x (var_ref t)) (expression float * (swiz x (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz x (var_ref t)))))))\n" - "\n" - " (assign (constant bool (1)) (y) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz y (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" - " (constant float (1.0)))\n" - " (constant float (0.0))))\n" - " (assign (constant bool (1)) (y) (var_ref retval) (expression float * (swiz y (var_ref t)) (expression float * (swiz y (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz y (var_ref t)))))))\n" - "\n" - " (assign (constant bool (1)) (z) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz z (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" - " (constant float (1.0)))\n" - " (constant float (0.0))))\n" - " (assign (constant bool (1)) (z) (var_ref retval) (expression float * (swiz z (var_ref t)) (expression float * (swiz z (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz z (var_ref t)))))))\n" - " (return (var_ref retval))\n" - " ))\n" + " (return (expression vec3 * (var_ref t) (expression vec3 * (var_ref t) (expression vec3 - (constant float (3.0)) (expression vec3 * (constant float (2.0)) (var_ref t))))))))\n" "\n" "\n" " (signature vec4\n" @@ -3086,74 +3050,55 @@ static const char builtin_smoothstep[] = " (declare (in) float edge1)\n" " (declare (in) vec4 x))\n" " ((declare () vec4 t)\n" - " (declare () vec4 retval)\n" - "\n" - " (assign (constant bool (1)) (x) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz x (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" + " (assign (xyzw) (var_ref t)\n" + " (expression vec4 max\n" + " (expression vec4 min\n" + " (expression vec4 / (expression vec4 - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" " (constant float (1.0)))\n" " (constant float (0.0))))\n" - " (assign (constant bool (1)) (x) (var_ref retval) (expression float * (swiz x (var_ref t)) (expression float * (swiz x (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz x (var_ref t)))))))\n" - "\n" - " (assign (constant bool (1)) (y) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz y (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" - " (constant float (1.0)))\n" - " (constant float (0.0))))\n" - " (assign (constant bool (1)) (y) (var_ref retval) (expression float * (swiz y (var_ref t)) (expression float * (swiz y (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz y (var_ref t)))))))\n" - "\n" - " (assign (constant bool (1)) (z) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz z (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" - " (constant float (1.0)))\n" - " (constant float (0.0))))\n" - " (assign (constant bool (1)) (z) (var_ref retval) (expression float * (swiz z (var_ref t)) (expression float * (swiz z (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz z (var_ref t)))))))\n" - "\n" - " (assign (constant bool (1)) (w) (var_ref t)\n" - " (expression float max\n" - " (expression float min\n" - " (expression float / (expression float - (swiz w (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0)))\n" - " (constant float (1.0)))\n" - " (constant float (0.0))))\n" - " (assign (constant bool (1)) (w) (var_ref retval) (expression float * (swiz w (var_ref t)) (expression float * (swiz w (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz w (var_ref t)))))))\n" - " (return (var_ref retval))\n" - " ))\n" + " (return (expression vec4 * (var_ref t) (expression vec4 * (var_ref t) (expression vec4 - (constant float (3.0)) (expression vec4 * (constant float (2.0)) (var_ref t))))))))\n" "\n" " (signature vec2\n" " (parameters\n" " (declare (in) vec2 edge0)\n" " (declare (in) vec2 edge1)\n" " (declare (in) vec2 x))\n" - " ((return (expression vec2 max\n" + " ((declare () vec2 t)\n" + " (assign (xy) (var_ref t)\n" + " (expression vec2 max\n" " (expression vec2 min\n" " (expression vec2 / (expression vec2 - (var_ref x) (var_ref edge0)) (expression vec2 - (var_ref edge1) (var_ref edge0)))\n" - " (constant vec2 (1.0 1.0)))\n" - " (constant vec2 (0.0 0.0))))))\n" + " (constant float (1.0)))\n" + " (constant float (0.0))))\n" + " (return (expression vec2 * (var_ref t) (expression vec2 * (var_ref t) (expression vec2 - (constant float (3.0)) (expression vec2 * (constant float (2.0)) (var_ref t))))))))\n" "\n" " (signature vec3\n" " (parameters\n" " (declare (in) vec3 edge0)\n" " (declare (in) vec3 edge1)\n" " (declare (in) vec3 x))\n" - " ((return (expression vec3 max\n" + " ((declare () vec3 t)\n" + " (assign (xyz) (var_ref t)\n" + " (expression vec3 max\n" " (expression vec3 min\n" " (expression vec3 / (expression vec3 - (var_ref x) (var_ref edge0)) (expression vec3 - (var_ref edge1) (var_ref edge0)))\n" - " (constant vec3 (1.0 1.0 1.0)))\n" - " (constant vec3 (0.0 0.0 0.0))))))\n" + " (constant float (1.0)))\n" + " (constant float (0.0))))\n" + " (return (expression vec3 * (var_ref t) (expression vec3 * (var_ref t) (expression vec3 - (constant float (3.0)) (expression vec3 * (constant float (2.0)) (var_ref t))))))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) vec4 edge0)\n" " (declare (in) vec4 edge1)\n" " (declare (in) vec4 x))\n" - " ((return (expression vec4 max\n" + " ((declare () vec4 t)\n" + " (assign (xyzw) (var_ref t)\n" + " (expression vec4 max\n" " (expression vec4 min\n" " (expression vec4 / (expression vec4 - (var_ref x) (var_ref edge0)) (expression vec4 - (var_ref edge1) (var_ref edge0)))\n" - " (constant vec4 (1.0 1.0 1.0 1.0)))\n" - " (constant vec4 (0.0 0.0 0.0 0.0))))))\n" + " (constant float (1.0)))\n" + " (constant float (0.0))))\n" + " (return (expression vec4 * (var_ref t) (expression vec4 * (var_ref t) (expression vec4 - (constant float (3.0)) (expression vec4 * (constant float (2.0)) (var_ref t))))))))\n" "))\n" "\n" "" @@ -3195,8 +3140,8 @@ static const char builtin_step[] = " (declare (in) float edge)\n" " (declare (in) vec2 x))\n" " ((declare () vec2 t)\n" - " (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge))))\n" - " (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge))))\n" + " (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge))))\n" + " (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge))))\n" " (return (var_ref t))))\n" "\n" " (signature vec3\n" @@ -3204,9 +3149,9 @@ static const char builtin_step[] = " (declare (in) float edge)\n" " (declare (in) vec3 x))\n" " ((declare () vec3 t)\n" - " (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge))))\n" - " (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge))))\n" - " (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge))))\n" + " (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge))))\n" + " (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge))))\n" + " (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge))))\n" " (return (var_ref t))))\n" "\n" " (signature vec4\n" @@ -3214,10 +3159,10 @@ static const char builtin_step[] = " (declare (in) float edge)\n" " (declare (in) vec4 x))\n" " ((declare () vec4 t)\n" - " (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge))))\n" - " (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge))))\n" - " (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge))))\n" - " (assign (constant bool (1)) (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(var_ref edge))))\n" + " (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge))))\n" + " (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge))))\n" + " (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge))))\n" + " (assign (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(var_ref edge))))\n" " (return (var_ref t))))\n" "\n" " (signature vec2\n" @@ -3225,8 +3170,8 @@ static const char builtin_step[] = " (declare (in) vec2 edge)\n" " (declare (in) vec2 x))\n" " ((declare () vec2 t)\n" - " (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge)))))\n" - " (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge)))))\n" + " (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge)))))\n" + " (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge)))))\n" " (return (var_ref t))))\n" "\n" " (signature vec3\n" @@ -3234,9 +3179,9 @@ static const char builtin_step[] = " (declare (in) vec3 edge)\n" " (declare (in) vec3 x))\n" " ((declare () vec3 t)\n" - " (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge)))))\n" - " (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge)))))\n" - " (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge)))))\n" + " (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge)))))\n" + " (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge)))))\n" + " (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge)))))\n" " (return (var_ref t))))\n" "\n" " (signature vec4\n" @@ -3244,10 +3189,10 @@ static const char builtin_step[] = " (declare (in) vec4 edge)\n" " (declare (in) vec4 x))\n" " ((declare () vec4 t)\n" - " (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge)))))\n" - " (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge)))))\n" - " (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge)))))\n" - " (assign (constant bool (1)) (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(swiz w (var_ref edge)))))\n" + " (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge)))))\n" + " (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge)))))\n" + " (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge)))))\n" + " (assign (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(swiz w (var_ref edge)))))\n" " (return (var_ref t))))\n" "))\n" "\n" @@ -3329,105 +3274,230 @@ static const char builtin_texelFetch[] = " (declare (in) sampler1D sampler)\n" " (declare (in) int P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) int P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) int P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) ivec2 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) ivec2 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) ivec2 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) ivec3 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) ivec3 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) ivec3 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DArray sampler)\n" " (declare (in) ivec2 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1DArray sampler)\n" " (declare (in) ivec2 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1DArray sampler)\n" " (declare (in) ivec2 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DArray sampler)\n" " (declare (in) ivec3 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2DArray sampler)\n" " (declare (in) ivec3 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2DArray sampler)\n" " (declare (in) ivec3 P) \n" " (declare (in) int lod) )\n" - " ((return (txf (var_ref sampler) (var_ref P) (0 0 0) (var_ref lod) ))))\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) 0 (var_ref lod) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_texelFetchOffset[] = + "((function texelFetchOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) int P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) int P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) int P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) ivec2 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) ivec2 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) ivec2 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) ivec3 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) ivec3 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) ivec3 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1DArray sampler)\n" + " (declare (in) ivec2 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1DArray sampler)\n" + " (declare (in) ivec2 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1DArray sampler)\n" + " (declare (in) ivec2 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2DArray sampler)\n" + " (declare (in) ivec3 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txf vec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2DArray sampler)\n" + " (declare (in) ivec3 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txf ivec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2DArray sampler)\n" + " (declare (in) ivec3 P) \n" + " (declare (in) int lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txf uvec4 (var_ref sampler) (var_ref P) (var_ref offset) (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3438,235 +3508,300 @@ static const char builtin_texture[] = " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) float P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) float P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) float P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) samplerCube sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isamplerCube sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usamplerCube sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DArray sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1DArray sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1DArray sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DArray sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2DArray sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2DArray sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) )\n" + " ((return (tex float (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) )\n" + " ((return (tex float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) samplerCubeShadow sampler)\n" + " (declare (in) vec4 P) )\n" + " ((return (tex float (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) )\n" + " ((return (tex float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DArrayShadow sampler)\n" + " (declare (in) vec4 P) )\n" + " ((return (tex float (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz w (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) samplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isamplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usamplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) samplerCubeShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DArrayShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz w (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3677,14 +3812,14 @@ static const char builtin_texture1D[] = " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) float P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3695,14 +3830,14 @@ static const char builtin_texture1DArray[] = " (parameters\n" " (declare (in) sampler1DArray sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3714,7 +3849,7 @@ static const char builtin_texture1DArrayLod[] = " (declare (in) sampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3726,7 +3861,7 @@ static const char builtin_texture1DLod[] = " (declare (in) sampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3737,27 +3872,27 @@ static const char builtin_texture1DProj[] = " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3769,14 +3904,14 @@ static const char builtin_texture1DProjLod[] = " (declare (in) sampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3787,14 +3922,14 @@ static const char builtin_texture2D[] = " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3805,14 +3940,14 @@ static const char builtin_texture2DArray[] = " (parameters\n" " (declare (in) sampler2DArray sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3824,7 +3959,7 @@ static const char builtin_texture2DArrayLod[] = " (declare (in) sampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3836,7 +3971,7 @@ static const char builtin_texture2DLod[] = " (declare (in) sampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3847,27 +3982,27 @@ static const char builtin_texture2DProj[] = " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3879,14 +4014,14 @@ static const char builtin_texture2DProjLod[] = " (declare (in) sampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3897,7 +4032,7 @@ static const char builtin_texture2DRect[] = " (parameters\n" " (declare (in) sampler2DRect sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" "))\n" "" @@ -3908,13 +4043,13 @@ static const char builtin_texture2DRectProj[] = " (parameters\n" " (declare (in) sampler2DRect sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DRect sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" "))\n" "" @@ -3925,14 +4060,14 @@ static const char builtin_texture3D[] = " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3944,7 +4079,7 @@ static const char builtin_texture3DLod[] = " (declare (in) sampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3955,14 +4090,14 @@ static const char builtin_texture3DProj[] = " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -3974,7 +4109,7 @@ static const char builtin_texture3DProjLod[] = " (declare (in) sampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -3985,14 +4120,14 @@ static const char builtin_textureCube[] = " (parameters\n" " (declare (in) samplerCube sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (var_ref P) (0 0 0) 1 () ))))\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) 0 1 () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) samplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref bias) ))))\n" "\n" "))\n" "" @@ -4004,7 +4139,7 @@ static const char builtin_textureCubeLod[] = " (declare (in) samplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" "))\n" "" @@ -4017,7 +4152,7 @@ static const char builtin_textureGrad[] = " (declare (in) float P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4025,7 +4160,7 @@ static const char builtin_textureGrad[] = " (declare (in) float P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4033,7 +4168,7 @@ static const char builtin_textureGrad[] = " (declare (in) float P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4041,7 +4176,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec2 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4049,7 +4184,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec2 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4057,7 +4192,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec2 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4065,7 +4200,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4073,7 +4208,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4081,7 +4216,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4089,7 +4224,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4097,7 +4232,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4105,7 +4240,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4113,7 +4248,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec2 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4121,7 +4256,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec2 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4129,7 +4264,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec2 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4137,7 +4272,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4145,7 +4280,7 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4153,7 +4288,250 @@ static const char builtin_textureGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (var_ref P) (0 0 0) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) 0 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) samplerCubeShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DArrayShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz xyz (var_ref P)) 0 1 (swiz w (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_textureGradOffset[] = + "((function textureGradOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) samplerCube sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isamplerCube sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usamplerCube sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DArrayShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd float (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) 1 (swiz w (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" "))\n" "" @@ -4165,126 +4543,571 @@ static const char builtin_textureLod[] = " (declare (in) sampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) float P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) samplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isamplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usamplerCube sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1DArray sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2DArray sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (var_ref P) (0 0 0) 1 () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) 0 1 () (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) )\n" + " ((return (txl float (var_ref sampler) (swiz x (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) )\n" + " ((return (txl float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) )\n" + " ((return (txl float (var_ref sampler) (swiz xy (var_ref P)) 0 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_textureLodOffset[] = + "((function textureLodOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_textureOffset[] = + "((function textureOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) float P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec3 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec3 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec3 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1DArray sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2DArray sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (var_ref P) (var_ref offset) 1 () (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DArrayShadow sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) 1 (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -4295,196 +5118,222 @@ static const char builtin_textureProj[] = " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) vec2 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec3 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex ivec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) vec4 P) )\n" - " ((return (tex (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ))))\n" + " ((return (tex uvec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) )\n" + " ((return (tex float (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) )\n" + " ((return (tex float (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb ivec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float bias) )\n" - " ((return (txb (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + " ((return (txb uvec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -4497,7 +5346,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec2 P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4505,7 +5354,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec2 P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4513,7 +5362,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec2 P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4521,7 +5370,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4529,7 +5378,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4537,7 +5386,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) float dPdx) \n" " (declare (in) float dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4545,7 +5394,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4553,7 +5402,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4561,7 +5410,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec3 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4569,7 +5418,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4577,7 +5426,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4585,7 +5434,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) vec2 dPdx) \n" " (declare (in) vec2 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature vec4\n" " (parameters\n" @@ -4593,7 +5442,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" @@ -4601,7 +5450,7 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd ivec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" @@ -4609,7 +5458,181 @@ static const char builtin_textureProjGrad[] = " (declare (in) vec4 P) \n" " (declare (in) vec3 dPdx) \n" " (declare (in) vec3 dPdy) )\n" - " ((return (txd (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + " ((return (txd uvec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) )\n" + " ((return (txd float (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_textureProjGradOffset[] = + "((function textureProjGradOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd vec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd ivec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec3 dPdx) \n" + " (declare (in) vec3 dPdy) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txd uvec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float dPdx) \n" + " (declare (in) float dPdy) \n" + " (declare (const_in) int offset) )\n" + " ((return (txd float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) vec2 dPdx) \n" + " (declare (in) vec2 dPdy) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txd float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) ((var_ref dPdx) (var_ref dPdy)) ))))\n" "\n" "))\n" "" @@ -4621,105 +5644,520 @@ static const char builtin_textureProjLod[] = " (declare (in) sampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) vec2 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz y (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler1D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz x (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec3 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz z (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler2D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xy (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature vec4\n" " (parameters\n" " (declare (in) sampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl vec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature ivec4\n" " (parameters\n" " (declare (in) isampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl ivec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" "\n" " (signature uvec4\n" " (parameters\n" " (declare (in) usampler3D sampler)\n" " (declare (in) vec4 P) \n" " (declare (in) float lod) )\n" - " ((return (txl (var_ref sampler) (swiz xyz (var_ref P)) (0 0 0) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + " ((return (txl uvec4 (var_ref sampler) (swiz xyz (var_ref P)) 0 (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) )\n" + " ((return (txl float (var_ref sampler) (swiz x (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) )\n" + " ((return (txl float (var_ref sampler) (swiz xy (var_ref P)) 0 (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_textureProjLodOffset[] = + "((function textureProjLodOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txl vec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txl ivec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (txl uvec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) int offset) )\n" + " ((return (txl float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (in) float lod) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (txl float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref lod) ))))\n" + "\n" + "))\n" + "" +; +static const char builtin_textureProjOffset[] = + "((function textureProjOffset\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (tex vec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (tex ivec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec3 offset) )\n" + " ((return (tex uvec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) )\n" + " ((return (tex float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) )\n" + " ((return (tex float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec2 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz y (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler1D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec3 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz z (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler2D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec3 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb vec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature ivec4\n" + " (parameters\n" + " (declare (in) isampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec3 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb ivec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature uvec4\n" + " (parameters\n" + " (declare (in) usampler3D sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec3 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb uvec4 (var_ref sampler) (swiz xyz (var_ref P)) (var_ref offset) (swiz w (var_ref P)) () (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler1DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) int offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz x (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" + "\n" + " (signature float\n" + " (parameters\n" + " (declare (in) sampler2DShadow sampler)\n" + " (declare (in) vec4 P) \n" + " (declare (const_in) ivec2 offset) \n" + " (declare (in) float bias) )\n" + " ((return (txb float (var_ref sampler) (swiz xy (var_ref P)) (var_ref offset) (swiz w (var_ref P)) (swiz z (var_ref P)) (var_ref bias) ))))\n" "\n" "))\n" "" @@ -4730,135 +6168,135 @@ static const char builtin_transpose[] = " (parameters\n" " (declare (in) mat2 m))\n" " ((declare () mat2 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat3x2\n" " (parameters\n" " (declare (in) mat2x3 m))\n" " ((declare () mat3x2 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat4x2\n" " (parameters\n" " (declare (in) mat2x4 m))\n" " ((declare () mat4x2 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat2x3\n" " (parameters\n" " (declare (in) mat3x2 m))\n" " ((declare () mat2x3 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat3\n" " (parameters\n" " (declare (in) mat3 m))\n" " ((declare () mat3 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat4x3\n" " (parameters\n" " (declare (in) mat3x4 m))\n" " ((declare () mat4x3 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat2x4\n" " (parameters\n" " (declare (in) mat4x2 m))\n" " ((declare () mat2x4 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat3x4\n" " (parameters\n" " (declare (in) mat4x3 m))\n" " ((declare () mat3x4 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3)))))\n" "(return (var_ref t))))\n" "\n" " (signature mat4\n" " (parameters\n" " (declare (in) mat4 m))\n" " ((declare () mat4 t)\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3)))))\n" - " (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3)))))\n" + " (assign (w) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (3)))))\n" "(return (var_ref t))))\n" ")\n" "\n" @@ -13062,12 +14500,18 @@ static const char prototypes_for_130_frag[] = '(','f','u','n','c','t','i','o','n',' ','a','l','l',' ','(','s','i','g','n','a','t','u','r','e',' ','b','o','o','l',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','2',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','o','o','l',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','3',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','o','o','l',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','4',' ','x',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','n','o','t',' ','(','s','i','g','n','a','t','u','r','e',' ','b','v','e','c','2',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','2',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','v','e','c','3',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','3',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','4',' ','x',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', -'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','L','o','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','e','l','F','e','t','c','h',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','e','l','F','e','t','c','h','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','L','o','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','L','o','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','L','o','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','G','r','a','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','G','r','a','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','G','r','a','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','G','r','a','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','o',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','1','D',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','c','o','o','r','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','1','D','P','r','o','j',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','c','o','o','r','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','c','o','o','r','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','1','D','L','o','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',')', @@ -13169,6 +14613,7 @@ static const char *functions_for_130_frag [] = { builtin_tan, builtin_tanh, builtin_texelFetch, + builtin_texelFetchOffset, builtin_texture, builtin_texture1D, builtin_texture1DLod, @@ -13185,10 +14630,15 @@ static const char *functions_for_130_frag [] = { builtin_textureCube, builtin_textureCubeLod, builtin_textureGrad, + builtin_textureGradOffset, builtin_textureLod, + builtin_textureLodOffset, + builtin_textureOffset, builtin_textureProj, builtin_textureProjGrad, + builtin_textureProjGradOffset, builtin_textureProjLod, + builtin_textureProjLodOffset, builtin_transpose, builtin_trunc, }; @@ -13253,12 +14703,18 @@ static const char prototypes_for_130_vert[] = '(','f','u','n','c','t','i','o','n',' ','a','l','l',' ','(','s','i','g','n','a','t','u','r','e',' ','b','o','o','l',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','2',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','o','o','l',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','3',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','o','o','l',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','4',' ','x',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','n','o','t',' ','(','s','i','g','n','a','t','u','r','e',' ','b','v','e','c','2',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','2',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','v','e','c','3',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','3',' ','x',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','b','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','b','v','e','c','4',' ','x',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', -'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','L','o','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','e','l','F','e','t','c','h',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','e','l','F','e','t','c','h','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','L','o','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','L','o','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','L','o','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','G','r','a','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','G','r','a','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','C','u','b','e',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','C','u','b','e',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','C','u','b','e',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f','s','e','t',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D','A','r','r','a','y',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','A','r','r','a','y','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','A','r','r','a','y','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','G','r','a','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','P','d','y',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','P','d','y',')',')',' ','(',')',')',')', +'(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','P','r','o','j','G','r','a','d','O','f','f','s','e','t',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','1','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','2','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','2',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','i','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','u','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','u','s','a','m','p','l','e','r','3','D',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','3',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','v','e','c','3',' ','o','f','f',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','i','n','t',' ','o',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','f','l','o','a','t',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','2','D','S','h','a','d','o','w',' ','s',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','P',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','x',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','d','y',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','o',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','1','D',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','c','o','o','r','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','1','D','P','r','o','j',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','c','o','o','r','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','c','o','o','r','d',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','2',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','v','e','c','4',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','b','i','a','s',')',')',' ','(',')',')',')', '(','f','u','n','c','t','i','o','n',' ','t','e','x','t','u','r','e','1','D','L','o','d',' ','(','s','i','g','n','a','t','u','r','e',' ','v','e','c','4',' ','(','p','a','r','a','m','e','t','e','r','s',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','s','a','m','p','l','e','r','1','D',' ','s','a','m','p','l','e','r',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','c','o','o','r','d',')',' ','(','d','e','c','l','a','r','e',' ','(','i','n',')',' ','f','l','o','a','t',' ','l','o','d',')',')',' ','(',')',')',')', @@ -13355,6 +14811,7 @@ static const char *functions_for_130_vert [] = { builtin_tan, builtin_tanh, builtin_texelFetch, + builtin_texelFetchOffset, builtin_texture, builtin_texture1D, builtin_texture1DLod, @@ -13371,10 +14828,15 @@ static const char *functions_for_130_vert [] = { builtin_textureCube, builtin_textureCubeLod, builtin_textureGrad, + builtin_textureGradOffset, builtin_textureLod, + builtin_textureLodOffset, + builtin_textureOffset, builtin_textureProj, builtin_textureProjGrad, + builtin_textureProjGradOffset, builtin_textureProjLod, + builtin_textureProjLodOffset, builtin_transpose, builtin_trunc, }; @@ -13562,21 +15024,86 @@ static const char *functions_for_EXT_texture_array_vert [] = { builtin_texture2DArray, builtin_texture2DArrayLod, }; -static gl_shader *builtin_profiles[12]; +static const char prototypes_for_OES_texture_3D_frag[] = + "(\n" + "(function texture3D\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 coord))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 coord)\n" + " (declare (in) float bias))\n" + " ()))\n" + "(function texture3DProj\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 coord))\n" + " ())\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 coord)\n" + " (declare (in) float bias))\n" + " ())))" +; +static const char *functions_for_OES_texture_3D_frag [] = { + builtin_texture3D, + builtin_texture3DProj, +}; +static const char prototypes_for_OES_texture_3D_vert[] = + "(\n" + "(function texture3D\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 coord))\n" + " ()))\n" + "(function texture3DProj\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 coord))\n" + " ()))\n" + "(function texture3DLod\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec3 coord)\n" + " (declare (in) float lod))\n" + " ()))\n" + "(function texture3DProjLod\n" + " (signature vec4\n" + " (parameters\n" + " (declare (in) sampler3D sampler)\n" + " (declare (in) vec4 coord)\n" + " (declare (in) float lod))\n" + " ())))" +; +static const char *functions_for_OES_texture_3D_vert [] = { + builtin_texture3D, + builtin_texture3DLod, + builtin_texture3DProj, + builtin_texture3DProjLod, +}; +static gl_shader *builtin_profiles[14]; void *builtin_mem_ctx = NULL; void _mesa_glsl_release_functions(void) { - talloc_free(builtin_mem_ctx); + ralloc_free(builtin_mem_ctx); builtin_mem_ctx = NULL; memset(builtin_profiles, 0, sizeof(builtin_profiles)); } static void _mesa_read_profile(struct _mesa_glsl_parse_state *state, - exec_list *instructions, int profile_index, const char *prototypes, const char **functions, @@ -13586,7 +15113,7 @@ _mesa_read_profile(struct _mesa_glsl_parse_state *state, if (sh == NULL) { sh = read_builtins(GL_VERTEX_SHADER, prototypes, functions, count); - talloc_steal(builtin_mem_ctx, sh); + ralloc_steal(builtin_mem_ctx, sh); builtin_profiles[profile_index] = sh; } @@ -13595,98 +15122,111 @@ _mesa_read_profile(struct _mesa_glsl_parse_state *state, } void -_mesa_glsl_initialize_functions(exec_list *instructions, - struct _mesa_glsl_parse_state *state) +_mesa_glsl_initialize_functions(struct _mesa_glsl_parse_state *state) { if (builtin_mem_ctx == NULL) { - builtin_mem_ctx = talloc_init("GLSL built-in functions"); + builtin_mem_ctx = ralloc_context(NULL); // "GLSL built-in functions" memset(&builtin_profiles, 0, sizeof(builtin_profiles)); } state->num_builtins_to_link = 0; if (state->target == fragment_shader && state->language_version == 100) { - _mesa_read_profile(state, instructions, 0, + _mesa_read_profile(state, 0, prototypes_for_100_frag, functions_for_100_frag, Elements(functions_for_100_frag)); } if (state->target == vertex_shader && state->language_version == 100) { - _mesa_read_profile(state, instructions, 1, + _mesa_read_profile(state, 1, prototypes_for_100_vert, functions_for_100_vert, Elements(functions_for_100_vert)); } if (state->target == fragment_shader && state->language_version == 110) { - _mesa_read_profile(state, instructions, 2, + _mesa_read_profile(state, 2, prototypes_for_110_frag, functions_for_110_frag, Elements(functions_for_110_frag)); } if (state->target == vertex_shader && state->language_version == 110) { - _mesa_read_profile(state, instructions, 3, + _mesa_read_profile(state, 3, prototypes_for_110_vert, functions_for_110_vert, Elements(functions_for_110_vert)); } if (state->target == fragment_shader && state->language_version == 120) { - _mesa_read_profile(state, instructions, 4, + _mesa_read_profile(state, 4, prototypes_for_120_frag, functions_for_120_frag, Elements(functions_for_120_frag)); } if (state->target == vertex_shader && state->language_version == 120) { - _mesa_read_profile(state, instructions, 5, + _mesa_read_profile(state, 5, prototypes_for_120_vert, functions_for_120_vert, Elements(functions_for_120_vert)); } if (state->target == fragment_shader && state->language_version == 130) { - _mesa_read_profile(state, instructions, 6, + _mesa_read_profile(state, 6, prototypes_for_130_frag, functions_for_130_frag, Elements(functions_for_130_frag)); } if (state->target == vertex_shader && state->language_version == 130) { - _mesa_read_profile(state, instructions, 7, + _mesa_read_profile(state, 7, prototypes_for_130_vert, functions_for_130_vert, Elements(functions_for_130_vert)); } if (state->target == fragment_shader && state->ARB_texture_rectangle_enable) { - _mesa_read_profile(state, instructions, 8, + _mesa_read_profile(state, 8, prototypes_for_ARB_texture_rectangle_frag, functions_for_ARB_texture_rectangle_frag, Elements(functions_for_ARB_texture_rectangle_frag)); } if (state->target == vertex_shader && state->ARB_texture_rectangle_enable) { - _mesa_read_profile(state, instructions, 9, + _mesa_read_profile(state, 9, prototypes_for_ARB_texture_rectangle_vert, functions_for_ARB_texture_rectangle_vert, Elements(functions_for_ARB_texture_rectangle_vert)); } if (state->target == fragment_shader && state->EXT_texture_array_enable) { - _mesa_read_profile(state, instructions, 10, + _mesa_read_profile(state, 10, prototypes_for_EXT_texture_array_frag, functions_for_EXT_texture_array_frag, Elements(functions_for_EXT_texture_array_frag)); } if (state->target == vertex_shader && state->EXT_texture_array_enable) { - _mesa_read_profile(state, instructions, 11, + _mesa_read_profile(state, 11, prototypes_for_EXT_texture_array_vert, functions_for_EXT_texture_array_vert, Elements(functions_for_EXT_texture_array_vert)); } + if (state->target == fragment_shader && state->OES_texture_3D_enable) { + _mesa_read_profile(state, 12, + prototypes_for_OES_texture_3D_frag, + functions_for_OES_texture_3D_frag, + Elements(functions_for_OES_texture_3D_frag)); + } + + if (state->target == vertex_shader && state->OES_texture_3D_enable) { + _mesa_read_profile(state, 13, + prototypes_for_OES_texture_3D_vert, + functions_for_OES_texture_3D_vert, + Elements(functions_for_OES_texture_3D_vert)); + } + } diff --git a/src/glsl/builtins/tools/builtin_function.cpp b/src/glsl/builtin_stubs.cpp index c44804f2ef..00b3294915 100644 --- a/src/glsl/builtins/tools/builtin_function.cpp +++ b/src/glsl/builtin_stubs.cpp @@ -33,7 +33,6 @@ _mesa_glsl_release_functions(void) } void -_mesa_glsl_initialize_functions(exec_list *instructions, - struct _mesa_glsl_parse_state *state) +_mesa_glsl_initialize_functions(_mesa_glsl_parse_state *state) { } diff --git a/src/glsl/builtin_types.h b/src/glsl/builtin_types.h index 443ae1606e..58b9a81273 100644 --- a/src/glsl/builtin_types.h +++ b/src/glsl/builtin_types.h @@ -24,10 +24,15 @@ const glsl_type glsl_type::_error_type = glsl_type(GL_INVALID_ENUM, GLSL_TYPE_ERROR, 0, 0, ""); -const glsl_type glsl_type::void_type = +const glsl_type glsl_type::_void_type = glsl_type(GL_INVALID_ENUM, GLSL_TYPE_VOID, 0, 0, "void"); +const glsl_type glsl_type::_sampler3D_type = + glsl_type(GL_SAMPLER_3D, GLSL_SAMPLER_DIM_3D, 0, 0, GLSL_TYPE_FLOAT, + "sampler3D"); + const glsl_type *const glsl_type::error_type = & glsl_type::_error_type; +const glsl_type *const glsl_type::void_type = & glsl_type::_void_type; /** \name Core built-in types * @@ -180,8 +185,6 @@ const glsl_type glsl_type::builtin_110_types[] = { "sampler1DShadow"), glsl_type(GL_SAMPLER_2D_SHADOW, GLSL_SAMPLER_DIM_2D, 1, 0, GLSL_TYPE_FLOAT, "sampler2DShadow"), - glsl_type(GL_SAMPLER_3D, GLSL_SAMPLER_DIM_3D, 0, 0, GLSL_TYPE_FLOAT, - "sampler3D"), }; /*@}*/ diff --git a/src/glsl/builtin_variables.h b/src/glsl/builtin_variables.h index a34c67e348..9b4f5d9e3e 100644 --- a/src/glsl/builtin_variables.h +++ b/src/glsl/builtin_variables.h @@ -101,5 +101,10 @@ static const builtin_variable builtin_110_deprecated_uniforms[] = { { ir_var_uniform, -1, "mat4", "gl_ModelViewProjectionMatrixInverseTranspose" }, { ir_var_uniform, -1, "float", "gl_NormalScale" }, { ir_var_uniform, -1, "gl_LightModelParameters", "gl_LightModel"}, + + /* Mesa-internal ATI_envmap_bumpmap state. */ + { ir_var_uniform, -1, "vec2", "gl_MESABumpRotMatrix0"}, + { ir_var_uniform, -1, "vec2", "gl_MESABumpRotMatrix1"}, + { ir_var_uniform, -1, "vec4", "gl_MESAFogParamsOptimized"}, }; diff --git a/src/glsl/builtins/ir/atan b/src/glsl/builtins/ir/atan index 3f97e0d46f..cfecc1f174 100644 --- a/src/glsl/builtins/ir/atan +++ b/src/glsl/builtins/ir/atan @@ -55,19 +55,19 @@ ( (declare () float r) (if (expression bool > (expression float abs (var_ref x)) (constant float (0.000100))) ( - (assign (constant bool (1)) (x) (var_ref r) (call atan ((expression float / (var_ref y) (var_ref x))))) + (assign (x) (var_ref r) (call atan ((expression float / (var_ref y) (var_ref x))))) (if (expression bool < (var_ref x) (constant float (0.000000)) ) ( (if (expression bool >= (var_ref y) (constant float (0.000000)) ) - ((assign (constant bool (1)) (x) (var_ref r) (expression float + (var_ref r) (constant float (3.141593))))) - ((assign (constant bool (1)) (x) (var_ref r) (expression float - (var_ref r) (constant float (3.141593)))))) + ((assign (x) (var_ref r) (expression float + (var_ref r) (constant float (3.141593))))) + ((assign (x) (var_ref r) (expression float - (var_ref r) (constant float (3.141593)))))) ) ( )) ) ( (declare () float sgn) - (assign (constant bool (1)) (x) (var_ref sgn) (expression float sign (var_ref y))) - (assign (constant bool (1)) (x) (var_ref r) (expression float * (var_ref sgn) (constant float (1.5707965)))) + (assign (x) (var_ref sgn) (expression float sign (var_ref y))) + (assign (x) (var_ref r) (expression float * (var_ref sgn) (constant float (1.5707965)))) )) (return (var_ref r) ) @@ -80,10 +80,10 @@ (declare (in) vec2 y) (declare (in) vec2 x)) ((declare () vec2 r) - (assign (constant bool (1)) (x) (var_ref r) + (assign (x) (var_ref r) (call atan ((swiz x (var_ref y)) (swiz x (var_ref x))))) - (assign (constant bool (1)) (y) (var_ref r) + (assign (y) (var_ref r) (call atan ((swiz y (var_ref y)) (swiz y (var_ref x))))) (return (var_ref r)))) @@ -93,13 +93,13 @@ (declare (in) vec3 y) (declare (in) vec3 x)) ((declare () vec3 r) - (assign (constant bool (1)) (x) (var_ref r) + (assign (x) (var_ref r) (call atan ((swiz x (var_ref y)) (swiz x (var_ref x))))) - (assign (constant bool (1)) (y) (var_ref r) + (assign (y) (var_ref r) (call atan ((swiz y (var_ref y)) (swiz y (var_ref x))))) - (assign (constant bool (1)) (z) (var_ref r) + (assign (z) (var_ref r) (call atan ((swiz z (var_ref y)) (swiz z (var_ref x))))) (return (var_ref r)))) @@ -109,16 +109,16 @@ (declare (in) vec4 y) (declare (in) vec4 x)) ((declare () vec4 r) - (assign (constant bool (1)) (x) (var_ref r) + (assign (x) (var_ref r) (call atan ((swiz x (var_ref y)) (swiz x (var_ref x))))) - (assign (constant bool (1)) (y) (var_ref r) + (assign (y) (var_ref r) (call atan ((swiz y (var_ref y)) (swiz y (var_ref x))))) - (assign (constant bool (1)) (z) (var_ref r) + (assign (z) (var_ref r) (call atan ((swiz z (var_ref y)) (swiz z (var_ref x))))) - (assign (constant bool (1)) (w) (var_ref r) + (assign (w) (var_ref r) (call atan ((swiz w (var_ref y)) (swiz w (var_ref x))))) (return (var_ref r))))) diff --git a/src/glsl/builtins/ir/distance b/src/glsl/builtins/ir/distance index 7789ca6314..c249f8c996 100644 --- a/src/glsl/builtins/ir/distance +++ b/src/glsl/builtins/ir/distance @@ -10,7 +10,7 @@ (declare (in) vec2 p0) (declare (in) vec2 p1)) ((declare () vec2 p) - (assign (constant bool (1)) (xy) (var_ref p) (expression vec2 - (var_ref p0) (var_ref p1))) + (assign (xy) (var_ref p) (expression vec2 - (var_ref p0) (var_ref p1))) (return (expression float sqrt (expression float dot (var_ref p) (var_ref p)))))) (signature float @@ -18,7 +18,7 @@ (declare (in) vec3 p0) (declare (in) vec3 p1)) ((declare () vec3 p) - (assign (constant bool (1)) (xyz) (var_ref p) (expression vec3 - (var_ref p0) (var_ref p1))) + (assign (xyz) (var_ref p) (expression vec3 - (var_ref p0) (var_ref p1))) (return (expression float sqrt (expression float dot (var_ref p) (var_ref p)))))) (signature float @@ -26,6 +26,6 @@ (declare (in) vec4 p0) (declare (in) vec4 p1)) ((declare () vec4 p) - (assign (constant bool (1)) (xyzw) (var_ref p) (expression vec4 - (var_ref p0) (var_ref p1))) + (assign (xyzw) (var_ref p) (expression vec4 - (var_ref p0) (var_ref p1))) (return (expression float sqrt (expression float dot (var_ref p) (var_ref p)))))) )) diff --git a/src/glsl/builtins/ir/matrixCompMult b/src/glsl/builtins/ir/matrixCompMult index 4be9b03e31..2400f11afa 100644 --- a/src/glsl/builtins/ir/matrixCompMult +++ b/src/glsl/builtins/ir/matrixCompMult @@ -4,8 +4,8 @@ (declare (in) mat2 x) (declare (in) mat2 y)) ((declare () mat2 z) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) (return (var_ref z)))) (signature mat3 @@ -13,9 +13,9 @@ (declare (in) mat3 x) (declare (in) mat3 y)) ((declare () mat3 z) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) + (assign (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) (return (var_ref z)))) (signature mat4 @@ -23,10 +23,10 @@ (declare (in) mat4 x) (declare (in) mat4 y)) ((declare () mat4 z) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (3))) (expression vec4 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (3))) (expression vec4 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3))))) (return (var_ref z)))) (signature mat2x3 @@ -34,8 +34,8 @@ (declare (in) mat2x3 x) (declare (in) mat2x3 y)) ((declare () mat2x3 z) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) (return (var_ref z)))) (signature mat3x2 @@ -43,9 +43,9 @@ (declare (in) mat3x2 x) (declare (in) mat3x2 y)) ((declare () mat3x2 z) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) + (assign (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) (return (var_ref z)))) (signature mat2x4 @@ -53,8 +53,8 @@ (declare (in) mat2x4 x) (declare (in) mat2x4 y)) ((declare () mat2x4 z) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) (return (var_ref z)))) (signature mat4x2 @@ -62,10 +62,10 @@ (declare (in) mat4x2 x) (declare (in) mat4x2 y)) ((declare () mat4x2 z) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) - (assign (constant bool (1)) (xy) (array_ref (var_ref z) (constant int (3))) (expression vec2 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3))))) + (assign (xy) (array_ref (var_ref z) (constant int (0))) (expression vec2 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xy) (array_ref (var_ref z) (constant int (1))) (expression vec2 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xy) (array_ref (var_ref z) (constant int (2))) (expression vec2 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) + (assign (xy) (array_ref (var_ref z) (constant int (3))) (expression vec2 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3))))) (return (var_ref z)))) (signature mat3x4 @@ -73,9 +73,9 @@ (declare (in) mat3x4 x) (declare (in) mat3x4 y)) ((declare () mat3x4 z) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (0))) (expression vec4 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (1))) (expression vec4 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xyzw) (array_ref (var_ref z) (constant int (2))) (expression vec4 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) (return (var_ref z)))) (signature mat4x3 @@ -83,9 +83,9 @@ (declare (in) mat4x3 x) (declare (in) mat4x3 y)) ((declare () mat4x3 z) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref z) (constant int (3))) (expression vec3 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3))))) + (assign (xyz) (array_ref (var_ref z) (constant int (0))) (expression vec3 * (array_ref (var_ref x) (constant int (0))) (array_ref (var_ref y) (constant int (0))))) + (assign (xyz) (array_ref (var_ref z) (constant int (1))) (expression vec3 * (array_ref (var_ref x) (constant int (1))) (array_ref (var_ref y) (constant int (1))))) + (assign (xyz) (array_ref (var_ref z) (constant int (2))) (expression vec3 * (array_ref (var_ref x) (constant int (2))) (array_ref (var_ref y) (constant int (2))))) + (assign (xyz) (array_ref (var_ref z) (constant int (3))) (expression vec3 * (array_ref (var_ref x) (constant int (3))) (array_ref (var_ref y) (constant int (3))))) (return (var_ref z)))) )) diff --git a/src/glsl/builtins/ir/modf b/src/glsl/builtins/ir/modf index 2b935a91a7..f4f631567b 100644 --- a/src/glsl/builtins/ir/modf +++ b/src/glsl/builtins/ir/modf @@ -4,9 +4,8 @@ (declare (in) float x) (declare (out) float i)) ((declare () float t) - (assign (constant bool (1)) (x) (var_ref t) - (expression float trunc (var_ref x))) - (assign (constant bool (1)) (x) (var_ref i) (var_ref t)) + (assign (x) (var_ref t) (expression float trunc (var_ref x))) + (assign (x) (var_ref i) (var_ref t)) (return (expression float - (var_ref x) (var_ref t))))) (signature vec2 @@ -14,9 +13,8 @@ (declare (in) vec2 x) (declare (out) vec2 i)) ((declare () vec2 t) - (assign (constant bool (1)) (xy) (var_ref t) - (expression vec2 trunc (var_ref x))) - (assign (constant bool (1)) (xy) (var_ref i) (var_ref t)) + (assign (xy) (var_ref t) (expression vec2 trunc (var_ref x))) + (assign (xy) (var_ref i) (var_ref t)) (return (expression vec2 - (var_ref x) (var_ref t))))) (signature vec3 @@ -24,9 +22,8 @@ (declare (in) vec3 x) (declare (out) vec3 i)) ((declare () vec3 t) - (assign (constant bool (1)) (xyz) (var_ref t) - (expression vec3 trunc (var_ref x))) - (assign (constant bool (1)) (xyz) (var_ref i) (var_ref t)) + (assign (xyz) (var_ref t) (expression vec3 trunc (var_ref x))) + (assign (xyz) (var_ref i) (var_ref t)) (return (expression vec3 - (var_ref x) (var_ref t))))) (signature vec4 @@ -34,8 +31,7 @@ (declare (in) vec4 x) (declare (out) vec4 i)) ((declare () vec4 t) - (assign (constant bool (1)) (xyzw) (var_ref t) - (expression vec4 trunc (var_ref x))) - (assign (constant bool (1)) (xyzw) (var_ref i) (var_ref t)) + (assign (xyzw) (var_ref t) (expression vec4 trunc (var_ref x))) + (assign (xyzw) (var_ref i) (var_ref t)) (return (expression vec4 - (var_ref x) (var_ref t))))) )) diff --git a/src/glsl/builtins/ir/noise2 b/src/glsl/builtins/ir/noise2 index 383fccfadf..d3366145fe 100644 --- a/src/glsl/builtins/ir/noise2 +++ b/src/glsl/builtins/ir/noise2 @@ -6,10 +6,10 @@ (declare () float b) (declare () vec2 t) - (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) (var_ref a)) - (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0))))) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) @@ -20,10 +20,10 @@ (declare () float b) (declare () vec2 t) - (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) (var_ref a)) - (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0))))) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) @@ -36,10 +36,10 @@ (declare () float b) (declare () vec2 t) - (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) (var_ref a)) - (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0))))) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) (return (var_ref t)) )) @@ -52,10 +52,10 @@ (declare () float b) (declare () vec2 t) - (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) (var_ref a)) - (assign (constant bool (1)) (y) (var_ref t) (var_ref b)) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0))))) + (assign (x) (var_ref t) (var_ref a)) + (assign (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 ed7ad5190f..1d8aa3f30d 100644 --- a/src/glsl/builtins/ir/noise3 +++ b/src/glsl/builtins/ir/noise3 @@ -7,13 +7,13 @@ (declare () float c) (declare () vec3 t) - (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 c) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.0))))) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0))))) + (assign (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) (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)) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) + (assign (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) @@ -25,13 +25,13 @@ (declare () float c) (declare () vec3 t) - (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 c) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.0))))) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0))))) + (assign (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) (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)) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) + (assign (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) @@ -43,13 +43,13 @@ (declare () float c) (declare () vec3 t) - (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 c) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.0))))) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression vec2 + (var_ref p) (constant vec2 (601.0 313.0))))) + (assign (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) (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)) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) + (assign (z) (var_ref t) (var_ref c)) (return (var_ref t)) )) @@ -61,13 +61,13 @@ (declare () float c) (declare () vec3 t) - (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 c) (expression float noise (expression float + (var_ref p) (constant float (1559.0))))) + (assign (x) (var_ref a) (expression float noise (var_ref p))) + (assign (x) (var_ref b) (expression float noise (expression float + (var_ref p) (constant float (601.0))))) + (assign (x) (var_ref c) (expression float noise (expression float + (var_ref p) (constant float (1559.0))))) - (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)) + (assign (x) (var_ref t) (var_ref a)) + (assign (y) (var_ref t) (var_ref b)) + (assign (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 77a2529a18..d0894fd5e3 100644 --- a/src/glsl/builtins/ir/noise4 +++ b/src/glsl/builtins/ir/noise4 @@ -9,17 +9,17 @@ (declare () vec4 _r) (declare () vec4 _p) - (assign (constant bool (1)) (xyzw) (var_ref _p) (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.0))) ) + (assign (xyzw) (var_ref _p) (expression vec4 + (var_ref p) (constant vec4 (1559.0 113.0 1861.0 797.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 vec4 + (var_ref p) (constant vec4 (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 vec4 + (var_ref _p) (constant vec4 (601.0 313.0 29.0 277.0))))) + (assign (x) (var_ref _x) (expression float noise(var_ref p))) + (assign (x) (var_ref _y) (expression float noise(expression vec4 + (var_ref p) (constant vec4 (601.0 313.0 29.0 277.0))))) + (assign (x) (var_ref _z) (expression float noise(var_ref _p))) + (assign (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) (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)) + (assign (x) (var_ref _r) (var_ref _x)) + (assign (y) (var_ref _r) (var_ref _y)) + (assign (z) (var_ref _r) (var_ref _z)) + (assign (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) @@ -33,17 +33,17 @@ (declare () vec4 _r) (declare () vec3 _p) - (assign (constant bool (1)) (xyz) (var_ref _p) (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.0))) ) + (assign (xyz) (var_ref _p) (expression vec3 + (var_ref p) (constant vec3 (1559.0 113.0 1861.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 vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.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 vec3 + (var_ref _p) (constant vec3 (601.0 313.0 29.0))))) + (assign (x) (var_ref _x) (expression float noise(var_ref p))) + (assign (x) (var_ref _y) (expression float noise(expression vec3 + (var_ref p) (constant vec3 (601.0 313.0 29.0))))) + (assign (x) (var_ref _z) (expression float noise(var_ref _p))) + (assign (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) (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)) + (assign (x) (var_ref _r) (var_ref _x)) + (assign (y) (var_ref _r) (var_ref _y)) + (assign (z) (var_ref _r) (var_ref _z)) + (assign (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) @@ -57,17 +57,17 @@ (declare () vec4 _r) (declare () vec2 _p) - (assign (constant bool (1)) (xy) (var_ref _p) (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.0))) ) + (assign (xy) (var_ref _p) (expression vec2 + (var_ref p) (constant vec2 (1559.0 113.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 vec2 + (var_ref p) (constant vec2 (601.0 313.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 vec2 + (var_ref _p) (constant vec2 (601.0 313.0))))) + (assign (x) (var_ref _x) (expression float noise(var_ref p))) + (assign (x) (var_ref _y) (expression float noise(expression vec2 + (var_ref p) (constant vec2 (601.0 313.0))))) + (assign (x) (var_ref _z) (expression float noise(var_ref _p))) + (assign (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) (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)) + (assign (x) (var_ref _r) (var_ref _x)) + (assign (y) (var_ref _r) (var_ref _y)) + (assign (z) (var_ref _r) (var_ref _z)) + (assign (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)) (x) (var_ref _p) (expression float + (var_ref p) (constant float (1559.0))) ) + (assign (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 (x) (var_ref _x) (expression float noise(var_ref p))) + (assign (x) (var_ref _y) (expression float noise(expression float + (var_ref p) (constant float (601.0 313.0 29.0 277.0))))) + (assign (x) (var_ref _z) (expression float noise(var_ref _p))) + (assign (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) (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)) + (assign (x) (var_ref _r) (var_ref _x)) + (assign (y) (var_ref _r) (var_ref _y)) + (assign (z) (var_ref _r) (var_ref _z)) + (assign (w) (var_ref _r) (var_ref _w)) (return (var_ref _r)) )) )) diff --git a/src/glsl/builtins/ir/outerProduct b/src/glsl/builtins/ir/outerProduct index 61d4626154..0e3f375bba 100644 --- a/src/glsl/builtins/ir/outerProduct +++ b/src/glsl/builtins/ir/outerProduct @@ -4,8 +4,8 @@ (declare (in) vec2 u) (declare (in) vec2 v)) ((declare () mat2 m) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v)))) (return (var_ref m)))) (signature mat2x3 @@ -13,8 +13,8 @@ (declare (in) vec3 u) (declare (in) vec2 v)) ((declare () mat2x3 m) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v)))) (return (var_ref m)))) (signature mat2x4 @@ -22,8 +22,8 @@ (declare (in) vec4 u) (declare (in) vec2 v)) ((declare () mat2x4 m) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v)))) (return (var_ref m)))) (signature mat3x2 @@ -31,9 +31,9 @@ (declare (in) vec2 u) (declare (in) vec3 v)) ((declare () mat3x2 m) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v)))) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v)))) (return (var_ref m)) )) @@ -42,9 +42,9 @@ (declare (in) vec3 u) (declare (in) vec3 v)) ((declare () mat3 m) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v)))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v)))) (return (var_ref m)))) (signature mat3x4 @@ -52,9 +52,9 @@ (declare (in) vec4 u) (declare (in) vec3 v)) ((declare () mat3x4 m) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v)))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v)))) (return (var_ref m)))) (signature mat4x2 @@ -62,10 +62,10 @@ (declare (in) vec2 u) (declare (in) vec4 v)) ((declare () mat4x2 m) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v)))) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v)))) - (assign (constant bool (1)) (xy) (array_ref (var_ref m) (constant int (3))) (expression vec2 * (var_ref u) (swiz w (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (0))) (expression vec2 * (var_ref u) (swiz x (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (1))) (expression vec2 * (var_ref u) (swiz y (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (2))) (expression vec2 * (var_ref u) (swiz z (var_ref v)))) + (assign (xy) (array_ref (var_ref m) (constant int (3))) (expression vec2 * (var_ref u) (swiz w (var_ref v)))) (return (var_ref m)))) (signature mat4x3 @@ -73,10 +73,10 @@ (declare (in) vec3 u) (declare (in) vec4 v)) ((declare () mat4x3 m) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v)))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v)))) - (assign (constant bool (1)) (xyz) (array_ref (var_ref m) (constant int (3))) (expression vec3 * (var_ref u) (swiz w (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (0))) (expression vec3 * (var_ref u) (swiz x (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (1))) (expression vec3 * (var_ref u) (swiz y (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (2))) (expression vec3 * (var_ref u) (swiz z (var_ref v)))) + (assign (xyz) (array_ref (var_ref m) (constant int (3))) (expression vec3 * (var_ref u) (swiz w (var_ref v)))) (return (var_ref m)))) (signature mat4 @@ -84,9 +84,9 @@ (declare (in) vec4 u) (declare (in) vec4 v)) ((declare () mat4 m) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v)))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v)))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v)))) - (assign (constant bool (1)) (xyzw) (array_ref (var_ref m) (constant int (3))) (expression vec4 * (var_ref u) (swiz w (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (0))) (expression vec4 * (var_ref u) (swiz x (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (1))) (expression vec4 * (var_ref u) (swiz y (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (2))) (expression vec4 * (var_ref u) (swiz z (var_ref v)))) + (assign (xyzw) (array_ref (var_ref m) (constant int (3))) (expression vec4 * (var_ref u) (swiz w (var_ref v)))) (return (var_ref m)))) )) diff --git a/src/glsl/builtins/ir/refract b/src/glsl/builtins/ir/refract index f6319b0ed4..60899f01ce 100644 --- a/src/glsl/builtins/ir/refract +++ b/src/glsl/builtins/ir/refract @@ -5,7 +5,7 @@ (declare (in) float n) (declare (in) float eta)) ((declare () float k) - (assign (constant bool (1)) (x) (var_ref k) + (assign (x) (var_ref k) (expression float - (constant float (1.0)) (expression float * (var_ref eta) (expression float * (var_ref eta) @@ -30,7 +30,7 @@ (declare (in) vec2 n) (declare (in) float eta)) ((declare () float k) - (assign (constant bool (1)) (x) (var_ref k) + (assign (x) (var_ref k) (expression float - (constant float (1.0)) (expression float * (var_ref eta) (expression float * (var_ref eta) @@ -55,7 +55,7 @@ (declare (in) vec3 n) (declare (in) float eta)) ((declare () float k) - (assign (constant bool (1)) (x) (var_ref k) + (assign (x) (var_ref k) (expression float - (constant float (1.0)) (expression float * (var_ref eta) (expression float * (var_ref eta) @@ -80,7 +80,7 @@ (declare (in) vec4 n) (declare (in) float eta)) ((declare () float k) - (assign (constant bool (1)) (x) (var_ref k) + (assign (x) (var_ref k) (expression float - (constant float (1.0)) (expression float * (var_ref eta) (expression float * (var_ref eta) diff --git a/src/glsl/builtins/ir/smoothstep b/src/glsl/builtins/ir/smoothstep index 0164219a05..94c98b29e5 100644 --- a/src/glsl/builtins/ir/smoothstep +++ b/src/glsl/builtins/ir/smoothstep @@ -5,40 +5,26 @@ (declare (in) float edge1) (declare (in) float x)) ((declare () float t) - - (assign (constant bool (1)) (x) (var_ref t) + (assign (x) (var_ref t) (expression float max (expression float min (expression float / (expression float - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) (constant float (1.0))) (constant float (0.0)))) - (return (expression float * (var_ref t) (expression float * (var_ref t) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (var_ref t)))))))) - + (return (expression float * (var_ref t) (expression float * (var_ref t) (expression float - (constant float (3.0)) (expression float * (constant float (2.0)) (var_ref t)))))))) (signature vec2 (parameters (declare (in) float edge0) (declare (in) float edge1) (declare (in) vec2 x)) ((declare () vec2 t) - (declare () vec2 retval) - - (assign (constant bool (1)) (x) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz x (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) + (assign (xy) (var_ref t) + (expression vec2 max + (expression vec2 min + (expression vec2 / (expression vec2 - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) (constant float (1.0))) (constant float (0.0)))) - (assign (constant bool (1)) (x) (var_ref retval) (expression float * (swiz x (var_ref t)) (expression float * (swiz x (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz x (var_ref t))))))) - - (assign (constant bool (1)) (y) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz y (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) - (constant float (1.0))) - (constant float (0.0)))) - (assign (constant bool (1)) (y) (var_ref retval) (expression float * (swiz y (var_ref t)) (expression float * (swiz y (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz y (var_ref t))))))) - (return (var_ref retval)) - )) + (return (expression vec2 * (var_ref t) (expression vec2 * (var_ref t) (expression vec2 - (constant float (3.0)) (expression vec2 * (constant float (2.0)) (var_ref t)))))))) (signature vec3 (parameters @@ -46,33 +32,13 @@ (declare (in) float edge1) (declare (in) vec3 x)) ((declare () vec3 t) - (declare () vec3 retval) - - (assign (constant bool (1)) (x) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz x (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) - (constant float (1.0))) - (constant float (0.0)))) - (assign (constant bool (1)) (x) (var_ref retval) (expression float * (swiz x (var_ref t)) (expression float * (swiz x (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz x (var_ref t))))))) - - (assign (constant bool (1)) (y) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz y (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) - (constant float (1.0))) - (constant float (0.0)))) - (assign (constant bool (1)) (y) (var_ref retval) (expression float * (swiz y (var_ref t)) (expression float * (swiz y (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz y (var_ref t))))))) - - (assign (constant bool (1)) (z) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz z (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) + (assign (xyz) (var_ref t) + (expression vec3 max + (expression vec3 min + (expression vec3 / (expression vec3 - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) (constant float (1.0))) (constant float (0.0)))) - (assign (constant bool (1)) (z) (var_ref retval) (expression float * (swiz z (var_ref t)) (expression float * (swiz z (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz z (var_ref t))))))) - (return (var_ref retval)) - )) + (return (expression vec3 * (var_ref t) (expression vec3 * (var_ref t) (expression vec3 - (constant float (3.0)) (expression vec3 * (constant float (2.0)) (var_ref t)))))))) (signature vec4 @@ -81,73 +47,54 @@ (declare (in) float edge1) (declare (in) vec4 x)) ((declare () vec4 t) - (declare () vec4 retval) - - (assign (constant bool (1)) (x) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz x (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) - (constant float (1.0))) - (constant float (0.0)))) - (assign (constant bool (1)) (x) (var_ref retval) (expression float * (swiz x (var_ref t)) (expression float * (swiz x (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz x (var_ref t))))))) - - (assign (constant bool (1)) (y) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz y (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) - (constant float (1.0))) - (constant float (0.0)))) - (assign (constant bool (1)) (y) (var_ref retval) (expression float * (swiz y (var_ref t)) (expression float * (swiz y (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz y (var_ref t))))))) - - (assign (constant bool (1)) (z) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz z (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) + (assign (xyzw) (var_ref t) + (expression vec4 max + (expression vec4 min + (expression vec4 / (expression vec4 - (var_ref x) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) (constant float (1.0))) (constant float (0.0)))) - (assign (constant bool (1)) (z) (var_ref retval) (expression float * (swiz z (var_ref t)) (expression float * (swiz z (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz z (var_ref t))))))) - - (assign (constant bool (1)) (w) (var_ref t) - (expression float max - (expression float min - (expression float / (expression float - (swiz w (var_ref x)) (var_ref edge0)) (expression float - (var_ref edge1) (var_ref edge0))) - (constant float (1.0))) - (constant float (0.0)))) - (assign (constant bool (1)) (w) (var_ref retval) (expression float * (swiz w (var_ref t)) (expression float * (swiz w (var_ref t)) (expression float - (constant float (3.000000)) (expression float * (constant float (2.000000)) (swiz w (var_ref t))))))) - (return (var_ref retval)) - )) + (return (expression vec4 * (var_ref t) (expression vec4 * (var_ref t) (expression vec4 - (constant float (3.0)) (expression vec4 * (constant float (2.0)) (var_ref t)))))))) (signature vec2 (parameters (declare (in) vec2 edge0) (declare (in) vec2 edge1) (declare (in) vec2 x)) - ((return (expression vec2 max + ((declare () vec2 t) + (assign (xy) (var_ref t) + (expression vec2 max (expression vec2 min (expression vec2 / (expression vec2 - (var_ref x) (var_ref edge0)) (expression vec2 - (var_ref edge1) (var_ref edge0))) - (constant vec2 (1.0 1.0))) - (constant vec2 (0.0 0.0)))))) + (constant float (1.0))) + (constant float (0.0)))) + (return (expression vec2 * (var_ref t) (expression vec2 * (var_ref t) (expression vec2 - (constant float (3.0)) (expression vec2 * (constant float (2.0)) (var_ref t)))))))) (signature vec3 (parameters (declare (in) vec3 edge0) (declare (in) vec3 edge1) (declare (in) vec3 x)) - ((return (expression vec3 max + ((declare () vec3 t) + (assign (xyz) (var_ref t) + (expression vec3 max (expression vec3 min (expression vec3 / (expression vec3 - (var_ref x) (var_ref edge0)) (expression vec3 - (var_ref edge1) (var_ref edge0))) - (constant vec3 (1.0 1.0 1.0))) - (constant vec3 (0.0 0.0 0.0)))))) + (constant float (1.0))) + (constant float (0.0)))) + (return (expression vec3 * (var_ref t) (expression vec3 * (var_ref t) (expression vec3 - (constant float (3.0)) (expression vec3 * (constant float (2.0)) (var_ref t)))))))) (signature vec4 (parameters (declare (in) vec4 edge0) (declare (in) vec4 edge1) (declare (in) vec4 x)) - ((return (expression vec4 max + ((declare () vec4 t) + (assign (xyzw) (var_ref t) + (expression vec4 max (expression vec4 min (expression vec4 / (expression vec4 - (var_ref x) (var_ref edge0)) (expression vec4 - (var_ref edge1) (var_ref edge0))) - (constant vec4 (1.0 1.0 1.0 1.0))) - (constant vec4 (0.0 0.0 0.0 0.0)))))) + (constant float (1.0))) + (constant float (0.0)))) + (return (expression vec4 * (var_ref t) (expression vec4 * (var_ref t) (expression vec4 - (constant float (3.0)) (expression vec4 * (constant float (2.0)) (var_ref t)))))))) )) diff --git a/src/glsl/builtins/ir/step b/src/glsl/builtins/ir/step index 7aec9d7a6c..efcd7bc802 100644 --- a/src/glsl/builtins/ir/step +++ b/src/glsl/builtins/ir/step @@ -10,8 +10,8 @@ (declare (in) float edge) (declare (in) vec2 x)) ((declare () vec2 t) - (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge)))) - (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge)))) + (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge)))) + (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge)))) (return (var_ref t)))) (signature vec3 @@ -19,9 +19,9 @@ (declare (in) float edge) (declare (in) vec3 x)) ((declare () vec3 t) - (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge)))) - (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge)))) - (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge)))) + (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge)))) + (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge)))) + (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge)))) (return (var_ref t)))) (signature vec4 @@ -29,10 +29,10 @@ (declare (in) float edge) (declare (in) vec4 x)) ((declare () vec4 t) - (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge)))) - (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge)))) - (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge)))) - (assign (constant bool (1)) (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(var_ref edge)))) + (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(var_ref edge)))) + (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(var_ref edge)))) + (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(var_ref edge)))) + (assign (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(var_ref edge)))) (return (var_ref t)))) (signature vec2 @@ -40,8 +40,8 @@ (declare (in) vec2 edge) (declare (in) vec2 x)) ((declare () vec2 t) - (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge))))) - (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge))))) + (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge))))) + (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge))))) (return (var_ref t)))) (signature vec3 @@ -49,9 +49,9 @@ (declare (in) vec3 edge) (declare (in) vec3 x)) ((declare () vec3 t) - (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge))))) - (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge))))) - (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge))))) + (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge))))) + (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge))))) + (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge))))) (return (var_ref t)))) (signature vec4 @@ -59,10 +59,10 @@ (declare (in) vec4 edge) (declare (in) vec4 x)) ((declare () vec4 t) - (assign (constant bool (1)) (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge))))) - (assign (constant bool (1)) (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge))))) - (assign (constant bool (1)) (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge))))) - (assign (constant bool (1)) (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(swiz w (var_ref edge))))) + (assign (x) (var_ref t) (expression float b2f (expression bool >= (swiz x (var_ref x))(swiz x (var_ref edge))))) + (assign (y) (var_ref t) (expression float b2f (expression bool >= (swiz y (var_ref x))(swiz y (var_ref edge))))) + (assign (z) (var_ref t) (expression float b2f (expression bool >= (swiz z (var_ref x))(swiz z (var_ref edge))))) + (assign (w) (var_ref t) (expression float b2f (expression bool >= (swiz w (var_ref x))(swiz w (var_ref edge))))) (return (var_ref t)))) )) diff --git a/src/glsl/builtins/ir/transpose b/src/glsl/builtins/ir/transpose index 4bed4489bf..043327d235 100644 --- a/src/glsl/builtins/ir/transpose +++ b/src/glsl/builtins/ir/transpose @@ -3,135 +3,135 @@ (parameters (declare (in) mat2 m)) ((declare () mat2 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) (return (var_ref t)))) (signature mat3x2 (parameters (declare (in) mat2x3 m)) ((declare () mat3x2 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) (return (var_ref t)))) (signature mat4x2 (parameters (declare (in) mat2x4 m)) ((declare () mat4x2 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1))))) (return (var_ref t)))) (signature mat2x3 (parameters (declare (in) mat3x2 m)) ((declare () mat2x3 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) (return (var_ref t)))) (signature mat3 (parameters (declare (in) mat3 m)) ((declare () mat3 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) + (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) (return (var_ref t)))) (signature mat4x3 (parameters (declare (in) mat3x4 m)) ((declare () mat4x3 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1))))) + (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2))))) (return (var_ref t)))) (signature mat2x4 (parameters (declare (in) mat4x2 m)) ((declare () mat2x4 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) + (assign (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3))))) + (assign (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3))))) (return (var_ref t)))) (signature mat3x4 (parameters (declare (in) mat4x3 m)) ((declare () mat3x4 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) + (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) + (assign (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3))))) + (assign (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3))))) + (assign (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3))))) (return (var_ref t)))) (signature mat4 (parameters (declare (in) mat4 m)) ((declare () mat4 t) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3))))) - (assign (constant bool (1)) (w) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (3))))) + (assign (x) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (0))))) + (assign (x) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (0))))) + (assign (y) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (1))))) + (assign (y) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (1))))) + (assign (z) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (2))))) + (assign (z) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (2))))) + (assign (w) (array_ref (var_ref t) (constant int (0))) (swiz x (array_ref (var_ref m) (constant int (3))))) + (assign (w) (array_ref (var_ref t) (constant int (1))) (swiz y (array_ref (var_ref m) (constant int (3))))) + (assign (w) (array_ref (var_ref t) (constant int (2))) (swiz z (array_ref (var_ref m) (constant int (3))))) + (assign (w) (array_ref (var_ref t) (constant int (3))) (swiz w (array_ref (var_ref m) (constant int (3))))) (return (var_ref t)))) ) diff --git a/src/glsl/builtins/profiles/130.frag b/src/glsl/builtins/profiles/130.frag index 329116f2a2..0e3c7ac419 100644 --- a/src/glsl/builtins/profiles/130.frag +++ b/src/glsl/builtins/profiles/130.frag @@ -491,8 +491,8 @@ ivec2 textureSize( sampler1DArray sampler, int lod); ivec2 textureSize(isampler1DArray sampler, int lod); ivec2 textureSize(usampler1DArray sampler, int lod); ivec3 textureSize( sampler2DArray sampler, int lod); -ivec2 textureSize(isampler2DArray sampler, int lod); -ivec2 textureSize(usampler2DArray sampler, int lod); +ivec3 textureSize(isampler2DArray sampler, int lod); +ivec3 textureSize(usampler2DArray sampler, int lod); ivec2 textureSize(sampler1DArrayShadow sampler, int lod); ivec3 textureSize(sampler2DArrayShadow sampler, int lod); @@ -635,7 +635,6 @@ uvec4 textureLod(usampler2DArray sampler, vec3 P, float lod); float textureLod(sampler1DArrayShadow sampler, vec3 P, float lod); -#if 0 /* textureOffset - no bias */ vec4 textureOffset( sampler1D sampler, float P, int offset); ivec4 textureOffset(isampler1D sampler, float P, int offset); @@ -687,7 +686,6 @@ ivec4 textureOffset(isampler2DArray sampler, vec3 P, ivec2 offset, float bias); uvec4 textureOffset(usampler2DArray sampler, vec3 P, ivec2 offset, float bias); float textureOffset(sampler1DArrayShadow samp, vec3 P, int offset, float bias); -#endif /* texelFetch */ vec4 texelFetch( sampler1D sampler, int P, int lod); @@ -710,7 +708,6 @@ uvec4 texelFetch(usampler1DArray sampler, ivec2 P, int lod); ivec4 texelFetch(isampler2DArray sampler, ivec3 P, int lod); uvec4 texelFetch(usampler2DArray sampler, ivec3 P, int lod); -#if 0 /* texelFetchOffset */ vec4 texelFetchOffset( sampler1D sampler, int P, int lod, int offset); ivec4 texelFetchOffset(isampler1D sampler, int P, int lod, int offset); @@ -801,7 +798,6 @@ ivec4 textureLodOffset(isampler2DArray samp, vec3 P, float lod, ivec2 offset); uvec4 textureLodOffset(usampler2DArray samp, vec3 P, float lod, ivec2 offset); float textureLodOffset(sampler1DArrayShadow s, vec3 P, float lod, int offset); -#endif /* textureProjLod */ vec4 textureProjLod( sampler1D sampler, vec2 P, float lod); @@ -825,7 +821,6 @@ uvec4 textureProjLod(usampler3D sampler, vec4 P, float lod); float textureProjLod(sampler1DShadow sampler, vec4 P, float lod); float textureProjLod(sampler2DShadow sampler, vec4 P, float lod); -#if 0 /* textureProjLodOffset */ vec4 textureProjLodOffset( sampler1D sampler, vec2 P, float lod, int offset); ivec4 textureProjLodOffset(isampler1D sampler, vec2 P, float lod, int offset); @@ -847,7 +842,6 @@ uvec4 textureProjLodOffset(usampler3D sampler, vec4 P, float lod, ivec3 offset); float textureProjLodOffset(sampler1DShadow s, vec4 P, float lod, int offset); float textureProjLodOffset(sampler2DShadow s, vec4 P, float lod, ivec2 offset); -#endif /* textureGrad */ vec4 textureGrad( sampler1D sampler, float P, float dPdx, float dPdy); @@ -881,7 +875,6 @@ uvec4 textureGrad(usampler2DArray sampler, vec3 P, vec2 dPdx, vec2 dPdy); float textureGrad(sampler1DArrayShadow sampler, vec3 P, float dPdx, float dPdy); float textureGrad(sampler2DArrayShadow sampler, vec4 P, vec2 dPdx, vec2 dPdy); -#if 0 /* textureGradOffset */ vec4 textureGradOffset( sampler1D s, float P, float dx, float dy, int off); ivec4 textureGradOffset(isampler1D s, float P, float dx, float dy, int offset); @@ -912,7 +905,6 @@ uvec4 textureGradOffset(usampler2DArray s, vec3 P, vec2 dx, vec2 dy, ivec2 off); float textureGradOffset(sampler1DArrayShadow s, vec3 P, float dx, float dy, int o); float textureGradOffset(sampler2DArrayShadow s, vec4 P, vec2 dx, vec2 dy, ivec2 o); -#endif /* textureProjGrad */ vec4 textureProjGrad( sampler1D sampler, vec2 P, float dPdx, float dPdy); @@ -936,7 +928,6 @@ uvec4 textureProjGrad(usampler3D sampler, vec4 P, vec3 dPdx, vec3 dPdy); float textureProjGrad(sampler1DShadow sampler, vec4 P, float dPdx, float dPdy); float textureProjGrad(sampler2DShadow sampler, vec4 P, vec2 dPdx, vec2 dPdy); -#if 0 /* textureProjGradOffset */ vec4 textureProjGradOffset( sampler1D s, vec2 P, float dx, float dy, int off); ivec4 textureProjGradOffset(isampler1D s, vec2 P, float dx, float dy, int off); @@ -958,7 +949,6 @@ uvec4 textureProjGradOffset(usampler3D s, vec4 P, vec3 dx, vec3 dy, ivec3 off); float textureProjGradOffset(sampler1DShadow s, vec4 P, float dx, float dy, int o); float textureProjGradOffset(sampler2DShadow s, vec4 P, vec2 dx, vec2 dy, vec2 o); -#endif /* * The following texture functions are deprecated: diff --git a/src/glsl/builtins/profiles/130.vert b/src/glsl/builtins/profiles/130.vert index 1c212ebb3c..f85b27f8f8 100644 --- a/src/glsl/builtins/profiles/130.vert +++ b/src/glsl/builtins/profiles/130.vert @@ -493,8 +493,8 @@ ivec2 textureSize( sampler1DArray sampler, int lod); ivec2 textureSize(isampler1DArray sampler, int lod); ivec2 textureSize(usampler1DArray sampler, int lod); ivec3 textureSize( sampler2DArray sampler, int lod); -ivec2 textureSize(isampler2DArray sampler, int lod); -ivec2 textureSize(usampler2DArray sampler, int lod); +ivec3 textureSize(isampler2DArray sampler, int lod); +ivec3 textureSize(usampler2DArray sampler, int lod); ivec2 textureSize(sampler1DArrayShadow sampler, int lod); ivec3 textureSize(sampler2DArrayShadow sampler, int lod); @@ -637,7 +637,6 @@ uvec4 textureLod(usampler2DArray sampler, vec3 P, float lod); float textureLod(sampler1DArrayShadow sampler, vec3 P, float lod); -#if 0 /* textureOffset - no bias */ vec4 textureOffset( sampler1D sampler, float P, int offset); ivec4 textureOffset(isampler1D sampler, float P, int offset); @@ -689,7 +688,6 @@ ivec4 textureOffset(isampler2DArray sampler, vec3 P, ivec2 offset, float bias); uvec4 textureOffset(usampler2DArray sampler, vec3 P, ivec2 offset, float bias); float textureOffset(sampler1DArrayShadow samp, vec3 P, int offset, float bias); -#endif /* texelFetch */ vec4 texelFetch( sampler1D sampler, int P, int lod); @@ -712,7 +710,6 @@ uvec4 texelFetch(usampler1DArray sampler, ivec2 P, int lod); ivec4 texelFetch(isampler2DArray sampler, ivec3 P, int lod); uvec4 texelFetch(usampler2DArray sampler, ivec3 P, int lod); -#if 0 /* texelFetchOffset */ vec4 texelFetchOffset( sampler1D sampler, int P, int lod, int offset); ivec4 texelFetchOffset(isampler1D sampler, int P, int lod, int offset); @@ -803,7 +800,6 @@ ivec4 textureLodOffset(isampler2DArray samp, vec3 P, float lod, ivec2 offset); uvec4 textureLodOffset(usampler2DArray samp, vec3 P, float lod, ivec2 offset); float textureLodOffset(sampler1DArrayShadow s, vec3 P, float lod, int offset); -#endif /* textureProjLod */ vec4 textureProjLod( sampler1D sampler, vec2 P, float lod); @@ -827,7 +823,6 @@ uvec4 textureProjLod(usampler3D sampler, vec4 P, float lod); float textureProjLod(sampler1DShadow sampler, vec4 P, float lod); float textureProjLod(sampler2DShadow sampler, vec4 P, float lod); -#if 0 /* textureProjLodOffset */ vec4 textureProjLodOffset( sampler1D sampler, vec2 P, float lod, int offset); ivec4 textureProjLodOffset(isampler1D sampler, vec2 P, float lod, int offset); @@ -849,7 +844,6 @@ uvec4 textureProjLodOffset(usampler3D sampler, vec4 P, float lod, ivec3 offset); float textureProjLodOffset(sampler1DShadow s, vec4 P, float lod, int offset); float textureProjLodOffset(sampler2DShadow s, vec4 P, float lod, ivec2 offset); -#endif /* textureGrad */ vec4 textureGrad( sampler1D sampler, float P, float dPdx, float dPdy); @@ -883,7 +877,6 @@ uvec4 textureGrad(usampler2DArray sampler, vec3 P, vec2 dPdx, vec2 dPdy); float textureGrad(sampler1DArrayShadow sampler, vec3 P, float dPdx, float dPdy); float textureGrad(sampler2DArrayShadow sampler, vec4 P, vec2 dPdx, vec2 dPdy); -#if 0 /* textureGradOffset */ vec4 textureGradOffset( sampler1D s, float P, float dx, float dy, int off); ivec4 textureGradOffset(isampler1D s, float P, float dx, float dy, int offset); @@ -914,7 +907,6 @@ uvec4 textureGradOffset(usampler2DArray s, vec3 P, vec2 dx, vec2 dy, ivec2 off); float textureGradOffset(sampler1DArrayShadow s, vec3 P, float dx, float dy, int o); float textureGradOffset(sampler2DArrayShadow s, vec4 P, vec2 dx, vec2 dy, ivec2 o); -#endif /* textureProjGrad */ vec4 textureProjGrad( sampler1D sampler, vec2 P, float dPdx, float dPdy); @@ -938,7 +930,6 @@ uvec4 textureProjGrad(usampler3D sampler, vec4 P, vec3 dPdx, vec3 dPdy); float textureProjGrad(sampler1DShadow sampler, vec4 P, float dPdx, float dPdy); float textureProjGrad(sampler2DShadow sampler, vec4 P, vec2 dPdx, vec2 dPdy); -#if 0 /* textureProjGradOffset */ vec4 textureProjGradOffset( sampler1D s, vec2 P, float dx, float dy, int off); ivec4 textureProjGradOffset(isampler1D s, vec2 P, float dx, float dy, int off); @@ -960,7 +951,6 @@ uvec4 textureProjGradOffset(usampler3D s, vec4 P, vec3 dx, vec3 dy, ivec3 off); float textureProjGradOffset(sampler1DShadow s, vec4 P, float dx, float dy, int o); float textureProjGradOffset(sampler2DShadow s, vec4 P, vec2 dx, vec2 dy, vec2 o); -#endif /* * The following texture functions are deprecated: diff --git a/src/glsl/builtins/profiles/OES_texture_3D.frag b/src/glsl/builtins/profiles/OES_texture_3D.frag new file mode 100644 index 0000000000..b6ebd6a311 --- /dev/null +++ b/src/glsl/builtins/profiles/OES_texture_3D.frag @@ -0,0 +1,7 @@ +#version 100 +#extension GL_OES_texture_3D : enable + +vec4 texture3D (sampler3D sampler, vec3 coord); +vec4 texture3DProj (sampler3D sampler, vec4 coord); +vec4 texture3D (sampler3D sampler, vec3 coord, float bias); +vec4 texture3DProj (sampler3D sampler, vec4 coord, float bias); diff --git a/src/glsl/builtins/profiles/OES_texture_3D.vert b/src/glsl/builtins/profiles/OES_texture_3D.vert new file mode 100644 index 0000000000..81d12f51e9 --- /dev/null +++ b/src/glsl/builtins/profiles/OES_texture_3D.vert @@ -0,0 +1,7 @@ +#version 100 +#extension GL_OES_texture_3D : enable + +vec4 texture3D (sampler3D sampler, vec3 coord); +vec4 texture3DProj (sampler3D sampler, vec4 coord); +vec4 texture3DLod (sampler3D sampler, vec3 coord, float lod); +vec4 texture3DProjLod (sampler3D sampler, vec4 coord, float lod); diff --git a/src/glsl/builtins/tools/generate_builtins.py b/src/glsl/builtins/tools/generate_builtins.py index 5ea4b5c48f..edd3c70e00 100755 --- a/src/glsl/builtins/tools/generate_builtins.py +++ b/src/glsl/builtins/tools/generate_builtins.py @@ -1,16 +1,27 @@ #!/usr/bin/python # -*- coding: utf-8 -*- +from __future__ import with_statement + import re +import sys from glob import glob from os import path from subprocess import Popen, PIPE +from sys import argv # Local module: generator for texture lookup builtins from texture_builtins import generate_texture_functions builtins_dir = path.join(path.dirname(path.abspath(__file__)), "..") +# Get the path to the standalone GLSL compiler +if len(argv) != 2: + print "Usage:", argv[0], "<path to compiler>" + sys.exit(1) + +compiler = argv[1] + # Read the files in builtins/ir/*...add them to the supplied dictionary. def read_ir_files(fs): for filename in glob(path.join(path.join(builtins_dir, 'ir'), '*')): @@ -47,14 +58,13 @@ def write_function_definitions(): print stringify(v), ';' def run_compiler(args): - compiler_path = path.join(path.join(builtins_dir, '..'), 'glsl_compiler') - command = [compiler_path, '--dump-lir'] + args + command = [compiler, '--dump-lir'] + args p = Popen(command, 1, stdout=PIPE, shell=False) output = p.communicate()[0] # Clean up output a bit by killing whitespace before a closing paren. - kill_paren_whitespace = re.compile(r'[ \n]*\)', re.MULTILINE); - output = kill_paren_whitespace.sub(')', output); + kill_paren_whitespace = re.compile(r'[ \n]*\)', re.MULTILINE) + output = kill_paren_whitespace.sub(')', output) # Also toss any duplicate newlines output = output.replace('\n\n', '\n') @@ -69,12 +79,12 @@ def write_profile(filename, profile): return # Kill any global variable declarations. We don't want them. - kill_globals = re.compile(r'^\(declare.*\n', re.MULTILINE); + kill_globals = re.compile(r'^\(declare.*\n', re.MULTILINE) proto_ir = kill_globals.sub('', proto_ir) # Kill pointer addresses. They're not necessary in prototypes and just # clutter the diff output. - proto_ir = re.sub(r'@0x[0-9a-f]+', '', proto_ir); + proto_ir = re.sub(r'@0x[0-9a-f]+', '', proto_ir) print 'static const char prototypes_for_' + profile + '[] =' print stringify(proto_ir), ';' @@ -142,6 +152,8 @@ read_builtins(GLenum target, const char *protos, const char **functions, unsigne { struct gl_context fakeCtx; fakeCtx.API = API_OPENGL; + fakeCtx.Const.GLSLVersion = 130; + fakeCtx.Extensions.ARB_ES2_compatibility = true; gl_shader *sh = _mesa_new_shader(NULL, 0, target); struct _mesa_glsl_parse_state *st = new(sh) _mesa_glsl_parse_state(&fakeCtx, target, sh); @@ -168,7 +180,7 @@ read_builtins(GLenum target, const char *protos, const char **functions, unsigne if (st->error) { printf("error reading builtin: %.35s ...\\n", functions[i]); printf("Info log:\\n%s\\n", st->info_log); - talloc_free(sh); + ralloc_free(sh); return NULL; } } @@ -193,14 +205,13 @@ void *builtin_mem_ctx = NULL; void _mesa_glsl_release_functions(void) { - talloc_free(builtin_mem_ctx); + ralloc_free(builtin_mem_ctx); builtin_mem_ctx = NULL; memset(builtin_profiles, 0, sizeof(builtin_profiles)); } static void _mesa_read_profile(struct _mesa_glsl_parse_state *state, - exec_list *instructions, int profile_index, const char *prototypes, const char **functions, @@ -210,7 +221,7 @@ _mesa_read_profile(struct _mesa_glsl_parse_state *state, if (sh == NULL) { sh = read_builtins(GL_VERTEX_SHADER, prototypes, functions, count); - talloc_steal(builtin_mem_ctx, sh); + ralloc_steal(builtin_mem_ctx, sh); builtin_profiles[profile_index] = sh; } @@ -219,18 +230,17 @@ _mesa_read_profile(struct _mesa_glsl_parse_state *state, } void -_mesa_glsl_initialize_functions(exec_list *instructions, - struct _mesa_glsl_parse_state *state) +_mesa_glsl_initialize_functions(struct _mesa_glsl_parse_state *state) { if (builtin_mem_ctx == NULL) { - builtin_mem_ctx = talloc_init("GLSL built-in functions"); + builtin_mem_ctx = ralloc_context(NULL); // "GLSL built-in functions" memset(&builtin_profiles, 0, sizeof(builtin_profiles)); } state->num_builtins_to_link = 0; """ - i=0 + i = 0 for (filename, profile) in profiles: if profile.endswith('_vert'): check = 'state->target == vertex_shader && ' @@ -244,7 +254,7 @@ _mesa_glsl_initialize_functions(exec_list *instructions, check += 'state->' + version + '_enable' print ' if (' + check + ') {' - print ' _mesa_read_profile(state, instructions, %d,' % i + print ' _mesa_read_profile(state, %d,' % i print ' prototypes_for_' + profile + ',' print ' functions_for_' + profile + ',' print ' Elements(functions_for_' + profile + '));' diff --git a/src/glsl/builtins/tools/texture_builtins.py b/src/glsl/builtins/tools/texture_builtins.py index 8bf708b5aa..2fbe79010f 100755 --- a/src/glsl/builtins/tools/texture_builtins.py +++ b/src/glsl/builtins/tools/texture_builtins.py @@ -3,6 +3,11 @@ import sys import StringIO +# Bitfield constants for the 'variant' argument to generate_sigs +Proj = 1 +Offset = 2 +Single = 4 + def vec_type(g, size): if size == 1: if g == "i": @@ -12,16 +17,20 @@ def vec_type(g, size): return "float" return g + "vec" + str(size) -# Get the base dimension - i.e. sampler3D gives 3 -# Array samplers also get +1 here since the layer is really an extra coordinate -def get_coord_dim(sampler_type): +# Get the sampler dimension - i.e. sampler3D gives 3 +def get_sampler_dim(sampler_type): if sampler_type[0].isdigit(): - coord_dim = int(sampler_type[0]) + sampler_dim = int(sampler_type[0]) elif sampler_type.startswith("Cube"): - coord_dim = 3 + sampler_dim = 3 else: assert False ("coord_dim: invalid sampler_type: " + sampler_type) + return sampler_dim +# Get the coordinate dimension for a given sampler type. +# Array samplers also get +1 here since the layer is really an extra coordinate +def get_coord_dim(sampler_type): + coord_dim = get_sampler_dim(sampler_type) if sampler_type.find("Array") != -1: coord_dim += 1 return coord_dim @@ -35,18 +44,22 @@ def get_extra_dim(sampler_type, use_proj, unused_fields): extra_dim += 1 return extra_dim -def generate_sigs(g, tex_inst, sampler_type, use_proj = False, unused_fields = 0): +def generate_sigs(g, tex_inst, sampler_type, variant = 0, unused_fields = 0): coord_dim = get_coord_dim(sampler_type) - extra_dim = get_extra_dim(sampler_type, use_proj, unused_fields) + extra_dim = get_extra_dim(sampler_type, variant & Proj, unused_fields) + offset_dim = get_sampler_dim(sampler_type) + + if variant & Single: + return_type = "float" + else: + return_type = g + "vec4" # Print parameters - print " (signature " + g + "vec4" + print " (signature", return_type print " (parameters" print " (declare (in) " + g + "sampler" + sampler_type + " sampler)" print " (declare (in) " + vec_type("i" if tex_inst == "txf" else "", coord_dim + extra_dim) + " P)", - if tex_inst == "txb": - print "\n (declare (in) float bias)", - elif tex_inst == "txl": + if tex_inst == "txl": print "\n (declare (in) float lod)", elif tex_inst == "txf": print "\n (declare (in) int lod)", @@ -55,7 +68,12 @@ def generate_sigs(g, tex_inst, sampler_type, use_proj = False, unused_fields = 0 print "\n (declare (in) " + grad_type + " dPdx)", print "\n (declare (in) " + grad_type + " dPdy)", - print ")\n ((return (" + tex_inst + " (var_ref sampler)", + if variant & Offset: + print "\n (declare (const_in) " + vec_type("i", offset_dim) + " offset)", + if tex_inst == "txb": + print "\n (declare (in) float bias)", + + print ")\n ((return (" + tex_inst, return_type, "(var_ref sampler)", # Coordinate if extra_dim > 0: @@ -63,12 +81,14 @@ def generate_sigs(g, tex_inst, sampler_type, use_proj = False, unused_fields = 0 else: print "(var_ref P)", - # Offset - print "(0 0 0)", + if variant & Offset: + print "(var_ref offset)", + else: + print "0", if tex_inst != "txf": # Projective divisor - if use_proj: + if variant & Proj: print "(swiz " + "xyzw"[coord_dim + extra_dim-1] + " (var_ref P))", else: print "1", @@ -90,10 +110,10 @@ def generate_sigs(g, tex_inst, sampler_type, use_proj = False, unused_fields = 0 print "((var_ref dPdx) (var_ref dPdy))", print "))))\n" -def generate_fiu_sigs(tex_inst, sampler_type, use_proj = False, unused_fields = 0): - generate_sigs("", tex_inst, sampler_type, use_proj, unused_fields) - generate_sigs("i", tex_inst, sampler_type, use_proj, unused_fields) - generate_sigs("u", tex_inst, sampler_type, use_proj, unused_fields) +def generate_fiu_sigs(tex_inst, sampler_type, variant = 0, unused_fields = 0): + generate_sigs("", tex_inst, sampler_type, variant, unused_fields) + generate_sigs("i", tex_inst, sampler_type, variant, unused_fields) + generate_sigs("u", tex_inst, sampler_type, variant, unused_fields) def start_function(name): sys.stdout = StringIO.StringIO() @@ -117,6 +137,11 @@ def generate_texture_functions(fs): generate_fiu_sigs("tex", "Cube") generate_fiu_sigs("tex", "1DArray") generate_fiu_sigs("tex", "2DArray") + generate_sigs("", "tex", "1DShadow", Single, 1); + generate_sigs("", "tex", "2DShadow", Single); + generate_sigs("", "tex", "CubeShadow", Single); + generate_sigs("", "tex", "1DArrayShadow", Single); + generate_sigs("", "tex", "2DArrayShadow", Single); generate_fiu_sigs("txb", "1D") generate_fiu_sigs("txb", "2D") @@ -124,20 +149,29 @@ def generate_texture_functions(fs): generate_fiu_sigs("txb", "Cube") generate_fiu_sigs("txb", "1DArray") generate_fiu_sigs("txb", "2DArray") + generate_sigs("", "txb", "1DShadow", Single, 1); + generate_sigs("", "txb", "2DShadow", Single); + generate_sigs("", "txb", "CubeShadow", Single); + generate_sigs("", "txb", "1DArrayShadow", Single); + generate_sigs("", "txb", "2DArrayShadow", Single); end_function(fs, "texture") start_function("textureProj") - generate_fiu_sigs("tex", "1D", True) - generate_fiu_sigs("tex", "1D", True, 2) - generate_fiu_sigs("tex", "2D", True) - generate_fiu_sigs("tex", "2D", True, 1) - generate_fiu_sigs("tex", "3D", True) - - generate_fiu_sigs("txb", "1D", True) - generate_fiu_sigs("txb", "1D", True, 2) - generate_fiu_sigs("txb", "2D", True) - generate_fiu_sigs("txb", "2D", True, 1) - generate_fiu_sigs("txb", "3D", True) + generate_fiu_sigs("tex", "1D", Proj) + generate_fiu_sigs("tex", "1D", Proj, 2) + generate_fiu_sigs("tex", "2D", Proj) + generate_fiu_sigs("tex", "2D", Proj, 1) + generate_fiu_sigs("tex", "3D", Proj) + generate_sigs("", "tex", "1DShadow", Proj | Single, 1); + generate_sigs("", "tex", "2DShadow", Proj | Single); + + generate_fiu_sigs("txb", "1D", Proj) + generate_fiu_sigs("txb", "1D", Proj, 2) + generate_fiu_sigs("txb", "2D", Proj) + generate_fiu_sigs("txb", "2D", Proj, 1) + generate_fiu_sigs("txb", "3D", Proj) + generate_sigs("", "txb", "1DShadow", Proj | Single, 1); + generate_sigs("", "txb", "2DShadow", Proj | Single); end_function(fs, "textureProj") start_function("textureLod") @@ -147,8 +181,42 @@ def generate_texture_functions(fs): generate_fiu_sigs("txl", "Cube") generate_fiu_sigs("txl", "1DArray") generate_fiu_sigs("txl", "2DArray") + generate_sigs("", "txl", "1DShadow", Single, 1); + generate_sigs("", "txl", "2DShadow", Single); + generate_sigs("", "txl", "1DArrayShadow", Single); end_function(fs, "textureLod") + start_function("textureLodOffset") + generate_fiu_sigs("txl", "1D", Offset) + generate_fiu_sigs("txl", "2D", Offset) + generate_fiu_sigs("txl", "3D", Offset) + generate_fiu_sigs("txl", "1DArray", Offset) + generate_fiu_sigs("txl", "2DArray", Offset) + generate_sigs("", "txl", "1DShadow", Offset | Single, 1); + generate_sigs("", "txl", "2DShadow", Offset | Single); + generate_sigs("", "txl", "1DArrayShadow", Offset | Single); + end_function(fs, "textureLodOffset") + + start_function("textureOffset") + generate_fiu_sigs("tex", "1D", Offset) + generate_fiu_sigs("tex", "2D", Offset) + generate_fiu_sigs("tex", "3D", Offset) + generate_fiu_sigs("tex", "1DArray", Offset) + generate_fiu_sigs("tex", "2DArray", Offset) + generate_sigs("", "tex", "1DShadow", Offset | Single, 1); + generate_sigs("", "tex", "2DShadow", Offset | Single); + generate_sigs("", "tex", "1DArrayShadow", Offset | Single); + + generate_fiu_sigs("txb", "1D", Offset) + generate_fiu_sigs("txb", "2D", Offset) + generate_fiu_sigs("txb", "3D", Offset) + generate_fiu_sigs("txb", "1DArray", Offset) + generate_fiu_sigs("txb", "2DArray", Offset) + generate_sigs("", "txb", "1DShadow", Offset | Single, 1); + generate_sigs("", "txb", "2DShadow", Offset | Single); + generate_sigs("", "txb", "1DArrayShadow", Offset | Single); + end_function(fs, "textureOffset") + start_function("texelFetch") generate_fiu_sigs("txf", "1D") generate_fiu_sigs("txf", "2D") @@ -157,14 +225,52 @@ def generate_texture_functions(fs): generate_fiu_sigs("txf", "2DArray") end_function(fs, "texelFetch") + start_function("texelFetchOffset") + generate_fiu_sigs("txf", "1D", Offset) + generate_fiu_sigs("txf", "2D", Offset) + generate_fiu_sigs("txf", "3D", Offset) + generate_fiu_sigs("txf", "1DArray", Offset) + generate_fiu_sigs("txf", "2DArray", Offset) + end_function(fs, "texelFetchOffset") + + start_function("textureProjOffset") + generate_fiu_sigs("tex", "1D", Proj | Offset) + generate_fiu_sigs("tex", "1D", Proj | Offset, 2) + generate_fiu_sigs("tex", "2D", Proj | Offset) + generate_fiu_sigs("tex", "2D", Proj | Offset, 1) + generate_fiu_sigs("tex", "3D", Proj | Offset) + generate_sigs("", "tex", "1DShadow", Proj | Offset | Single, 1); + generate_sigs("", "tex", "2DShadow", Proj | Offset | Single); + + generate_fiu_sigs("txb", "1D", Proj | Offset) + generate_fiu_sigs("txb", "1D", Proj | Offset, 2) + generate_fiu_sigs("txb", "2D", Proj | Offset) + generate_fiu_sigs("txb", "2D", Proj | Offset, 1) + generate_fiu_sigs("txb", "3D", Proj | Offset) + generate_sigs("", "txb", "1DShadow", Proj | Offset | Single, 1); + generate_sigs("", "txb", "2DShadow", Proj | Offset | Single); + end_function(fs, "textureProjOffset") + start_function("textureProjLod") - generate_fiu_sigs("txl", "1D", True) - generate_fiu_sigs("txl", "1D", True, 2) - generate_fiu_sigs("txl", "2D", True) - generate_fiu_sigs("txl", "2D", True, 1) - generate_fiu_sigs("txl", "3D", True) + generate_fiu_sigs("txl", "1D", Proj) + generate_fiu_sigs("txl", "1D", Proj, 2) + generate_fiu_sigs("txl", "2D", Proj) + generate_fiu_sigs("txl", "2D", Proj, 1) + generate_fiu_sigs("txl", "3D", Proj) + generate_sigs("", "txl", "1DShadow", Proj | Single, 1); + generate_sigs("", "txl", "2DShadow", Proj | Single); end_function(fs, "textureProjLod") + start_function("textureProjLodOffset") + generate_fiu_sigs("txl", "1D", Proj | Offset) + generate_fiu_sigs("txl", "1D", Proj | Offset, 2) + generate_fiu_sigs("txl", "2D", Proj | Offset) + generate_fiu_sigs("txl", "2D", Proj | Offset, 1) + generate_fiu_sigs("txl", "3D", Proj | Offset) + generate_sigs("", "txl", "1DShadow", Proj | Offset | Single, 1); + generate_sigs("", "txl", "2DShadow", Proj | Offset | Single); + end_function(fs, "textureProjLodOffset") + start_function("textureGrad") generate_fiu_sigs("txd", "1D") generate_fiu_sigs("txd", "2D") @@ -172,24 +278,55 @@ def generate_texture_functions(fs): generate_fiu_sigs("txd", "Cube") generate_fiu_sigs("txd", "1DArray") generate_fiu_sigs("txd", "2DArray") + generate_sigs("", "txd", "1DShadow", Single, 1); + generate_sigs("", "txd", "2DShadow", Single); + generate_sigs("", "txd", "CubeShadow", Single); + generate_sigs("", "txd", "1DArrayShadow", Single); + generate_sigs("", "txd", "2DArrayShadow", Single); end_function(fs, "textureGrad") + start_function("textureGradOffset") + generate_fiu_sigs("txd", "1D", Offset) + generate_fiu_sigs("txd", "2D", Offset) + generate_fiu_sigs("txd", "3D", Offset) + generate_fiu_sigs("txd", "Cube", Offset) + generate_fiu_sigs("txd", "1DArray", Offset) + generate_fiu_sigs("txd", "2DArray", Offset) + generate_sigs("", "txd", "1DShadow", Offset | Single, 1); + generate_sigs("", "txd", "2DShadow", Offset | Single); + generate_sigs("", "txd", "1DArrayShadow", Offset | Single); + generate_sigs("", "txd", "2DArrayShadow", Offset | Single); + end_function(fs, "textureGradOffset") + start_function("textureProjGrad") - generate_fiu_sigs("txd", "1D", True) - generate_fiu_sigs("txd", "1D", True, 2) - generate_fiu_sigs("txd", "2D", True) - generate_fiu_sigs("txd", "2D", True, 1) - generate_fiu_sigs("txd", "3D", True) + generate_fiu_sigs("txd", "1D", Proj) + generate_fiu_sigs("txd", "1D", Proj, 2) + generate_fiu_sigs("txd", "2D", Proj) + generate_fiu_sigs("txd", "2D", Proj, 1) + generate_fiu_sigs("txd", "3D", Proj) + generate_sigs("", "txd", "1DShadow", Proj | Single, 1); + generate_sigs("", "txd", "2DShadow", Proj | Single); end_function(fs, "textureProjGrad") + start_function("textureProjGradOffset") + generate_fiu_sigs("txd", "1D", Proj | Offset) + generate_fiu_sigs("txd", "1D", Proj | Offset, 2) + generate_fiu_sigs("txd", "2D", Proj | Offset) + generate_fiu_sigs("txd", "2D", Proj | Offset, 1) + generate_fiu_sigs("txd", "3D", Proj | Offset) + generate_sigs("", "txd", "1DShadow", Proj | Offset | Single, 1); + generate_sigs("", "txd", "2DShadow", Proj | Offset | Single); + end_function(fs, "textureProjGradOffset") + + # ARB_texture_rectangle extension start_function("texture2DRect") generate_sigs("", "tex", "2DRect") end_function(fs, "texture2DRect") start_function("texture2DRectProj") - generate_sigs("", "tex", "2DRect", True) - generate_sigs("", "tex", "2DRect", True, 1) + generate_sigs("", "tex", "2DRect", Proj) + generate_sigs("", "tex", "2DRect", Proj, 1) end_function(fs, "texture2DRectProj") start_function("shadow2DRect") @@ -197,7 +334,7 @@ def generate_texture_functions(fs): end_function(fs, "shadow2DRect") start_function("shadow2DRectProj") - generate_sigs("", "tex", "2DRectShadow", True) + generate_sigs("", "tex", "2DRectShadow", Proj) end_function(fs, "shadow2DRectProj") # EXT_texture_array extension @@ -243,15 +380,15 @@ def generate_texture_functions(fs): end_function(fs, "texture1DLod") start_function("texture1DProj") - generate_sigs("", "tex", "1D", True) - generate_sigs("", "tex", "1D", True, 2) - generate_sigs("", "txb", "1D", True) - generate_sigs("", "txb", "1D", True, 2) + generate_sigs("", "tex", "1D", Proj) + generate_sigs("", "tex", "1D", Proj, 2) + generate_sigs("", "txb", "1D", Proj) + generate_sigs("", "txb", "1D", Proj, 2) end_function(fs, "texture1DProj") start_function("texture1DProjLod") - generate_sigs("", "txl", "1D", True) - generate_sigs("", "txl", "1D", True, 2) + generate_sigs("", "txl", "1D", Proj) + generate_sigs("", "txl", "1D", Proj, 2) end_function(fs, "texture1DProjLod") start_function("texture2D") @@ -264,15 +401,15 @@ def generate_texture_functions(fs): end_function(fs, "texture2DLod") start_function("texture2DProj") - generate_sigs("", "tex", "2D", True) - generate_sigs("", "tex", "2D", True, 1) - generate_sigs("", "txb", "2D", True) - generate_sigs("", "txb", "2D", True, 1) + generate_sigs("", "tex", "2D", Proj) + generate_sigs("", "tex", "2D", Proj, 1) + generate_sigs("", "txb", "2D", Proj) + generate_sigs("", "txb", "2D", Proj, 1) end_function(fs, "texture2DProj") start_function("texture2DProjLod") - generate_sigs("", "txl", "2D", True) - generate_sigs("", "txl", "2D", True, 1) + generate_sigs("", "txl", "2D", Proj) + generate_sigs("", "txl", "2D", Proj, 1) end_function(fs, "texture2DProjLod") start_function("texture3D") @@ -285,12 +422,12 @@ def generate_texture_functions(fs): end_function(fs, "texture3DLod") start_function("texture3DProj") - generate_sigs("", "tex", "3D", True) - generate_sigs("", "txb", "3D", True) + generate_sigs("", "tex", "3D", Proj) + generate_sigs("", "txb", "3D", Proj) end_function(fs, "texture3DProj") start_function("texture3DProjLod") - generate_sigs("", "txl", "3D", True) + generate_sigs("", "txl", "3D", Proj) end_function(fs, "texture3DProjLod") start_function("textureCube") @@ -312,12 +449,12 @@ def generate_texture_functions(fs): end_function(fs, "shadow1DLod") start_function("shadow1DProj") - generate_sigs("", "tex", "1DShadow", True, 1) - generate_sigs("", "txb", "1DShadow", True, 1) + generate_sigs("", "tex", "1DShadow", Proj, 1) + generate_sigs("", "txb", "1DShadow", Proj, 1) end_function(fs, "shadow1DProj") start_function("shadow1DProjLod") - generate_sigs("", "txl", "1DShadow", True, 1) + generate_sigs("", "txl", "1DShadow", Proj, 1) end_function(fs, "shadow1DProjLod") start_function("shadow2D") @@ -330,12 +467,12 @@ def generate_texture_functions(fs): end_function(fs, "shadow2DLod") start_function("shadow2DProj") - generate_sigs("", "tex", "2DShadow", True) - generate_sigs("", "txb", "2DShadow", True) + generate_sigs("", "tex", "2DShadow", Proj) + generate_sigs("", "txb", "2DShadow", Proj) end_function(fs, "shadow2DProj") start_function("shadow2DProjLod") - generate_sigs("", "txl", "2DShadow", True) + generate_sigs("", "txl", "2DShadow", Proj) end_function(fs, "shadow2DProjLod") sys.stdout = sys.__stdout__ @@ -346,4 +483,4 @@ if __name__ == "__main__": fs = {} generate_texture_functions(fs); for k, v in fs.iteritems(): - print v + print v diff --git a/src/glsl/configure.ac b/src/glsl/configure.ac deleted file mode 100644 index 73ce67de3d..0000000000 --- a/src/glsl/configure.ac +++ /dev/null @@ -1,69 +0,0 @@ -# -*- Autoconf -*- -# Process this file with autoconf to produce a configure script. - -AC_PREREQ(2.61) -AC_INIT(glsl, XXXXX, idr@freedesktop.org, glsl) -AC_CONFIG_SRCDIR([Makefile.am]) -AM_CONFIG_HEADER([config.h]) -AC_CONFIG_FILES([glcpp/Makefile]) - -AM_INIT_AUTOMAKE -LT_INIT - -AM_MAINTAINER_MODE - -# Checks for programs. -AC_PROG_CXX -AC_PROG_CC -AC_PROG_MAKE_SET -AC_PROG_YACC -AC_PROG_LEX - -m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) - -# Checks for libraries. - -# Checks for header files. - -# Checks for typedefs, structures, and compiler characteristics. - -# Checks for library functions. -AC_HEADER_STDC - -AH_TOP([#ifndef GLSL_CONFIG_H -#define GLSL_CONFIG_H]) -AH_BOTTOM([#endif /* GLSL_CONFIG_H */]) - -PKG_CHECK_MODULES([talloc], [talloc >= 2.0]) - -AC_ARG_ENABLE([debug], - [AS_HELP_STRING([--enable-debug], - [use debug compiler flags and macros @<:@default=disabled@:>@])], - [enable_debug="$enableval"], - [enable_debug=no] -) -if test "x$enable_debug" = xyes; then - DEFINES="$DEFINES -DDEBUG" - if test "x$GCC" = xyes; then - # Remove any -g or -O flags from the command line - CFLAGS=[`echo $CFLAGS | sed 's/-g[^ \t]*[ \t]*//g;s/-O[^ \t]*[ \t]*//g'`] - CFLAGS="$CFLAGS -O0 -ggdb3 -fstack-protector -D_FORTIFY_SOURCE=2" - fi - if test "x$GXX" = xyes; then - # Remove any -g flags from the command line - CXXFLAGS=[`echo $CXXFLAGS | sed 's/-g[^ \t]*[ \t]*//g;s/-O[^ \t]*[ \t]*//g'`] - CXXFLAGS="$CXXFLAGS -O0 -ggdb3 -fstack-protector -D_FORTIFY_SOURCE=2" - fi -fi - -if test "x$GXX" = xyes ; then - WARN="-Wall -Wextra -Wunsafe-loop-optimizations -Wstack-protector" -else - WARN="" -fi - -CFLAGS="$CFLAGS $WARN" -CXXFLAGS="$CXXFLAGS $WARN" -YFLAGS="-d -v" - -AC_OUTPUT([Makefile]) diff --git a/src/glsl/glcpp/.gitignore b/src/glsl/glcpp/.gitignore index dbc37e1926..fb0be2065b 100644 --- a/src/glsl/glcpp/.gitignore +++ b/src/glsl/glcpp/.gitignore @@ -1,5 +1,8 @@ glcpp +glcpp-lex.c glcpp-parse.output +glcpp-parse.c +glcpp-parse.h *.o *.lo *.la diff --git a/src/glsl/glcpp/Makefile.am b/src/glsl/glcpp/Makefile.am deleted file mode 100644 index 81147e6e12..0000000000 --- a/src/glsl/glcpp/Makefile.am +++ /dev/null @@ -1,44 +0,0 @@ -# Copyright © 2010 Intel Corporation -# All Rights Reserved. -# -# 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 -# on the rights to use, copy, modify, merge, publish, distribute, sub -# license, 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 NON-INFRINGEMENT. IN NO EVENT SHALL -# AUTHORS, COPYRIGHT HOLDERS, AND/OR THEIR SUPPLIERS 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. - -noinst_LTLIBRARIES = libglcpp.la -libglcpp_la_SOURCES = \ - glcpp-lex.l \ - glcpp-parse.y \ - glcpp.h \ - pp.c - -BUILT_SOURCES = glcpp-parse.h glcpp-parse.c glcpp-lex.c -CLEANFILES = $(BUILT_SOURCES) - -glcpp-parse.h: glcpp-parse.c - -bin_PROGRAMS = glcpp -glcpp_LDADD = libglcpp.la -glcpp_LDFLAGS = @LDFLAGS@ $(talloc_LIBS) -glcpp_SOURCES = glcpp.c - -.l.c: - $(LEXCOMPILE) --outfile="$@" $< - -test: glcpp - @(cd tests; ./glcpp-test) diff --git a/src/glsl/glcpp/glcpp-lex.c b/src/glsl/glcpp/glcpp-lex.c index 156af3008c..3460559882 100644 --- a/src/glsl/glcpp/glcpp-lex.c +++ b/src/glsl/glcpp/glcpp-lex.c @@ -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. @@ -358,45 +367,43 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_acclist[137] = +static yyconst flex_int16_t yy_acclist[125] = { 0, 3, 3, 44, 39, 43, 40, 43, 41, 43, 43, 38, 43, 43, 38, 43, 38, 43, 38, 43, 25, 39, 43, 24, 39, 43, 38, 43, 38, 43, 38, 43, 37, 39, 43, 37, 39, 43, 38, 43, 40, - 43, 23, 43, 43, 3, 43, 4, 43, 5, 43, - 42, 43, 39, 18, 40, 32, 35, 33, 2, 1, - 25, 39, 25, 39, 39, 24, 39, 24, 39, 27, - 29, 31, 30, 28, 37, 39, 37, 39, 34, 40, - 23, 23, 3, 4, 5, 6, 5, 7, 1, 26, - 39, 37, 39,16398, 26, 39, 37, 39, 18, 37, - - 39,16399,16400, 8206, 18, 8206, 37, 39, 8207, 18, - 8208, 18,16401, 19,16396, 22, 36, 37, 39, 21, - 8209, 18, 19, 8204, 18,16397,16404, 8205, 18, 11, - 18, 9, 8, 8212, 10, 18 + 43, 23, 43, 3, 43, 4, 43, 5, 43, 42, + 43, 18, 43, 18, 43, 18, 43, 39, 40, 32, + 35, 33, 2, 1, 25, 39, 25, 39, 39, 24, + 39, 24, 39, 27, 29, 31, 30, 28, 37, 39, + 37, 39, 34, 40, 23, 23, 3, 4, 5, 6, + 5, 7, 1, 26, 39, 37, 39, 26, 39, 37, + + 39, 14, 37, 39, 15, 16, 37, 39, 17, 19, + 12, 22, 36, 37, 39, 21, 19, 13,16404, 11, + 9, 8, 8212, 10 } ; -static yyconst flex_int16_t yy_accept[164] = +static yyconst flex_int16_t yy_accept[155] = { 0, - 1, 1, 1, 1, 1, 2, 3, 3, 3, 4, - 6, 8, 10, 11, 13, 14, 16, 18, 20, 23, - 26, 28, 30, 32, 35, 38, 40, 42, 44, 45, - 47, 49, 51, 53, 54, 54, 55, 56, 57, 58, - 59, 60, 61, 63, 65, 66, 68, 70, 71, 72, - 73, 74, 75, 77, 79, 80, 81, 82, 83, 83, - 83, 83, 83, 83, 83, 83, 84, 85, 86, 87, - 88, 89, 90, 92, 94, 94, 94, 94, 94, 94, - 95, 95, 95, 95, 95, 97, 99, 99, 99, 99, - 99, 99, 99, 99, 100, 100, 100, 100, 100, 100, - - 100, 102, 102, 103, 104, 104, 104, 104, 104, 106, - 106, 107, 107, 107, 107, 107, 107, 107, 109, 109, - 109, 111, 111, 113, 114, 115, 115, 116, 116, 116, - 116, 117, 117, 120, 121, 121, 123, 124, 124, 124, - 126, 127, 127, 127, 127, 128, 128, 128, 130, 130, - 132, 132, 133, 134, 134, 134, 134, 135, 135, 135, - 137, 137, 137 + 1, 1, 1, 1, 1, 2, 3, 3, 3, 3, + 3, 4, 6, 8, 10, 11, 13, 14, 16, 18, + 20, 23, 26, 28, 30, 32, 35, 38, 40, 42, + 44, 46, 48, 50, 52, 54, 56, 58, 59, 60, + 61, 62, 63, 64, 65, 67, 69, 70, 72, 74, + 75, 76, 77, 78, 79, 81, 83, 84, 85, 86, + 87, 87, 87, 87, 87, 87, 87, 87, 88, 89, + 90, 91, 92, 93, 93, 93, 93, 93, 94, 96, + 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, + 98, 100, 102, 102, 102, 102, 102, 102, 102, 103, + + 103, 103, 103, 103, 103, 103, 105, 105, 106, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 109, + 109, 110, 111, 111, 112, 112, 112, 112, 113, 113, + 116, 117, 118, 118, 119, 119, 119, 119, 120, 120, + 120, 121, 121, 122, 123, 123, 123, 123, 124, 124, + 124, 125, 125, 125 } ; static yyconst flex_int32_t yy_ec[256] = @@ -433,198 +440,144 @@ static yyconst flex_int32_t yy_ec[256] = static yyconst flex_int32_t yy_meta[40] = { 0, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1 + 1, 2, 3, 4, 4, 4, 4, 4, 5, 6, + 4, 7, 7, 7, 4, 4, 4, 8, 8, 8, + 8, 8, 9, 8, 8, 8, 8, 8, 8, 9, + 8, 8, 8, 8, 8, 8, 8, 8, 4 } ; -static yyconst flex_int16_t yy_base[182] = +static yyconst flex_int16_t yy_base[168] = { 0, - 0, 38, 0, 0, 38, 39, 499, 498, 500, 48, - 43, 552, 496, 44, 63, 495, 59, 65, 87, 125, - 58, 67, 68, 164, 203, 40, 75, 241, 552, 494, - 552, 140, 552, 140, 493, 552, 144, 492, 491, 487, - 486, 485, 156, 179, 267, 0, 209, 472, 471, 470, - 469, 468, 446, 124, 466, 153, 462, 458, 154, 198, - 159, 155, 183, 160, 193, 460, 552, 222, 552, 227, - 552, 459, 204, 161, 231, 232, 238, 243, 236, 303, - 245, 180, 247, 249, 281, 56, 257, 271, 248, 259, - 252, 264, 455, 454, 297, 299, 312, 313, 320, 294, - - 407, 295, 427, 426, 321, 296, 324, 425, 552, 424, - 552, 327, 329, 195, 328, 331, 332, 230, 334, 378, - 552, 377, 552, 371, 370, 335, 365, 337, 358, 342, - 360, 344, 326, 255, 340, 552, 260, 338, 246, 552, - 197, 364, 192, 352, 382, 348, 186, 552, 420, 552, - 423, 184, 141, 437, 421, 447, 79, 476, 346, 552, - 453, 552, 515, 517, 519, 521, 523, 525, 71, 527, - 529, 531, 533, 535, 537, 539, 541, 543, 545, 547, - 549 + 0, 38, 0, 0, 38, 39, 328, 327, 326, 44, + 328, 0, 325, 332, 332, 310, 319, 332, 316, 41, + 41, 44, 44, 307, 49, 321, 44, 282, 61, 79, + 317, 332, 72, 332, 332, 67, 68, 0, 317, 332, + 332, 332, 332, 0, 34, 0, 105, 0, 0, 332, + 332, 332, 332, 332, 317, 73, 332, 82, 311, 310, + 291, 61, 289, 286, 279, 281, 286, 306, 332, 90, + 332, 94, 332, 84, 85, 108, 48, 0, 88, 95, + 283, 86, 284, 273, 270, 91, 274, 281, 279, 268, + 0, 124, 273, 274, 274, 270, 265, 271, 332, 267, + + 264, 262, 259, 260, 249, 125, 245, 332, 332, 241, + 229, 231, 223, 209, 222, 194, 197, 194, 130, 196, + 332, 0, 181, 332, 189, 131, 191, 332, 181, 210, + 162, 0, 136, 332, 134, 0, 130, 155, 111, 138, + 332, 153, 0, 332, 125, 41, 156, 332, 34, 136, + 332, 159, 332, 173, 182, 191, 200, 209, 218, 227, + 236, 245, 254, 263, 272, 280, 285 } ; -static yyconst flex_int16_t yy_def[182] = +static yyconst flex_int16_t yy_def[168] = { 0, - 162, 1, 163, 163, 164, 164, 165, 165, 162, 166, - 167, 162, 167, 167, 167, 167, 167, 167, 162, 166, - 167, 167, 167, 168, 168, 167, 167, 167, 162, 169, - 162, 170, 162, 20, 167, 162, 167, 167, 167, 167, - 167, 171, 19, 20, 20, 20, 20, 167, 167, 167, - 167, 167, 25, 25, 167, 167, 28, 28, 167, 167, - 167, 167, 167, 167, 167, 169, 162, 170, 162, 170, - 162, 171, 45, 25, 167, 167, 167, 167, 167, 167, - 167, 167, 167, 167, 20, 25, 167, 167, 167, 167, - 167, 167, 172, 173, 167, 167, 167, 167, 167, 167, - - 25, 167, 174, 175, 167, 167, 167, 172, 162, 173, - 162, 167, 167, 167, 167, 167, 167, 25, 167, 174, - 162, 175, 162, 176, 177, 167, 178, 167, 167, 167, - 167, 167, 25, 167, 176, 162, 177, 167, 178, 162, - 179, 167, 180, 167, 162, 167, 179, 162, 167, 162, - 167, 180, 167, 181, 167, 167, 167, 181, 167, 162, - 167, 0, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162 + 153, 1, 154, 154, 155, 155, 156, 156, 157, 157, + 153, 158, 153, 153, 153, 153, 153, 153, 153, 153, + 158, 158, 153, 153, 153, 159, 159, 153, 153, 153, + 160, 153, 161, 153, 153, 153, 153, 158, 153, 153, + 153, 153, 153, 162, 21, 158, 158, 22, 158, 153, + 153, 153, 153, 153, 159, 159, 153, 153, 30, 30, + 153, 153, 153, 153, 153, 153, 153, 160, 153, 161, + 153, 161, 153, 153, 153, 153, 153, 162, 47, 159, + 153, 153, 153, 153, 153, 163, 153, 153, 153, 153, + 158, 159, 153, 153, 153, 153, 153, 153, 153, 153, + + 153, 153, 153, 153, 153, 159, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 159, 153, + 153, 164, 153, 153, 153, 153, 153, 153, 153, 159, + 153, 164, 153, 153, 153, 165, 153, 166, 153, 153, + 153, 153, 165, 153, 167, 153, 153, 153, 167, 153, + 153, 153, 0, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153 } ; -static yyconst flex_int16_t yy_nxt[592] = +static yyconst flex_int16_t yy_nxt[372] = { 0, - 10, 11, 12, 13, 14, 15, 16, 17, 16, 16, - 18, 19, 20, 20, 21, 22, 23, 24, 24, 24, - 24, 24, 25, 24, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 24, 26, 27, - 31, 31, 36, 28, 37, 36, 36, 32, 32, 35, - 36, 35, 35, 35, 35, 35, 35, 35, 35, 38, - 36, 36, 35, 35, 35, 36, 40, 36, 39, 36, - 36, 66, 48, 49, 41, 42, 56, 36, 55, 53, - 57, 36, 50, 51, 52, 101, 35, 34, 35, 36, - 35, 35, 35, 35, 35, 35, 35, 35, 43, 43, - - 34, 35, 35, 35, 34, 34, 44, 45, 34, 34, - 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, - 34, 34, 44, 34, 45, 35, 35, 36, 35, 35, - 35, 35, 35, 35, 35, 35, 46, 46, 46, 35, - 35, 35, 69, 36, 47, 37, 36, 53, 74, 70, - 71, 34, 34, 34, 56, 36, 36, 36, 57, 34, - 47, 36, 36, 35, 34, 35, 36, 35, 35, 35, - 35, 35, 35, 35, 35, 34, 34, 75, 35, 35, - 35, 81, 36, 80, 53, 36, 36, 86, 148, 83, - 34, 34, 34, 34, 36, 36, 129, 36, 34, 148, - - 36, 98, 35, 34, 35, 36, 35, 35, 35, 35, - 35, 35, 35, 35, 34, 82, 84, 35, 35, 35, - 34, 34, 34, 85, 69, 76, 54, 77, 34, 69, - 78, 162, 162, 36, 36, 79, 70, 71, 36, 85, - 36, 35, 58, 36, 34, 36, 39, 36, 140, 36, - 36, 36, 133, 53, 36, 87, 145, 36, 88, 36, - 90, 36, 36, 59, 60, 89, 36, 61, 62, 99, - 92, 104, 63, 36, 97, 91, 64, 65, 73, 73, - 73, 100, 106, 102, 73, 105, 34, 107, 73, 73, - 73, 73, 34, 34, 34, 103, 36, 36, 36, 36, - - 34, 36, 34, 93, 93, 94, 93, 93, 93, 93, - 93, 93, 93, 93, 36, 36, 34, 93, 93, 93, - 112, 113, 36, 36, 119, 95, 36, 117, 125, 36, - 36, 36, 96, 36, 36, 114, 36, 36, 115, 36, - 36, 93, 136, 116, 36, 124, 36, 159, 160, 53, - 36, 127, 128, 126, 36, 131, 130, 134, 132, 129, - 36, 141, 36, 143, 146, 149, 150, 140, 138, 142, - 142, 142, 36, 136, 144, 151, 151, 151, 155, 123, - 121, 153, 35, 145, 36, 35, 35, 35, 35, 35, - 35, 35, 35, 35, 35, 35, 35, 35, 35, 154, - - 154, 154, 154, 154, 154, 154, 154, 154, 154, 154, - 154, 154, 154, 154, 154, 154, 154, 154, 154, 154, - 35, 149, 150, 36, 149, 150, 111, 109, 123, 121, - 118, 156, 156, 156, 151, 151, 151, 35, 35, 36, - 35, 35, 35, 35, 35, 157, 35, 35, 159, 160, - 143, 35, 35, 35, 159, 160, 111, 109, 161, 161, - 161, 36, 67, 35, 161, 161, 161, 35, 36, 53, - 36, 36, 36, 36, 36, 35, 35, 35, 36, 35, - 35, 35, 35, 35, 157, 35, 35, 36, 36, 36, - 35, 35, 35, 36, 36, 36, 67, 36, 36, 162, - - 29, 29, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 35, 29, 29, 30, 30, 33, - 33, 34, 34, 35, 35, 53, 53, 68, 68, 72, - 72, 108, 108, 110, 110, 120, 120, 122, 122, 135, - 135, 137, 137, 139, 139, 147, 147, 152, 152, 158, - 158, 9, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162 - + 12, 13, 14, 15, 16, 17, 18, 19, 18, 18, + 20, 21, 22, 22, 23, 24, 25, 26, 26, 26, + 26, 26, 27, 26, 26, 26, 26, 26, 26, 26, + 26, 26, 26, 26, 26, 26, 26, 26, 28, 29, + 32, 32, 148, 30, 38, 36, 14, 33, 33, 37, + 43, 44, 45, 45, 38, 48, 48, 48, 50, 51, + 46, 47, 58, 49, 53, 54, 59, 56, 74, 76, + 136, 38, 75, 38, 71, 82, 46, 83, 47, 49, + 60, 72, 73, 58, 41, 74, 76, 59, 82, 75, + 83, 77, 71, 84, 63, 38, 71, 80, 85, 153, + + 153, 61, 62, 72, 73, 63, 64, 91, 77, 76, + 65, 63, 94, 100, 66, 67, 79, 79, 79, 95, + 101, 92, 79, 91, 38, 38, 79, 79, 79, 79, + 38, 77, 126, 148, 63, 140, 141, 150, 151, 140, + 141, 146, 135, 135, 135, 142, 142, 142, 119, 147, + 147, 147, 130, 106, 140, 141, 138, 150, 151, 144, + 150, 151, 139, 138, 142, 142, 142, 152, 152, 152, + 152, 152, 152, 15, 15, 15, 15, 15, 15, 15, + 15, 15, 31, 31, 31, 31, 31, 31, 31, 31, + 31, 34, 34, 34, 34, 34, 34, 34, 34, 34, + + 35, 35, 35, 35, 35, 35, 35, 35, 35, 38, + 38, 137, 136, 134, 133, 38, 38, 38, 55, 131, + 129, 128, 127, 126, 55, 55, 55, 68, 68, 68, + 68, 68, 125, 68, 68, 68, 70, 70, 70, 70, + 70, 70, 70, 70, 70, 78, 78, 124, 78, 78, + 78, 78, 78, 78, 99, 99, 99, 99, 99, 99, + 123, 122, 99, 132, 132, 121, 132, 132, 132, 132, + 132, 132, 143, 143, 120, 143, 143, 143, 143, 143, + 143, 145, 118, 117, 116, 115, 114, 145, 145, 149, + 113, 149, 149, 149, 112, 111, 110, 109, 108, 107, + + 105, 104, 103, 102, 98, 97, 96, 93, 69, 90, + 89, 88, 87, 86, 81, 153, 153, 38, 39, 69, + 57, 38, 52, 42, 41, 40, 39, 153, 14, 15, + 15, 11, 153, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153 } ; -static yyconst flex_int16_t yy_chk[592] = +static yyconst flex_int16_t yy_chk[372] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, - 5, 6, 26, 2, 11, 11, 14, 5, 6, 10, - 10, 10, 10, 10, 10, 10, 10, 10, 10, 14, - 21, 17, 10, 10, 10, 15, 17, 18, 15, 22, - 23, 169, 21, 21, 18, 18, 27, 27, 26, 86, - 27, 157, 22, 23, 23, 86, 10, 19, 19, 19, - 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, - - 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, - 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, - 19, 19, 19, 19, 19, 19, 20, 20, 20, 20, - 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, - 20, 20, 32, 153, 20, 37, 37, 54, 54, 32, - 32, 34, 34, 34, 56, 56, 59, 62, 56, 34, - 20, 61, 64, 20, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 34, 43, 59, 24, 24, - 24, 62, 82, 61, 74, 63, 152, 74, 147, 64, - 44, 44, 44, 43, 143, 65, 114, 114, 44, 141, - - 60, 82, 24, 25, 25, 25, 25, 25, 25, 25, - 25, 25, 25, 25, 44, 63, 65, 25, 25, 25, - 47, 47, 47, 73, 68, 60, 25, 60, 47, 70, - 60, 68, 68, 75, 76, 60, 70, 70, 79, 73, - 77, 25, 28, 28, 47, 78, 28, 81, 139, 83, - 89, 84, 118, 118, 91, 75, 134, 134, 76, 87, - 77, 90, 137, 28, 28, 76, 92, 28, 28, 83, - 79, 89, 28, 88, 81, 78, 28, 28, 45, 45, - 45, 84, 91, 87, 45, 90, 45, 92, 45, 45, - 45, 45, 85, 85, 85, 88, 100, 102, 106, 95, - - 85, 96, 45, 80, 80, 80, 80, 80, 80, 80, - 80, 80, 80, 80, 97, 98, 85, 80, 80, 80, - 95, 96, 99, 105, 102, 80, 107, 100, 106, 112, - 115, 113, 80, 116, 117, 97, 119, 126, 98, 128, - 138, 80, 135, 99, 130, 105, 132, 159, 159, 133, - 146, 112, 113, 107, 144, 116, 115, 119, 117, 129, - 129, 128, 131, 130, 138, 142, 142, 127, 126, 129, - 129, 129, 125, 124, 132, 142, 142, 142, 146, 122, - 120, 144, 145, 145, 145, 145, 145, 145, 145, 145, - 145, 145, 145, 145, 145, 145, 145, 145, 145, 145, - - 145, 145, 145, 145, 145, 145, 145, 145, 145, 145, - 145, 145, 145, 145, 145, 145, 145, 145, 145, 145, - 145, 149, 149, 155, 151, 151, 110, 108, 104, 103, - 101, 149, 149, 149, 151, 151, 151, 154, 154, 154, - 154, 154, 154, 154, 154, 154, 154, 154, 156, 156, - 155, 154, 154, 154, 161, 161, 94, 93, 156, 156, - 156, 72, 66, 58, 161, 161, 161, 57, 55, 53, - 52, 51, 50, 49, 48, 154, 158, 158, 158, 158, - 158, 158, 158, 158, 158, 158, 158, 42, 41, 40, - 158, 158, 158, 39, 38, 35, 30, 16, 13, 9, - - 8, 7, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 158, 163, 163, 164, 164, 165, - 165, 166, 166, 167, 167, 168, 168, 170, 170, 171, - 171, 172, 172, 173, 173, 174, 174, 175, 175, 176, - 176, 177, 177, 178, 178, 179, 179, 180, 180, 181, - 181, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, - 162 - + 5, 6, 149, 2, 27, 10, 10, 5, 6, 10, + 20, 20, 21, 21, 45, 22, 22, 22, 23, 23, + 21, 21, 29, 22, 25, 25, 29, 27, 36, 37, + 146, 45, 36, 56, 33, 77, 21, 77, 21, 22, + 30, 33, 33, 58, 30, 74, 75, 58, 62, 74, + 62, 37, 70, 62, 37, 80, 72, 56, 62, 70, + + 70, 30, 30, 72, 72, 30, 30, 79, 75, 76, + 30, 75, 82, 86, 30, 30, 47, 47, 47, 82, + 86, 80, 47, 79, 92, 106, 47, 47, 47, 47, + 119, 76, 126, 145, 76, 135, 135, 150, 150, 140, + 140, 139, 126, 126, 126, 135, 135, 135, 106, 140, + 140, 140, 119, 92, 142, 142, 138, 147, 147, 137, + 152, 152, 133, 131, 142, 142, 142, 147, 147, 147, + 152, 152, 152, 154, 154, 154, 154, 154, 154, 154, + 154, 154, 155, 155, 155, 155, 155, 155, 155, 155, + 155, 156, 156, 156, 156, 156, 156, 156, 156, 156, + + 157, 157, 157, 157, 157, 157, 157, 157, 157, 158, + 130, 129, 127, 125, 123, 158, 158, 158, 159, 120, + 118, 117, 116, 115, 159, 159, 159, 160, 160, 160, + 160, 160, 114, 160, 160, 160, 161, 161, 161, 161, + 161, 161, 161, 161, 161, 162, 162, 113, 162, 162, + 162, 162, 162, 162, 163, 163, 163, 163, 163, 163, + 112, 111, 163, 164, 164, 110, 164, 164, 164, 164, + 164, 164, 165, 165, 107, 165, 165, 165, 165, 165, + 165, 166, 105, 104, 103, 102, 101, 166, 166, 167, + 100, 167, 167, 167, 98, 97, 96, 95, 94, 93, + + 90, 89, 88, 87, 85, 84, 83, 81, 68, 67, + 66, 65, 64, 63, 61, 60, 59, 55, 39, 31, + 28, 26, 24, 19, 17, 16, 13, 11, 9, 8, + 7, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, + 153 } ; #define YY_TRAILING_MASK 0x2000 @@ -680,6 +633,10 @@ goto find_rule; \ int glcpp_get_column (yyscan_t yyscanner); void glcpp_set_column (int column_no , yyscan_t yyscanner); +#ifdef _MSC_VER +#define YY_NO_UNISTD_H +#endif + #define YY_NO_INPUT #define YY_USER_ACTION \ @@ -696,12 +653,13 @@ void glcpp_set_column (int column_no , yyscan_t yyscanner); yylloc->source = 0; \ } while(0) -#line 700 "glcpp/glcpp-lex.c" +#line 657 "glcpp/glcpp-lex.c" #define INITIAL 0 #define DONE 1 #define COMMENT 2 #define UNREACHABLE 3 +#define SKIP 4 #define YY_EXTRA_TYPE glcpp_parser_t * @@ -843,7 +801,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. */ @@ -862,7 +825,7 @@ static int input (yyscan_t yyscanner ); if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ { \ int c = '*'; \ - unsigned n; \ + size_t n; \ for ( n = 0; n < max_size && \ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ @@ -950,11 +913,22 @@ YY_DECL register int yy_act; struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; -#line 76 "glcpp/glcpp-lex.l" +#line 80 "glcpp/glcpp-lex.l" + /* Implicitly switch between SKIP and INITIAL (non-skipping); + * don't switch if some other state was explicitly set. + */ + glcpp_parser_t *parser = yyextra; + if (YY_START == 0 || YY_START == SKIP) { + if (parser->lexing_if || parser->skip_stack == NULL || parser->skip_stack->type == SKIP_NO_SKIP) { + BEGIN 0; + } else { + BEGIN SKIP; + } + } /* Single-line comments */ -#line 958 "glcpp/glcpp-lex.c" +#line 932 "glcpp/glcpp-lex.c" yylval = yylval_param; @@ -1017,14 +991,14 @@ 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 >= 163 ) + if ( yy_current_state >= 154 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; *yyg->yy_state_ptr++ = yy_current_state; ++yy_cp; } - while ( yy_current_state != 162 ); + while ( yy_current_state != 153 ); yy_find_action: yy_current_state = *--yyg->yy_state_ptr; @@ -1049,9 +1023,6 @@ find_rule: /* we branch to this label when backing up */ { yyg->yy_looking_for_trail_begin = yy_act & ~YY_TRAILING_MASK; yyg->yy_looking_for_trail_begin |= YY_TRAILING_HEAD_MASK; - yyg->yy_full_match = yy_cp; - yyg->yy_full_state = yyg->yy_state_ptr; - yyg->yy_full_lp = yyg->yy_lp; } else { @@ -1076,41 +1047,41 @@ do_action: /* This label is used only to access EOF actions. */ { /* beginning of action switch */ case 1: YY_RULE_SETUP -#line 79 "glcpp/glcpp-lex.l" +#line 94 "glcpp/glcpp-lex.l" { } YY_BREAK /* Multi-line comments */ case 2: YY_RULE_SETUP -#line 83 "glcpp/glcpp-lex.l" +#line 98 "glcpp/glcpp-lex.l" { yy_push_state(COMMENT, yyscanner); } YY_BREAK case 3: YY_RULE_SETUP -#line 84 "glcpp/glcpp-lex.l" +#line 99 "glcpp/glcpp-lex.l" YY_BREAK case 4: /* rule 4 can match eol */ YY_RULE_SETUP -#line 85 "glcpp/glcpp-lex.l" +#line 100 "glcpp/glcpp-lex.l" { yylineno++; yycolumn = 0; return NEWLINE; } YY_BREAK case 5: YY_RULE_SETUP -#line 86 "glcpp/glcpp-lex.l" +#line 101 "glcpp/glcpp-lex.l" YY_BREAK case 6: /* rule 6 can match eol */ YY_RULE_SETUP -#line 87 "glcpp/glcpp-lex.l" +#line 102 "glcpp/glcpp-lex.l" { yylineno++; yycolumn = 0; return NEWLINE; } YY_BREAK case 7: YY_RULE_SETUP -#line 88 "glcpp/glcpp-lex.l" +#line 103 "glcpp/glcpp-lex.l" { yy_pop_state(yyscanner); if (yyextra->space_tokens) @@ -1119,9 +1090,9 @@ YY_RULE_SETUP YY_BREAK case 8: YY_RULE_SETUP -#line 94 "glcpp/glcpp-lex.l" +#line 109 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); yyextra->space_tokens = 0; return HASH_VERSION; } @@ -1130,9 +1101,9 @@ YY_RULE_SETUP * Simply pass them through to the main compiler's lexer/parser. */ case 9: YY_RULE_SETUP -#line 102 "glcpp/glcpp-lex.l" +#line 117 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); yylineno++; yycolumn = 0; return OTHER; @@ -1143,7 +1114,7 @@ case 10: yyg->yy_c_buf_p = yy_cp -= 1; YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 109 "glcpp/glcpp-lex.l" +#line 124 "glcpp/glcpp-lex.l" { /* Eat characters until the first digit is * encountered @@ -1165,7 +1136,7 @@ case 11: yyg->yy_c_buf_p = yy_cp -= 1; YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 125 "glcpp/glcpp-lex.l" +#line 140 "glcpp/glcpp-lex.l" { /* Eat characters until the first digit is * encountered @@ -1181,10 +1152,10 @@ YY_RULE_SETUP yylineno = strtol(ptr, &ptr, 0) - 1; } YY_BREAK + case 12: -/* rule 12 can match eol */ YY_RULE_SETUP -#line 140 "glcpp/glcpp-lex.l" +#line 156 "glcpp/glcpp-lex.l" { yyextra->lexing_if = 1; yyextra->space_tokens = 0; @@ -1192,9 +1163,8 @@ YY_RULE_SETUP } YY_BREAK case 13: -/* rule 13 can match eol */ YY_RULE_SETUP -#line 146 "glcpp/glcpp-lex.l" +#line 162 "glcpp/glcpp-lex.l" { yyextra->lexing_if = 1; yyextra->space_tokens = 0; @@ -1203,8 +1173,11 @@ YY_RULE_SETUP YY_BREAK case 14: /* rule 14 can match eol */ +*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */ +yyg->yy_c_buf_p = yy_cp -= 1; +YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 152 "glcpp/glcpp-lex.l" +#line 168 "glcpp/glcpp-lex.l" { yyextra->lexing_if = 1; yyextra->space_tokens = 0; @@ -1212,9 +1185,8 @@ YY_RULE_SETUP } YY_BREAK case 15: -/* rule 15 can match eol */ YY_RULE_SETUP -#line 158 "glcpp/glcpp-lex.l" +#line 174 "glcpp/glcpp-lex.l" { yyextra->lexing_if = 1; yyextra->space_tokens = 0; @@ -1222,53 +1194,30 @@ YY_RULE_SETUP } YY_BREAK case 16: -/* rule 16 can match eol */ YY_RULE_SETUP -#line 164 "glcpp/glcpp-lex.l" +#line 180 "glcpp/glcpp-lex.l" { yyextra->space_tokens = 0; return HASH_ELSE; } YY_BREAK case 17: -/* rule 17 can match eol */ YY_RULE_SETUP -#line 169 "glcpp/glcpp-lex.l" +#line 185 "glcpp/glcpp-lex.l" { yyextra->space_tokens = 0; return HASH_ENDIF; } YY_BREAK -/* When skipping (due to an #if 0 or similar) consume anything - * up to a newline. We do this with less priority than any - * #if-related directive (#if, #elif, #else, #endif), but with - * more priority than any other directive or token to avoid - * any side-effects from skipped content. - * - * We use the lexing_if flag to avoid skipping any part of an - * if conditional expression. */ + case 18: -/* rule 18 can match eol */ -*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */ -yyg->yy_c_buf_p = yy_cp -= 1; -YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 182 "glcpp/glcpp-lex.l" -{ - /* Since this rule always matches, YY_USER_ACTION gets called for it, - * wrongly incrementing yycolumn. We undo that effect here. */ - yycolumn -= yyleng; - if (yyextra->lexing_if || - yyextra->skip_stack == NULL || - yyextra->skip_stack->type == SKIP_NO_SKIP) - { - REJECT; - } -} +#line 191 "glcpp/glcpp-lex.l" +; YY_BREAK case 19: YY_RULE_SETUP -#line 194 "glcpp/glcpp-lex.l" +#line 193 "glcpp/glcpp-lex.l" { char *p; for (p = yytext; !isalpha(p[0]); p++); /* skip " # " */ @@ -1278,7 +1227,7 @@ YY_RULE_SETUP YY_BREAK case 20: YY_RULE_SETUP -#line 201 "glcpp/glcpp-lex.l" +#line 200 "glcpp/glcpp-lex.l" { yyextra->space_tokens = 0; return HASH_DEFINE_FUNC; @@ -1286,7 +1235,7 @@ YY_RULE_SETUP YY_BREAK case 21: YY_RULE_SETUP -#line 206 "glcpp/glcpp-lex.l" +#line 205 "glcpp/glcpp-lex.l" { yyextra->space_tokens = 0; return HASH_DEFINE_OBJ; @@ -1294,7 +1243,7 @@ YY_RULE_SETUP YY_BREAK case 22: YY_RULE_SETUP -#line 211 "glcpp/glcpp-lex.l" +#line 210 "glcpp/glcpp-lex.l" { yyextra->space_tokens = 0; return HASH_UNDEF; @@ -1302,7 +1251,7 @@ YY_RULE_SETUP YY_BREAK case 23: YY_RULE_SETUP -#line 216 "glcpp/glcpp-lex.l" +#line 215 "glcpp/glcpp-lex.l" { yyextra->space_tokens = 0; return HASH; @@ -1310,124 +1259,124 @@ YY_RULE_SETUP YY_BREAK case 24: YY_RULE_SETUP -#line 221 "glcpp/glcpp-lex.l" +#line 220 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return INTEGER_STRING; } YY_BREAK case 25: YY_RULE_SETUP -#line 226 "glcpp/glcpp-lex.l" +#line 225 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return INTEGER_STRING; } YY_BREAK case 26: YY_RULE_SETUP -#line 231 "glcpp/glcpp-lex.l" +#line 230 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return INTEGER_STRING; } YY_BREAK case 27: YY_RULE_SETUP -#line 236 "glcpp/glcpp-lex.l" +#line 235 "glcpp/glcpp-lex.l" { return LEFT_SHIFT; } YY_BREAK case 28: YY_RULE_SETUP -#line 240 "glcpp/glcpp-lex.l" +#line 239 "glcpp/glcpp-lex.l" { return RIGHT_SHIFT; } YY_BREAK case 29: YY_RULE_SETUP -#line 244 "glcpp/glcpp-lex.l" +#line 243 "glcpp/glcpp-lex.l" { return LESS_OR_EQUAL; } YY_BREAK case 30: YY_RULE_SETUP -#line 248 "glcpp/glcpp-lex.l" +#line 247 "glcpp/glcpp-lex.l" { return GREATER_OR_EQUAL; } YY_BREAK case 31: YY_RULE_SETUP -#line 252 "glcpp/glcpp-lex.l" +#line 251 "glcpp/glcpp-lex.l" { return EQUAL; } YY_BREAK case 32: YY_RULE_SETUP -#line 256 "glcpp/glcpp-lex.l" +#line 255 "glcpp/glcpp-lex.l" { return NOT_EQUAL; } YY_BREAK case 33: YY_RULE_SETUP -#line 260 "glcpp/glcpp-lex.l" +#line 259 "glcpp/glcpp-lex.l" { return AND; } YY_BREAK case 34: YY_RULE_SETUP -#line 264 "glcpp/glcpp-lex.l" +#line 263 "glcpp/glcpp-lex.l" { return OR; } YY_BREAK case 35: YY_RULE_SETUP -#line 268 "glcpp/glcpp-lex.l" +#line 267 "glcpp/glcpp-lex.l" { return PASTE; } YY_BREAK case 36: YY_RULE_SETUP -#line 272 "glcpp/glcpp-lex.l" +#line 271 "glcpp/glcpp-lex.l" { return DEFINED; } YY_BREAK case 37: YY_RULE_SETUP -#line 276 "glcpp/glcpp-lex.l" +#line 275 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return IDENTIFIER; } YY_BREAK case 38: YY_RULE_SETUP -#line 281 "glcpp/glcpp-lex.l" +#line 280 "glcpp/glcpp-lex.l" { return yytext[0]; } YY_BREAK case 39: YY_RULE_SETUP -#line 285 "glcpp/glcpp-lex.l" +#line 284 "glcpp/glcpp-lex.l" { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return OTHER; } YY_BREAK case 40: YY_RULE_SETUP -#line 290 "glcpp/glcpp-lex.l" +#line 289 "glcpp/glcpp-lex.l" { if (yyextra->space_tokens) { return SPACE; @@ -1437,7 +1386,7 @@ YY_RULE_SETUP case 41: /* rule 41 can match eol */ YY_RULE_SETUP -#line 296 "glcpp/glcpp-lex.l" +#line 295 "glcpp/glcpp-lex.l" { yyextra->lexing_if = 0; yylineno++; @@ -1447,7 +1396,7 @@ YY_RULE_SETUP YY_BREAK /* Handle missing newline at EOF. */ case YY_STATE_EOF(INITIAL): -#line 304 "glcpp/glcpp-lex.l" +#line 303 "glcpp/glcpp-lex.l" { BEGIN DONE; /* Don't keep matching this rule forever. */ yyextra->lexing_if = 0; @@ -1460,7 +1409,7 @@ case YY_STATE_EOF(INITIAL): warnings. */ case 42: YY_RULE_SETUP -#line 314 "glcpp/glcpp-lex.l" +#line 313 "glcpp/glcpp-lex.l" { unput('.'); yy_top_state(yyextra); @@ -1468,13 +1417,14 @@ YY_RULE_SETUP YY_BREAK case 43: YY_RULE_SETUP -#line 319 "glcpp/glcpp-lex.l" +#line 318 "glcpp/glcpp-lex.l" ECHO; YY_BREAK -#line 1475 "glcpp/glcpp-lex.c" +#line 1424 "glcpp/glcpp-lex.c" case YY_STATE_EOF(DONE): case YY_STATE_EOF(COMMENT): case YY_STATE_EOF(UNREACHABLE): + case YY_STATE_EOF(SKIP): yyterminate(); case YY_END_OF_BUFFER: @@ -1737,7 +1687,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 >= 163 ) + if ( yy_current_state >= 154 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -1761,11 +1711,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 >= 163 ) + if ( yy_current_state >= 154 ) 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 == 162); + yy_is_jam = (yy_current_state == 153); if ( ! yy_is_jam ) *yyg->yy_state_ptr++ = yy_current_state; @@ -2210,8 +2160,8 @@ YY_BUFFER_STATE glcpp__scan_string (yyconst char * yystr , yyscan_t yyscanner) /** Setup the input buffer state to scan the given bytes. The next call to glcpp_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. */ @@ -2665,7 +2615,7 @@ void glcpp_free (void * ptr , yyscan_t yyscanner) #define YYTABLES_NAME "yytables" -#line 319 "glcpp/glcpp-lex.l" +#line 318 "glcpp/glcpp-lex.l" diff --git a/src/glsl/glcpp/glcpp-lex.l b/src/glsl/glcpp/glcpp-lex.l index e936854cf2..8661887088 100644 --- a/src/glsl/glcpp/glcpp-lex.l +++ b/src/glsl/glcpp/glcpp-lex.l @@ -34,6 +34,10 @@ int glcpp_get_column (yyscan_t yyscanner); void glcpp_set_column (int column_no , yyscan_t yyscanner); +#ifdef _MSC_VER +#define YY_NO_UNISTD_H +#endif + #define YY_NO_INPUT #define YY_USER_ACTION \ @@ -57,7 +61,7 @@ void glcpp_set_column (int column_no , yyscan_t yyscanner); %option stack %option never-interactive -%x DONE COMMENT UNREACHABLE +%x DONE COMMENT UNREACHABLE SKIP SPACE [[:space:]] NONSPACE [^[:space:]] @@ -74,6 +78,17 @@ OCTAL_INTEGER 0[0-7]*[uU]? HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? %% + /* Implicitly switch between SKIP and INITIAL (non-skipping); + * don't switch if some other state was explicitly set. + */ + glcpp_parser_t *parser = yyextra; + if (YY_START == 0 || YY_START == SKIP) { + if (parser->lexing_if || parser->skip_stack == NULL || parser->skip_stack->type == SKIP_NO_SKIP) { + BEGIN 0; + } else { + BEGIN SKIP; + } + } /* Single-line comments */ "//"[^\n]* { @@ -92,7 +107,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? } {HASH}version { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); yyextra->space_tokens = 0; return HASH_VERSION; } @@ -100,7 +115,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? /* glcpp doesn't handle #extension, #version, or #pragma directives. * Simply pass them through to the main compiler's lexer/parser. */ {HASH}(extension|pragma)[^\n]+ { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); yylineno++; yycolumn = 0; return OTHER; @@ -137,60 +152,44 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? yylineno = strtol(ptr, &ptr, 0) - 1; } -{HASH}ifdef/.*\n { +<SKIP,INITIAL>{ +{HASH}ifdef { yyextra->lexing_if = 1; yyextra->space_tokens = 0; return HASH_IFDEF; } -{HASH}ifndef/.*\n { +{HASH}ifndef { yyextra->lexing_if = 1; yyextra->space_tokens = 0; return HASH_IFNDEF; } -{HASH}if/[^_a-zA-Z0-9].*\n { +{HASH}if/[^_a-zA-Z0-9] { yyextra->lexing_if = 1; yyextra->space_tokens = 0; return HASH_IF; } -{HASH}elif/.*\n { +{HASH}elif { yyextra->lexing_if = 1; yyextra->space_tokens = 0; return HASH_ELIF; } -{HASH}else/.*\n { +{HASH}else { yyextra->space_tokens = 0; return HASH_ELSE; } -{HASH}endif/.*\n { +{HASH}endif { yyextra->space_tokens = 0; return HASH_ENDIF; } - - /* When skipping (due to an #if 0 or similar) consume anything - * up to a newline. We do this with less priority than any - * #if-related directive (#if, #elif, #else, #endif), but with - * more priority than any other directive or token to avoid - * any side-effects from skipped content. - * - * We use the lexing_if flag to avoid skipping any part of an - * if conditional expression. */ -[^\n]+/\n { - /* Since this rule always matches, YY_USER_ACTION gets called for it, - * wrongly incrementing yycolumn. We undo that effect here. */ - yycolumn -= yyleng; - if (yyextra->lexing_if || - yyextra->skip_stack == NULL || - yyextra->skip_stack->type == SKIP_NO_SKIP) - { - REJECT; - } } +<SKIP>[^\n] ; + {HASH}error.* { char *p; for (p = yytext; !isalpha(p[0]); p++); /* skip " # " */ @@ -219,17 +218,17 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? } {DECIMAL_INTEGER} { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return INTEGER_STRING; } {OCTAL_INTEGER} { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return INTEGER_STRING; } {HEXADECIMAL_INTEGER} { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return INTEGER_STRING; } @@ -274,7 +273,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? } {IDENTIFIER} { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return IDENTIFIER; } @@ -283,7 +282,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? } {OTHER}+ { - yylval->str = talloc_strdup (yyextra, yytext); + yylval->str = ralloc_strdup (yyextra, yytext); return OTHER; } @@ -293,7 +292,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? } } -\n { +<SKIP,INITIAL>\n { yyextra->lexing_if = 0; yylineno++; yycolumn = 0; diff --git a/src/glsl/glcpp/glcpp-parse.c b/src/glsl/glcpp/glcpp-parse.c index ab7c30ed78..29c45c7f30 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" @@ -102,10 +103,6 @@ #include "main/core.h" /* for struct gl_extensions */ #include "main/mtypes.h" /* for gl_api enum */ -#define glcpp_print(stream, str) stream = talloc_strdup_append(stream, str) -#define glcpp_printf(stream, fmt, args, ...) \ - stream = talloc_asprintf_append(stream, fmt, args) - static void yyerror (YYLTYPE *locp, glcpp_parser_t *parser, const char *error); @@ -149,7 +146,7 @@ _argument_list_length (argument_list_t *list); static token_list_t * _argument_list_member_at (argument_list_t *list, int index); -/* Note: This function talloc_steal()s the str pointer. */ +/* Note: This function ralloc_steal()s the str pointer. */ static token_t * _token_create_str (void *ctx, int type, char *str); @@ -159,10 +156,7 @@ _token_create_ival (void *ctx, int type, int ival); static token_list_t * _token_list_create (void *ctx); -/* Note: This function adds a talloc_reference() to token. - * - * You may want to talloc_unlink any current reference if you no - * longer need it. */ +/* Note: This function calls ralloc_steal on token. */ static void _token_list_append (token_list_t *list, token_t *token); @@ -219,7 +213,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 217 "glcpp/glcpp-parse.c" /* Enabling traces. */ #ifndef YYDEBUG @@ -307,7 +301,7 @@ typedef struct YYLTYPE /* Line 264 of yacc.c */ -#line 311 "glcpp/glcpp-parse.c" +#line 305 "glcpp/glcpp-parse.c" #ifdef short # undef short @@ -357,7 +351,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) @@ -632,17 +626,17 @@ static const yytype_int8 yyrhs[] = /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 188, 188, 190, 194, 197, 202, 203, 207, 210, - 216, 219, 222, 225, 233, 252, 262, 267, 272, 291, - 306, 309, 312, 333, 337, 346, 351, 352, 355, 358, - 361, 364, 367, 370, 373, 376, 379, 382, 385, 388, - 391, 394, 397, 400, 403, 406, 409, 412, 415, 418, - 424, 429, 437, 438, 442, 448, 449, 452, 454, 461, - 465, 469, 474, 479, 487, 493, 501, 505, 509, 513, - 517, 524, 525, 526, 527, 528, 529, 530, 531, 532, - 533, 534, 535, 536, 537, 538, 539, 540, 541, 542, - 543, 544, 545, 546, 547, 548, 549, 550, 551, 552, - 553, 554 + 0, 181, 181, 183, 187, 190, 195, 196, 200, 203, + 209, 212, 215, 218, 226, 245, 255, 260, 265, 284, + 299, 302, 305, 326, 330, 339, 344, 345, 348, 351, + 354, 357, 360, 363, 366, 369, 372, 375, 378, 381, + 384, 387, 390, 398, 406, 409, 412, 415, 418, 421, + 427, 432, 440, 441, 445, 451, 452, 455, 457, 464, + 468, 472, 477, 481, 488, 493, 500, 504, 508, 512, + 516, 523, 524, 525, 526, 527, 528, 529, 530, 531, + 532, 533, 534, 535, 536, 537, 538, 539, 540, 541, + 542, 543, 544, 545, 546, 547, 548, 549, 550, 551, + 552, 553 }; #endif @@ -945,18 +939,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 +998,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 +1540,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 +1587,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,8 +1595,8 @@ YYLTYPE yylloc; /* User initialization code. */ -/* Line 1251 of yacc.c */ -#line 155 "glcpp/glcpp-parse.y" +/* Line 1242 of yacc.c */ +#line 148 "glcpp/glcpp-parse.y" { yylloc.first_line = 1; yylloc.first_column = 1; @@ -1620,8 +1605,8 @@ YYLTYPE yylloc; yylloc.source = 0; } -/* Line 1251 of yacc.c */ -#line 1625 "glcpp/glcpp-parse.c" +/* Line 1242 of yacc.c */ +#line 1610 "glcpp/glcpp-parse.c" yylsp[0] = yylloc; goto yysetstate; @@ -1808,28 +1793,28 @@ yyreduce: { case 4: -/* Line 1464 of yacc.c */ -#line 194 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 187 "glcpp/glcpp-parse.y" { - glcpp_print(parser->output, "\n"); + ralloc_strcat (&parser->output, "\n"); ;} break; case 5: -/* Line 1464 of yacc.c */ -#line 197 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 190 "glcpp/glcpp-parse.y" { _glcpp_parser_print_expanded_token_list (parser, (yyvsp[(1) - (1)].token_list)); - glcpp_print(parser->output, "\n"); - talloc_free ((yyvsp[(1) - (1)].token_list)); + ralloc_strcat (&parser->output, "\n"); + ralloc_free ((yyvsp[(1) - (1)].token_list)); ;} break; case 8: -/* Line 1464 of yacc.c */ -#line 207 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 200 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_push_if (parser, & (yylsp[(1) - (3)]), (yyvsp[(2) - (3)].ival)); ;} @@ -1837,8 +1822,8 @@ yyreduce: case 9: -/* Line 1464 of yacc.c */ -#line 210 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 203 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_change_if (parser, & (yylsp[(1) - (3)]), "elif", (yyvsp[(2) - (3)].ival)); ;} @@ -1846,8 +1831,8 @@ yyreduce: case 10: -/* Line 1464 of yacc.c */ -#line 216 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 209 "glcpp/glcpp-parse.y" { _define_object_macro (parser, & (yylsp[(2) - (4)]), (yyvsp[(2) - (4)].str), (yyvsp[(3) - (4)].token_list)); ;} @@ -1855,8 +1840,8 @@ yyreduce: case 11: -/* Line 1464 of yacc.c */ -#line 219 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 212 "glcpp/glcpp-parse.y" { _define_function_macro (parser, & (yylsp[(2) - (6)]), (yyvsp[(2) - (6)].str), NULL, (yyvsp[(5) - (6)].token_list)); ;} @@ -1864,8 +1849,8 @@ yyreduce: case 12: -/* Line 1464 of yacc.c */ -#line 222 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 215 "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,22 +1858,22 @@ yyreduce: case 13: -/* Line 1464 of yacc.c */ -#line 225 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 218 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, (yyvsp[(2) - (3)].str)); if (macro) { hash_table_remove (parser->defines, (yyvsp[(2) - (3)].str)); - talloc_free (macro); + ralloc_free (macro); } - talloc_free ((yyvsp[(2) - (3)].str)); + ralloc_free ((yyvsp[(2) - (3)].str)); ;} break; case 14: -/* Line 1464 of yacc.c */ -#line 233 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 226 "glcpp/glcpp-parse.y" { /* Be careful to only evaluate the 'if' expression if * we are not skipping. When we are skipping, we @@ -1912,8 +1897,8 @@ yyreduce: case 15: -/* Line 1464 of yacc.c */ -#line 252 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 245 "glcpp/glcpp-parse.y" { /* #if without an expression is only an error if we * are not skipping */ @@ -1928,30 +1913,30 @@ yyreduce: case 16: -/* Line 1464 of yacc.c */ -#line 262 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 255 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, (yyvsp[(2) - (4)].str)); - talloc_free ((yyvsp[(2) - (4)].str)); + ralloc_free ((yyvsp[(2) - (4)].str)); _glcpp_parser_skip_stack_push_if (parser, & (yylsp[(1) - (4)]), macro != NULL); ;} break; case 17: -/* Line 1464 of yacc.c */ -#line 267 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 260 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, (yyvsp[(2) - (4)].str)); - talloc_free ((yyvsp[(2) - (4)].str)); + ralloc_free ((yyvsp[(2) - (4)].str)); _glcpp_parser_skip_stack_push_if (parser, & (yylsp[(1) - (4)]), macro == NULL); ;} break; case 18: -/* Line 1464 of yacc.c */ -#line 272 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 265 "glcpp/glcpp-parse.y" { /* Be careful to only evaluate the 'elif' expression * if we are not skipping. When we are skipping, we @@ -1975,8 +1960,8 @@ yyreduce: case 19: -/* Line 1464 of yacc.c */ -#line 291 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 284 "glcpp/glcpp-parse.y" { /* #elif without an expression is an error unless we * are skipping. */ @@ -1996,8 +1981,8 @@ yyreduce: case 20: -/* Line 1464 of yacc.c */ -#line 306 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 299 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_change_if (parser, & (yylsp[(1) - (2)]), "else", 1); ;} @@ -2005,8 +1990,8 @@ yyreduce: case 21: -/* Line 1464 of yacc.c */ -#line 309 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 302 "glcpp/glcpp-parse.y" { _glcpp_parser_skip_stack_pop (parser, & (yylsp[(1) - (2)])); ;} @@ -2014,13 +1999,13 @@ yyreduce: case 22: -/* Line 1464 of yacc.c */ -#line 312 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 305 "glcpp/glcpp-parse.y" { macro_t *macro = hash_table_find (parser->defines, "__VERSION__"); if (macro) { hash_table_remove (parser->defines, "__VERSION__"); - talloc_free (macro); + ralloc_free (macro); } add_builtin_define (parser, "__VERSION__", (yyvsp[(2) - (3)].ival)); @@ -2035,14 +2020,14 @@ yyreduce: if ((yyvsp[(2) - (3)].ival) >= 130 || (yyvsp[(2) - (3)].ival) == 100) add_builtin_define (parser, "GL_FRAGMENT_PRECISION_HIGH", 1); - glcpp_printf(parser->output, "#version %" PRIiMAX, (yyvsp[(2) - (3)].ival)); + ralloc_asprintf_append (&parser->output, "#version %" PRIiMAX, (yyvsp[(2) - (3)].ival)); ;} break; case 24: -/* Line 1464 of yacc.c */ -#line 337 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 330 "glcpp/glcpp-parse.y" { if (strlen ((yyvsp[(1) - (1)].str)) >= 3 && strncmp ((yyvsp[(1) - (1)].str), "0x", 2) == 0) { (yyval.ival) = strtoll ((yyvsp[(1) - (1)].str) + 2, NULL, 16); @@ -2056,8 +2041,8 @@ yyreduce: case 25: -/* Line 1464 of yacc.c */ -#line 346 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 339 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (1)].ival); ;} @@ -2065,8 +2050,8 @@ yyreduce: case 27: -/* Line 1464 of yacc.c */ -#line 352 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 345 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) || (yyvsp[(3) - (3)].ival); ;} @@ -2074,8 +2059,8 @@ yyreduce: case 28: -/* Line 1464 of yacc.c */ -#line 355 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 348 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) && (yyvsp[(3) - (3)].ival); ;} @@ -2083,8 +2068,8 @@ yyreduce: case 29: -/* Line 1464 of yacc.c */ -#line 358 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 351 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) | (yyvsp[(3) - (3)].ival); ;} @@ -2092,8 +2077,8 @@ yyreduce: case 30: -/* Line 1464 of yacc.c */ -#line 361 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 354 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) ^ (yyvsp[(3) - (3)].ival); ;} @@ -2101,8 +2086,8 @@ yyreduce: case 31: -/* Line 1464 of yacc.c */ -#line 364 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 357 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) & (yyvsp[(3) - (3)].ival); ;} @@ -2110,8 +2095,8 @@ yyreduce: case 32: -/* Line 1464 of yacc.c */ -#line 367 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 360 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) != (yyvsp[(3) - (3)].ival); ;} @@ -2119,8 +2104,8 @@ yyreduce: case 33: -/* Line 1464 of yacc.c */ -#line 370 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 363 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) == (yyvsp[(3) - (3)].ival); ;} @@ -2128,8 +2113,8 @@ yyreduce: case 34: -/* Line 1464 of yacc.c */ -#line 373 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 366 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) >= (yyvsp[(3) - (3)].ival); ;} @@ -2137,8 +2122,8 @@ yyreduce: case 35: -/* Line 1464 of yacc.c */ -#line 376 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 369 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) <= (yyvsp[(3) - (3)].ival); ;} @@ -2146,8 +2131,8 @@ yyreduce: case 36: -/* Line 1464 of yacc.c */ -#line 379 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 372 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) > (yyvsp[(3) - (3)].ival); ;} @@ -2155,8 +2140,8 @@ yyreduce: case 37: -/* Line 1464 of yacc.c */ -#line 382 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 375 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) < (yyvsp[(3) - (3)].ival); ;} @@ -2164,8 +2149,8 @@ yyreduce: case 38: -/* Line 1464 of yacc.c */ -#line 385 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 378 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) >> (yyvsp[(3) - (3)].ival); ;} @@ -2173,8 +2158,8 @@ yyreduce: case 39: -/* Line 1464 of yacc.c */ -#line 388 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 381 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) << (yyvsp[(3) - (3)].ival); ;} @@ -2182,8 +2167,8 @@ yyreduce: case 40: -/* Line 1464 of yacc.c */ -#line 391 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 384 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) - (yyvsp[(3) - (3)].ival); ;} @@ -2191,8 +2176,8 @@ yyreduce: case 41: -/* Line 1464 of yacc.c */ -#line 394 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 387 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) + (yyvsp[(3) - (3)].ival); ;} @@ -2200,26 +2185,36 @@ yyreduce: case 42: -/* Line 1464 of yacc.c */ -#line 397 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 390 "glcpp/glcpp-parse.y" { - (yyval.ival) = (yyvsp[(1) - (3)].ival) % (yyvsp[(3) - (3)].ival); + if ((yyvsp[(3) - (3)].ival) == 0) { + yyerror (& (yylsp[(1) - (3)]), parser, + "zero modulus in preprocessor directive"); + } else { + (yyval.ival) = (yyvsp[(1) - (3)].ival) % (yyvsp[(3) - (3)].ival); + } ;} break; case 43: -/* Line 1464 of yacc.c */ -#line 400 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 398 "glcpp/glcpp-parse.y" { - (yyval.ival) = (yyvsp[(1) - (3)].ival) / (yyvsp[(3) - (3)].ival); + if ((yyvsp[(3) - (3)].ival) == 0) { + yyerror (& (yylsp[(1) - (3)]), parser, + "division by 0 in preprocessor directive"); + } else { + (yyval.ival) = (yyvsp[(1) - (3)].ival) / (yyvsp[(3) - (3)].ival); + } ;} break; case 44: -/* Line 1464 of yacc.c */ -#line 403 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 406 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(1) - (3)].ival) * (yyvsp[(3) - (3)].ival); ;} @@ -2227,8 +2222,8 @@ yyreduce: case 45: -/* Line 1464 of yacc.c */ -#line 406 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 409 "glcpp/glcpp-parse.y" { (yyval.ival) = ! (yyvsp[(2) - (2)].ival); ;} @@ -2236,8 +2231,8 @@ yyreduce: case 46: -/* Line 1464 of yacc.c */ -#line 409 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 412 "glcpp/glcpp-parse.y" { (yyval.ival) = ~ (yyvsp[(2) - (2)].ival); ;} @@ -2245,8 +2240,8 @@ yyreduce: case 47: -/* Line 1464 of yacc.c */ -#line 412 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 415 "glcpp/glcpp-parse.y" { (yyval.ival) = - (yyvsp[(2) - (2)].ival); ;} @@ -2254,8 +2249,8 @@ yyreduce: case 48: -/* Line 1464 of yacc.c */ -#line 415 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 418 "glcpp/glcpp-parse.y" { (yyval.ival) = + (yyvsp[(2) - (2)].ival); ;} @@ -2263,8 +2258,8 @@ yyreduce: case 49: -/* Line 1464 of yacc.c */ -#line 418 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 421 "glcpp/glcpp-parse.y" { (yyval.ival) = (yyvsp[(2) - (3)].ival); ;} @@ -2272,37 +2267,37 @@ yyreduce: case 50: -/* Line 1464 of yacc.c */ -#line 424 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 427 "glcpp/glcpp-parse.y" { (yyval.string_list) = _string_list_create (parser); _string_list_append_item ((yyval.string_list), (yyvsp[(1) - (1)].str)); - talloc_steal ((yyval.string_list), (yyvsp[(1) - (1)].str)); + ralloc_steal ((yyval.string_list), (yyvsp[(1) - (1)].str)); ;} break; case 51: -/* Line 1464 of yacc.c */ -#line 429 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 432 "glcpp/glcpp-parse.y" { (yyval.string_list) = (yyvsp[(1) - (3)].string_list); _string_list_append_item ((yyval.string_list), (yyvsp[(3) - (3)].str)); - talloc_steal ((yyval.string_list), (yyvsp[(3) - (3)].str)); + ralloc_steal ((yyval.string_list), (yyvsp[(3) - (3)].str)); ;} break; case 52: -/* Line 1464 of yacc.c */ -#line 437 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 440 "glcpp/glcpp-parse.y" { (yyval.token_list) = NULL; ;} break; case 54: -/* Line 1464 of yacc.c */ -#line 442 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 445 "glcpp/glcpp-parse.y" { yyerror (& (yylsp[(1) - (2)]), parser, "Invalid tokens after #"); ;} @@ -2310,15 +2305,15 @@ yyreduce: case 55: -/* Line 1464 of yacc.c */ -#line 448 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 451 "glcpp/glcpp-parse.y" { (yyval.token_list) = NULL; ;} break; case 58: -/* Line 1464 of yacc.c */ -#line 454 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 457 "glcpp/glcpp-parse.y" { glcpp_warning(&(yylsp[(1) - (1)]), parser, "extra tokens at end of directive"); ;} @@ -2326,8 +2321,8 @@ yyreduce: case 59: -/* Line 1464 of yacc.c */ -#line 461 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 464 "glcpp/glcpp-parse.y" { int v = hash_table_find (parser->defines, (yyvsp[(2) - (2)].str)) ? 1 : 0; (yyval.token) = _token_create_ival (parser, INTEGER, v); @@ -2336,8 +2331,8 @@ yyreduce: case 60: -/* Line 1464 of yacc.c */ -#line 465 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 468 "glcpp/glcpp-parse.y" { int v = hash_table_find (parser->defines, (yyvsp[(3) - (4)].str)) ? 1 : 0; (yyval.token) = _token_create_ival (parser, INTEGER, v); @@ -2346,53 +2341,49 @@ yyreduce: case 62: -/* Line 1464 of yacc.c */ -#line 474 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 477 "glcpp/glcpp-parse.y" { (yyval.token_list) = _token_list_create (parser); _token_list_append ((yyval.token_list), (yyvsp[(1) - (1)].token)); - talloc_unlink (parser, (yyvsp[(1) - (1)].token)); ;} break; case 63: -/* Line 1464 of yacc.c */ -#line 479 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 481 "glcpp/glcpp-parse.y" { (yyval.token_list) = (yyvsp[(1) - (2)].token_list); _token_list_append ((yyval.token_list), (yyvsp[(2) - (2)].token)); - talloc_unlink (parser, (yyvsp[(2) - (2)].token)); ;} break; case 64: -/* Line 1464 of yacc.c */ -#line 487 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 488 "glcpp/glcpp-parse.y" { parser->space_tokens = 1; (yyval.token_list) = _token_list_create (parser); _token_list_append ((yyval.token_list), (yyvsp[(1) - (1)].token)); - talloc_unlink (parser, (yyvsp[(1) - (1)].token)); ;} break; case 65: -/* Line 1464 of yacc.c */ +/* Line 1455 of yacc.c */ #line 493 "glcpp/glcpp-parse.y" { (yyval.token_list) = (yyvsp[(1) - (2)].token_list); _token_list_append ((yyval.token_list), (yyvsp[(2) - (2)].token)); - talloc_unlink (parser, (yyvsp[(2) - (2)].token)); ;} break; case 66: -/* Line 1464 of yacc.c */ -#line 501 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 500 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_str (parser, IDENTIFIER, (yyvsp[(1) - (1)].str)); (yyval.token)->location = yylloc; @@ -2401,8 +2392,8 @@ yyreduce: case 67: -/* Line 1464 of yacc.c */ -#line 505 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 504 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_str (parser, INTEGER_STRING, (yyvsp[(1) - (1)].str)); (yyval.token)->location = yylloc; @@ -2411,8 +2402,8 @@ yyreduce: case 68: -/* Line 1464 of yacc.c */ -#line 509 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 508 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_ival (parser, (yyvsp[(1) - (1)].ival), (yyvsp[(1) - (1)].ival)); (yyval.token)->location = yylloc; @@ -2421,8 +2412,8 @@ yyreduce: case 69: -/* Line 1464 of yacc.c */ -#line 513 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 512 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_str (parser, OTHER, (yyvsp[(1) - (1)].str)); (yyval.token)->location = yylloc; @@ -2431,8 +2422,8 @@ yyreduce: case 70: -/* Line 1464 of yacc.c */ -#line 517 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 516 "glcpp/glcpp-parse.y" { (yyval.token) = _token_create_ival (parser, SPACE, SPACE); (yyval.token)->location = yylloc; @@ -2441,225 +2432,225 @@ yyreduce: case 71: -/* Line 1464 of yacc.c */ -#line 524 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 523 "glcpp/glcpp-parse.y" { (yyval.ival) = '['; ;} break; case 72: -/* Line 1464 of yacc.c */ -#line 525 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 524 "glcpp/glcpp-parse.y" { (yyval.ival) = ']'; ;} break; case 73: -/* Line 1464 of yacc.c */ -#line 526 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 525 "glcpp/glcpp-parse.y" { (yyval.ival) = '('; ;} break; case 74: -/* Line 1464 of yacc.c */ -#line 527 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 526 "glcpp/glcpp-parse.y" { (yyval.ival) = ')'; ;} break; case 75: -/* Line 1464 of yacc.c */ -#line 528 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 527 "glcpp/glcpp-parse.y" { (yyval.ival) = '{'; ;} break; case 76: -/* Line 1464 of yacc.c */ -#line 529 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 528 "glcpp/glcpp-parse.y" { (yyval.ival) = '}'; ;} break; case 77: -/* Line 1464 of yacc.c */ -#line 530 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 529 "glcpp/glcpp-parse.y" { (yyval.ival) = '.'; ;} break; case 78: -/* Line 1464 of yacc.c */ -#line 531 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 530 "glcpp/glcpp-parse.y" { (yyval.ival) = '&'; ;} break; case 79: -/* Line 1464 of yacc.c */ -#line 532 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 531 "glcpp/glcpp-parse.y" { (yyval.ival) = '*'; ;} break; case 80: -/* Line 1464 of yacc.c */ -#line 533 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 532 "glcpp/glcpp-parse.y" { (yyval.ival) = '+'; ;} break; case 81: -/* Line 1464 of yacc.c */ -#line 534 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 533 "glcpp/glcpp-parse.y" { (yyval.ival) = '-'; ;} break; case 82: -/* Line 1464 of yacc.c */ -#line 535 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 534 "glcpp/glcpp-parse.y" { (yyval.ival) = '~'; ;} break; case 83: -/* Line 1464 of yacc.c */ -#line 536 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 535 "glcpp/glcpp-parse.y" { (yyval.ival) = '!'; ;} break; case 84: -/* Line 1464 of yacc.c */ -#line 537 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 536 "glcpp/glcpp-parse.y" { (yyval.ival) = '/'; ;} break; case 85: -/* Line 1464 of yacc.c */ -#line 538 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 537 "glcpp/glcpp-parse.y" { (yyval.ival) = '%'; ;} break; case 86: -/* Line 1464 of yacc.c */ -#line 539 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 538 "glcpp/glcpp-parse.y" { (yyval.ival) = LEFT_SHIFT; ;} break; case 87: -/* Line 1464 of yacc.c */ -#line 540 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 539 "glcpp/glcpp-parse.y" { (yyval.ival) = RIGHT_SHIFT; ;} break; case 88: -/* Line 1464 of yacc.c */ -#line 541 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 540 "glcpp/glcpp-parse.y" { (yyval.ival) = '<'; ;} break; case 89: -/* Line 1464 of yacc.c */ -#line 542 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 541 "glcpp/glcpp-parse.y" { (yyval.ival) = '>'; ;} break; case 90: -/* Line 1464 of yacc.c */ -#line 543 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 542 "glcpp/glcpp-parse.y" { (yyval.ival) = LESS_OR_EQUAL; ;} break; case 91: -/* Line 1464 of yacc.c */ -#line 544 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 543 "glcpp/glcpp-parse.y" { (yyval.ival) = GREATER_OR_EQUAL; ;} break; case 92: -/* Line 1464 of yacc.c */ -#line 545 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 544 "glcpp/glcpp-parse.y" { (yyval.ival) = EQUAL; ;} break; case 93: -/* Line 1464 of yacc.c */ -#line 546 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 545 "glcpp/glcpp-parse.y" { (yyval.ival) = NOT_EQUAL; ;} break; case 94: -/* Line 1464 of yacc.c */ -#line 547 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 546 "glcpp/glcpp-parse.y" { (yyval.ival) = '^'; ;} break; case 95: -/* Line 1464 of yacc.c */ -#line 548 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 547 "glcpp/glcpp-parse.y" { (yyval.ival) = '|'; ;} break; case 96: -/* Line 1464 of yacc.c */ -#line 549 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 548 "glcpp/glcpp-parse.y" { (yyval.ival) = AND; ;} break; case 97: -/* Line 1464 of yacc.c */ -#line 550 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 549 "glcpp/glcpp-parse.y" { (yyval.ival) = OR; ;} break; case 98: -/* Line 1464 of yacc.c */ -#line 551 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 550 "glcpp/glcpp-parse.y" { (yyval.ival) = ';'; ;} break; case 99: -/* Line 1464 of yacc.c */ -#line 552 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 551 "glcpp/glcpp-parse.y" { (yyval.ival) = ','; ;} break; case 100: -/* Line 1464 of yacc.c */ -#line 553 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 552 "glcpp/glcpp-parse.y" { (yyval.ival) = '='; ;} break; case 101: -/* Line 1464 of yacc.c */ -#line 554 "glcpp/glcpp-parse.y" +/* Line 1455 of yacc.c */ +#line 553 "glcpp/glcpp-parse.y" { (yyval.ival) = PASTE; ;} break; -/* Line 1464 of yacc.c */ -#line 2663 "glcpp/glcpp-parse.c" +/* Line 1455 of yacc.c */ +#line 2654 "glcpp/glcpp-parse.c" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -2731,7 +2722,7 @@ yyerrlab: #endif } - yyerror_range[1] = yylloc; + yyerror_range[0] = yylloc; if (yyerrstatus == 3) { @@ -2768,7 +2759,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); @@ -2802,7 +2793,7 @@ yyerrlab1: if (yyssp == yyss) YYABORT; - yyerror_range[1] = *yylsp; + yyerror_range[0] = *yylsp; yydestruct ("Error: popping", yystos[yystate], yyvsp, yylsp, parser); YYPOPSTACK (1); @@ -2812,10 +2803,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. */ @@ -2877,8 +2868,8 @@ yyreturn: -/* Line 1684 of yacc.c */ -#line 557 "glcpp/glcpp-parse.y" +/* Line 1675 of yacc.c */ +#line 556 "glcpp/glcpp-parse.y" string_list_t * @@ -2886,7 +2877,7 @@ _string_list_create (void *ctx) { string_list_t *list; - list = talloc (ctx, string_list_t); + list = ralloc (ctx, string_list_t); list->head = NULL; list->tail = NULL; @@ -2898,8 +2889,8 @@ _string_list_append_item (string_list_t *list, const char *str) { string_node_t *node; - node = talloc (list, string_node_t); - node->str = talloc_strdup (node, str); + node = ralloc (list, string_node_t); + node->str = ralloc_strdup (node, str); node->next = NULL; @@ -2977,7 +2968,7 @@ _argument_list_create (void *ctx) { argument_list_t *list; - list = talloc (ctx, argument_list_t); + list = ralloc (ctx, argument_list_t); list->head = NULL; list->tail = NULL; @@ -2989,7 +2980,7 @@ _argument_list_append (argument_list_t *list, token_list_t *argument) { argument_node_t *node; - node = talloc (list, argument_node_t); + node = ralloc (list, argument_node_t); node->argument = argument; node->next = NULL; @@ -3040,15 +3031,17 @@ _argument_list_member_at (argument_list_t *list, int index) return NULL; } -/* Note: This function talloc_steal()s the str pointer. */ +/* Note: This function ralloc_steal()s the str pointer. */ token_t * _token_create_str (void *ctx, int type, char *str) { token_t *token; - token = talloc (ctx, token_t); + token = ralloc (ctx, token_t); token->type = type; - token->value.str = talloc_steal (token, str); + token->value.str = str; + + ralloc_steal (token, str); return token; } @@ -3058,7 +3051,7 @@ _token_create_ival (void *ctx, int type, int ival) { token_t *token; - token = talloc (ctx, token_t); + token = ralloc (ctx, token_t); token->type = type; token->value.ival = ival; @@ -3070,7 +3063,7 @@ _token_list_create (void *ctx) { token_list_t *list; - list = talloc (ctx, token_list_t); + list = ralloc (ctx, token_list_t); list->head = NULL; list->tail = NULL; list->non_space_tail = NULL; @@ -3083,11 +3076,12 @@ _token_list_append (token_list_t *list, token_t *token) { token_node_t *node; - node = talloc (list, token_node_t); - node->token = talloc_reference (list, token); - + node = ralloc (list, token_node_t); + node->token = token; node->next = NULL; + ralloc_steal (list, token); + if (list->head == NULL) { list->head = node; } else { @@ -3125,8 +3119,11 @@ _token_list_copy (void *ctx, token_list_t *other) return NULL; copy = _token_list_create (ctx); - for (node = other->head; node; node = node->next) - _token_list_append (copy, node->token); + for (node = other->head; node; node = node->next) { + token_t *new_token = ralloc (copy, token_t); + *new_token = *node->token; + _token_list_append (copy, new_token); + } return copy; } @@ -3143,17 +3140,38 @@ _token_list_trim_trailing_space (token_list_t *list) while (tail) { next = tail->next; - talloc_free (tail); + ralloc_free (tail); tail = next; } } } +static int +_token_list_is_empty_ignoring_space (token_list_t *l) +{ + token_node_t *n; + + if (l == NULL) + return 1; + + n = l->head; + while (n != NULL && n->token->type == SPACE) + n = n->next; + + return n == NULL; +} + int _token_list_equal_ignoring_space (token_list_t *a, token_list_t *b) { token_node_t *node_a, *node_b; + if (a == NULL || b == NULL) { + int a_empty = _token_list_is_empty_ignoring_space(a); + int b_empty = _token_list_is_empty_ignoring_space(b); + return a_empty == b_empty; + } + node_a = a->head; node_b = b->head; @@ -3208,51 +3226,51 @@ static void _token_print (char **out, token_t *token) { if (token->type < 256) { - glcpp_printf (*out, "%c", token->type); + ralloc_asprintf_append (out, "%c", token->type); return; } switch (token->type) { case INTEGER: - glcpp_printf (*out, "%" PRIiMAX, token->value.ival); + ralloc_asprintf_append (out, "%" PRIiMAX, token->value.ival); break; case IDENTIFIER: case INTEGER_STRING: case OTHER: - glcpp_print (*out, token->value.str); + ralloc_strcat (out, token->value.str); break; case SPACE: - glcpp_print (*out, " "); + ralloc_strcat (out, " "); break; case LEFT_SHIFT: - glcpp_print (*out, "<<"); + ralloc_strcat (out, "<<"); break; case RIGHT_SHIFT: - glcpp_print (*out, ">>"); + ralloc_strcat (out, ">>"); break; case LESS_OR_EQUAL: - glcpp_print (*out, "<="); + ralloc_strcat (out, "<="); break; case GREATER_OR_EQUAL: - glcpp_print (*out, ">="); + ralloc_strcat (out, ">="); break; case EQUAL: - glcpp_print (*out, "=="); + ralloc_strcat (out, "=="); break; case NOT_EQUAL: - glcpp_print (*out, "!="); + ralloc_strcat (out, "!="); break; case AND: - glcpp_print (*out, "&&"); + ralloc_strcat (out, "&&"); break; case OR: - glcpp_print (*out, "||"); + ralloc_strcat (out, "||"); break; case PASTE: - glcpp_print (*out, "##"); + ralloc_strcat (out, "##"); break; case COMMA_FINAL: - glcpp_print (*out, ","); + ralloc_strcat (out, ","); break; case PLACEHOLDER: /* Nothing to print. */ @@ -3263,7 +3281,7 @@ _token_print (char **out, token_t *token) } } -/* Return a new token (talloc()ed off of 'token') formed by pasting +/* Return a new token (ralloc()ed off of 'token') formed by pasting * 'token' and 'other'. Note that this function may return 'token' or * 'other' directly rather than allocating anything new. * @@ -3334,7 +3352,7 @@ _token_paste (glcpp_parser_t *parser, token_t *token, token_t *other) { char *str; - str = talloc_asprintf (token, "%s%s", token->value.str, + str = ralloc_asprintf (token, "%s%s", token->value.str, other->value.str); combined = _token_create_str (token, token->type, str); combined->location = token->location; @@ -3342,11 +3360,11 @@ _token_paste (glcpp_parser_t *parser, token_t *token, token_t *other) } glcpp_error (&token->location, parser, ""); - glcpp_print (parser->info_log, "Pasting \""); + ralloc_strcat (&parser->info_log, "Pasting \""); _token_print (&parser->info_log, token); - glcpp_print (parser->info_log, "\" and \""); + ralloc_strcat (&parser->info_log, "\" and \""); _token_print (&parser->info_log, other); - glcpp_print (parser->info_log, "\" does not give a valid preprocessing token.\n"); + ralloc_strcat (&parser->info_log, "\" does not give a valid preprocessing token.\n"); return token; } @@ -3380,8 +3398,6 @@ static void add_builtin_define(glcpp_parser_t *parser, list = _token_list_create(parser); _token_list_append(list, tok); _define_object_macro(parser, NULL, name, list); - - talloc_unlink(parser, tok); } glcpp_parser_t * @@ -3390,7 +3406,7 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) glcpp_parser_t *parser; int language_version; - parser = talloc (NULL, glcpp_parser_t); + parser = ralloc (NULL, glcpp_parser_t); glcpp_lex_init_extra (parser, &parser->scanner); parser->defines = hash_table_ctor (32, hash_table_string_hash, @@ -3407,8 +3423,8 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) parser->lex_from_list = NULL; parser->lex_from_node = NULL; - parser->output = talloc_strdup(parser, ""); - parser->info_log = talloc_strdup(parser, ""); + parser->output = ralloc_strdup(parser, ""); + parser->info_log = ralloc_strdup(parser, ""); parser->error = 0; /* Add pre-defined macros. */ @@ -3429,6 +3445,8 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) if (extensions->ARB_explicit_attrib_location) add_builtin_define(parser, "GL_ARB_explicit_attrib_location", 1); + if (extensions->AMD_conservative_depth) + add_builtin_define(parser, "GL_AMD_conservative_depth", 1); } language_version = 110; @@ -3448,7 +3466,7 @@ glcpp_parser_destroy (glcpp_parser_t *parser) { glcpp_lex_destroy (parser->scanner); hash_table_dtor (parser->defines); - talloc_free (parser); + ralloc_free (parser); } typedef enum function_status @@ -3619,7 +3637,7 @@ _glcpp_parser_expand_function (glcpp_parser_t *parser, /* Replace a macro defined as empty with a SPACE token. */ if (macro->replacements == NULL) { - talloc_free (arguments); + ralloc_free (arguments); return _token_list_create_with_one_space (parser); } @@ -3775,7 +3793,7 @@ _glcpp_parser_expand_node (glcpp_parser_t *parser, token_list_t *expansion; token_t *final; - str = talloc_strdup (parser, token->value.str); + str = ralloc_strdup (parser, token->value.str); final = _token_create_str (parser, OTHER, str); expansion = _token_list_create (parser); _token_list_append (expansion, final); @@ -3811,8 +3829,8 @@ _active_list_push (active_list_t *list, { active_list_t *node; - node = talloc (list, active_list_t); - node->identifier = talloc_strdup (node, identifier); + node = ralloc (list, active_list_t); + node->identifier = ralloc_strdup (node, identifier); node->marker = marker; node->next = list; @@ -3828,7 +3846,7 @@ _active_list_pop (active_list_t *list) return NULL; node = list->next; - talloc_free (list); + ralloc_free (list); return node; } @@ -3977,17 +3995,18 @@ _define_object_macro (glcpp_parser_t *parser, if (loc != NULL) _check_for_reserved_macro_name(parser, loc, identifier); - macro = talloc (parser, macro_t); + macro = ralloc (parser, macro_t); macro->is_function = 0; macro->parameters = NULL; - macro->identifier = talloc_strdup (macro, identifier); - macro->replacements = talloc_steal (macro, replacements); + macro->identifier = ralloc_strdup (macro, identifier); + macro->replacements = replacements; + ralloc_steal (macro, replacements); previous = hash_table_find (parser->defines, identifier); if (previous) { if (_macro_equal (macro, previous)) { - talloc_free (macro); + ralloc_free (macro); return; } glcpp_error (loc, parser, "Redefinition of macro %s\n", @@ -4008,17 +4027,18 @@ _define_function_macro (glcpp_parser_t *parser, _check_for_reserved_macro_name(parser, loc, identifier); - macro = talloc (parser, macro_t); + macro = ralloc (parser, macro_t); + ralloc_steal (macro, parameters); + ralloc_steal (macro, replacements); macro->is_function = 1; - macro->parameters = talloc_steal (macro, parameters); - macro->identifier = talloc_strdup (macro, identifier); - macro->replacements = talloc_steal (macro, replacements); - + macro->parameters = parameters; + macro->identifier = ralloc_strdup (macro, identifier); + macro->replacements = replacements; previous = hash_table_find (parser->defines, identifier); if (previous) { if (_macro_equal (macro, previous)) { - talloc_free (macro); + ralloc_free (macro); return; } glcpp_error (loc, parser, "Redefinition of macro %s\n", @@ -4094,7 +4114,7 @@ glcpp_parser_lex (YYSTYPE *yylval, YYLTYPE *yylloc, glcpp_parser_t *parser) node = parser->lex_from_node; if (node == NULL) { - talloc_free (parser->lex_from_list); + ralloc_free (parser->lex_from_list); parser->lex_from_list = NULL; return NEWLINE; } @@ -4123,13 +4143,13 @@ glcpp_parser_lex_from (glcpp_parser_t *parser, token_list_t *list) _token_list_append (parser->lex_from_list, node->token); } - talloc_free (list); + ralloc_free (list); parser->lex_from_node = parser->lex_from_list->head; /* It's possible the list consisted of nothing but whitespace. */ if (parser->lex_from_node == NULL) { - talloc_free (parser->lex_from_list); + ralloc_free (parser->lex_from_list); parser->lex_from_list = NULL; } } @@ -4144,7 +4164,7 @@ _glcpp_parser_skip_stack_push_if (glcpp_parser_t *parser, YYLTYPE *loc, if (parser->skip_stack) current = parser->skip_stack->type; - node = talloc (parser, skip_node_t); + node = ralloc (parser, skip_node_t); node->loc = *loc; if (current == SKIP_NO_SKIP) { @@ -4189,6 +4209,6 @@ _glcpp_parser_skip_stack_pop (glcpp_parser_t *parser, YYLTYPE *loc) node = parser->skip_stack; parser->skip_stack = node->next; - talloc_free (node); + ralloc_free (node); } 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 558ad0acac..1f6e67fa06 100644 --- a/src/glsl/glcpp/glcpp-parse.y +++ b/src/glsl/glcpp/glcpp-parse.y @@ -32,10 +32,6 @@ #include "main/core.h" /* for struct gl_extensions */ #include "main/mtypes.h" /* for gl_api enum */ -#define glcpp_print(stream, str) stream = talloc_strdup_append(stream, str) -#define glcpp_printf(stream, fmt, args, ...) \ - stream = talloc_asprintf_append(stream, fmt, args) - static void yyerror (YYLTYPE *locp, glcpp_parser_t *parser, const char *error); @@ -79,7 +75,7 @@ _argument_list_length (argument_list_t *list); static token_list_t * _argument_list_member_at (argument_list_t *list, int index); -/* Note: This function talloc_steal()s the str pointer. */ +/* Note: This function ralloc_steal()s the str pointer. */ static token_t * _token_create_str (void *ctx, int type, char *str); @@ -89,10 +85,7 @@ _token_create_ival (void *ctx, int type, int ival); static token_list_t * _token_list_create (void *ctx); -/* Note: This function adds a talloc_reference() to token. - * - * You may want to talloc_unlink any current reference if you no - * longer need it. */ +/* Note: This function calls ralloc_steal on token. */ static void _token_list_append (token_list_t *list, token_t *token); @@ -192,12 +185,12 @@ input: line: control_line { - glcpp_print(parser->output, "\n"); + ralloc_strcat (&parser->output, "\n"); } | text_line { _glcpp_parser_print_expanded_token_list (parser, $1); - glcpp_print(parser->output, "\n"); - talloc_free ($1); + ralloc_strcat (&parser->output, "\n"); + ralloc_free ($1); } | expanded_line | HASH non_directive @@ -226,9 +219,9 @@ control_line: macro_t *macro = hash_table_find (parser->defines, $2); if (macro) { hash_table_remove (parser->defines, $2); - talloc_free (macro); + ralloc_free (macro); } - talloc_free ($2); + ralloc_free ($2); } | HASH_IF conditional_tokens NEWLINE { /* Be careful to only evaluate the 'if' expression if @@ -261,12 +254,12 @@ control_line: } | HASH_IFDEF IDENTIFIER junk NEWLINE { macro_t *macro = hash_table_find (parser->defines, $2); - talloc_free ($2); + ralloc_free ($2); _glcpp_parser_skip_stack_push_if (parser, & @1, macro != NULL); } | HASH_IFNDEF IDENTIFIER junk NEWLINE { macro_t *macro = hash_table_find (parser->defines, $2); - talloc_free ($2); + ralloc_free ($2); _glcpp_parser_skip_stack_push_if (parser, & @1, macro == NULL); } | HASH_ELIF conditional_tokens NEWLINE { @@ -313,7 +306,7 @@ control_line: macro_t *macro = hash_table_find (parser->defines, "__VERSION__"); if (macro) { hash_table_remove (parser->defines, "__VERSION__"); - talloc_free (macro); + ralloc_free (macro); } add_builtin_define (parser, "__VERSION__", $2); @@ -328,7 +321,7 @@ control_line: if ($2 >= 130 || $2 == 100) add_builtin_define (parser, "GL_FRAGMENT_PRECISION_HIGH", 1); - glcpp_printf(parser->output, "#version %" PRIiMAX, $2); + ralloc_asprintf_append (&parser->output, "#version %" PRIiMAX, $2); } | HASH NEWLINE ; @@ -395,10 +388,20 @@ expression: $$ = $1 + $3; } | expression '%' expression { - $$ = $1 % $3; + if ($3 == 0) { + yyerror (& @1, parser, + "zero modulus in preprocessor directive"); + } else { + $$ = $1 % $3; + } } | expression '/' expression { - $$ = $1 / $3; + if ($3 == 0) { + yyerror (& @1, parser, + "division by 0 in preprocessor directive"); + } else { + $$ = $1 / $3; + } } | expression '*' expression { $$ = $1 * $3; @@ -424,12 +427,12 @@ identifier_list: IDENTIFIER { $$ = _string_list_create (parser); _string_list_append_item ($$, $1); - talloc_steal ($$, $1); + ralloc_steal ($$, $1); } | identifier_list ',' IDENTIFIER { $$ = $1; _string_list_append_item ($$, $3); - talloc_steal ($$, $3); + ralloc_steal ($$, $3); } ; @@ -474,12 +477,10 @@ conditional_tokens: conditional_token { $$ = _token_list_create (parser); _token_list_append ($$, $1); - talloc_unlink (parser, $1); } | conditional_tokens conditional_token { $$ = $1; _token_list_append ($$, $2); - talloc_unlink (parser, $2); } ; @@ -488,12 +489,10 @@ pp_tokens: parser->space_tokens = 1; $$ = _token_list_create (parser); _token_list_append ($$, $1); - talloc_unlink (parser, $1); } | pp_tokens preprocessing_token { $$ = $1; _token_list_append ($$, $2); - talloc_unlink (parser, $2); } ; @@ -561,7 +560,7 @@ _string_list_create (void *ctx) { string_list_t *list; - list = talloc (ctx, string_list_t); + list = ralloc (ctx, string_list_t); list->head = NULL; list->tail = NULL; @@ -573,8 +572,8 @@ _string_list_append_item (string_list_t *list, const char *str) { string_node_t *node; - node = talloc (list, string_node_t); - node->str = talloc_strdup (node, str); + node = ralloc (list, string_node_t); + node->str = ralloc_strdup (node, str); node->next = NULL; @@ -652,7 +651,7 @@ _argument_list_create (void *ctx) { argument_list_t *list; - list = talloc (ctx, argument_list_t); + list = ralloc (ctx, argument_list_t); list->head = NULL; list->tail = NULL; @@ -664,7 +663,7 @@ _argument_list_append (argument_list_t *list, token_list_t *argument) { argument_node_t *node; - node = talloc (list, argument_node_t); + node = ralloc (list, argument_node_t); node->argument = argument; node->next = NULL; @@ -715,15 +714,17 @@ _argument_list_member_at (argument_list_t *list, int index) return NULL; } -/* Note: This function talloc_steal()s the str pointer. */ +/* Note: This function ralloc_steal()s the str pointer. */ token_t * _token_create_str (void *ctx, int type, char *str) { token_t *token; - token = talloc (ctx, token_t); + token = ralloc (ctx, token_t); token->type = type; - token->value.str = talloc_steal (token, str); + token->value.str = str; + + ralloc_steal (token, str); return token; } @@ -733,7 +734,7 @@ _token_create_ival (void *ctx, int type, int ival) { token_t *token; - token = talloc (ctx, token_t); + token = ralloc (ctx, token_t); token->type = type; token->value.ival = ival; @@ -745,7 +746,7 @@ _token_list_create (void *ctx) { token_list_t *list; - list = talloc (ctx, token_list_t); + list = ralloc (ctx, token_list_t); list->head = NULL; list->tail = NULL; list->non_space_tail = NULL; @@ -758,11 +759,12 @@ _token_list_append (token_list_t *list, token_t *token) { token_node_t *node; - node = talloc (list, token_node_t); - node->token = talloc_reference (list, token); - + node = ralloc (list, token_node_t); + node->token = token; node->next = NULL; + ralloc_steal (list, token); + if (list->head == NULL) { list->head = node; } else { @@ -800,8 +802,11 @@ _token_list_copy (void *ctx, token_list_t *other) return NULL; copy = _token_list_create (ctx); - for (node = other->head; node; node = node->next) - _token_list_append (copy, node->token); + for (node = other->head; node; node = node->next) { + token_t *new_token = ralloc (copy, token_t); + *new_token = *node->token; + _token_list_append (copy, new_token); + } return copy; } @@ -818,17 +823,38 @@ _token_list_trim_trailing_space (token_list_t *list) while (tail) { next = tail->next; - talloc_free (tail); + ralloc_free (tail); tail = next; } } } +static int +_token_list_is_empty_ignoring_space (token_list_t *l) +{ + token_node_t *n; + + if (l == NULL) + return 1; + + n = l->head; + while (n != NULL && n->token->type == SPACE) + n = n->next; + + return n == NULL; +} + int _token_list_equal_ignoring_space (token_list_t *a, token_list_t *b) { token_node_t *node_a, *node_b; + if (a == NULL || b == NULL) { + int a_empty = _token_list_is_empty_ignoring_space(a); + int b_empty = _token_list_is_empty_ignoring_space(b); + return a_empty == b_empty; + } + node_a = a->head; node_b = b->head; @@ -883,51 +909,51 @@ static void _token_print (char **out, token_t *token) { if (token->type < 256) { - glcpp_printf (*out, "%c", token->type); + ralloc_asprintf_append (out, "%c", token->type); return; } switch (token->type) { case INTEGER: - glcpp_printf (*out, "%" PRIiMAX, token->value.ival); + ralloc_asprintf_append (out, "%" PRIiMAX, token->value.ival); break; case IDENTIFIER: case INTEGER_STRING: case OTHER: - glcpp_print (*out, token->value.str); + ralloc_strcat (out, token->value.str); break; case SPACE: - glcpp_print (*out, " "); + ralloc_strcat (out, " "); break; case LEFT_SHIFT: - glcpp_print (*out, "<<"); + ralloc_strcat (out, "<<"); break; case RIGHT_SHIFT: - glcpp_print (*out, ">>"); + ralloc_strcat (out, ">>"); break; case LESS_OR_EQUAL: - glcpp_print (*out, "<="); + ralloc_strcat (out, "<="); break; case GREATER_OR_EQUAL: - glcpp_print (*out, ">="); + ralloc_strcat (out, ">="); break; case EQUAL: - glcpp_print (*out, "=="); + ralloc_strcat (out, "=="); break; case NOT_EQUAL: - glcpp_print (*out, "!="); + ralloc_strcat (out, "!="); break; case AND: - glcpp_print (*out, "&&"); + ralloc_strcat (out, "&&"); break; case OR: - glcpp_print (*out, "||"); + ralloc_strcat (out, "||"); break; case PASTE: - glcpp_print (*out, "##"); + ralloc_strcat (out, "##"); break; case COMMA_FINAL: - glcpp_print (*out, ","); + ralloc_strcat (out, ","); break; case PLACEHOLDER: /* Nothing to print. */ @@ -938,7 +964,7 @@ _token_print (char **out, token_t *token) } } -/* Return a new token (talloc()ed off of 'token') formed by pasting +/* Return a new token (ralloc()ed off of 'token') formed by pasting * 'token' and 'other'. Note that this function may return 'token' or * 'other' directly rather than allocating anything new. * @@ -1009,7 +1035,7 @@ _token_paste (glcpp_parser_t *parser, token_t *token, token_t *other) { char *str; - str = talloc_asprintf (token, "%s%s", token->value.str, + str = ralloc_asprintf (token, "%s%s", token->value.str, other->value.str); combined = _token_create_str (token, token->type, str); combined->location = token->location; @@ -1017,11 +1043,11 @@ _token_paste (glcpp_parser_t *parser, token_t *token, token_t *other) } glcpp_error (&token->location, parser, ""); - glcpp_print (parser->info_log, "Pasting \""); + ralloc_strcat (&parser->info_log, "Pasting \""); _token_print (&parser->info_log, token); - glcpp_print (parser->info_log, "\" and \""); + ralloc_strcat (&parser->info_log, "\" and \""); _token_print (&parser->info_log, other); - glcpp_print (parser->info_log, "\" does not give a valid preprocessing token.\n"); + ralloc_strcat (&parser->info_log, "\" does not give a valid preprocessing token.\n"); return token; } @@ -1055,8 +1081,6 @@ static void add_builtin_define(glcpp_parser_t *parser, list = _token_list_create(parser); _token_list_append(list, tok); _define_object_macro(parser, NULL, name, list); - - talloc_unlink(parser, tok); } glcpp_parser_t * @@ -1065,7 +1089,7 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) glcpp_parser_t *parser; int language_version; - parser = talloc (NULL, glcpp_parser_t); + parser = ralloc (NULL, glcpp_parser_t); glcpp_lex_init_extra (parser, &parser->scanner); parser->defines = hash_table_ctor (32, hash_table_string_hash, @@ -1082,8 +1106,8 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) parser->lex_from_list = NULL; parser->lex_from_node = NULL; - parser->output = talloc_strdup(parser, ""); - parser->info_log = talloc_strdup(parser, ""); + parser->output = ralloc_strdup(parser, ""); + parser->info_log = ralloc_strdup(parser, ""); parser->error = 0; /* Add pre-defined macros. */ @@ -1104,6 +1128,8 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) if (extensions->ARB_explicit_attrib_location) add_builtin_define(parser, "GL_ARB_explicit_attrib_location", 1); + if (extensions->AMD_conservative_depth) + add_builtin_define(parser, "GL_AMD_conservative_depth", 1); } language_version = 110; @@ -1123,7 +1149,7 @@ glcpp_parser_destroy (glcpp_parser_t *parser) { glcpp_lex_destroy (parser->scanner); hash_table_dtor (parser->defines); - talloc_free (parser); + ralloc_free (parser); } typedef enum function_status @@ -1294,7 +1320,7 @@ _glcpp_parser_expand_function (glcpp_parser_t *parser, /* Replace a macro defined as empty with a SPACE token. */ if (macro->replacements == NULL) { - talloc_free (arguments); + ralloc_free (arguments); return _token_list_create_with_one_space (parser); } @@ -1450,7 +1476,7 @@ _glcpp_parser_expand_node (glcpp_parser_t *parser, token_list_t *expansion; token_t *final; - str = talloc_strdup (parser, token->value.str); + str = ralloc_strdup (parser, token->value.str); final = _token_create_str (parser, OTHER, str); expansion = _token_list_create (parser); _token_list_append (expansion, final); @@ -1486,8 +1512,8 @@ _active_list_push (active_list_t *list, { active_list_t *node; - node = talloc (list, active_list_t); - node->identifier = talloc_strdup (node, identifier); + node = ralloc (list, active_list_t); + node->identifier = ralloc_strdup (node, identifier); node->marker = marker; node->next = list; @@ -1503,7 +1529,7 @@ _active_list_pop (active_list_t *list) return NULL; node = list->next; - talloc_free (list); + ralloc_free (list); return node; } @@ -1652,17 +1678,18 @@ _define_object_macro (glcpp_parser_t *parser, if (loc != NULL) _check_for_reserved_macro_name(parser, loc, identifier); - macro = talloc (parser, macro_t); + macro = ralloc (parser, macro_t); macro->is_function = 0; macro->parameters = NULL; - macro->identifier = talloc_strdup (macro, identifier); - macro->replacements = talloc_steal (macro, replacements); + macro->identifier = ralloc_strdup (macro, identifier); + macro->replacements = replacements; + ralloc_steal (macro, replacements); previous = hash_table_find (parser->defines, identifier); if (previous) { if (_macro_equal (macro, previous)) { - talloc_free (macro); + ralloc_free (macro); return; } glcpp_error (loc, parser, "Redefinition of macro %s\n", @@ -1683,17 +1710,18 @@ _define_function_macro (glcpp_parser_t *parser, _check_for_reserved_macro_name(parser, loc, identifier); - macro = talloc (parser, macro_t); + macro = ralloc (parser, macro_t); + ralloc_steal (macro, parameters); + ralloc_steal (macro, replacements); macro->is_function = 1; - macro->parameters = talloc_steal (macro, parameters); - macro->identifier = talloc_strdup (macro, identifier); - macro->replacements = talloc_steal (macro, replacements); - + macro->parameters = parameters; + macro->identifier = ralloc_strdup (macro, identifier); + macro->replacements = replacements; previous = hash_table_find (parser->defines, identifier); if (previous) { if (_macro_equal (macro, previous)) { - talloc_free (macro); + ralloc_free (macro); return; } glcpp_error (loc, parser, "Redefinition of macro %s\n", @@ -1769,7 +1797,7 @@ glcpp_parser_lex (YYSTYPE *yylval, YYLTYPE *yylloc, glcpp_parser_t *parser) node = parser->lex_from_node; if (node == NULL) { - talloc_free (parser->lex_from_list); + ralloc_free (parser->lex_from_list); parser->lex_from_list = NULL; return NEWLINE; } @@ -1798,13 +1826,13 @@ glcpp_parser_lex_from (glcpp_parser_t *parser, token_list_t *list) _token_list_append (parser->lex_from_list, node->token); } - talloc_free (list); + ralloc_free (list); parser->lex_from_node = parser->lex_from_list->head; /* It's possible the list consisted of nothing but whitespace. */ if (parser->lex_from_node == NULL) { - talloc_free (parser->lex_from_list); + ralloc_free (parser->lex_from_list); parser->lex_from_list = NULL; } } @@ -1819,7 +1847,7 @@ _glcpp_parser_skip_stack_push_if (glcpp_parser_t *parser, YYLTYPE *loc, if (parser->skip_stack) current = parser->skip_stack->type; - node = talloc (parser, skip_node_t); + node = ralloc (parser, skip_node_t); node->loc = *loc; if (current == SKIP_NO_SKIP) { @@ -1864,5 +1892,5 @@ _glcpp_parser_skip_stack_pop (glcpp_parser_t *parser, YYLTYPE *loc) node = parser->skip_stack; parser->skip_stack = node->next; - talloc_free (node); + ralloc_free (node); } diff --git a/src/glsl/glcpp/glcpp.c b/src/glsl/glcpp/glcpp.c index 062eb6b72d..325289129d 100644 --- a/src/glsl/glcpp/glcpp.c +++ b/src/glsl/glcpp/glcpp.c @@ -21,10 +21,7 @@ * DEALINGS IN THE SOFTWARE. */ -#include <sys/types.h> -#include <sys/stat.h> -#include <fcntl.h> -#include <unistd.h> +#include <stdio.h> #include <string.h> #include <errno.h> #include "glcpp.h" @@ -40,39 +37,32 @@ _mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr, *ptr = sh; } -/* Read from fd until EOF and return a string of everything read. +/* Read from fp until EOF and return a string of everything read. */ static char * -load_text_fd (void *ctx, int fd) +load_text_fp (void *ctx, FILE *fp) { #define CHUNK 4096 char *text = NULL; - ssize_t text_size = 0; - ssize_t total_read = 0; - ssize_t bytes; + size_t text_size = 0; + size_t total_read = 0; + size_t bytes; while (1) { if (total_read + CHUNK + 1 > text_size) { text_size = text_size ? text_size * 2 : CHUNK + 1; - text = talloc_realloc_size (ctx, text, text_size); + text = reralloc_size (ctx, text, text_size); if (text == NULL) { fprintf (stderr, "Out of memory\n"); return NULL; } } - bytes = read (fd, text + total_read, CHUNK); - if (bytes < 0) { - fprintf (stderr, "Error while reading: %s\n", - strerror (errno)); - talloc_free (text); - return NULL; - } + bytes = fread (text + total_read, 1, CHUNK, fp); + total_read += bytes; - if (bytes == 0) { + if (bytes < CHUNK) { break; } - - total_read += bytes; } text[total_read] = '\0'; @@ -84,21 +74,21 @@ static char * load_text_file(void *ctx, const char *filename) { char *text; - int fd; + FILE *fp; if (filename == NULL || strcmp (filename, "-") == 0) - return load_text_fd (ctx, STDIN_FILENO); + return load_text_fp (ctx, stdin); - fd = open (filename, O_RDONLY); - if (fd < 0) { + fp = fopen (filename, "r"); + if (fp == NULL) { fprintf (stderr, "Failed to open file %s: %s\n", filename, strerror (errno)); return NULL; } - text = load_text_fd (ctx, fd); + text = load_text_fp (ctx, fp); - close(fd); + fclose(fp); return text; } @@ -107,8 +97,8 @@ int main (int argc, char *argv[]) { char *filename = NULL; - void *ctx = talloc(NULL, void*); - char *info_log = talloc_strdup(ctx, ""); + void *ctx = ralloc(NULL, void*); + char *info_log = ralloc_strdup(ctx, ""); const char *shader; int ret; @@ -125,7 +115,7 @@ main (int argc, char *argv[]) printf("%s", shader); fprintf(stderr, "%s", info_log); - talloc_free(ctx); + ralloc_free(ctx); return ret; } diff --git a/src/glsl/glcpp/glcpp.h b/src/glsl/glcpp/glcpp.h index 7125d325df..dc816e90ee 100644 --- a/src/glsl/glcpp/glcpp.h +++ b/src/glsl/glcpp/glcpp.h @@ -26,7 +26,7 @@ #include <stdint.h> -#include <talloc.h> +#include "../ralloc.h" #include "program/hash_table.h" @@ -189,7 +189,7 @@ void glcpp_parser_destroy (glcpp_parser_t *parser); int -preprocess(void *talloc_ctx, const char **shader, char **info_log, +preprocess(void *ralloc_ctx, const char **shader, char **info_log, const struct gl_extensions *extensions, int api); /* Functions for writing to the info log */ diff --git a/src/glsl/glcpp/pp.c b/src/glsl/glcpp/pp.c index e1a3a88a3e..3640896a2c 100644 --- a/src/glsl/glcpp/pp.c +++ b/src/glsl/glcpp/pp.c @@ -33,16 +33,15 @@ glcpp_error (YYLTYPE *locp, glcpp_parser_t *parser, const char *fmt, ...) va_list ap; parser->error = 1; - parser->info_log = talloc_asprintf_append(parser->info_log, - "%u:%u(%u): " + ralloc_asprintf_append(&parser->info_log, "%u:%u(%u): " "preprocessor error: ", locp->source, locp->first_line, locp->first_column); va_start(ap, fmt); - parser->info_log = talloc_vasprintf_append(parser->info_log, fmt, ap); + ralloc_vasprintf_append(&parser->info_log, fmt, ap); va_end(ap); - parser->info_log = talloc_strdup_append(parser->info_log, "\n"); + ralloc_strcat(&parser->info_log, "\n"); } void @@ -50,16 +49,15 @@ glcpp_warning (YYLTYPE *locp, glcpp_parser_t *parser, const char *fmt, ...) { va_list ap; - parser->info_log = talloc_asprintf_append(parser->info_log, - "%u:%u(%u): " + ralloc_asprintf_append(&parser->info_log, "%u:%u(%u): " "preprocessor warning: ", locp->source, locp->first_line, locp->first_column); va_start(ap, fmt); - parser->info_log = talloc_vasprintf_append(parser->info_log, fmt, ap); + ralloc_vasprintf_append(&parser->info_log, fmt, ap); va_end(ap); - parser->info_log = talloc_strdup_append(parser->info_log, "\n"); + ralloc_strcat(&parser->info_log, "\n"); } /* Searches backwards for '^ *#' from a given starting point. */ @@ -92,7 +90,7 @@ remove_line_continuations(glcpp_parser_t *ctx, const char *shader) { int in_continued_line = 0; int extra_newlines = 0; - char *clean = talloc_strdup(ctx, ""); + char *clean = ralloc_strdup(ctx, ""); const char *search_start = shader; const char *newline; while ((newline = strchr(search_start, '\n')) != NULL) { @@ -122,27 +120,27 @@ remove_line_continuations(glcpp_parser_t *ctx, const char *shader) } if (in_continued_line) { /* Copy everything before the \ */ - clean = talloc_strndup_append(clean, shader, backslash - shader); + ralloc_strncat(&clean, shader, backslash - shader); shader = newline + 1; extra_newlines++; } } else if (in_continued_line) { /* Copy everything up to and including the \n */ - clean = talloc_strndup_append(clean, shader, newline - shader + 1); + ralloc_strncat(&clean, shader, newline - shader + 1); shader = newline + 1; /* Output extra newlines to make line numbers match */ for (; extra_newlines > 0; extra_newlines--) - clean = talloc_strdup_append(clean, "\n"); + ralloc_strcat(&clean, "\n"); in_continued_line = 0; } search_start = newline + 1; } - clean = talloc_strdup_append(clean, shader); + ralloc_strcat(&clean, shader); return clean; } int -preprocess(void *talloc_ctx, const char **shader, char **info_log, +preprocess(void *ralloc_ctx, const char **shader, char **info_log, const struct gl_extensions *extensions, int api) { int errors; @@ -156,9 +154,9 @@ preprocess(void *talloc_ctx, const char **shader, char **info_log, if (parser->skip_stack) glcpp_error (&parser->skip_stack->loc, parser, "Unterminated #if\n"); - *info_log = talloc_strdup_append(*info_log, parser->info_log); + ralloc_strcat(info_log, parser->info_log); - talloc_steal(talloc_ctx, parser->output); + ralloc_steal(ralloc_ctx, parser->output); *shader = parser->output; errors = parser->error; diff --git a/src/glsl/glcpp/tests/063-comments.c.expected b/src/glsl/glcpp/tests/063-comments.c.expected index ed4feedd45..73ca7071fa 100644 --- a/src/glsl/glcpp/tests/063-comments.c.expected +++ b/src/glsl/glcpp/tests/063-comments.c.expected @@ -5,8 +5,15 @@ f = g /h; l(); m = n + p; + + + + + + more code here + are not treated like comments. diff --git a/src/glsl/glcpp/tests/092-redefine-macro-error-2.c b/src/glsl/glcpp/tests/092-redefine-macro-error-2.c new file mode 100644 index 0000000000..3c161a5c50 --- /dev/null +++ b/src/glsl/glcpp/tests/092-redefine-macro-error-2.c @@ -0,0 +1,5 @@ +#define A +#define A 1 + +#define B 1 +#define B diff --git a/src/glsl/glcpp/tests/092-redefine-macro-error-2.c.expected b/src/glsl/glcpp/tests/092-redefine-macro-error-2.c.expected new file mode 100644 index 0000000000..0026f91f32 --- /dev/null +++ b/src/glsl/glcpp/tests/092-redefine-macro-error-2.c.expected @@ -0,0 +1,10 @@ +0:2(9): preprocessor error: Redefinition of macro A + +0:5(9): preprocessor error: Redefinition of macro B + + + + + + + diff --git a/src/glsl/glcpp/tests/093-divide-by-zero.c b/src/glsl/glcpp/tests/093-divide-by-zero.c new file mode 100644 index 0000000000..bf65d4f527 --- /dev/null +++ b/src/glsl/glcpp/tests/093-divide-by-zero.c @@ -0,0 +1,2 @@ +#if (1 / 0) +#endif diff --git a/src/glsl/glcpp/tests/094-divide-by-zero-short-circuit.c b/src/glsl/glcpp/tests/094-divide-by-zero-short-circuit.c new file mode 100644 index 0000000000..a9c6f36def --- /dev/null +++ b/src/glsl/glcpp/tests/094-divide-by-zero-short-circuit.c @@ -0,0 +1,2 @@ +#if 1 || (1 / 0) +#endif diff --git a/src/glsl/glcpp/tests/095-recursive-define.c b/src/glsl/glcpp/tests/095-recursive-define.c new file mode 100644 index 0000000000..801d90ce2e --- /dev/null +++ b/src/glsl/glcpp/tests/095-recursive-define.c @@ -0,0 +1,3 @@ +#define A(a, b) B(a, b) +#define C A(0, C) +C diff --git a/src/glsl/glsl_lexer.cpp b/src/glsl/glsl_lexer.cpp index e3d0a3cfc9..ef0d99e478 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 209 -#define YY_END_OF_BUFFER 210 +#define YY_NUM_RULES 210 +#define YY_END_OF_BUFFER 211 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -358,98 +367,100 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[813] = +static yyconst flex_int16_t yy_accept[836] = { 0, - 0, 0, 15, 15, 0, 0, 210, 208, 1, 20, - 208, 208, 208, 208, 208, 208, 208, 208, 119, 117, - 208, 208, 208, 207, 208, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 208, 1, 208, 209, 15, - 19, 209, 18, 16, 17, 13, 12, 1, 101, 110, - 102, 113, 107, 96, 109, 97, 116, 121, 108, 122, - 119, 0, 0, 124, 119, 0, 117, 117, 105, 98, - 100, 99, 106, 207, 114, 104, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 29, 207, - - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 33, 207, 207, 60, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 115, - 103, 1, 0, 0, 2, 0, 0, 0, 0, 15, - 14, 18, 17, 0, 121, 120, 0, 122, 0, 123, - 118, 111, 112, 207, 127, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 32, 207, 207, 207, - - 207, 207, 207, 207, 207, 207, 207, 25, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 61, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 0, 0, 0, 0, 14, 0, 121, 0, 120, 0, - 122, 123, 118, 207, 207, 23, 207, 207, 174, 167, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 31, - 130, 207, 207, 207, 207, 67, 207, 207, 135, 149, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - - 207, 207, 146, 170, 48, 49, 50, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 133, 125, 207, - 207, 26, 207, 207, 207, 207, 207, 207, 207, 45, - 46, 47, 94, 207, 207, 0, 0, 0, 0, 0, - 120, 207, 207, 27, 36, 37, 38, 207, 128, 207, - 22, 207, 207, 207, 207, 157, 158, 159, 207, 126, - 207, 150, 24, 160, 161, 162, 172, 154, 155, 156, - 207, 207, 207, 62, 152, 207, 207, 207, 39, 40, - 41, 207, 207, 207, 207, 207, 207, 207, 207, 207, - - 207, 207, 207, 207, 207, 207, 207, 147, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 129, 207, - 207, 169, 42, 43, 44, 207, 207, 30, 0, 0, - 0, 0, 177, 207, 207, 175, 207, 207, 207, 148, - 143, 180, 207, 207, 207, 207, 207, 207, 138, 207, - 207, 207, 95, 51, 52, 53, 54, 55, 56, 57, - 58, 59, 207, 207, 207, 207, 153, 134, 207, 207, - 141, 35, 207, 207, 166, 68, 142, 93, 178, 136, - 207, 207, 207, 207, 207, 207, 207, 207, 0, 0, - 0, 0, 207, 207, 207, 137, 34, 207, 207, 207, - - 207, 207, 207, 181, 182, 183, 207, 207, 207, 207, - 207, 171, 207, 207, 207, 207, 207, 207, 207, 207, - 131, 207, 207, 207, 207, 207, 63, 207, 207, 64, - 207, 0, 0, 0, 0, 0, 207, 65, 28, 144, - 185, 186, 187, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 139, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 132, 189, 190, 191, 207, - 207, 151, 207, 140, 0, 0, 6, 0, 0, 0, - 11, 3, 21, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 184, 145, 66, 207, 207, 207, 207, 168, - - 207, 176, 173, 206, 70, 71, 72, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 0, 0, 0, - 0, 0, 0, 207, 207, 207, 188, 207, 207, 207, - 207, 207, 81, 82, 83, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 192, 87, - 88, 89, 207, 4, 0, 5, 0, 0, 0, 0, - 0, 207, 207, 207, 207, 207, 207, 207, 203, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 73, 207, 207, 207, 207, 207, 207, 0, 0, 0, - 207, 207, 204, 193, 207, 194, 207, 207, 207, 84, - - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 205, 207, 207, 90, 0, 0, 195, 196, 207, - 199, 207, 200, 207, 207, 69, 207, 207, 207, 163, - 207, 164, 179, 207, 197, 198, 207, 207, 0, 0, - 207, 207, 207, 207, 74, 207, 75, 207, 207, 207, - 207, 207, 0, 0, 0, 207, 207, 85, 86, 207, - 76, 207, 207, 77, 207, 91, 92, 0, 0, 0, - 207, 207, 207, 207, 207, 207, 0, 0, 0, 207, - 207, 207, 207, 207, 78, 0, 0, 7, 0, 0, - 201, 202, 207, 207, 207, 0, 8, 0, 0, 207, - - 207, 165, 0, 0, 79, 80, 0, 0, 9, 0, - 10, 0 + 0, 0, 16, 16, 0, 0, 211, 209, 1, 21, + 209, 209, 209, 209, 209, 209, 209, 209, 120, 118, + 209, 209, 209, 208, 209, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 209, 1, 209, 210, 16, + 20, 210, 19, 17, 18, 14, 13, 1, 102, 111, + 103, 114, 108, 97, 110, 98, 117, 122, 109, 123, + 120, 0, 0, 125, 120, 0, 118, 118, 106, 99, + 101, 100, 107, 208, 115, 105, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 30, 208, + + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 34, 208, 208, 61, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 116, + 104, 1, 0, 0, 2, 0, 0, 0, 0, 16, + 15, 19, 18, 0, 122, 121, 0, 123, 0, 124, + 119, 112, 113, 208, 128, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 33, 208, 208, 208, + + 208, 208, 208, 208, 208, 208, 208, 26, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 62, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 0, 0, 0, 0, 15, 0, 122, 0, 121, 0, + 123, 124, 119, 208, 208, 24, 208, 208, 175, 168, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 32, + 131, 208, 208, 208, 208, 68, 208, 208, 136, 150, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + + 208, 208, 147, 171, 49, 50, 51, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 134, 126, 208, + 208, 27, 208, 208, 208, 208, 208, 208, 208, 46, + 47, 48, 95, 208, 208, 0, 0, 0, 0, 0, + 121, 208, 208, 28, 37, 38, 39, 208, 129, 208, + 23, 208, 208, 208, 208, 158, 159, 160, 208, 127, + 208, 151, 25, 161, 162, 163, 173, 155, 156, 157, + 208, 208, 208, 63, 153, 208, 208, 208, 40, 41, + 42, 208, 208, 208, 208, 208, 208, 208, 208, 208, + + 208, 208, 208, 208, 208, 208, 208, 148, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 130, 208, + 208, 170, 43, 44, 45, 208, 208, 31, 0, 0, + 0, 0, 178, 208, 208, 176, 208, 208, 208, 149, + 144, 181, 208, 208, 208, 208, 208, 208, 139, 208, + 208, 208, 96, 52, 53, 54, 55, 56, 57, 58, + 59, 60, 208, 208, 208, 208, 154, 135, 208, 208, + 142, 36, 208, 208, 167, 69, 143, 94, 179, 137, + 208, 208, 208, 208, 208, 208, 208, 208, 0, 0, + 0, 0, 208, 208, 208, 138, 35, 208, 208, 208, + + 208, 208, 208, 182, 183, 184, 208, 208, 208, 208, + 208, 172, 208, 208, 208, 208, 208, 208, 208, 208, + 132, 208, 208, 208, 208, 208, 64, 208, 208, 65, + 208, 0, 0, 0, 0, 0, 208, 66, 29, 145, + 186, 187, 188, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 140, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 133, 190, 191, 192, 208, + 208, 152, 208, 141, 0, 0, 6, 0, 0, 0, + 12, 3, 22, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 185, 146, 67, 208, 208, 208, 208, 169, + + 208, 177, 174, 207, 71, 72, 73, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 0, 0, 0, + 0, 0, 0, 0, 208, 208, 208, 189, 208, 208, + 208, 208, 208, 82, 83, 84, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 193, + 88, 89, 90, 208, 4, 0, 5, 0, 0, 0, + 0, 0, 0, 208, 208, 208, 208, 208, 208, 208, + 204, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 74, 208, 208, 208, 208, 208, 208, 0, + 0, 0, 0, 208, 208, 205, 194, 208, 195, 208, + + 208, 208, 85, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 206, 208, 208, 91, 0, 0, + 0, 196, 197, 208, 200, 208, 201, 208, 208, 70, + 208, 208, 208, 164, 208, 165, 180, 208, 198, 199, + 208, 208, 0, 0, 0, 208, 208, 208, 208, 75, + 208, 76, 208, 208, 208, 208, 208, 0, 0, 0, + 0, 208, 208, 86, 87, 208, 77, 208, 208, 78, + 208, 92, 93, 0, 0, 0, 0, 208, 208, 208, + 208, 208, 208, 0, 0, 0, 0, 208, 208, 208, + 208, 208, 79, 0, 0, 0, 7, 0, 0, 202, + + 203, 208, 208, 208, 0, 0, 8, 0, 0, 208, + 208, 166, 0, 0, 0, 80, 81, 0, 0, 0, + 9, 0, 0, 10, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 11, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -461,13 +472,13 @@ static yyconst flex_int32_t yy_ec[256] = 10, 11, 12, 1, 13, 14, 15, 16, 17, 18, 19, 20, 21, 21, 21, 22, 22, 23, 1, 24, 25, 26, 1, 1, 27, 28, 29, 30, 31, 32, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 34, 35, 33, 36, 33, 33, 37, 33, 33, - 1, 1, 1, 38, 39, 1, 40, 41, 42, 43, + 33, 34, 34, 34, 34, 35, 34, 34, 34, 34, + 34, 36, 37, 38, 39, 34, 34, 40, 34, 34, + 1, 1, 1, 41, 42, 1, 43, 44, 45, 46, - 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, - 54, 55, 33, 56, 57, 58, 59, 60, 61, 62, - 63, 64, 1, 65, 1, 1, 1, 1, 1, 1, + 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, + 57, 58, 34, 59, 60, 61, 62, 63, 64, 65, + 66, 67, 1, 68, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -484,350 +495,357 @@ static yyconst flex_int32_t yy_ec[256] = 1, 1, 1, 1, 1 } ; -static yyconst flex_int32_t yy_meta[66] = +static yyconst flex_int32_t yy_meta[69] = { 0, - 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 4, 4, 4, 4, 4, - 4, 5, 1, 1, 1, 1, 6, 6, 6, 6, - 5, 5, 7, 7, 7, 7, 8, 1, 7, 6, - 6, 6, 6, 5, 5, 7, 7, 7, 7, 7, - 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, - 7, 8, 7, 7, 1 + 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 3, 3, 3, 3, 3, + 3, 3, 1, 1, 1, 1, 4, 4, 4, 4, + 3, 3, 5, 5, 5, 5, 5, 5, 5, 5, + 1, 5, 4, 4, 4, 4, 3, 3, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 1 } ; -static yyconst flex_int16_t yy_base[824] = +static yyconst flex_int16_t yy_base[845] = { 0, - 0, 64, 70, 0, 1185, 1184, 1186, 1189, 65, 1189, - 1160, 1159, 128, 1158, 125, 126, 124, 1157, 140, 189, - 123, 1156, 138, 0, 127, 124, 113, 135, 144, 161, - 176, 1126, 130, 187, 140, 143, 161, 1120, 182, 174, - 202, 199, 211, 212, 1131, 130, 263, 255, 1189, 189, - 1189, 1162, 256, 1189, 0, 1189, 1189, 215, 1189, 1189, - 1189, 1189, 1189, 1189, 1189, 1189, 1189, 248, 1189, 250, - 112, 302, 319, 1189, 1189, 0, 0, 1189, 1151, 1189, - 1189, 1189, 1150, 0, 1189, 1189, 1116, 1121, 1114, 1117, - 1126, 1125, 1111, 1114, 1126, 144, 1120, 1107, 1104, 1118, - - 1104, 1101, 1101, 1107, 175, 191, 1101, 1112, 1097, 1103, - 1107, 1108, 0, 1099, 1110, 247, 1109, 1104, 1084, 230, - 1088, 1102, 1092, 241, 1085, 228, 1098, 1100, 1082, 1078, - 1086, 1083, 1072, 1081, 173, 1079, 1085, 1080, 1083, 1071, - 1074, 233, 240, 260, 1084, 1071, 1084, 239, 1077, 1189, - 1189, 307, 301, 323, 1189, 1062, 1075, 1066, 1077, 249, - 0, 368, 0, 379, 1189, 298, 390, 1189, 397, 404, - 291, 1189, 1189, 1072, 0, 1063, 1067, 1077, 1074, 270, - 1057, 1057, 1061, 291, 1072, 1069, 1069, 1067, 1064, 1055, - 1062, 1048, 1046, 1059, 1044, 1061, 0, 1058, 1045, 1053, - - 1050, 1054, 1055, 1048, 1045, 1033, 1032, 1046, 1049, 1036, - 1045, 1032, 1039, 1029, 335, 1035, 1038, 1028, 1036, 1024, - 1028, 1019, 1034, 1024, 1015, 1034, 1017, 1015, 1026, 1015, - 1010, 1008, 1022, 1007, 1009, 1006, 1018, 1017, 1020, 1001, - 306, 1010, 1005, 1003, 1013, 991, 339, 1010, 1012, 1000, - 992, 996, 1008, 991, 0, 411, 421, 438, 1189, 451, - 458, 1189, 1189, 986, 997, 0, 994, 344, 0, 0, - 987, 985, 987, 982, 991, 979, 997, 985, 350, 0, - 0, 979, 990, 989, 989, 0, 973, 353, 0, 0, - 975, 357, 983, 984, 974, 968, 967, 968, 967, 967, - - 361, 962, 0, 0, 958, 957, 956, 958, 959, 964, - 958, 954, 968, 963, 962, 961, 952, 955, 955, 947, - 950, 945, 954, 959, 944, 957, 947, 0, 0, 954, - 950, 0, 941, 941, 947, 937, 945, 426, 942, 0, - 0, 0, 0, 931, 944, 943, 942, 939, 927, 465, - 475, 939, 941, 0, 0, 0, 0, 927, 0, 927, - 0, 926, 927, 921, 932, 0, 0, 0, 922, 0, - 918, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 929, 481, 928, 0, 0, 926, 922, 918, 0, 0, - 0, 910, 443, 486, 493, 915, 911, 917, 907, 905, - - 919, 903, 903, 917, 905, 917, 912, 0, 910, 907, - 911, 894, 896, 903, 909, 904, 903, 890, 0, 892, - 893, 0, 0, 0, 0, 890, 894, 0, 888, 938, - 887, 890, 0, 878, 888, 0, 876, 876, 890, 0, - 892, 0, 497, 901, 900, 899, 869, 868, 0, 886, - 885, 880, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 868, 882, 868, 865, 0, 0, 871, 870, - 0, 0, 868, 860, 0, 0, 0, 0, 0, 0, - 857, 869, 500, 861, 868, 867, 864, 858, 851, 519, - 867, 852, 847, 861, 859, 0, 0, 851, 871, 870, - - 869, 839, 838, 495, 496, 0, 851, 854, 852, 840, - 836, 0, 849, 846, 845, 834, 833, 832, 515, 841, - 0, 854, 853, 852, 822, 821, 0, 836, 822, 0, - 833, 828, 543, 545, 873, 821, 829, 0, 0, 0, - 845, 844, 0, 825, 828, 812, 820, 810, 818, 819, - 819, 818, 803, 539, 816, 0, 817, 805, 804, 800, - 825, 824, 823, 793, 792, 0, 823, 822, 0, 803, - 806, 0, 552, 0, 792, 557, 1189, 580, 0, 590, - 499, 1189, 0, 789, 788, 798, 798, 785, 800, 783, - 798, 793, 0, 0, 0, 806, 805, 804, 774, 0, - - 774, 0, 0, 0, 559, 568, 797, 785, 788, 772, - 771, 781, 781, 794, 793, 792, 762, 767, 552, 613, - 363, 775, 763, 761, 760, 771, 0, 774, 770, 772, - 768, 754, 782, 781, 0, 766, 758, 749, 757, 747, - 758, 754, 756, 754, 754, 741, 740, 751, 0, 767, - 766, 0, 751, 1189, 391, 1189, 620, 0, 640, 750, - 732, 749, 748, 731, 723, 731, 721, 729, 0, 726, - 725, 736, 719, 722, 737, 720, 733, 734, 731, 728, - 736, 730, 729, 712, 711, 710, 721, 402, 705, 715, - 699, 698, 0, 725, 698, 723, 696, 700, 699, 0, - - 710, 713, 709, 711, 688, 702, 686, 680, 688, 671, - 662, 0, 640, 639, 0, 648, 641, 0, 0, 645, - 0, 644, 0, 650, 649, 0, 625, 633, 623, 650, - 630, 0, 0, 643, 0, 0, 642, 641, 582, 632, - 639, 638, 614, 613, 635, 608, 633, 607, 590, 607, - 586, 585, 611, 380, 526, 545, 544, 0, 0, 538, - 0, 504, 510, 0, 495, 0, 0, 550, 572, 483, - 470, 454, 462, 449, 445, 404, 419, 616, 619, 391, - 387, 404, 392, 290, 0, 617, 642, 1189, 644, 570, - 0, 0, 263, 258, 139, 645, 1189, 643, 618, 107, - - 77, 0, 23, 662, 0, 0, 663, 664, 1189, 665, - 1189, 1189, 697, 702, 707, 712, 714, 716, 722, 729, - 734, 739, 744 + 0, 67, 73, 0, 1210, 1209, 1211, 1214, 68, 1214, + 1185, 1184, 134, 1183, 131, 132, 130, 1182, 146, 198, + 129, 1181, 144, 0, 130, 113, 124, 141, 150, 126, + 181, 1148, 159, 192, 118, 129, 146, 1142, 147, 174, + 206, 192, 203, 222, 1153, 203, 221, 231, 1214, 260, + 1214, 1187, 279, 1214, 0, 1214, 1214, 270, 1214, 1214, + 1214, 1214, 1214, 1214, 1214, 1214, 1214, 244, 1214, 255, + 139, 290, 307, 1214, 1214, 0, 0, 1214, 1176, 1214, + 1214, 1214, 1175, 0, 1214, 1214, 1138, 1143, 1136, 1139, + 1148, 1147, 1133, 1136, 1148, 144, 1142, 1129, 1126, 1140, + + 1126, 1123, 1123, 1129, 219, 193, 1123, 1134, 1119, 1125, + 1129, 1130, 0, 1121, 1132, 278, 1131, 1126, 1106, 224, + 1110, 1124, 1114, 232, 1107, 271, 1120, 1122, 1104, 1100, + 1108, 1105, 1094, 1103, 234, 1101, 1107, 1102, 1105, 1093, + 1096, 226, 145, 262, 1106, 1093, 1106, 263, 1099, 1214, + 1214, 338, 331, 343, 1214, 1084, 1097, 1088, 1099, 345, + 0, 334, 0, 345, 1214, 328, 391, 1214, 352, 398, + 338, 1214, 1214, 1094, 0, 1085, 1089, 1099, 1096, 332, + 1079, 1079, 1083, 320, 1094, 1091, 1091, 1089, 1086, 1077, + 1084, 1070, 1068, 1081, 1066, 1083, 0, 1080, 1067, 1075, + + 1072, 1076, 1077, 1070, 1067, 1055, 1054, 1068, 1071, 1058, + 1067, 1054, 1061, 1051, 364, 1057, 1060, 1050, 1058, 1046, + 1050, 1041, 1056, 1046, 1037, 1056, 1039, 1037, 1048, 1037, + 1032, 1030, 1044, 1029, 1031, 1028, 1040, 1039, 1042, 1023, + 338, 1032, 1027, 1025, 1035, 1013, 403, 1032, 1034, 1022, + 1014, 1018, 1030, 1013, 0, 415, 422, 439, 1214, 446, + 455, 1214, 1214, 1008, 1019, 0, 1016, 406, 0, 0, + 1009, 1007, 1009, 1004, 1013, 1001, 1019, 1007, 409, 0, + 0, 1001, 1012, 1011, 1011, 0, 995, 429, 0, 0, + 997, 460, 1005, 1006, 996, 990, 989, 990, 989, 989, + + 463, 984, 0, 0, 980, 979, 978, 980, 981, 986, + 980, 976, 990, 985, 984, 983, 974, 977, 977, 969, + 972, 967, 976, 981, 966, 979, 969, 0, 0, 976, + 972, 0, 963, 963, 969, 959, 967, 466, 964, 0, + 0, 0, 0, 953, 966, 965, 964, 961, 949, 472, + 479, 961, 963, 0, 0, 0, 0, 949, 0, 949, + 0, 948, 949, 943, 954, 0, 0, 0, 944, 0, + 940, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 951, 487, 950, 0, 0, 948, 944, 940, 0, 0, + 0, 932, 489, 494, 499, 937, 933, 939, 929, 927, + + 941, 925, 925, 939, 927, 939, 934, 0, 932, 929, + 933, 916, 918, 925, 931, 926, 925, 912, 0, 914, + 915, 0, 0, 0, 0, 912, 916, 0, 910, 963, + 909, 912, 0, 900, 910, 0, 898, 898, 912, 0, + 914, 0, 503, 926, 925, 924, 891, 890, 0, 908, + 907, 902, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 890, 904, 890, 887, 0, 0, 893, 892, + 0, 0, 890, 882, 0, 0, 0, 0, 0, 0, + 879, 891, 506, 883, 890, 889, 886, 880, 873, 524, + 889, 874, 869, 883, 881, 0, 0, 873, 896, 895, + + 894, 861, 860, 361, 365, 0, 873, 876, 874, 862, + 858, 0, 871, 868, 867, 856, 855, 854, 519, 863, + 0, 879, 878, 877, 844, 843, 0, 858, 844, 0, + 855, 850, 547, 553, 898, 843, 851, 0, 0, 0, + 870, 869, 0, 847, 850, 834, 842, 832, 840, 841, + 841, 840, 825, 559, 838, 0, 839, 827, 826, 822, + 850, 849, 848, 815, 814, 0, 848, 847, 0, 825, + 828, 0, 562, 0, 814, 580, 1214, 587, 0, 607, + 584, 1214, 0, 811, 810, 820, 820, 807, 822, 805, + 820, 815, 0, 0, 0, 831, 830, 829, 796, 0, + + 796, 0, 0, 0, 502, 524, 820, 807, 810, 794, + 793, 803, 803, 819, 818, 817, 784, 789, 615, 640, + 550, 806, 796, 784, 782, 781, 792, 0, 795, 791, + 793, 789, 775, 806, 805, 0, 787, 779, 770, 778, + 768, 779, 775, 777, 775, 775, 762, 761, 772, 0, + 791, 790, 0, 772, 1214, 555, 1214, 647, 0, 667, + 785, 770, 752, 769, 768, 751, 743, 751, 741, 749, + 0, 746, 745, 756, 739, 742, 757, 740, 753, 754, + 751, 748, 757, 750, 749, 732, 731, 730, 741, 582, + 754, 724, 734, 718, 717, 0, 745, 717, 743, 715, + + 719, 718, 0, 729, 732, 728, 730, 711, 725, 709, + 710, 718, 701, 700, 0, 706, 705, 0, 728, 713, + 706, 0, 0, 710, 0, 709, 0, 715, 714, 0, + 690, 698, 688, 716, 695, 0, 0, 708, 0, 0, + 707, 706, 746, 611, 696, 703, 702, 678, 677, 705, + 677, 703, 689, 674, 691, 670, 669, 190, 613, 557, + 667, 687, 686, 0, 0, 681, 0, 680, 686, 0, + 671, 0, 0, 671, 590, 343, 672, 645, 644, 654, + 635, 631, 612, 612, 604, 443, 635, 576, 575, 549, + 25, 87, 0, 183, 500, 552, 1214, 636, 591, 0, + + 0, 196, 258, 254, 272, 609, 1214, 614, 598, 279, + 284, 0, 336, 348, 671, 0, 0, 362, 672, 688, + 1214, 394, 689, 1214, 408, 670, 691, 649, 651, 474, + 476, 693, 694, 1214, 1214, 704, 707, 710, 530, 591, + 713, 717, 720, 722 } ; -static yyconst flex_int16_t yy_def[824] = +static yyconst flex_int16_t yy_def[845] = { 0, - 812, 1, 812, 3, 813, 813, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 814, 812, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 815, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 816, 812, 817, - 19, 812, 812, 812, 812, 818, 20, 812, 812, 812, - 812, 812, 812, 814, 812, 812, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 819, 812, 815, 812, 812, 817, 812, 812, 812, 812, - 818, 812, 812, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 812, 812, 812, 812, 819, 812, 812, 812, 812, 812, - 812, 812, 812, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 812, 812, 812, 812, 812, - 812, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 812, 812, - 812, 812, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 812, 812, - 812, 812, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 812, 820, 812, 812, 812, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 812, 812, 812, 812, 821, 812, - 812, 812, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 812, 822, 812, - 821, 812, 812, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 812, 812, 812, 812, 823, 812, 812, - 812, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 823, 812, 812, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 812, 812, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 814, 812, 812, - 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, - 814, 814, 812, 812, 812, 814, 814, 814, 814, 814, - 814, 814, 814, 814, 814, 814, 814, 812, 812, 812, - 814, 814, 814, 814, 814, 814, 812, 812, 812, 814, - 814, 814, 814, 814, 814, 812, 812, 812, 812, 812, - 814, 814, 814, 814, 814, 812, 812, 812, 812, 814, - - 814, 814, 812, 812, 814, 814, 812, 812, 812, 812, - 812, 0, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812 + 835, 1, 835, 3, 836, 836, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 837, 835, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 838, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 839, 835, 840, + 19, 835, 835, 835, 835, 841, 20, 835, 835, 835, + 835, 835, 835, 837, 835, 835, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 842, 835, 838, 835, 835, 840, 835, 835, 835, 835, + 841, 835, 835, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 835, 835, 835, 835, 842, 835, 835, 835, 835, 835, + 835, 835, 835, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 835, 835, 835, 835, 835, + 835, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 835, 835, + 835, 835, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 835, 835, + 835, 835, 837, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 835, 835, 835, 835, 835, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 835, 835, 835, 835, 843, 835, + 835, 835, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 835, 835, 835, + 843, 835, 835, 835, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 835, 835, 835, 835, 844, 835, + 835, 835, 835, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 844, + 835, 835, 835, 837, 837, 837, 837, 837, 837, 837, + + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 835, 835, + 835, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 835, 835, 835, 837, 837, 837, 837, 837, + 837, 837, 837, 837, 837, 837, 837, 835, 835, 835, + 835, 837, 837, 837, 837, 837, 837, 837, 837, 837, + 837, 837, 837, 835, 835, 835, 835, 837, 837, 837, + 837, 837, 837, 835, 835, 835, 835, 837, 837, 837, + 837, 837, 837, 835, 835, 835, 835, 835, 835, 837, + + 837, 837, 837, 837, 835, 835, 835, 835, 835, 837, + 837, 837, 835, 835, 835, 837, 837, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 0, 835, 835, 835, 835, 835, + 835, 835, 835, 835 } ; -static yyconst flex_int16_t yy_nxt[1255] = +static yyconst flex_int16_t yy_nxt[1283] = { 0, 8, 9, 10, 9, 11, 8, 12, 13, 8, 8, 14, 15, 16, 17, 18, 19, 20, 20, 20, 20, 20, 20, 8, 21, 22, 23, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 25, 24, 26, - 27, 28, 29, 30, 31, 32, 33, 34, 24, 24, - 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, - 45, 24, 24, 24, 46, 47, 58, 807, 58, 48, - 49, 50, 51, 50, 49, 49, 49, 49, 49, 49, - 49, 49, 49, 49, 52, 49, 53, 53, 53, 53, - 53, 53, 54, 49, 49, 49, 55, 55, 55, 55, - - 55, 55, 55, 55, 55, 55, 55, 49, 55, 55, + 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, + 25, 24, 26, 27, 28, 29, 30, 31, 32, 33, + 34, 24, 24, 35, 36, 37, 38, 39, 40, 41, + 42, 43, 44, 45, 24, 24, 24, 46, 47, 58, + 803, 58, 48, 49, 50, 51, 50, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 52, 49, 53, + 53, 53, 53, 53, 53, 54, 49, 49, 49, 55, + + 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, + 55, 55, 55, 49, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, 55, - 55, 55, 55, 55, 49, 61, 64, 806, 66, 68, - 68, 68, 68, 68, 68, 68, 79, 80, 812, 65, - 67, 85, 62, 70, 150, 71, 71, 71, 71, 71, - 71, 72, 82, 83, 86, 87, 90, 805, 91, 110, - 73, 74, 92, 812, 93, 75, 76, 111, 94, 119, - 88, 89, 121, 73, 74, 95, 122, 97, 96, 112, - 160, 98, 160, 120, 151, 183, 184, 99, 75, 802, - - 123, 76, 70, 100, 77, 77, 77, 77, 77, 77, - 77, 101, 231, 102, 124, 104, 58, 129, 58, 73, - 74, 126, 103, 105, 78, 193, 106, 130, 232, 107, - 195, 113, 73, 74, 114, 108, 194, 127, 115, 116, - 128, 131, 138, 117, 196, 139, 118, 78, 132, 133, - 160, 146, 160, 134, 140, 147, 154, 155, 142, 135, - 136, 141, 137, 143, 152, 148, 58, 144, 153, 221, - 145, 162, 162, 162, 162, 162, 162, 162, 164, 165, - 167, 168, 213, 222, 239, 240, 248, 241, 218, 249, - 214, 164, 165, 167, 168, 219, 242, 205, 156, 243, - - 206, 207, 154, 155, 208, 157, 209, 244, 152, 158, - 58, 801, 153, 269, 159, 70, 800, 72, 72, 72, - 72, 72, 72, 72, 154, 155, 263, 270, 258, 259, - 169, 169, 73, 74, 170, 170, 170, 170, 170, 170, - 170, 258, 259, 795, 156, 73, 74, 274, 275, 263, - 333, 157, 305, 306, 307, 158, 340, 341, 342, 334, - 159, 355, 356, 357, 576, 577, 156, 366, 367, 368, - 374, 375, 376, 157, 378, 379, 380, 158, 389, 390, - 391, 768, 159, 162, 162, 162, 162, 162, 162, 162, - 256, 256, 655, 656, 257, 257, 257, 257, 257, 257, - - 257, 260, 260, 655, 656, 261, 261, 261, 261, 261, - 261, 261, 170, 170, 170, 170, 170, 170, 170, 170, - 170, 170, 170, 170, 170, 170, 257, 257, 257, 257, - 257, 257, 257, 769, 794, 262, 257, 257, 257, 257, - 257, 257, 257, 423, 424, 425, 793, 792, 262, 350, - 350, 791, 165, 351, 351, 351, 351, 351, 351, 351, - 454, 455, 456, 786, 785, 165, 261, 261, 261, 261, - 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, - 351, 351, 351, 351, 351, 351, 351, 784, 783, 168, - 351, 351, 351, 351, 351, 351, 351, 444, 445, 446, - - 581, 782, 168, 457, 458, 459, 259, 781, 447, 448, - 460, 461, 462, 499, 500, 501, 522, 523, 524, 259, - 490, 546, 548, 780, 502, 503, 779, 525, 526, 547, - 549, 561, 562, 563, 533, 534, 534, 534, 534, 534, - 534, 622, 564, 565, 576, 577, 576, 577, 776, 775, - 774, 768, 623, 655, 656, 596, 597, 598, 576, 577, - 580, 580, 580, 580, 580, 580, 580, 599, 614, 615, - 616, 798, 619, 620, 620, 620, 620, 620, 620, 579, - 617, 576, 577, 753, 773, 638, 772, 771, 658, 770, - 754, 576, 577, 639, 640, 578, 578, 578, 578, 578, - - 578, 641, 642, 769, 579, 580, 580, 580, 580, 580, - 580, 580, 753, 658, 655, 656, 777, 787, 796, 754, - 789, 655, 656, 799, 778, 788, 797, 790, 659, 659, - 659, 659, 659, 659, 659, 657, 657, 657, 657, 657, - 657, 655, 656, 787, 798, 789, 796, 767, 766, 765, - 764, 788, 790, 763, 797, 659, 659, 659, 659, 659, - 659, 659, 803, 808, 810, 808, 810, 762, 761, 760, - 804, 809, 811, 809, 811, 759, 758, 757, 756, 755, - 752, 751, 750, 749, 748, 747, 746, 745, 744, 743, - 742, 741, 740, 739, 738, 737, 799, 56, 56, 56, - - 56, 56, 56, 56, 56, 84, 84, 84, 84, 84, - 163, 163, 163, 163, 163, 68, 68, 166, 166, 171, - 171, 171, 255, 255, 736, 255, 255, 255, 255, 255, - 578, 578, 578, 735, 734, 733, 578, 621, 621, 621, - 657, 657, 657, 732, 731, 730, 657, 688, 688, 688, - 729, 728, 727, 726, 725, 724, 723, 722, 721, 720, - 719, 718, 717, 716, 715, 714, 713, 712, 711, 710, - 709, 708, 707, 706, 705, 704, 703, 702, 701, 700, - 699, 698, 697, 696, 695, 694, 693, 692, 691, 690, - 689, 687, 686, 685, 684, 683, 682, 681, 680, 679, - - 678, 677, 676, 675, 674, 673, 672, 671, 670, 669, - 668, 667, 666, 665, 664, 663, 662, 661, 660, 654, - 653, 652, 651, 650, 649, 648, 647, 646, 645, 644, - 643, 637, 636, 635, 634, 633, 632, 631, 630, 629, - 628, 627, 626, 625, 624, 618, 613, 612, 611, 610, - 609, 608, 607, 606, 605, 604, 603, 602, 601, 600, - 595, 594, 593, 592, 591, 590, 589, 588, 587, 586, - 585, 584, 583, 582, 581, 575, 574, 573, 572, 571, - 570, 569, 568, 567, 566, 560, 559, 558, 557, 556, - 555, 554, 553, 552, 551, 550, 545, 544, 543, 542, - - 541, 540, 539, 538, 537, 536, 535, 532, 531, 530, - 529, 528, 527, 521, 520, 519, 518, 517, 516, 515, - 514, 513, 512, 511, 510, 509, 508, 507, 506, 505, - 504, 498, 497, 496, 495, 494, 493, 492, 491, 490, - 489, 488, 487, 486, 485, 484, 483, 482, 481, 480, - 479, 478, 477, 476, 475, 474, 473, 472, 471, 470, - 469, 468, 467, 466, 465, 464, 463, 453, 452, 451, - 450, 449, 443, 442, 441, 440, 439, 438, 437, 436, - 435, 434, 433, 432, 431, 430, 429, 428, 427, 426, - 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, 388, 387, 386, 385, 384, 383, 382, 381, 377, - 373, 372, 371, 370, 369, 365, 364, 363, 362, 361, - 360, 359, 358, 354, 353, 352, 349, 348, 347, 346, - 345, 344, 343, 339, 338, 337, 336, 335, 332, 331, - 330, 329, 328, 327, 326, 325, 324, 323, 322, 321, - 320, 319, 318, 317, 316, 315, 314, 313, 312, 311, - 310, 309, 308, 304, 303, 302, 301, 300, 299, 298, - 297, 296, 295, 294, 293, 292, 291, 290, 289, 288, - - 287, 286, 285, 284, 283, 282, 281, 280, 279, 278, - 277, 276, 273, 272, 271, 268, 267, 266, 265, 264, - 254, 253, 252, 251, 250, 247, 246, 245, 238, 237, - 236, 235, 234, 233, 230, 229, 228, 227, 226, 225, - 224, 223, 220, 217, 216, 215, 212, 211, 210, 204, - 203, 202, 201, 200, 199, 198, 197, 192, 191, 190, - 189, 188, 187, 186, 185, 182, 181, 180, 179, 178, - 177, 176, 175, 174, 173, 172, 161, 149, 125, 109, - 81, 69, 63, 60, 59, 812, 57, 57, 7, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812 + 49, 61, 64, 804, 66, 68, 68, 68, 68, 68, + 68, 68, 79, 80, 85, 65, 67, 87, 62, 70, + 119, 71, 71, 71, 71, 71, 71, 72, 82, 83, + 86, 121, 88, 89, 120, 122, 73, 74, 835, 101, + 90, 102, 91, 93, 75, 76, 92, 94, 123, 126, + 103, 758, 73, 74, 95, 241, 97, 96, 183, 184, + + 98, 110, 124, 835, 242, 127, 99, 75, 128, 111, + 76, 70, 100, 77, 77, 77, 77, 77, 77, 77, + 129, 112, 152, 104, 58, 805, 153, 150, 73, 74, + 130, 105, 154, 155, 106, 195, 78, 107, 138, 113, + 774, 139, 114, 108, 73, 74, 115, 116, 131, 196, + 140, 117, 810, 142, 118, 132, 133, 141, 143, 78, + 134, 160, 144, 160, 146, 145, 135, 136, 147, 137, + 151, 58, 193, 58, 164, 165, 231, 156, 148, 213, + 239, 240, 218, 194, 157, 167, 168, 214, 158, 219, + 164, 165, 232, 159, 162, 162, 162, 162, 162, 162, + + 162, 167, 168, 70, 243, 72, 72, 72, 72, 72, + 72, 72, 244, 248, 811, 221, 249, 812, 169, 169, + 73, 74, 170, 170, 170, 170, 170, 170, 170, 222, + 813, 205, 154, 155, 206, 207, 73, 74, 208, 152, + 209, 58, 816, 153, 154, 155, 160, 817, 160, 162, + 162, 162, 162, 162, 162, 162, 256, 256, 258, 259, + 257, 257, 257, 257, 257, 257, 257, 170, 170, 170, + 170, 170, 170, 170, 258, 259, 263, 156, 269, 274, + 275, 305, 306, 307, 157, 333, 818, 546, 158, 156, + 785, 548, 270, 159, 334, 819, 157, 547, 786, 263, + + 158, 549, 260, 260, 822, 159, 261, 261, 261, 261, + 261, 261, 261, 170, 170, 170, 170, 170, 170, 170, + 340, 341, 342, 355, 356, 357, 366, 367, 368, 262, + 257, 257, 257, 257, 257, 257, 257, 257, 257, 257, + 257, 257, 257, 257, 796, 262, 374, 375, 376, 825, + 350, 350, 797, 165, 351, 351, 351, 351, 351, 351, + 351, 261, 261, 261, 261, 261, 261, 261, 826, 165, + 261, 261, 261, 261, 261, 261, 261, 378, 379, 380, + 389, 390, 391, 423, 424, 425, 168, 351, 351, 351, + 351, 351, 351, 351, 351, 351, 351, 351, 351, 351, + + 351, 806, 168, 444, 445, 446, 454, 455, 456, 807, + 259, 457, 458, 459, 447, 448, 460, 461, 462, 499, + 500, 501, 522, 523, 524, 490, 259, 831, 639, 832, + 502, 503, 68, 525, 526, 561, 562, 563, 640, 533, + 534, 534, 534, 534, 534, 534, 564, 565, 576, 577, + 641, 576, 577, 796, 576, 577, 656, 657, 775, 642, + 643, 797, 578, 578, 578, 578, 578, 578, 580, 580, + 580, 580, 580, 580, 580, 596, 597, 598, 614, 615, + 616, 576, 577, 656, 657, 581, 579, 599, 576, 577, + 617, 775, 808, 166, 802, 619, 620, 620, 620, 620, + + 620, 620, 578, 578, 578, 578, 578, 578, 576, 577, + 806, 579, 759, 776, 759, 808, 656, 657, 807, 760, + 622, 760, 580, 580, 580, 580, 580, 580, 580, 623, + 658, 658, 658, 658, 658, 658, 798, 798, 801, 800, + 624, 656, 657, 799, 799, 814, 776, 809, 656, 657, + 829, 795, 829, 815, 659, 660, 660, 660, 660, 660, + 660, 660, 658, 658, 658, 658, 658, 658, 656, 657, + 809, 827, 820, 823, 794, 793, 792, 791, 828, 659, + 821, 824, 660, 660, 660, 660, 660, 660, 660, 820, + 823, 830, 827, 830, 833, 833, 790, 821, 824, 828, + + 789, 788, 834, 834, 56, 56, 56, 56, 56, 84, + 84, 84, 163, 163, 163, 171, 171, 255, 787, 255, + 255, 255, 621, 621, 690, 690, 784, 783, 782, 781, + 780, 779, 778, 777, 773, 772, 771, 770, 769, 768, + 767, 766, 765, 764, 763, 762, 761, 758, 757, 756, + 755, 754, 753, 752, 751, 750, 749, 748, 747, 746, + 745, 744, 743, 742, 741, 740, 739, 738, 737, 736, + 735, 734, 733, 732, 731, 730, 729, 728, 727, 726, + 725, 724, 723, 722, 721, 720, 719, 718, 717, 716, + 715, 714, 713, 712, 711, 710, 709, 708, 707, 706, + + 705, 704, 703, 702, 701, 700, 699, 698, 697, 696, + 695, 694, 693, 692, 691, 689, 688, 687, 686, 685, + 684, 683, 682, 681, 680, 679, 678, 677, 676, 675, + 674, 673, 672, 671, 670, 669, 668, 667, 666, 665, + 664, 663, 662, 661, 655, 654, 653, 652, 651, 650, + 649, 648, 647, 646, 645, 644, 638, 637, 636, 635, + 634, 633, 632, 631, 630, 629, 628, 627, 626, 625, + 618, 613, 612, 611, 610, 609, 608, 607, 606, 605, + 604, 603, 602, 601, 600, 595, 594, 593, 592, 591, + 590, 589, 588, 587, 586, 585, 584, 583, 582, 581, + + 575, 574, 573, 572, 571, 570, 569, 568, 567, 566, + 560, 559, 558, 557, 556, 555, 554, 553, 552, 551, + 550, 545, 544, 543, 542, 541, 540, 539, 538, 537, + 536, 535, 532, 531, 530, 529, 528, 527, 521, 520, + 519, 518, 517, 516, 515, 514, 513, 512, 511, 510, + 509, 508, 507, 506, 505, 504, 498, 497, 496, 495, + 494, 493, 492, 491, 490, 489, 488, 487, 486, 485, + 484, 483, 482, 481, 480, 479, 478, 477, 476, 475, + 474, 473, 472, 471, 470, 469, 468, 467, 466, 465, + 464, 463, 453, 452, 451, 450, 449, 443, 442, 441, + + 440, 439, 438, 437, 436, 435, 434, 433, 432, 431, + 430, 429, 428, 427, 426, 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, 388, 387, 386, 385, + 384, 383, 382, 381, 377, 373, 372, 371, 370, 369, + 365, 364, 363, 362, 361, 360, 359, 358, 354, 353, + 352, 349, 348, 347, 346, 345, 344, 343, 339, 338, + 337, 336, 335, 332, 331, 330, 329, 328, 327, 326, + 325, 324, 323, 322, 321, 320, 319, 318, 317, 316, + + 315, 314, 313, 312, 311, 310, 309, 308, 304, 303, + 302, 301, 300, 299, 298, 297, 296, 295, 294, 293, + 292, 291, 290, 289, 288, 287, 286, 285, 284, 283, + 282, 281, 280, 279, 278, 277, 276, 273, 272, 271, + 268, 267, 266, 265, 264, 254, 253, 252, 251, 250, + 247, 246, 245, 238, 237, 236, 235, 234, 233, 230, + 229, 228, 227, 226, 225, 224, 223, 220, 217, 216, + 215, 212, 211, 210, 204, 203, 202, 201, 200, 199, + 198, 197, 192, 191, 190, 189, 188, 187, 186, 185, + 182, 181, 180, 179, 178, 177, 176, 175, 174, 173, + + 172, 161, 149, 125, 109, 81, 69, 63, 60, 59, + 835, 57, 57, 7, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835 } ; -static yyconst flex_int16_t yy_chk[1255] = +static yyconst flex_int16_t yy_chk[1283] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -835,138 +853,141 @@ static yyconst flex_int16_t yy_chk[1255] = 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 2, 9, 803, 9, 2, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 9, + 791, 9, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 3, 3, 13, 15, 801, 16, 17, - 17, 17, 17, 17, 17, 17, 21, 21, 71, 15, - 16, 25, 13, 19, 46, 19, 19, 19, 19, 19, - 19, 19, 23, 23, 25, 26, 27, 800, 27, 33, - 19, 19, 27, 71, 28, 19, 19, 33, 28, 35, - 26, 26, 36, 19, 19, 28, 36, 29, 28, 33, - 50, 29, 50, 35, 46, 96, 96, 29, 19, 795, - - 37, 19, 20, 29, 20, 20, 20, 20, 20, 20, - 20, 30, 135, 30, 37, 31, 58, 40, 58, 20, - 20, 39, 30, 31, 20, 105, 31, 40, 135, 31, - 106, 34, 20, 20, 34, 31, 105, 39, 34, 34, - 39, 41, 42, 34, 106, 42, 34, 20, 41, 41, - 160, 44, 160, 41, 42, 44, 48, 48, 43, 41, - 41, 42, 41, 43, 47, 44, 47, 43, 47, 126, - 43, 53, 53, 53, 53, 53, 53, 53, 68, 68, - 70, 70, 120, 126, 142, 142, 148, 143, 124, 148, - 120, 68, 68, 70, 70, 124, 143, 116, 48, 144, - - 116, 116, 153, 153, 116, 48, 116, 144, 152, 48, - 152, 794, 152, 180, 48, 72, 793, 72, 72, 72, - 72, 72, 72, 72, 154, 154, 171, 180, 166, 166, - 73, 73, 72, 72, 73, 73, 73, 73, 73, 73, - 73, 166, 166, 784, 153, 72, 72, 184, 184, 171, - 241, 153, 215, 215, 215, 153, 247, 247, 247, 241, - 153, 268, 268, 268, 621, 621, 154, 279, 279, 279, - 288, 288, 288, 154, 292, 292, 292, 154, 301, 301, - 301, 754, 154, 162, 162, 162, 162, 162, 162, 162, - 164, 164, 655, 655, 164, 164, 164, 164, 164, 164, - - 164, 167, 167, 688, 688, 167, 167, 167, 167, 167, - 167, 167, 169, 169, 169, 169, 169, 169, 169, 170, - 170, 170, 170, 170, 170, 170, 256, 256, 256, 256, - 256, 256, 256, 754, 783, 170, 257, 257, 257, 257, - 257, 257, 257, 338, 338, 338, 782, 781, 170, 258, - 258, 780, 257, 258, 258, 258, 258, 258, 258, 258, - 393, 393, 393, 777, 776, 257, 260, 260, 260, 260, - 260, 260, 260, 261, 261, 261, 261, 261, 261, 261, - 350, 350, 350, 350, 350, 350, 350, 775, 774, 261, - 351, 351, 351, 351, 351, 351, 351, 382, 382, 382, - - 581, 773, 261, 394, 394, 394, 351, 772, 382, 382, - 395, 395, 395, 443, 443, 443, 483, 483, 483, 351, - 490, 504, 505, 771, 443, 443, 770, 483, 483, 504, - 505, 519, 519, 519, 490, 490, 490, 490, 490, 490, - 490, 581, 519, 519, 533, 533, 534, 534, 765, 763, - 762, 768, 581, 619, 619, 554, 554, 554, 576, 576, - 534, 534, 534, 534, 534, 534, 534, 554, 573, 573, - 573, 790, 576, 576, 576, 576, 576, 576, 576, 533, - 573, 578, 578, 739, 760, 605, 757, 756, 619, 755, - 739, 580, 580, 605, 606, 578, 578, 578, 578, 578, - - 578, 606, 606, 768, 533, 580, 580, 580, 580, 580, - 580, 580, 753, 619, 620, 620, 769, 778, 786, 753, - 779, 657, 657, 790, 769, 778, 786, 779, 620, 620, - 620, 620, 620, 620, 620, 657, 657, 657, 657, 657, - 657, 659, 659, 787, 798, 789, 796, 752, 751, 750, - 749, 787, 789, 748, 796, 659, 659, 659, 659, 659, - 659, 659, 799, 804, 807, 808, 810, 747, 746, 745, - 799, 804, 807, 808, 810, 744, 743, 742, 741, 740, - 738, 737, 734, 731, 730, 729, 728, 727, 725, 724, - 722, 720, 717, 716, 714, 713, 798, 813, 813, 813, - - 813, 813, 813, 813, 813, 814, 814, 814, 814, 814, - 815, 815, 815, 815, 815, 816, 816, 817, 817, 818, - 818, 818, 819, 819, 711, 819, 819, 819, 819, 819, - 820, 820, 820, 710, 709, 708, 820, 821, 821, 821, - 822, 822, 822, 707, 706, 705, 822, 823, 823, 823, - 704, 703, 702, 701, 699, 698, 697, 696, 695, 694, - 692, 691, 690, 689, 687, 686, 685, 684, 683, 682, - 681, 680, 679, 678, 677, 676, 675, 674, 673, 672, - 671, 670, 668, 667, 666, 665, 664, 663, 662, 661, - 660, 653, 651, 650, 648, 647, 646, 645, 644, 643, - - 642, 641, 640, 639, 638, 637, 636, 634, 633, 632, - 631, 630, 629, 628, 626, 625, 624, 623, 622, 618, - 617, 616, 615, 614, 613, 612, 611, 610, 609, 608, - 607, 601, 599, 598, 597, 596, 592, 591, 590, 589, - 588, 587, 586, 585, 584, 575, 571, 570, 568, 567, - 565, 564, 563, 562, 561, 560, 559, 558, 557, 555, - 553, 552, 551, 550, 549, 548, 547, 546, 545, 544, - 542, 541, 537, 536, 535, 532, 531, 529, 528, 526, - 525, 524, 523, 522, 520, 518, 517, 516, 515, 514, - 513, 511, 510, 509, 508, 507, 503, 502, 501, 500, - - 499, 498, 495, 494, 493, 492, 491, 489, 488, 487, - 486, 485, 484, 482, 481, 474, 473, 470, 469, 466, - 465, 464, 463, 452, 451, 450, 448, 447, 446, 445, - 444, 441, 439, 438, 437, 435, 434, 432, 431, 430, - 429, 427, 426, 421, 420, 418, 417, 416, 415, 414, - 413, 412, 411, 410, 409, 407, 406, 405, 404, 403, - 402, 401, 400, 399, 398, 397, 396, 392, 388, 387, - 386, 383, 381, 371, 369, 365, 364, 363, 362, 360, - 358, 353, 352, 349, 348, 347, 346, 345, 344, 339, - 337, 336, 335, 334, 333, 331, 330, 327, 326, 325, - - 324, 323, 322, 321, 320, 319, 318, 317, 316, 315, - 314, 313, 312, 311, 310, 309, 308, 307, 306, 305, - 302, 300, 299, 298, 297, 296, 295, 294, 293, 291, - 287, 285, 284, 283, 282, 278, 277, 276, 275, 274, - 273, 272, 271, 267, 265, 264, 254, 253, 252, 251, - 250, 249, 248, 246, 245, 244, 243, 242, 240, 239, - 238, 237, 236, 235, 234, 233, 232, 231, 230, 229, - 228, 227, 226, 225, 224, 223, 222, 221, 220, 219, - 218, 217, 216, 214, 213, 212, 211, 210, 209, 208, - 207, 206, 205, 204, 203, 202, 201, 200, 199, 198, - - 196, 195, 194, 193, 192, 191, 190, 189, 188, 187, - 186, 185, 183, 182, 181, 179, 178, 177, 176, 174, - 159, 158, 157, 156, 149, 147, 146, 145, 141, 140, - 139, 138, 137, 136, 134, 133, 132, 131, 130, 129, - 128, 127, 125, 123, 122, 121, 119, 118, 117, 115, - 114, 112, 111, 110, 109, 108, 107, 104, 103, 102, - 101, 100, 99, 98, 97, 95, 94, 93, 92, 91, - 90, 89, 88, 87, 83, 79, 52, 45, 38, 32, - 22, 18, 14, 12, 11, 7, 6, 5, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, - 812, 812, 812, 812 + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 13, 15, 792, 16, 17, 17, 17, 17, 17, + 17, 17, 21, 21, 25, 15, 16, 26, 13, 19, + 35, 19, 19, 19, 19, 19, 19, 19, 23, 23, + 25, 36, 26, 26, 35, 36, 19, 19, 71, 30, + 27, 30, 27, 28, 19, 19, 27, 28, 37, 39, + 30, 758, 19, 19, 28, 143, 29, 28, 96, 96, + + 29, 33, 37, 71, 143, 39, 29, 19, 39, 33, + 19, 20, 29, 20, 20, 20, 20, 20, 20, 20, + 40, 33, 47, 31, 47, 794, 47, 46, 20, 20, + 40, 31, 48, 48, 31, 106, 20, 31, 42, 34, + 758, 42, 34, 31, 20, 20, 34, 34, 41, 106, + 42, 34, 802, 43, 34, 41, 41, 42, 43, 20, + 41, 50, 43, 50, 44, 43, 41, 41, 44, 41, + 46, 58, 105, 58, 68, 68, 135, 48, 44, 120, + 142, 142, 124, 105, 48, 70, 70, 120, 48, 124, + 68, 68, 135, 48, 53, 53, 53, 53, 53, 53, + + 53, 70, 70, 72, 144, 72, 72, 72, 72, 72, + 72, 72, 144, 148, 803, 126, 148, 804, 73, 73, + 72, 72, 73, 73, 73, 73, 73, 73, 73, 126, + 805, 116, 153, 153, 116, 116, 72, 72, 116, 152, + 116, 152, 810, 152, 154, 154, 160, 811, 160, 162, + 162, 162, 162, 162, 162, 162, 164, 164, 166, 166, + 164, 164, 164, 164, 164, 164, 164, 169, 169, 169, + 169, 169, 169, 169, 166, 166, 171, 153, 180, 184, + 184, 215, 215, 215, 153, 241, 813, 504, 153, 154, + 776, 505, 180, 153, 241, 814, 154, 504, 776, 171, + + 154, 505, 167, 167, 818, 154, 167, 167, 167, 167, + 167, 167, 167, 170, 170, 170, 170, 170, 170, 170, + 247, 247, 247, 268, 268, 268, 279, 279, 279, 170, + 256, 256, 256, 256, 256, 256, 256, 257, 257, 257, + 257, 257, 257, 257, 786, 170, 288, 288, 288, 822, + 258, 258, 786, 257, 258, 258, 258, 258, 258, 258, + 258, 260, 260, 260, 260, 260, 260, 260, 825, 257, + 261, 261, 261, 261, 261, 261, 261, 292, 292, 292, + 301, 301, 301, 338, 338, 338, 261, 350, 350, 350, + 350, 350, 350, 350, 351, 351, 351, 351, 351, 351, + + 351, 795, 261, 382, 382, 382, 393, 393, 393, 795, + 351, 394, 394, 394, 382, 382, 395, 395, 395, 443, + 443, 443, 483, 483, 483, 490, 351, 830, 605, 831, + 443, 443, 839, 483, 483, 519, 519, 519, 605, 490, + 490, 490, 490, 490, 490, 490, 519, 519, 533, 533, + 606, 621, 621, 796, 534, 534, 656, 656, 760, 606, + 606, 796, 533, 533, 533, 533, 533, 533, 534, 534, + 534, 534, 534, 534, 534, 554, 554, 554, 573, 573, + 573, 576, 576, 690, 690, 581, 533, 554, 578, 578, + 573, 775, 799, 840, 790, 576, 576, 576, 576, 576, + + 576, 576, 578, 578, 578, 578, 578, 578, 580, 580, + 806, 533, 744, 760, 759, 808, 619, 619, 806, 744, + 581, 759, 580, 580, 580, 580, 580, 580, 580, 581, + 619, 619, 619, 619, 619, 619, 787, 798, 789, 788, + 581, 620, 620, 787, 798, 809, 775, 799, 658, 658, + 828, 785, 829, 809, 619, 620, 620, 620, 620, 620, + 620, 620, 658, 658, 658, 658, 658, 658, 660, 660, + 808, 826, 815, 819, 784, 783, 782, 781, 826, 619, + 815, 819, 660, 660, 660, 660, 660, 660, 660, 820, + 823, 828, 827, 829, 832, 833, 780, 820, 823, 827, + + 779, 778, 832, 833, 836, 836, 836, 836, 836, 837, + 837, 837, 838, 838, 838, 841, 841, 842, 777, 842, + 842, 842, 843, 843, 844, 844, 774, 771, 769, 768, + 766, 763, 762, 761, 757, 756, 755, 754, 753, 752, + 751, 750, 749, 748, 747, 746, 745, 743, 742, 741, + 738, 735, 734, 733, 732, 731, 729, 728, 726, 724, + 721, 720, 719, 717, 716, 714, 713, 712, 711, 710, + 709, 708, 707, 706, 705, 704, 702, 701, 700, 699, + 698, 697, 695, 694, 693, 692, 691, 689, 688, 687, + 686, 685, 684, 683, 682, 681, 680, 679, 678, 677, + + 676, 675, 674, 673, 672, 670, 669, 668, 667, 666, + 665, 664, 663, 662, 661, 654, 652, 651, 649, 648, + 647, 646, 645, 644, 643, 642, 641, 640, 639, 638, + 637, 635, 634, 633, 632, 631, 630, 629, 627, 626, + 625, 624, 623, 622, 618, 617, 616, 615, 614, 613, + 612, 611, 610, 609, 608, 607, 601, 599, 598, 597, + 596, 592, 591, 590, 589, 588, 587, 586, 585, 584, + 575, 571, 570, 568, 567, 565, 564, 563, 562, 561, + 560, 559, 558, 557, 555, 553, 552, 551, 550, 549, + 548, 547, 546, 545, 544, 542, 541, 537, 536, 535, + + 532, 531, 529, 528, 526, 525, 524, 523, 522, 520, + 518, 517, 516, 515, 514, 513, 511, 510, 509, 508, + 507, 503, 502, 501, 500, 499, 498, 495, 494, 493, + 492, 491, 489, 488, 487, 486, 485, 484, 482, 481, + 474, 473, 470, 469, 466, 465, 464, 463, 452, 451, + 450, 448, 447, 446, 445, 444, 441, 439, 438, 437, + 435, 434, 432, 431, 430, 429, 427, 426, 421, 420, + 418, 417, 416, 415, 414, 413, 412, 411, 410, 409, + 407, 406, 405, 404, 403, 402, 401, 400, 399, 398, + 397, 396, 392, 388, 387, 386, 383, 381, 371, 369, + + 365, 364, 363, 362, 360, 358, 353, 352, 349, 348, + 347, 346, 345, 344, 339, 337, 336, 335, 334, 333, + 331, 330, 327, 326, 325, 324, 323, 322, 321, 320, + 319, 318, 317, 316, 315, 314, 313, 312, 311, 310, + 309, 308, 307, 306, 305, 302, 300, 299, 298, 297, + 296, 295, 294, 293, 291, 287, 285, 284, 283, 282, + 278, 277, 276, 275, 274, 273, 272, 271, 267, 265, + 264, 254, 253, 252, 251, 250, 249, 248, 246, 245, + 244, 243, 242, 240, 239, 238, 237, 236, 235, 234, + 233, 232, 231, 230, 229, 228, 227, 226, 225, 224, + + 223, 222, 221, 220, 219, 218, 217, 216, 214, 213, + 212, 211, 210, 209, 208, 207, 206, 205, 204, 203, + 202, 201, 200, 199, 198, 196, 195, 194, 193, 192, + 191, 190, 189, 188, 187, 186, 185, 183, 182, 181, + 179, 178, 177, 176, 174, 159, 158, 157, 156, 149, + 147, 146, 145, 141, 140, 139, 138, 137, 136, 134, + 133, 132, 131, 130, 129, 128, 127, 125, 123, 122, + 121, 119, 118, 117, 115, 114, 112, 111, 110, 109, + 108, 107, 104, 103, 102, 101, 100, 99, 98, 97, + 95, 94, 93, 92, 91, 90, 89, 88, 87, 83, + + 79, 52, 45, 38, 32, 22, 18, 14, 12, 11, + 7, 6, 5, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, + 835, 835 } ; /* The intent behind this definition is that it'll catch @@ -976,8 +997,8 @@ static yyconst flex_int16_t yy_chk[1255] = #define yymore() yymore_used_but_not_detected #define YY_MORE_ADJ 0 #define YY_RESTORE_YY_MORE_OFFSET -#line 1 "glsl_lexer.lpp" -#line 2 "glsl_lexer.lpp" +#line 1 "glsl_lexer.ll" +#line 2 "glsl_lexer.ll" /* * Copyright © 2008, 2009 Intel Corporation * @@ -1001,10 +1022,17 @@ static yyconst flex_int16_t yy_chk[1255] = * DEALINGS IN THE SOFTWARE. */ #include <ctype.h> +#include "strtod.h" #include "ast.h" #include "glsl_parser_extras.h" #include "glsl_parser.h" +static int classify_identifier(struct _mesa_glsl_parse_state *, const char *); + +#ifdef _MSC_VER +#define YY_NO_UNISTD_H +#endif + #define YY_USER_ACTION \ do { \ yylloc->source = 0; \ @@ -1040,7 +1068,7 @@ static yyconst flex_int16_t yy_chk[1255] = return ERROR_TOK; \ } else { \ yylval->identifier = strdup(yytext); \ - return IDENTIFIER; \ + return classify_identifier(yyextra, yytext); \ } \ } while (0) @@ -1054,7 +1082,7 @@ static yyconst flex_int16_t yy_chk[1255] = */ #define ES yyextra->es_shader -#line 1058 "glsl_lexer.cpp" +#line 1086 "glsl_lexer.cpp" #define INITIAL 0 #define PP 1 @@ -1141,10 +1169,6 @@ int _mesa_glsl_get_lineno (yyscan_t yyscanner ); void _mesa_glsl_set_lineno (int line_number ,yyscan_t yyscanner ); -int _mesa_glsl_get_column (yyscan_t yyscanner ); - -void _mesa_glsl_set_column (int column_no ,yyscan_t yyscanner ); - YYSTYPE * _mesa_glsl_get_lval (yyscan_t yyscanner ); void _mesa_glsl_set_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner ); @@ -1185,7 +1209,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. */ @@ -1204,7 +1233,7 @@ static int input (yyscan_t yyscanner ); if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ { \ int c = '*'; \ - unsigned n; \ + size_t n; \ for ( n = 0; n < max_size && \ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ @@ -1292,10 +1321,10 @@ YY_DECL register int yy_act; struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; -#line 94 "glsl_lexer.lpp" +#line 101 "glsl_lexer.ll" -#line 1299 "glsl_lexer.cpp" +#line 1328 "glsl_lexer.cpp" yylval = yylval_param; @@ -1353,13 +1382,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 >= 813 ) + if ( yy_current_state >= 836 ) 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 != 812 ); + while ( yy_current_state != 835 ); yy_cp = yyg->yy_last_accepting_cpos; yy_current_state = yyg->yy_last_accepting_state; @@ -1381,7 +1410,7 @@ do_action: /* This label is used only to access EOF actions. */ case 1: YY_RULE_SETUP -#line 96 "glsl_lexer.lpp" +#line 103 "glsl_lexer.ll" ; YY_BREAK /* Preprocessor tokens. */ @@ -1390,17 +1419,17 @@ case 2: yyg->yy_c_buf_p = yy_cp -= 1; YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 99 "glsl_lexer.lpp" +#line 106 "glsl_lexer.ll" ; YY_BREAK case 3: YY_RULE_SETUP -#line 100 "glsl_lexer.lpp" +#line 107 "glsl_lexer.ll" { BEGIN PP; return VERSION; } YY_BREAK case 4: YY_RULE_SETUP -#line 101 "glsl_lexer.lpp" +#line 108 "glsl_lexer.ll" { BEGIN PP; return EXTENSION; } YY_BREAK case 5: @@ -1408,7 +1437,7 @@ case 5: yyg->yy_c_buf_p = yy_cp -= 1; YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 102 "glsl_lexer.lpp" +#line 109 "glsl_lexer.ll" { /* Eat characters until the first digit is * encountered @@ -1430,7 +1459,7 @@ case 6: yyg->yy_c_buf_p = yy_cp -= 1; YY_DO_BEFORE_ACTION; /* set up yytext again */ YY_RULE_SETUP -#line 117 "glsl_lexer.lpp" +#line 124 "glsl_lexer.ll" { /* Eat characters until the first digit is * encountered @@ -1448,7 +1477,7 @@ YY_RULE_SETUP YY_BREAK case 7: YY_RULE_SETUP -#line 131 "glsl_lexer.lpp" +#line 138 "glsl_lexer.ll" { BEGIN PP; return PRAGMA_DEBUG_ON; @@ -1456,7 +1485,7 @@ YY_RULE_SETUP YY_BREAK case 8: YY_RULE_SETUP -#line 135 "glsl_lexer.lpp" +#line 142 "glsl_lexer.ll" { BEGIN PP; return PRAGMA_DEBUG_OFF; @@ -1464,7 +1493,7 @@ YY_RULE_SETUP YY_BREAK case 9: YY_RULE_SETUP -#line 139 "glsl_lexer.lpp" +#line 146 "glsl_lexer.ll" { BEGIN PP; return PRAGMA_OPTIMIZE_ON; @@ -1472,7 +1501,7 @@ YY_RULE_SETUP YY_BREAK case 10: YY_RULE_SETUP -#line 143 "glsl_lexer.lpp" +#line 150 "glsl_lexer.ll" { BEGIN PP; return PRAGMA_OPTIMIZE_OFF; @@ -1480,440 +1509,449 @@ YY_RULE_SETUP YY_BREAK case 11: YY_RULE_SETUP -#line 147 "glsl_lexer.lpp" -{ BEGIN PRAGMA; } +#line 154 "glsl_lexer.ll" +{ + BEGIN PP; + return PRAGMA_INVARIANT_ALL; + } YY_BREAK case 12: -/* rule 12 can match eol */ YY_RULE_SETUP -#line 149 "glsl_lexer.lpp" -{ BEGIN 0; yylineno++; yycolumn = 0; } +#line 158 "glsl_lexer.ll" +{ BEGIN PRAGMA; } YY_BREAK case 13: +/* rule 13 can match eol */ YY_RULE_SETUP -#line 150 "glsl_lexer.lpp" -{ } +#line 160 "glsl_lexer.ll" +{ BEGIN 0; yylineno++; yycolumn = 0; } YY_BREAK case 14: YY_RULE_SETUP -#line 152 "glsl_lexer.lpp" +#line 161 "glsl_lexer.ll" { } YY_BREAK case 15: YY_RULE_SETUP -#line 153 "glsl_lexer.lpp" +#line 163 "glsl_lexer.ll" { } YY_BREAK case 16: YY_RULE_SETUP -#line 154 "glsl_lexer.lpp" -return COLON; +#line 164 "glsl_lexer.ll" +{ } YY_BREAK case 17: YY_RULE_SETUP -#line 155 "glsl_lexer.lpp" +#line 165 "glsl_lexer.ll" +return COLON; + YY_BREAK +case 18: +YY_RULE_SETUP +#line 166 "glsl_lexer.ll" { yylval->identifier = strdup(yytext); return IDENTIFIER; } YY_BREAK -case 18: +case 19: YY_RULE_SETUP -#line 159 "glsl_lexer.lpp" +#line 170 "glsl_lexer.ll" { yylval->n = strtol(yytext, NULL, 10); return INTCONSTANT; } YY_BREAK -case 19: -/* rule 19 can match eol */ +case 20: +/* rule 20 can match eol */ YY_RULE_SETUP -#line 163 "glsl_lexer.lpp" +#line 174 "glsl_lexer.ll" { BEGIN 0; yylineno++; yycolumn = 0; return EOL; } YY_BREAK -case 20: -/* rule 20 can match eol */ +case 21: +/* rule 21 can match eol */ YY_RULE_SETUP -#line 165 "glsl_lexer.lpp" +#line 176 "glsl_lexer.ll" { yylineno++; yycolumn = 0; } YY_BREAK -case 21: +case 22: YY_RULE_SETUP -#line 167 "glsl_lexer.lpp" +#line 178 "glsl_lexer.ll" return ATTRIBUTE; YY_BREAK -case 22: +case 23: YY_RULE_SETUP -#line 168 "glsl_lexer.lpp" +#line 179 "glsl_lexer.ll" return CONST_TOK; YY_BREAK -case 23: +case 24: YY_RULE_SETUP -#line 169 "glsl_lexer.lpp" +#line 180 "glsl_lexer.ll" return BOOL_TOK; YY_BREAK -case 24: +case 25: YY_RULE_SETUP -#line 170 "glsl_lexer.lpp" +#line 181 "glsl_lexer.ll" return FLOAT_TOK; YY_BREAK -case 25: +case 26: YY_RULE_SETUP -#line 171 "glsl_lexer.lpp" +#line 182 "glsl_lexer.ll" return INT_TOK; YY_BREAK -case 26: +case 27: YY_RULE_SETUP -#line 172 "glsl_lexer.lpp" +#line 183 "glsl_lexer.ll" KEYWORD(130, 130, UINT_TOK); YY_BREAK -case 27: +case 28: YY_RULE_SETUP -#line 174 "glsl_lexer.lpp" +#line 185 "glsl_lexer.ll" return BREAK; YY_BREAK -case 28: +case 29: YY_RULE_SETUP -#line 175 "glsl_lexer.lpp" +#line 186 "glsl_lexer.ll" return CONTINUE; YY_BREAK -case 29: +case 30: YY_RULE_SETUP -#line 176 "glsl_lexer.lpp" +#line 187 "glsl_lexer.ll" return DO; YY_BREAK -case 30: +case 31: YY_RULE_SETUP -#line 177 "glsl_lexer.lpp" +#line 188 "glsl_lexer.ll" return WHILE; YY_BREAK -case 31: +case 32: YY_RULE_SETUP -#line 178 "glsl_lexer.lpp" +#line 189 "glsl_lexer.ll" return ELSE; YY_BREAK -case 32: +case 33: YY_RULE_SETUP -#line 179 "glsl_lexer.lpp" +#line 190 "glsl_lexer.ll" return FOR; YY_BREAK -case 33: +case 34: YY_RULE_SETUP -#line 180 "glsl_lexer.lpp" +#line 191 "glsl_lexer.ll" return IF; YY_BREAK -case 34: +case 35: YY_RULE_SETUP -#line 181 "glsl_lexer.lpp" +#line 192 "glsl_lexer.ll" return DISCARD; YY_BREAK -case 35: +case 36: YY_RULE_SETUP -#line 182 "glsl_lexer.lpp" +#line 193 "glsl_lexer.ll" return RETURN; YY_BREAK -case 36: +case 37: YY_RULE_SETUP -#line 184 "glsl_lexer.lpp" +#line 195 "glsl_lexer.ll" return BVEC2; YY_BREAK -case 37: +case 38: YY_RULE_SETUP -#line 185 "glsl_lexer.lpp" +#line 196 "glsl_lexer.ll" return BVEC3; YY_BREAK -case 38: +case 39: YY_RULE_SETUP -#line 186 "glsl_lexer.lpp" +#line 197 "glsl_lexer.ll" return BVEC4; YY_BREAK -case 39: +case 40: YY_RULE_SETUP -#line 187 "glsl_lexer.lpp" +#line 198 "glsl_lexer.ll" return IVEC2; YY_BREAK -case 40: +case 41: YY_RULE_SETUP -#line 188 "glsl_lexer.lpp" +#line 199 "glsl_lexer.ll" return IVEC3; YY_BREAK -case 41: +case 42: YY_RULE_SETUP -#line 189 "glsl_lexer.lpp" +#line 200 "glsl_lexer.ll" return IVEC4; YY_BREAK -case 42: +case 43: YY_RULE_SETUP -#line 190 "glsl_lexer.lpp" +#line 201 "glsl_lexer.ll" KEYWORD(130, 130, UVEC2); YY_BREAK -case 43: +case 44: YY_RULE_SETUP -#line 191 "glsl_lexer.lpp" +#line 202 "glsl_lexer.ll" KEYWORD(130, 130, UVEC3); YY_BREAK -case 44: +case 45: YY_RULE_SETUP -#line 192 "glsl_lexer.lpp" +#line 203 "glsl_lexer.ll" KEYWORD(130, 130, UVEC4); YY_BREAK -case 45: +case 46: YY_RULE_SETUP -#line 193 "glsl_lexer.lpp" +#line 204 "glsl_lexer.ll" return VEC2; YY_BREAK -case 46: +case 47: YY_RULE_SETUP -#line 194 "glsl_lexer.lpp" +#line 205 "glsl_lexer.ll" return VEC3; YY_BREAK -case 47: +case 48: YY_RULE_SETUP -#line 195 "glsl_lexer.lpp" +#line 206 "glsl_lexer.ll" return VEC4; YY_BREAK -case 48: +case 49: YY_RULE_SETUP -#line 196 "glsl_lexer.lpp" +#line 207 "glsl_lexer.ll" return MAT2X2; YY_BREAK -case 49: +case 50: YY_RULE_SETUP -#line 197 "glsl_lexer.lpp" +#line 208 "glsl_lexer.ll" return MAT3X3; YY_BREAK -case 50: +case 51: YY_RULE_SETUP -#line 198 "glsl_lexer.lpp" +#line 209 "glsl_lexer.ll" return MAT4X4; YY_BREAK -case 51: +case 52: YY_RULE_SETUP -#line 199 "glsl_lexer.lpp" +#line 210 "glsl_lexer.ll" KEYWORD(120, 120, MAT2X2); YY_BREAK -case 52: +case 53: YY_RULE_SETUP -#line 200 "glsl_lexer.lpp" +#line 211 "glsl_lexer.ll" KEYWORD(120, 120, MAT2X3); YY_BREAK -case 53: +case 54: YY_RULE_SETUP -#line 201 "glsl_lexer.lpp" +#line 212 "glsl_lexer.ll" KEYWORD(120, 120, MAT2X4); YY_BREAK -case 54: +case 55: YY_RULE_SETUP -#line 202 "glsl_lexer.lpp" +#line 213 "glsl_lexer.ll" KEYWORD(120, 120, MAT3X2); YY_BREAK -case 55: +case 56: YY_RULE_SETUP -#line 203 "glsl_lexer.lpp" +#line 214 "glsl_lexer.ll" KEYWORD(120, 120, MAT3X3); YY_BREAK -case 56: +case 57: YY_RULE_SETUP -#line 204 "glsl_lexer.lpp" +#line 215 "glsl_lexer.ll" KEYWORD(120, 120, MAT3X4); YY_BREAK -case 57: +case 58: YY_RULE_SETUP -#line 205 "glsl_lexer.lpp" +#line 216 "glsl_lexer.ll" KEYWORD(120, 120, MAT4X2); YY_BREAK -case 58: +case 59: YY_RULE_SETUP -#line 206 "glsl_lexer.lpp" +#line 217 "glsl_lexer.ll" KEYWORD(120, 120, MAT4X3); YY_BREAK -case 59: +case 60: YY_RULE_SETUP -#line 207 "glsl_lexer.lpp" +#line 218 "glsl_lexer.ll" KEYWORD(120, 120, MAT4X4); YY_BREAK -case 60: +case 61: YY_RULE_SETUP -#line 209 "glsl_lexer.lpp" +#line 220 "glsl_lexer.ll" return IN_TOK; YY_BREAK -case 61: +case 62: YY_RULE_SETUP -#line 210 "glsl_lexer.lpp" +#line 221 "glsl_lexer.ll" return OUT_TOK; YY_BREAK -case 62: +case 63: YY_RULE_SETUP -#line 211 "glsl_lexer.lpp" +#line 222 "glsl_lexer.ll" return INOUT_TOK; YY_BREAK -case 63: +case 64: YY_RULE_SETUP -#line 212 "glsl_lexer.lpp" +#line 223 "glsl_lexer.ll" return UNIFORM; YY_BREAK -case 64: +case 65: YY_RULE_SETUP -#line 213 "glsl_lexer.lpp" +#line 224 "glsl_lexer.ll" return VARYING; YY_BREAK -case 65: +case 66: YY_RULE_SETUP -#line 214 "glsl_lexer.lpp" +#line 225 "glsl_lexer.ll" KEYWORD(120, 120, CENTROID); YY_BREAK -case 66: +case 67: YY_RULE_SETUP -#line 215 "glsl_lexer.lpp" +#line 226 "glsl_lexer.ll" KEYWORD(120 || ES, 120 || ES, INVARIANT); YY_BREAK -case 67: +case 68: YY_RULE_SETUP -#line 216 "glsl_lexer.lpp" +#line 227 "glsl_lexer.ll" KEYWORD(130 || ES, 130, FLAT); YY_BREAK -case 68: +case 69: YY_RULE_SETUP -#line 217 "glsl_lexer.lpp" +#line 228 "glsl_lexer.ll" KEYWORD(130, 130, SMOOTH); YY_BREAK -case 69: +case 70: YY_RULE_SETUP -#line 218 "glsl_lexer.lpp" +#line 229 "glsl_lexer.ll" KEYWORD(130, 130, NOPERSPECTIVE); YY_BREAK -case 70: +case 71: YY_RULE_SETUP -#line 220 "glsl_lexer.lpp" +#line 231 "glsl_lexer.ll" return SAMPLER1D; YY_BREAK -case 71: +case 72: YY_RULE_SETUP -#line 221 "glsl_lexer.lpp" +#line 232 "glsl_lexer.ll" return SAMPLER2D; YY_BREAK -case 72: +case 73: YY_RULE_SETUP -#line 222 "glsl_lexer.lpp" +#line 233 "glsl_lexer.ll" return SAMPLER3D; YY_BREAK -case 73: +case 74: YY_RULE_SETUP -#line 223 "glsl_lexer.lpp" +#line 234 "glsl_lexer.ll" return SAMPLERCUBE; YY_BREAK -case 74: +case 75: YY_RULE_SETUP -#line 224 "glsl_lexer.lpp" +#line 235 "glsl_lexer.ll" KEYWORD(130, 130, SAMPLER1DARRAY); YY_BREAK -case 75: +case 76: YY_RULE_SETUP -#line 225 "glsl_lexer.lpp" +#line 236 "glsl_lexer.ll" KEYWORD(130, 130, SAMPLER2DARRAY); YY_BREAK -case 76: +case 77: YY_RULE_SETUP -#line 226 "glsl_lexer.lpp" +#line 237 "glsl_lexer.ll" return SAMPLER1DSHADOW; YY_BREAK -case 77: +case 78: YY_RULE_SETUP -#line 227 "glsl_lexer.lpp" +#line 238 "glsl_lexer.ll" return SAMPLER2DSHADOW; YY_BREAK -case 78: +case 79: YY_RULE_SETUP -#line 228 "glsl_lexer.lpp" +#line 239 "glsl_lexer.ll" KEYWORD(130, 130, SAMPLERCUBESHADOW); YY_BREAK -case 79: +case 80: YY_RULE_SETUP -#line 229 "glsl_lexer.lpp" +#line 240 "glsl_lexer.ll" KEYWORD(130, 130, SAMPLER1DARRAYSHADOW); YY_BREAK -case 80: +case 81: YY_RULE_SETUP -#line 230 "glsl_lexer.lpp" +#line 241 "glsl_lexer.ll" KEYWORD(130, 130, SAMPLER2DARRAYSHADOW); YY_BREAK -case 81: +case 82: YY_RULE_SETUP -#line 231 "glsl_lexer.lpp" +#line 242 "glsl_lexer.ll" KEYWORD(130, 130, ISAMPLER1D); YY_BREAK -case 82: +case 83: YY_RULE_SETUP -#line 232 "glsl_lexer.lpp" +#line 243 "glsl_lexer.ll" KEYWORD(130, 130, ISAMPLER2D); YY_BREAK -case 83: +case 84: YY_RULE_SETUP -#line 233 "glsl_lexer.lpp" +#line 244 "glsl_lexer.ll" KEYWORD(130, 130, ISAMPLER3D); YY_BREAK -case 84: +case 85: YY_RULE_SETUP -#line 234 "glsl_lexer.lpp" +#line 245 "glsl_lexer.ll" KEYWORD(130, 130, ISAMPLERCUBE); YY_BREAK -case 85: +case 86: YY_RULE_SETUP -#line 235 "glsl_lexer.lpp" +#line 246 "glsl_lexer.ll" KEYWORD(130, 130, ISAMPLER1DARRAY); YY_BREAK -case 86: +case 87: YY_RULE_SETUP -#line 236 "glsl_lexer.lpp" +#line 247 "glsl_lexer.ll" KEYWORD(130, 130, ISAMPLER2DARRAY); YY_BREAK -case 87: +case 88: YY_RULE_SETUP -#line 237 "glsl_lexer.lpp" +#line 248 "glsl_lexer.ll" KEYWORD(130, 130, USAMPLER1D); YY_BREAK -case 88: +case 89: YY_RULE_SETUP -#line 238 "glsl_lexer.lpp" +#line 249 "glsl_lexer.ll" KEYWORD(130, 130, USAMPLER2D); YY_BREAK -case 89: +case 90: YY_RULE_SETUP -#line 239 "glsl_lexer.lpp" +#line 250 "glsl_lexer.ll" KEYWORD(130, 130, USAMPLER3D); YY_BREAK -case 90: +case 91: YY_RULE_SETUP -#line 240 "glsl_lexer.lpp" +#line 251 "glsl_lexer.ll" KEYWORD(130, 130, USAMPLERCUBE); YY_BREAK -case 91: +case 92: YY_RULE_SETUP -#line 241 "glsl_lexer.lpp" +#line 252 "glsl_lexer.ll" KEYWORD(130, 130, USAMPLER1DARRAY); YY_BREAK -case 92: +case 93: YY_RULE_SETUP -#line 242 "glsl_lexer.lpp" +#line 253 "glsl_lexer.ll" KEYWORD(130, 130, USAMPLER2DARRAY); YY_BREAK -case 93: +case 94: YY_RULE_SETUP -#line 245 "glsl_lexer.lpp" +#line 256 "glsl_lexer.ll" return STRUCT; YY_BREAK -case 94: +case 95: YY_RULE_SETUP -#line 246 "glsl_lexer.lpp" +#line 257 "glsl_lexer.ll" return VOID_TOK; YY_BREAK -case 95: +case 96: YY_RULE_SETUP -#line 248 "glsl_lexer.lpp" +#line 259 "glsl_lexer.ll" { if ((yyextra->language_version >= 140) + || yyextra->AMD_conservative_depth_enable || yyextra->ARB_explicit_attrib_location_enable - || (yyextra->ARB_fragment_coord_conventions_enable)){ + || yyextra->ARB_fragment_coord_conventions_enable) { return LAYOUT_TOK; } else { yylval->identifier = strdup(yytext); @@ -1921,615 +1959,615 @@ YY_RULE_SETUP } } YY_BREAK -case 96: +case 97: YY_RULE_SETUP -#line 259 "glsl_lexer.lpp" +#line 271 "glsl_lexer.ll" return INC_OP; YY_BREAK -case 97: +case 98: YY_RULE_SETUP -#line 260 "glsl_lexer.lpp" +#line 272 "glsl_lexer.ll" return DEC_OP; YY_BREAK -case 98: +case 99: YY_RULE_SETUP -#line 261 "glsl_lexer.lpp" +#line 273 "glsl_lexer.ll" return LE_OP; YY_BREAK -case 99: +case 100: YY_RULE_SETUP -#line 262 "glsl_lexer.lpp" +#line 274 "glsl_lexer.ll" return GE_OP; YY_BREAK -case 100: +case 101: YY_RULE_SETUP -#line 263 "glsl_lexer.lpp" +#line 275 "glsl_lexer.ll" return EQ_OP; YY_BREAK -case 101: +case 102: YY_RULE_SETUP -#line 264 "glsl_lexer.lpp" +#line 276 "glsl_lexer.ll" return NE_OP; YY_BREAK -case 102: +case 103: YY_RULE_SETUP -#line 265 "glsl_lexer.lpp" +#line 277 "glsl_lexer.ll" return AND_OP; YY_BREAK -case 103: +case 104: YY_RULE_SETUP -#line 266 "glsl_lexer.lpp" +#line 278 "glsl_lexer.ll" return OR_OP; YY_BREAK -case 104: +case 105: YY_RULE_SETUP -#line 267 "glsl_lexer.lpp" +#line 279 "glsl_lexer.ll" return XOR_OP; YY_BREAK -case 105: +case 106: YY_RULE_SETUP -#line 268 "glsl_lexer.lpp" +#line 280 "glsl_lexer.ll" return LEFT_OP; YY_BREAK -case 106: +case 107: YY_RULE_SETUP -#line 269 "glsl_lexer.lpp" +#line 281 "glsl_lexer.ll" return RIGHT_OP; YY_BREAK -case 107: +case 108: YY_RULE_SETUP -#line 271 "glsl_lexer.lpp" +#line 283 "glsl_lexer.ll" return MUL_ASSIGN; YY_BREAK -case 108: +case 109: YY_RULE_SETUP -#line 272 "glsl_lexer.lpp" +#line 284 "glsl_lexer.ll" return DIV_ASSIGN; YY_BREAK -case 109: +case 110: YY_RULE_SETUP -#line 273 "glsl_lexer.lpp" +#line 285 "glsl_lexer.ll" return ADD_ASSIGN; YY_BREAK -case 110: +case 111: YY_RULE_SETUP -#line 274 "glsl_lexer.lpp" +#line 286 "glsl_lexer.ll" return MOD_ASSIGN; YY_BREAK -case 111: +case 112: YY_RULE_SETUP -#line 275 "glsl_lexer.lpp" +#line 287 "glsl_lexer.ll" return LEFT_ASSIGN; YY_BREAK -case 112: +case 113: YY_RULE_SETUP -#line 276 "glsl_lexer.lpp" +#line 288 "glsl_lexer.ll" return RIGHT_ASSIGN; YY_BREAK -case 113: +case 114: YY_RULE_SETUP -#line 277 "glsl_lexer.lpp" +#line 289 "glsl_lexer.ll" return AND_ASSIGN; YY_BREAK -case 114: +case 115: YY_RULE_SETUP -#line 278 "glsl_lexer.lpp" +#line 290 "glsl_lexer.ll" return XOR_ASSIGN; YY_BREAK -case 115: +case 116: YY_RULE_SETUP -#line 279 "glsl_lexer.lpp" +#line 291 "glsl_lexer.ll" return OR_ASSIGN; YY_BREAK -case 116: +case 117: YY_RULE_SETUP -#line 280 "glsl_lexer.lpp" +#line 292 "glsl_lexer.ll" return SUB_ASSIGN; YY_BREAK -case 117: +case 118: YY_RULE_SETUP -#line 282 "glsl_lexer.lpp" +#line 294 "glsl_lexer.ll" { yylval->n = strtol(yytext, NULL, 10); return IS_UINT ? UINTCONSTANT : INTCONSTANT; } YY_BREAK -case 118: +case 119: YY_RULE_SETUP -#line 286 "glsl_lexer.lpp" +#line 298 "glsl_lexer.ll" { yylval->n = strtol(yytext + 2, NULL, 16); return IS_UINT ? UINTCONSTANT : INTCONSTANT; } YY_BREAK -case 119: +case 120: YY_RULE_SETUP -#line 290 "glsl_lexer.lpp" +#line 302 "glsl_lexer.ll" { yylval->n = strtol(yytext, NULL, 8); return IS_UINT ? UINTCONSTANT : INTCONSTANT; } YY_BREAK -case 120: -YY_RULE_SETUP -#line 295 "glsl_lexer.lpp" -{ - yylval->real = strtod(yytext, NULL); - return FLOATCONSTANT; - } - YY_BREAK case 121: YY_RULE_SETUP -#line 299 "glsl_lexer.lpp" +#line 307 "glsl_lexer.ll" { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK case 122: YY_RULE_SETUP -#line 303 "glsl_lexer.lpp" +#line 311 "glsl_lexer.ll" { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK case 123: YY_RULE_SETUP -#line 307 "glsl_lexer.lpp" +#line 315 "glsl_lexer.ll" { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK case 124: YY_RULE_SETUP -#line 311 "glsl_lexer.lpp" +#line 319 "glsl_lexer.ll" { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } YY_BREAK case 125: YY_RULE_SETUP -#line 316 "glsl_lexer.lpp" +#line 323 "glsl_lexer.ll" +{ + yylval->real = glsl_strtod(yytext, NULL); + return FLOATCONSTANT; + } + YY_BREAK +case 126: +YY_RULE_SETUP +#line 328 "glsl_lexer.ll" { yylval->n = 1; return BOOLCONSTANT; } YY_BREAK -case 126: +case 127: YY_RULE_SETUP -#line 320 "glsl_lexer.lpp" +#line 332 "glsl_lexer.ll" { yylval->n = 0; return BOOLCONSTANT; } YY_BREAK /* Reserved words in GLSL 1.10. */ -case 127: +case 128: YY_RULE_SETUP -#line 327 "glsl_lexer.lpp" +#line 339 "glsl_lexer.ll" KEYWORD(110 || ES, 999, ASM); YY_BREAK -case 128: +case 129: YY_RULE_SETUP -#line 328 "glsl_lexer.lpp" +#line 340 "glsl_lexer.ll" KEYWORD(110 || ES, 999, CLASS); YY_BREAK -case 129: +case 130: YY_RULE_SETUP -#line 329 "glsl_lexer.lpp" +#line 341 "glsl_lexer.ll" KEYWORD(110 || ES, 999, UNION); YY_BREAK -case 130: +case 131: YY_RULE_SETUP -#line 330 "glsl_lexer.lpp" +#line 342 "glsl_lexer.ll" KEYWORD(110 || ES, 999, ENUM); YY_BREAK -case 131: +case 132: YY_RULE_SETUP -#line 331 "glsl_lexer.lpp" +#line 343 "glsl_lexer.ll" KEYWORD(110 || ES, 999, TYPEDEF); YY_BREAK -case 132: +case 133: YY_RULE_SETUP -#line 332 "glsl_lexer.lpp" +#line 344 "glsl_lexer.ll" KEYWORD(110 || ES, 999, TEMPLATE); YY_BREAK -case 133: +case 134: YY_RULE_SETUP -#line 333 "glsl_lexer.lpp" +#line 345 "glsl_lexer.ll" KEYWORD(110 || ES, 999, THIS); YY_BREAK -case 134: +case 135: YY_RULE_SETUP -#line 334 "glsl_lexer.lpp" +#line 346 "glsl_lexer.ll" KEYWORD(110 || ES, 999, PACKED_TOK); YY_BREAK -case 135: +case 136: YY_RULE_SETUP -#line 335 "glsl_lexer.lpp" +#line 347 "glsl_lexer.ll" KEYWORD(110 || ES, 999, GOTO); YY_BREAK -case 136: +case 137: YY_RULE_SETUP -#line 336 "glsl_lexer.lpp" +#line 348 "glsl_lexer.ll" KEYWORD(110 || ES, 130, SWITCH); YY_BREAK -case 137: +case 138: YY_RULE_SETUP -#line 337 "glsl_lexer.lpp" +#line 349 "glsl_lexer.ll" KEYWORD(110 || ES, 130, DEFAULT); YY_BREAK -case 138: +case 139: YY_RULE_SETUP -#line 338 "glsl_lexer.lpp" +#line 350 "glsl_lexer.ll" KEYWORD(110 || ES, 999, INLINE_TOK); YY_BREAK -case 139: +case 140: YY_RULE_SETUP -#line 339 "glsl_lexer.lpp" +#line 351 "glsl_lexer.ll" KEYWORD(110 || ES, 999, NOINLINE); YY_BREAK -case 140: +case 141: YY_RULE_SETUP -#line 340 "glsl_lexer.lpp" +#line 352 "glsl_lexer.ll" KEYWORD(110 || ES, 999, VOLATILE); YY_BREAK -case 141: +case 142: YY_RULE_SETUP -#line 341 "glsl_lexer.lpp" +#line 353 "glsl_lexer.ll" KEYWORD(110 || ES, 999, PUBLIC_TOK); YY_BREAK -case 142: +case 143: YY_RULE_SETUP -#line 342 "glsl_lexer.lpp" +#line 354 "glsl_lexer.ll" KEYWORD(110 || ES, 999, STATIC); YY_BREAK -case 143: +case 144: YY_RULE_SETUP -#line 343 "glsl_lexer.lpp" +#line 355 "glsl_lexer.ll" KEYWORD(110 || ES, 999, EXTERN); YY_BREAK -case 144: +case 145: YY_RULE_SETUP -#line 344 "glsl_lexer.lpp" +#line 356 "glsl_lexer.ll" KEYWORD(110 || ES, 999, EXTERNAL); YY_BREAK -case 145: +case 146: YY_RULE_SETUP -#line 345 "glsl_lexer.lpp" +#line 357 "glsl_lexer.ll" KEYWORD(110 || ES, 999, INTERFACE); YY_BREAK -case 146: +case 147: YY_RULE_SETUP -#line 346 "glsl_lexer.lpp" +#line 358 "glsl_lexer.ll" KEYWORD(110 || ES, 999, LONG_TOK); YY_BREAK -case 147: +case 148: YY_RULE_SETUP -#line 347 "glsl_lexer.lpp" +#line 359 "glsl_lexer.ll" KEYWORD(110 || ES, 999, SHORT_TOK); YY_BREAK -case 148: +case 149: YY_RULE_SETUP -#line 348 "glsl_lexer.lpp" +#line 360 "glsl_lexer.ll" KEYWORD(110 || ES, 400, DOUBLE_TOK); YY_BREAK -case 149: +case 150: YY_RULE_SETUP -#line 349 "glsl_lexer.lpp" +#line 361 "glsl_lexer.ll" KEYWORD(110 || ES, 999, HALF); YY_BREAK -case 150: +case 151: YY_RULE_SETUP -#line 350 "glsl_lexer.lpp" +#line 362 "glsl_lexer.ll" KEYWORD(110 || ES, 999, FIXED_TOK); YY_BREAK -case 151: +case 152: YY_RULE_SETUP -#line 351 "glsl_lexer.lpp" +#line 363 "glsl_lexer.ll" KEYWORD(110 || ES, 999, UNSIGNED); YY_BREAK -case 152: +case 153: YY_RULE_SETUP -#line 352 "glsl_lexer.lpp" +#line 364 "glsl_lexer.ll" KEYWORD(110 || ES, 999, INPUT_TOK); YY_BREAK -case 153: +case 154: YY_RULE_SETUP -#line 353 "glsl_lexer.lpp" +#line 365 "glsl_lexer.ll" KEYWORD(110 || ES, 999, OUTPUT); YY_BREAK -case 154: +case 155: YY_RULE_SETUP -#line 354 "glsl_lexer.lpp" +#line 366 "glsl_lexer.ll" KEYWORD(110 || ES, 999, HVEC2); YY_BREAK -case 155: +case 156: YY_RULE_SETUP -#line 355 "glsl_lexer.lpp" +#line 367 "glsl_lexer.ll" KEYWORD(110 || ES, 999, HVEC3); YY_BREAK -case 156: +case 157: YY_RULE_SETUP -#line 356 "glsl_lexer.lpp" +#line 368 "glsl_lexer.ll" KEYWORD(110 || ES, 999, HVEC4); YY_BREAK -case 157: +case 158: YY_RULE_SETUP -#line 357 "glsl_lexer.lpp" +#line 369 "glsl_lexer.ll" KEYWORD(110 || ES, 400, DVEC2); YY_BREAK -case 158: +case 159: YY_RULE_SETUP -#line 358 "glsl_lexer.lpp" +#line 370 "glsl_lexer.ll" KEYWORD(110 || ES, 400, DVEC3); YY_BREAK -case 159: +case 160: YY_RULE_SETUP -#line 359 "glsl_lexer.lpp" +#line 371 "glsl_lexer.ll" KEYWORD(110 || ES, 400, DVEC4); YY_BREAK -case 160: +case 161: YY_RULE_SETUP -#line 360 "glsl_lexer.lpp" +#line 372 "glsl_lexer.ll" KEYWORD(110 || ES, 999, FVEC2); YY_BREAK -case 161: +case 162: YY_RULE_SETUP -#line 361 "glsl_lexer.lpp" +#line 373 "glsl_lexer.ll" KEYWORD(110 || ES, 999, FVEC3); YY_BREAK -case 162: +case 163: YY_RULE_SETUP -#line 362 "glsl_lexer.lpp" +#line 374 "glsl_lexer.ll" KEYWORD(110 || ES, 999, FVEC4); YY_BREAK -case 163: +case 164: YY_RULE_SETUP -#line 363 "glsl_lexer.lpp" +#line 375 "glsl_lexer.ll" return SAMPLER2DRECT; YY_BREAK -case 164: +case 165: YY_RULE_SETUP -#line 364 "glsl_lexer.lpp" +#line 376 "glsl_lexer.ll" KEYWORD(110 || ES, 999, SAMPLER3DRECT); YY_BREAK -case 165: +case 166: YY_RULE_SETUP -#line 365 "glsl_lexer.lpp" +#line 377 "glsl_lexer.ll" return SAMPLER2DRECTSHADOW; YY_BREAK -case 166: +case 167: YY_RULE_SETUP -#line 366 "glsl_lexer.lpp" +#line 378 "glsl_lexer.ll" KEYWORD(110 || ES, 999, SIZEOF); YY_BREAK -case 167: +case 168: YY_RULE_SETUP -#line 367 "glsl_lexer.lpp" +#line 379 "glsl_lexer.ll" KEYWORD(110 || ES, 999, CAST); YY_BREAK -case 168: +case 169: YY_RULE_SETUP -#line 368 "glsl_lexer.lpp" +#line 380 "glsl_lexer.ll" KEYWORD(110 || ES, 999, NAMESPACE); YY_BREAK -case 169: +case 170: YY_RULE_SETUP -#line 369 "glsl_lexer.lpp" +#line 381 "glsl_lexer.ll" KEYWORD(110 || ES, 999, USING); YY_BREAK /* Additional reserved words in GLSL 1.20. */ -case 170: +case 171: YY_RULE_SETUP -#line 372 "glsl_lexer.lpp" +#line 384 "glsl_lexer.ll" KEYWORD(120, 130 || ES, LOWP); YY_BREAK -case 171: +case 172: YY_RULE_SETUP -#line 373 "glsl_lexer.lpp" +#line 385 "glsl_lexer.ll" KEYWORD(120, 130 || ES, MEDIUMP); YY_BREAK -case 172: +case 173: YY_RULE_SETUP -#line 374 "glsl_lexer.lpp" +#line 386 "glsl_lexer.ll" KEYWORD(120, 130 || ES, HIGHP); YY_BREAK -case 173: +case 174: YY_RULE_SETUP -#line 375 "glsl_lexer.lpp" +#line 387 "glsl_lexer.ll" KEYWORD(120, 130 || ES, PRECISION); YY_BREAK /* Additional reserved words in GLSL 1.30. */ -case 174: +case 175: YY_RULE_SETUP -#line 378 "glsl_lexer.lpp" +#line 390 "glsl_lexer.ll" KEYWORD(130, 130, CASE); YY_BREAK -case 175: +case 176: YY_RULE_SETUP -#line 379 "glsl_lexer.lpp" +#line 391 "glsl_lexer.ll" KEYWORD(130, 999, COMMON); YY_BREAK -case 176: +case 177: YY_RULE_SETUP -#line 380 "glsl_lexer.lpp" +#line 392 "glsl_lexer.ll" KEYWORD(130, 999, PARTITION); YY_BREAK -case 177: +case 178: YY_RULE_SETUP -#line 381 "glsl_lexer.lpp" +#line 393 "glsl_lexer.ll" KEYWORD(130, 999, ACTIVE); YY_BREAK -case 178: +case 179: YY_RULE_SETUP -#line 382 "glsl_lexer.lpp" +#line 394 "glsl_lexer.ll" KEYWORD(130 || ES, 999, SUPERP); YY_BREAK -case 179: +case 180: YY_RULE_SETUP -#line 383 "glsl_lexer.lpp" +#line 395 "glsl_lexer.ll" KEYWORD(130, 140, SAMPLERBUFFER); YY_BREAK -case 180: +case 181: YY_RULE_SETUP -#line 384 "glsl_lexer.lpp" +#line 396 "glsl_lexer.ll" KEYWORD(130, 999, FILTER); YY_BREAK -case 181: +case 182: YY_RULE_SETUP -#line 385 "glsl_lexer.lpp" +#line 397 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE1D); YY_BREAK -case 182: +case 183: YY_RULE_SETUP -#line 386 "glsl_lexer.lpp" +#line 398 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE2D); YY_BREAK -case 183: +case 184: YY_RULE_SETUP -#line 387 "glsl_lexer.lpp" +#line 399 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE3D); YY_BREAK -case 184: +case 185: YY_RULE_SETUP -#line 388 "glsl_lexer.lpp" +#line 400 "glsl_lexer.ll" KEYWORD(130, 999, IMAGECUBE); YY_BREAK -case 185: +case 186: YY_RULE_SETUP -#line 389 "glsl_lexer.lpp" +#line 401 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGE1D); YY_BREAK -case 186: +case 187: YY_RULE_SETUP -#line 390 "glsl_lexer.lpp" +#line 402 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGE2D); YY_BREAK -case 187: +case 188: YY_RULE_SETUP -#line 391 "glsl_lexer.lpp" +#line 403 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGE3D); YY_BREAK -case 188: +case 189: YY_RULE_SETUP -#line 392 "glsl_lexer.lpp" +#line 404 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGECUBE); YY_BREAK -case 189: +case 190: YY_RULE_SETUP -#line 393 "glsl_lexer.lpp" +#line 405 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGE1D); YY_BREAK -case 190: +case 191: YY_RULE_SETUP -#line 394 "glsl_lexer.lpp" +#line 406 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGE2D); YY_BREAK -case 191: +case 192: YY_RULE_SETUP -#line 395 "glsl_lexer.lpp" +#line 407 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGE3D); YY_BREAK -case 192: +case 193: YY_RULE_SETUP -#line 396 "glsl_lexer.lpp" +#line 408 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGECUBE); YY_BREAK -case 193: +case 194: YY_RULE_SETUP -#line 397 "glsl_lexer.lpp" +#line 409 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE1DARRAY); YY_BREAK -case 194: +case 195: YY_RULE_SETUP -#line 398 "glsl_lexer.lpp" +#line 410 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE2DARRAY); YY_BREAK -case 195: +case 196: YY_RULE_SETUP -#line 399 "glsl_lexer.lpp" +#line 411 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGE1DARRAY); YY_BREAK -case 196: +case 197: YY_RULE_SETUP -#line 400 "glsl_lexer.lpp" +#line 412 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGE2DARRAY); YY_BREAK -case 197: +case 198: YY_RULE_SETUP -#line 401 "glsl_lexer.lpp" +#line 413 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGE1DARRAY); YY_BREAK -case 198: +case 199: YY_RULE_SETUP -#line 402 "glsl_lexer.lpp" +#line 414 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGE2DARRAY); YY_BREAK -case 199: +case 200: YY_RULE_SETUP -#line 403 "glsl_lexer.lpp" +#line 415 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE1DSHADOW); YY_BREAK -case 200: +case 201: YY_RULE_SETUP -#line 404 "glsl_lexer.lpp" +#line 416 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE2DSHADOW); YY_BREAK -case 201: +case 202: YY_RULE_SETUP -#line 405 "glsl_lexer.lpp" +#line 417 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE1DARRAYSHADOW); YY_BREAK -case 202: +case 203: YY_RULE_SETUP -#line 406 "glsl_lexer.lpp" +#line 418 "glsl_lexer.ll" KEYWORD(130, 999, IMAGE2DARRAYSHADOW); YY_BREAK -case 203: +case 204: YY_RULE_SETUP -#line 407 "glsl_lexer.lpp" +#line 419 "glsl_lexer.ll" KEYWORD(130, 999, IMAGEBUFFER); YY_BREAK -case 204: +case 205: YY_RULE_SETUP -#line 408 "glsl_lexer.lpp" +#line 420 "glsl_lexer.ll" KEYWORD(130, 999, IIMAGEBUFFER); YY_BREAK -case 205: +case 206: YY_RULE_SETUP -#line 409 "glsl_lexer.lpp" +#line 421 "glsl_lexer.ll" KEYWORD(130, 999, UIMAGEBUFFER); YY_BREAK -case 206: +case 207: YY_RULE_SETUP -#line 410 "glsl_lexer.lpp" +#line 422 "glsl_lexer.ll" KEYWORD(130, 999, ROW_MAJOR); YY_BREAK -case 207: +case 208: YY_RULE_SETUP -#line 412 "glsl_lexer.lpp" +#line 424 "glsl_lexer.ll" { struct _mesa_glsl_parse_state *state = yyextra; void *ctx = state; - yylval->identifier = talloc_strdup(ctx, yytext); - return IDENTIFIER; + yylval->identifier = ralloc_strdup(ctx, yytext); + return classify_identifier(state, yytext); } YY_BREAK -case 208: +case 209: YY_RULE_SETUP -#line 419 "glsl_lexer.lpp" +#line 431 "glsl_lexer.ll" { return yytext[0]; } YY_BREAK -case 209: +case 210: YY_RULE_SETUP -#line 421 "glsl_lexer.lpp" +#line 433 "glsl_lexer.ll" ECHO; YY_BREAK -#line 2533 "glsl_lexer.cpp" +#line 2571 "glsl_lexer.cpp" case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(PP): case YY_STATE_EOF(PRAGMA): @@ -2827,7 +2865,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 >= 813 ) + if ( yy_current_state >= 836 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -2856,11 +2894,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 >= 813 ) + if ( yy_current_state >= 836 ) 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 == 812); + yy_is_jam = (yy_current_state == 835); return yy_is_jam ? 0 : yy_current_state; } @@ -3265,8 +3303,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. */ @@ -3672,10 +3710,21 @@ void _mesa_glsl_free (void * ptr , yyscan_t yyscanner) #define YYTABLES_NAME "yytables" -#line 421 "glsl_lexer.lpp" +#line 433 "glsl_lexer.ll" +int +classify_identifier(struct _mesa_glsl_parse_state *state, const char *name) +{ + if (state->symbols->get_variable(name) || state->symbols->get_function(name)) + return IDENTIFIER; + else if (state->symbols->get_type(name)) + return TYPE_IDENTIFIER; + else + return NEW_IDENTIFIER; +} + void _mesa_glsl_lexer_ctor(struct _mesa_glsl_parse_state *state, const char *string) { diff --git a/src/glsl/glsl_lexer.lpp b/src/glsl/glsl_lexer.ll index 7a3f1a67e6..cfd8926175 100644 --- a/src/glsl/glsl_lexer.lpp +++ b/src/glsl/glsl_lexer.ll @@ -22,10 +22,17 @@ * DEALINGS IN THE SOFTWARE. */ #include <ctype.h> +#include "strtod.h" #include "ast.h" #include "glsl_parser_extras.h" #include "glsl_parser.h" +static int classify_identifier(struct _mesa_glsl_parse_state *, const char *); + +#ifdef _MSC_VER +#define YY_NO_UNISTD_H +#endif + #define YY_USER_ACTION \ do { \ yylloc->source = 0; \ @@ -61,7 +68,7 @@ return ERROR_TOK; \ } else { \ yylval->identifier = strdup(yytext); \ - return IDENTIFIER; \ + return classify_identifier(yyextra, yytext); \ } \ } while (0) @@ -144,6 +151,10 @@ HASH ^{SPC}#{SPC} BEGIN PP; return PRAGMA_OPTIMIZE_OFF; } +^{SPC}#{SPC}pragma{SPCP}STDGL{SPCP}invariant{SPC}\({SPC}all{SPC}\) { + BEGIN PP; + return PRAGMA_INVARIANT_ALL; + } ^{SPC}#{SPC}pragma{SPCP} { BEGIN PRAGMA; } <PRAGMA>\n { BEGIN 0; yylineno++; yycolumn = 0; } @@ -247,8 +258,9 @@ void return VOID_TOK; layout { if ((yyextra->language_version >= 140) + || yyextra->AMD_conservative_depth_enable || yyextra->ARB_explicit_attrib_location_enable - || (yyextra->ARB_fragment_coord_conventions_enable)){ + || yyextra->ARB_fragment_coord_conventions_enable) { return LAYOUT_TOK; } else { yylval->identifier = strdup(yytext); @@ -293,23 +305,23 @@ layout { } [0-9]+\.[0-9]+([eE][+-]?[0-9]+)?[fF]? { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } \.[0-9]+([eE][+-]?[0-9]+)?[fF]? { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } [0-9]+\.([eE][+-]?[0-9]+)?[fF]? { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } [0-9]+[eE][+-]?[0-9]+[fF]? { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } [0-9]+[fF] { - yylval->real = strtod(yytext, NULL); + yylval->real = glsl_strtod(yytext, NULL); return FLOATCONSTANT; } @@ -412,14 +424,25 @@ row_major KEYWORD(130, 999, ROW_MAJOR); [_a-zA-Z][_a-zA-Z0-9]* { struct _mesa_glsl_parse_state *state = yyextra; void *ctx = state; - yylval->identifier = talloc_strdup(ctx, yytext); - return IDENTIFIER; + yylval->identifier = ralloc_strdup(ctx, yytext); + return classify_identifier(state, yytext); } . { return yytext[0]; } %% +int +classify_identifier(struct _mesa_glsl_parse_state *state, const char *name) +{ + if (state->symbols->get_variable(name) || state->symbols->get_function(name)) + return IDENTIFIER; + else if (state->symbols->get_type(name)) + return TYPE_IDENTIFIER; + else + return NEW_IDENTIFIER; +} + void _mesa_glsl_lexer_ctor(struct _mesa_glsl_parse_state *state, const char *string) { diff --git a/src/glsl/glsl_parser.cpp b/src/glsl/glsl_parser.cpp index 23e439c7c5..c9c2fb31a2 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" @@ -75,7 +76,7 @@ /* Copy the first part of user declarations. */ /* Line 189 of yacc.c */ -#line 1 "glsl_parser.ypp" +#line 1 "glsl_parser.yy" /* * Copyright © 2008, 2009 Intel Corporation @@ -113,7 +114,7 @@ /* Line 189 of yacc.c */ -#line 117 "glsl_parser.cpp" +#line 118 "glsl_parser.cpp" /* Enabling traces. */ #ifndef YYDEBUG @@ -214,122 +215,125 @@ VOID_TOK = 329, WHILE = 330, IDENTIFIER = 331, - FLOATCONSTANT = 332, - INTCONSTANT = 333, - UINTCONSTANT = 334, - BOOLCONSTANT = 335, - FIELD_SELECTION = 336, - LEFT_OP = 337, - RIGHT_OP = 338, - INC_OP = 339, - DEC_OP = 340, - LE_OP = 341, - GE_OP = 342, - EQ_OP = 343, - NE_OP = 344, - AND_OP = 345, - OR_OP = 346, - XOR_OP = 347, - MUL_ASSIGN = 348, - DIV_ASSIGN = 349, - ADD_ASSIGN = 350, - MOD_ASSIGN = 351, - LEFT_ASSIGN = 352, - RIGHT_ASSIGN = 353, - AND_ASSIGN = 354, - XOR_ASSIGN = 355, - OR_ASSIGN = 356, - SUB_ASSIGN = 357, - INVARIANT = 358, - LOWP = 359, - MEDIUMP = 360, - HIGHP = 361, - SUPERP = 362, - PRECISION = 363, - VERSION = 364, - EXTENSION = 365, - LINE = 366, - COLON = 367, - EOL = 368, - INTERFACE = 369, - OUTPUT = 370, - PRAGMA_DEBUG_ON = 371, - PRAGMA_DEBUG_OFF = 372, - PRAGMA_OPTIMIZE_ON = 373, - PRAGMA_OPTIMIZE_OFF = 374, - LAYOUT_TOK = 375, - ASM = 376, - CLASS = 377, - UNION = 378, - ENUM = 379, - TYPEDEF = 380, - TEMPLATE = 381, - THIS = 382, - PACKED_TOK = 383, - GOTO = 384, - INLINE_TOK = 385, - NOINLINE = 386, - VOLATILE = 387, - PUBLIC_TOK = 388, - STATIC = 389, - EXTERN = 390, - EXTERNAL = 391, - LONG_TOK = 392, - SHORT_TOK = 393, - DOUBLE_TOK = 394, - HALF = 395, - FIXED_TOK = 396, - UNSIGNED = 397, - INPUT_TOK = 398, - OUPTUT = 399, - HVEC2 = 400, - HVEC3 = 401, - HVEC4 = 402, - DVEC2 = 403, - DVEC3 = 404, - DVEC4 = 405, - FVEC2 = 406, - FVEC3 = 407, - FVEC4 = 408, - SAMPLER2DRECT = 409, - SAMPLER3DRECT = 410, - SAMPLER2DRECTSHADOW = 411, - SIZEOF = 412, - CAST = 413, - NAMESPACE = 414, - USING = 415, - ERROR_TOK = 416, - COMMON = 417, - PARTITION = 418, - ACTIVE = 419, - SAMPLERBUFFER = 420, - FILTER = 421, - IMAGE1D = 422, - IMAGE2D = 423, - IMAGE3D = 424, - IMAGECUBE = 425, - IMAGE1DARRAY = 426, - IMAGE2DARRAY = 427, - IIMAGE1D = 428, - IIMAGE2D = 429, - IIMAGE3D = 430, - IIMAGECUBE = 431, - IIMAGE1DARRAY = 432, - IIMAGE2DARRAY = 433, - UIMAGE1D = 434, - UIMAGE2D = 435, - UIMAGE3D = 436, - UIMAGECUBE = 437, - UIMAGE1DARRAY = 438, - UIMAGE2DARRAY = 439, - IMAGE1DSHADOW = 440, - IMAGE2DSHADOW = 441, - IMAGEBUFFER = 442, - IIMAGEBUFFER = 443, - UIMAGEBUFFER = 444, - IMAGE1DARRAYSHADOW = 445, - IMAGE2DARRAYSHADOW = 446, - ROW_MAJOR = 447 + TYPE_IDENTIFIER = 332, + NEW_IDENTIFIER = 333, + FLOATCONSTANT = 334, + INTCONSTANT = 335, + UINTCONSTANT = 336, + BOOLCONSTANT = 337, + FIELD_SELECTION = 338, + LEFT_OP = 339, + RIGHT_OP = 340, + INC_OP = 341, + DEC_OP = 342, + LE_OP = 343, + GE_OP = 344, + EQ_OP = 345, + NE_OP = 346, + AND_OP = 347, + OR_OP = 348, + XOR_OP = 349, + MUL_ASSIGN = 350, + DIV_ASSIGN = 351, + ADD_ASSIGN = 352, + MOD_ASSIGN = 353, + LEFT_ASSIGN = 354, + RIGHT_ASSIGN = 355, + AND_ASSIGN = 356, + XOR_ASSIGN = 357, + OR_ASSIGN = 358, + SUB_ASSIGN = 359, + INVARIANT = 360, + LOWP = 361, + MEDIUMP = 362, + HIGHP = 363, + SUPERP = 364, + PRECISION = 365, + VERSION = 366, + EXTENSION = 367, + LINE = 368, + COLON = 369, + EOL = 370, + INTERFACE = 371, + OUTPUT = 372, + PRAGMA_DEBUG_ON = 373, + PRAGMA_DEBUG_OFF = 374, + PRAGMA_OPTIMIZE_ON = 375, + PRAGMA_OPTIMIZE_OFF = 376, + PRAGMA_INVARIANT_ALL = 377, + LAYOUT_TOK = 378, + ASM = 379, + CLASS = 380, + UNION = 381, + ENUM = 382, + TYPEDEF = 383, + TEMPLATE = 384, + THIS = 385, + PACKED_TOK = 386, + GOTO = 387, + INLINE_TOK = 388, + NOINLINE = 389, + VOLATILE = 390, + PUBLIC_TOK = 391, + STATIC = 392, + EXTERN = 393, + EXTERNAL = 394, + LONG_TOK = 395, + SHORT_TOK = 396, + DOUBLE_TOK = 397, + HALF = 398, + FIXED_TOK = 399, + UNSIGNED = 400, + INPUT_TOK = 401, + OUPTUT = 402, + HVEC2 = 403, + HVEC3 = 404, + HVEC4 = 405, + DVEC2 = 406, + DVEC3 = 407, + DVEC4 = 408, + FVEC2 = 409, + FVEC3 = 410, + FVEC4 = 411, + SAMPLER2DRECT = 412, + SAMPLER3DRECT = 413, + SAMPLER2DRECTSHADOW = 414, + SIZEOF = 415, + CAST = 416, + NAMESPACE = 417, + USING = 418, + ERROR_TOK = 419, + COMMON = 420, + PARTITION = 421, + ACTIVE = 422, + SAMPLERBUFFER = 423, + FILTER = 424, + IMAGE1D = 425, + IMAGE2D = 426, + IMAGE3D = 427, + IMAGECUBE = 428, + IMAGE1DARRAY = 429, + IMAGE2DARRAY = 430, + IIMAGE1D = 431, + IIMAGE2D = 432, + IIMAGE3D = 433, + IIMAGECUBE = 434, + IIMAGE1DARRAY = 435, + IIMAGE2DARRAY = 436, + UIMAGE1D = 437, + UIMAGE2D = 438, + UIMAGE3D = 439, + UIMAGECUBE = 440, + UIMAGE1DARRAY = 441, + UIMAGE2DARRAY = 442, + IMAGE1DSHADOW = 443, + IMAGE2DSHADOW = 444, + IMAGEBUFFER = 445, + IIMAGEBUFFER = 446, + UIMAGEBUFFER = 447, + IMAGE1DARRAYSHADOW = 448, + IMAGE2DARRAYSHADOW = 449, + ROW_MAJOR = 450 }; #endif @@ -340,7 +344,7 @@ typedef union YYSTYPE { /* Line 214 of yacc.c */ -#line 52 "glsl_parser.ypp" +#line 52 "glsl_parser.yy" int n; float real; @@ -373,7 +377,7 @@ typedef union YYSTYPE /* Line 214 of yacc.c */ -#line 377 "glsl_parser.cpp" +#line 381 "glsl_parser.cpp" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ @@ -398,7 +402,7 @@ typedef struct YYLTYPE /* Line 264 of yacc.c */ -#line 402 "glsl_parser.cpp" +#line 406 "glsl_parser.cpp" #ifdef short # undef short @@ -448,7 +452,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) @@ -615,20 +619,20 @@ union yyalloc /* YYFINAL -- State number of the termination state. */ #define YYFINAL 5 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 3718 +#define YYLAST 3692 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 217 +#define YYNTOKENS 220 /* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 87 +#define YYNNTS 93 /* YYNRULES -- Number of rules. */ -#define YYNRULES 278 +#define YYNRULES 291 /* YYNRULES -- Number of states. */ -#define YYNSTATES 413 +#define YYNSTATES 434 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 447 +#define YYMAXUTOK 450 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -639,16 +643,16 @@ static const yytype_uint8 yytranslate[] = 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 201, 2, 2, 2, 205, 208, 2, - 193, 194, 203, 199, 198, 200, 197, 204, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 212, 214, - 206, 213, 207, 211, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 204, 2, 2, 2, 208, 211, 2, + 196, 197, 206, 202, 201, 203, 200, 207, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 215, 217, + 209, 216, 210, 214, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 195, 2, 196, 209, 2, 2, 2, 2, 2, + 2, 198, 2, 199, 212, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 215, 210, 216, 202, 2, 2, 2, + 2, 2, 2, 218, 213, 219, 205, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, @@ -680,7 +684,8 @@ static const yytype_uint8 yytranslate[] = 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, - 185, 186, 187, 188, 189, 190, 191, 192 + 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, + 195 }; #if YYDEBUG @@ -689,151 +694,158 @@ static const yytype_uint8 yytranslate[] = static const yytype_uint16 yyprhs[] = { 0, 0, 3, 4, 9, 10, 14, 17, 20, 23, - 26, 27, 30, 36, 38, 41, 43, 45, 47, 49, - 51, 53, 57, 59, 64, 66, 70, 73, 76, 78, - 80, 82, 86, 89, 92, 95, 97, 100, 104, 107, - 109, 111, 113, 115, 118, 121, 124, 126, 128, 130, - 132, 134, 138, 142, 146, 148, 152, 156, 158, 162, - 166, 168, 172, 176, 180, 184, 186, 190, 194, 196, - 200, 202, 206, 208, 212, 214, 218, 220, 224, 226, - 230, 232, 238, 240, 244, 246, 248, 250, 252, 254, - 256, 258, 260, 262, 264, 266, 268, 272, 274, 277, - 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, 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 + 26, 29, 30, 33, 35, 37, 39, 45, 47, 50, + 52, 54, 56, 58, 60, 62, 64, 68, 70, 75, + 77, 81, 84, 87, 89, 91, 93, 97, 100, 103, + 106, 108, 111, 115, 118, 120, 122, 124, 127, 130, + 133, 135, 138, 142, 145, 147, 150, 153, 156, 158, + 160, 162, 164, 166, 170, 174, 178, 180, 184, 188, + 190, 194, 198, 200, 204, 208, 212, 216, 218, 222, + 226, 228, 232, 234, 238, 240, 244, 246, 250, 252, + 256, 258, 262, 264, 270, 272, 276, 278, 280, 282, + 284, 286, 288, 290, 292, 294, 296, 298, 300, 304, + 306, 309, 312, 317, 320, 322, 324, 327, 331, 335, + 338, 344, 348, 351, 355, 358, 359, 361, 363, 365, + 367, 369, 373, 379, 386, 394, 403, 409, 411, 414, + 419, 425, 432, 440, 445, 448, 450, 453, 458, 460, + 464, 466, 470, 472, 474, 476, 478, 480, 482, 485, + 487, 490, 493, 497, 499, 501, 503, 505, 508, 510, + 512, 515, 518, 520, 522, 525, 527, 531, 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, + 620, 622, 624, 626, 628, 630, 632, 634, 636, 638, + 640, 642, 644, 646, 648, 650, 656, 661, 663, 666, + 670, 672, 676, 678, 683, 685, 687, 689, 691, 693, + 695, 697, 699, 701, 703, 705, 708, 709, 714, 716, + 718, 721, 725, 727, 730, 732, 735, 741, 745, 747, + 749, 754, 760, 764, 767, 773, 781, 788, 790, 792, + 794, 795, 798, 802, 805, 808, 811, 815, 818, 820, + 822, 824 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int16 yyrhs[] = { - 218, 0, -1, -1, 220, 222, 219, 224, -1, -1, - 109, 78, 113, -1, 116, 113, -1, 117, 113, -1, - 118, 113, -1, 119, 113, -1, -1, 222, 223, -1, - 110, 76, 112, 76, 113, -1, 302, -1, 224, 302, - -1, 76, -1, 225, -1, 78, -1, 79, -1, 77, - -1, 80, -1, 193, 252, 194, -1, 226, -1, 227, - 195, 228, 196, -1, 229, -1, 227, 197, 76, -1, - 227, 84, -1, 227, 85, -1, 252, -1, 230, -1, - 231, -1, 227, 197, 231, -1, 233, 194, -1, 232, - 194, -1, 234, 74, -1, 234, -1, 234, 250, -1, - 233, 198, 250, -1, 235, 193, -1, 273, -1, 76, - -1, 81, -1, 227, -1, 84, 236, -1, 85, 236, - -1, 237, 236, -1, 199, -1, 200, -1, 201, -1, - 202, -1, 236, -1, 238, 203, 236, -1, 238, 204, - 236, -1, 238, 205, 236, -1, 238, -1, 239, 199, - 238, -1, 239, 200, 238, -1, 239, -1, 240, 82, - 239, -1, 240, 83, 239, -1, 240, -1, 241, 206, - 240, -1, 241, 207, 240, -1, 241, 86, 240, -1, - 241, 87, 240, -1, 241, -1, 242, 88, 241, -1, - 242, 89, 241, -1, 242, -1, 243, 208, 242, -1, - 243, -1, 244, 209, 243, -1, 244, -1, 245, 210, - 244, -1, 245, -1, 246, 90, 245, -1, 246, -1, - 247, 92, 246, -1, 247, -1, 248, 91, 247, -1, - 248, -1, 248, 211, 252, 212, 250, -1, 249, -1, - 236, 251, 250, -1, 213, -1, 93, -1, 94, -1, - 96, -1, 95, -1, 102, -1, 97, -1, 98, -1, - 99, -1, 100, -1, 101, -1, 250, -1, 252, 198, - 250, -1, 249, -1, 255, 214, -1, 263, 214, -1, - 108, 277, 274, 214, -1, 256, 194, -1, 258, -1, - 257, -1, 258, 260, -1, 257, 198, 260, -1, 265, - 76, 193, -1, 273, 76, -1, 273, 76, 195, 253, - 196, -1, 270, 261, 259, -1, 261, 259, -1, 270, - 261, 262, -1, 261, 262, -1, -1, 33, -1, 34, - -1, 35, -1, 273, -1, 264, -1, 263, 198, 76, - -1, 263, 198, 76, 195, 196, -1, 263, 198, 76, - 195, 253, 196, -1, 263, 198, 76, 195, 196, 213, - 283, -1, 263, 198, 76, 195, 253, 196, 213, 283, - -1, 263, 198, 76, 213, 283, -1, 265, -1, 265, - 76, -1, 265, 76, 195, 196, -1, 265, 76, 195, - 253, 196, -1, 265, 76, 195, 196, 213, 283, -1, - 265, 76, 195, 253, 196, 213, 283, -1, 265, 76, - 213, 283, -1, 103, 76, -1, 273, -1, 271, 273, - -1, 120, 193, 267, 194, -1, 268, -1, 267, 198, - 268, -1, 76, -1, 76, 213, 78, -1, 40, -1, - 39, -1, 38, -1, 4, -1, 272, -1, 266, -1, - 266, 272, -1, 269, -1, 269, 272, -1, 103, 272, - -1, 103, 269, 272, -1, 103, -1, 4, -1, 3, - -1, 37, -1, 32, 37, -1, 33, -1, 34, -1, - 32, 33, -1, 32, 34, -1, 36, -1, 274, -1, - 277, 274, -1, 275, -1, 275, 195, 196, -1, 275, - 195, 253, 196, -1, 276, -1, 278, -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, - 215, 279, 216, -1, 73, 215, 279, 216, -1, 280, - -1, 279, 280, -1, 273, 281, 214, -1, 282, -1, - 281, 198, 282, -1, 76, -1, 76, 195, 253, 196, - -1, 250, -1, 254, -1, 287, -1, 286, -1, 284, - -1, 291, -1, 292, -1, 295, -1, 296, -1, 297, - -1, 301, -1, 215, 216, -1, 215, 290, 216, -1, - 289, -1, 286, -1, 215, 216, -1, 215, 290, 216, - -1, 285, -1, 290, 285, -1, 214, -1, 252, 214, - -1, 14, 193, 252, 194, 293, -1, 285, 12, 285, - -1, 285, -1, 252, -1, 265, 76, 213, 283, -1, - 17, 193, 252, 194, 287, -1, 18, 252, 212, -1, - 19, 212, -1, 75, 193, 294, 194, 288, -1, 11, - 285, 75, 193, 252, 194, 214, -1, 13, 193, 298, - 300, 194, 288, -1, 291, -1, 284, -1, 294, -1, - -1, 299, 214, -1, 299, 214, 252, -1, 10, 214, - -1, 9, 214, -1, 16, 214, -1, 16, 252, 214, - -1, 15, 214, -1, 303, -1, 254, -1, 221, -1, - 255, 289, -1 + 221, 0, -1, -1, 223, 225, 222, 228, -1, -1, + 111, 80, 115, -1, 118, 115, -1, 119, 115, -1, + 120, 115, -1, 121, 115, -1, 122, 115, -1, -1, + 225, 227, -1, 76, -1, 77, -1, 78, -1, 112, + 226, 114, 226, 115, -1, 311, -1, 228, 311, -1, + 76, -1, 78, -1, 229, -1, 80, -1, 81, -1, + 79, -1, 82, -1, 196, 260, 197, -1, 230, -1, + 231, 198, 232, 199, -1, 233, -1, 231, 200, 226, + -1, 231, 86, -1, 231, 87, -1, 260, -1, 234, + -1, 235, -1, 231, 200, 240, -1, 237, 197, -1, + 236, 197, -1, 238, 74, -1, 238, -1, 238, 258, + -1, 237, 201, 258, -1, 239, 196, -1, 281, -1, + 229, -1, 83, -1, 242, 197, -1, 241, 197, -1, + 243, 74, -1, 243, -1, 243, 258, -1, 242, 201, + 258, -1, 229, 196, -1, 231, -1, 86, 244, -1, + 87, 244, -1, 245, 244, -1, 202, -1, 203, -1, + 204, -1, 205, -1, 244, -1, 246, 206, 244, -1, + 246, 207, 244, -1, 246, 208, 244, -1, 246, -1, + 247, 202, 246, -1, 247, 203, 246, -1, 247, -1, + 248, 84, 247, -1, 248, 85, 247, -1, 248, -1, + 249, 209, 248, -1, 249, 210, 248, -1, 249, 88, + 248, -1, 249, 89, 248, -1, 249, -1, 250, 90, + 249, -1, 250, 91, 249, -1, 250, -1, 251, 211, + 250, -1, 251, -1, 252, 212, 251, -1, 252, -1, + 253, 213, 252, -1, 253, -1, 254, 92, 253, -1, + 254, -1, 255, 94, 254, -1, 255, -1, 256, 93, + 255, -1, 256, -1, 256, 214, 260, 215, 258, -1, + 257, -1, 244, 259, 258, -1, 216, -1, 95, -1, + 96, -1, 98, -1, 97, -1, 104, -1, 99, -1, + 100, -1, 101, -1, 102, -1, 103, -1, 258, -1, + 260, 201, 258, -1, 257, -1, 263, 217, -1, 271, + 217, -1, 110, 285, 282, 217, -1, 264, 197, -1, + 266, -1, 265, -1, 266, 268, -1, 265, 201, 268, + -1, 273, 229, 196, -1, 281, 226, -1, 281, 226, + 198, 261, 199, -1, 278, 269, 267, -1, 269, 267, + -1, 278, 269, 270, -1, 269, 270, -1, -1, 33, + -1, 34, -1, 35, -1, 281, -1, 272, -1, 271, + 201, 226, -1, 271, 201, 226, 198, 199, -1, 271, + 201, 226, 198, 261, 199, -1, 271, 201, 226, 198, + 199, 216, 291, -1, 271, 201, 226, 198, 261, 199, + 216, 291, -1, 271, 201, 226, 216, 291, -1, 273, + -1, 273, 226, -1, 273, 226, 198, 199, -1, 273, + 226, 198, 261, 199, -1, 273, 226, 198, 199, 216, + 291, -1, 273, 226, 198, 261, 199, 216, 291, -1, + 273, 226, 216, 291, -1, 105, 229, -1, 281, -1, + 279, 281, -1, 123, 196, 275, 197, -1, 276, -1, + 275, 201, 276, -1, 226, -1, 226, 216, 80, -1, + 40, -1, 39, -1, 38, -1, 4, -1, 280, -1, + 274, -1, 274, 280, -1, 277, -1, 277, 280, -1, + 105, 280, -1, 105, 277, 280, -1, 105, -1, 4, + -1, 3, -1, 37, -1, 32, 37, -1, 33, -1, + 34, -1, 32, 33, -1, 32, 34, -1, 36, -1, + 282, -1, 285, 282, -1, 283, -1, 283, 198, 199, + -1, 283, 198, 261, 199, -1, 284, -1, 286, -1, + 77, -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, 157, -1, + 52, -1, 53, -1, 54, -1, 55, -1, 159, -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, 108, -1, 107, -1, 106, -1, + 73, 226, 218, 287, 219, -1, 73, 218, 287, 219, + -1, 288, -1, 287, 288, -1, 281, 289, 217, -1, + 290, -1, 289, 201, 290, -1, 226, -1, 226, 198, + 261, 199, -1, 258, -1, 262, -1, 295, -1, 294, + -1, 292, -1, 300, -1, 301, -1, 304, -1, 305, + -1, 306, -1, 310, -1, 218, 219, -1, -1, 218, + 296, 299, 219, -1, 298, -1, 294, -1, 218, 219, + -1, 218, 299, 219, -1, 293, -1, 299, 293, -1, + 217, -1, 260, 217, -1, 14, 196, 260, 197, 302, + -1, 293, 12, 293, -1, 293, -1, 260, -1, 273, + 226, 216, 291, -1, 17, 196, 260, 197, 295, -1, + 18, 260, 215, -1, 19, 215, -1, 75, 196, 303, + 197, 297, -1, 11, 293, 75, 196, 260, 197, 217, + -1, 13, 196, 307, 309, 197, 297, -1, 300, -1, + 292, -1, 303, -1, -1, 308, 217, -1, 308, 217, + 260, -1, 10, 217, -1, 9, 217, -1, 16, 217, + -1, 16, 260, 217, -1, 15, 217, -1, 312, -1, + 262, -1, 224, -1, 263, 298, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 212, 212, 211, 218, 220, 240, 241, 242, 243, - 246, 248, 252, 261, 269, 280, 284, 291, 298, 305, - 312, 319, 326, 327, 333, 337, 344, 350, 359, 363, - 367, 368, 377, 378, 382, 383, 387, 393, 405, 409, - 415, 422, 433, 434, 440, 446, 456, 457, 458, 459, - 463, 464, 470, 476, 485, 486, 492, 501, 502, 508, - 517, 518, 524, 530, 536, 545, 546, 552, 561, 562, - 571, 572, 581, 582, 591, 592, 601, 602, 611, 612, - 621, 622, 631, 632, 641, 642, 643, 644, 645, 646, - 647, 648, 649, 650, 651, 655, 659, 675, 679, 683, - 687, 701, 705, 706, 710, 715, 723, 734, 744, 759, - 766, 771, 782, 795, 798, 803, 808, 817, 821, 822, - 831, 840, 849, 858, 867, 880, 891, 900, 909, 918, - 927, 936, 945, 959, 966, 977, 984, 985, 1004, 1033, - 1074, 1079, 1084, 1092, 1100, 1101, 1102, 1107, 1108, 1113, - 1118, 1124, 1132, 1137, 1142, 1147, 1153, 1158, 1163, 1168, - 1173, 1181, 1182, 1190, 1191, 1197, 1206, 1212, 1218, 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, 1277, - 1281, 1292, 1303, 1317, 1323, 1332, 1337, 1345, 1360, 1365, - 1373, 1379, 1388, 1392, 1398, 1399, 1403, 1404, 1405, 1406, - 1407, 1408, 1409, 1413, 1419, 1428, 1429, 1433, 1439, 1448, - 1458, 1470, 1476, 1485, 1494, 1499, 1507, 1511, 1525, 1529, - 1530, 1534, 1541, 1548, 1558, 1559, 1563, 1565, 1571, 1576, - 1585, 1591, 1597, 1603, 1609, 1618, 1619, 1620, 1624 + 0, 218, 218, 217, 229, 231, 271, 272, 273, 274, + 275, 287, 289, 293, 294, 295, 299, 308, 316, 327, + 328, 332, 339, 346, 353, 360, 367, 374, 375, 381, + 385, 392, 398, 407, 411, 415, 416, 425, 426, 430, + 431, 435, 441, 453, 457, 463, 470, 480, 481, 485, + 486, 490, 496, 508, 519, 520, 526, 532, 542, 543, + 544, 545, 549, 550, 556, 562, 571, 572, 578, 587, + 588, 594, 603, 604, 610, 616, 622, 631, 632, 638, + 647, 648, 657, 658, 667, 668, 677, 678, 687, 688, + 697, 698, 707, 708, 717, 718, 727, 728, 729, 730, + 731, 732, 733, 734, 735, 736, 737, 741, 745, 761, + 765, 770, 774, 783, 787, 788, 792, 797, 805, 819, + 829, 844, 851, 856, 867, 880, 883, 888, 893, 902, + 906, 907, 917, 927, 937, 947, 957, 971, 982, 991, + 1000, 1009, 1018, 1027, 1036, 1050, 1057, 1068, 1075, 1076, + 1095, 1147, 1188, 1193, 1198, 1206, 1214, 1215, 1216, 1221, + 1222, 1227, 1232, 1238, 1246, 1251, 1256, 1261, 1267, 1272, + 1277, 1282, 1287, 1295, 1299, 1307, 1308, 1314, 1323, 1329, + 1335, 1344, 1345, 1346, 1347, 1348, 1349, 1350, 1351, 1352, + 1353, 1354, 1355, 1356, 1357, 1358, 1359, 1360, 1361, 1362, + 1363, 1364, 1365, 1366, 1367, 1368, 1369, 1370, 1371, 1372, + 1373, 1374, 1375, 1376, 1377, 1378, 1379, 1380, 1381, 1382, + 1383, 1384, 1385, 1386, 1387, 1388, 1389, 1390, 1391, 1392, + 1393, 1394, 1398, 1408, 1418, 1431, 1438, 1447, 1452, 1460, + 1475, 1480, 1488, 1495, 1504, 1508, 1514, 1515, 1519, 1520, + 1521, 1522, 1523, 1524, 1525, 1529, 1536, 1535, 1549, 1550, + 1554, 1560, 1569, 1579, 1591, 1597, 1606, 1615, 1620, 1628, + 1632, 1646, 1650, 1651, 1655, 1662, 1669, 1679, 1680, 1684, + 1686, 1692, 1697, 1706, 1712, 1718, 1724, 1730, 1739, 1740, + 1741, 1745 }; #endif @@ -856,38 +868,41 @@ static const char *const yytname[] = "ISAMPLERCUBE", "ISAMPLER1DARRAY", "ISAMPLER2DARRAY", "USAMPLER1D", "USAMPLER2D", "USAMPLER3D", "USAMPLERCUBE", "USAMPLER1DARRAY", "USAMPLER2DARRAY", "STRUCT", "VOID_TOK", "WHILE", "IDENTIFIER", - "FLOATCONSTANT", "INTCONSTANT", "UINTCONSTANT", "BOOLCONSTANT", - "FIELD_SELECTION", "LEFT_OP", "RIGHT_OP", "INC_OP", "DEC_OP", "LE_OP", - "GE_OP", "EQ_OP", "NE_OP", "AND_OP", "OR_OP", "XOR_OP", "MUL_ASSIGN", - "DIV_ASSIGN", "ADD_ASSIGN", "MOD_ASSIGN", "LEFT_ASSIGN", "RIGHT_ASSIGN", - "AND_ASSIGN", "XOR_ASSIGN", "OR_ASSIGN", "SUB_ASSIGN", "INVARIANT", - "LOWP", "MEDIUMP", "HIGHP", "SUPERP", "PRECISION", "VERSION", - "EXTENSION", "LINE", "COLON", "EOL", "INTERFACE", "OUTPUT", - "PRAGMA_DEBUG_ON", "PRAGMA_DEBUG_OFF", "PRAGMA_OPTIMIZE_ON", - "PRAGMA_OPTIMIZE_OFF", "LAYOUT_TOK", "ASM", "CLASS", "UNION", "ENUM", - "TYPEDEF", "TEMPLATE", "THIS", "PACKED_TOK", "GOTO", "INLINE_TOK", - "NOINLINE", "VOLATILE", "PUBLIC_TOK", "STATIC", "EXTERN", "EXTERNAL", - "LONG_TOK", "SHORT_TOK", "DOUBLE_TOK", "HALF", "FIXED_TOK", "UNSIGNED", - "INPUT_TOK", "OUPTUT", "HVEC2", "HVEC3", "HVEC4", "DVEC2", "DVEC3", - "DVEC4", "FVEC2", "FVEC3", "FVEC4", "SAMPLER2DRECT", "SAMPLER3DRECT", - "SAMPLER2DRECTSHADOW", "SIZEOF", "CAST", "NAMESPACE", "USING", - "ERROR_TOK", "COMMON", "PARTITION", "ACTIVE", "SAMPLERBUFFER", "FILTER", - "IMAGE1D", "IMAGE2D", "IMAGE3D", "IMAGECUBE", "IMAGE1DARRAY", - "IMAGE2DARRAY", "IIMAGE1D", "IIMAGE2D", "IIMAGE3D", "IIMAGECUBE", - "IIMAGE1DARRAY", "IIMAGE2DARRAY", "UIMAGE1D", "UIMAGE2D", "UIMAGE3D", - "UIMAGECUBE", "UIMAGE1DARRAY", "UIMAGE2DARRAY", "IMAGE1DSHADOW", - "IMAGE2DSHADOW", "IMAGEBUFFER", "IIMAGEBUFFER", "UIMAGEBUFFER", - "IMAGE1DARRAYSHADOW", "IMAGE2DARRAYSHADOW", "ROW_MAJOR", "'('", "')'", - "'['", "']'", "'.'", "','", "'+'", "'-'", "'!'", "'~'", "'*'", "'/'", - "'%'", "'<'", "'>'", "'&'", "'^'", "'|'", "'?'", "':'", "'='", "';'", - "'{'", "'}'", "$accept", "translation_unit", "$@1", "version_statement", - "pragma_statement", "extension_statement_list", "extension_statement", + "TYPE_IDENTIFIER", "NEW_IDENTIFIER", "FLOATCONSTANT", "INTCONSTANT", + "UINTCONSTANT", "BOOLCONSTANT", "FIELD_SELECTION", "LEFT_OP", "RIGHT_OP", + "INC_OP", "DEC_OP", "LE_OP", "GE_OP", "EQ_OP", "NE_OP", "AND_OP", + "OR_OP", "XOR_OP", "MUL_ASSIGN", "DIV_ASSIGN", "ADD_ASSIGN", + "MOD_ASSIGN", "LEFT_ASSIGN", "RIGHT_ASSIGN", "AND_ASSIGN", "XOR_ASSIGN", + "OR_ASSIGN", "SUB_ASSIGN", "INVARIANT", "LOWP", "MEDIUMP", "HIGHP", + "SUPERP", "PRECISION", "VERSION", "EXTENSION", "LINE", "COLON", "EOL", + "INTERFACE", "OUTPUT", "PRAGMA_DEBUG_ON", "PRAGMA_DEBUG_OFF", + "PRAGMA_OPTIMIZE_ON", "PRAGMA_OPTIMIZE_OFF", "PRAGMA_INVARIANT_ALL", + "LAYOUT_TOK", "ASM", "CLASS", "UNION", "ENUM", "TYPEDEF", "TEMPLATE", + "THIS", "PACKED_TOK", "GOTO", "INLINE_TOK", "NOINLINE", "VOLATILE", + "PUBLIC_TOK", "STATIC", "EXTERN", "EXTERNAL", "LONG_TOK", "SHORT_TOK", + "DOUBLE_TOK", "HALF", "FIXED_TOK", "UNSIGNED", "INPUT_TOK", "OUPTUT", + "HVEC2", "HVEC3", "HVEC4", "DVEC2", "DVEC3", "DVEC4", "FVEC2", "FVEC3", + "FVEC4", "SAMPLER2DRECT", "SAMPLER3DRECT", "SAMPLER2DRECTSHADOW", + "SIZEOF", "CAST", "NAMESPACE", "USING", "ERROR_TOK", "COMMON", + "PARTITION", "ACTIVE", "SAMPLERBUFFER", "FILTER", "IMAGE1D", "IMAGE2D", + "IMAGE3D", "IMAGECUBE", "IMAGE1DARRAY", "IMAGE2DARRAY", "IIMAGE1D", + "IIMAGE2D", "IIMAGE3D", "IIMAGECUBE", "IIMAGE1DARRAY", "IIMAGE2DARRAY", + "UIMAGE1D", "UIMAGE2D", "UIMAGE3D", "UIMAGECUBE", "UIMAGE1DARRAY", + "UIMAGE2DARRAY", "IMAGE1DSHADOW", "IMAGE2DSHADOW", "IMAGEBUFFER", + "IIMAGEBUFFER", "UIMAGEBUFFER", "IMAGE1DARRAYSHADOW", + "IMAGE2DARRAYSHADOW", "ROW_MAJOR", "'('", "')'", "'['", "']'", "'.'", + "','", "'+'", "'-'", "'!'", "'~'", "'*'", "'/'", "'%'", "'<'", "'>'", + "'&'", "'^'", "'|'", "'?'", "':'", "'='", "';'", "'{'", "'}'", "$accept", + "translation_unit", "$@1", "version_statement", "pragma_statement", + "extension_statement_list", "any_identifier", "extension_statement", "external_declaration_list", "variable_identifier", "primary_expression", "postfix_expression", "integer_expression", "function_call", "function_call_or_method", "function_call_generic", "function_call_header_no_parameters", "function_call_header_with_parameters", "function_call_header", - "function_identifier", "unary_expression", "unary_operator", + "function_identifier", "method_call_generic", + "method_call_header_no_parameters", "method_call_header_with_parameters", + "method_call_header", "unary_expression", "unary_operator", "multiplicative_expression", "additive_expression", "shift_expression", "relational_expression", "equality_expression", "and_expression", "exclusive_or_expression", "inclusive_or_expression", @@ -906,7 +921,7 @@ static const char *const yytname[] = "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", "$@2", "statement_no_new_scope", "compound_statement_no_new_scope", "statement_list", "expression_statement", "selection_statement", "selection_rest_statement", "condition", "switch_statement", @@ -940,76 +955,80 @@ static const yytype_uint16 yytoknum[] = 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, - 445, 446, 447, 40, 41, 91, 93, 46, 44, 43, - 45, 33, 126, 42, 47, 37, 60, 62, 38, 94, - 124, 63, 58, 61, 59, 123, 125 + 445, 446, 447, 448, 449, 450, 40, 41, 91, 93, + 46, 44, 43, 45, 33, 126, 42, 47, 37, 60, + 62, 38, 94, 124, 63, 58, 61, 59, 123, 125 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint16 yyr1[] = { - 0, 217, 219, 218, 220, 220, 221, 221, 221, 221, - 222, 222, 223, 224, 224, 225, 226, 226, 226, 226, - 226, 226, 227, 227, 227, 227, 227, 227, 228, 229, - 230, 230, 231, 231, 232, 232, 233, 233, 234, 235, - 235, 235, 236, 236, 236, 236, 237, 237, 237, 237, - 238, 238, 238, 238, 239, 239, 239, 240, 240, 240, - 241, 241, 241, 241, 241, 242, 242, 242, 243, 243, - 244, 244, 245, 245, 246, 246, 247, 247, 248, 248, - 249, 249, 250, 250, 251, 251, 251, 251, 251, 251, - 251, 251, 251, 251, 251, 252, 252, 253, 254, 254, - 254, 255, 256, 256, 257, 257, 258, 259, 259, 260, - 260, 260, 260, 261, 261, 261, 261, 262, 263, 263, - 263, 263, 263, 263, 263, 264, 264, 264, 264, 264, - 264, 264, 264, 265, 265, 266, 267, 267, 268, 268, - 269, 269, 269, 270, 271, 271, 271, 271, 271, 271, - 271, 271, 272, 272, 272, 272, 272, 272, 272, 272, - 272, 273, 273, 274, 274, 274, 275, 275, 275, 276, - 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, - 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, - 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, - 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, - 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, - 277, 277, 277, 278, 278, 279, 279, 280, 281, 281, - 282, 282, 283, 284, 285, 285, 286, 286, 286, 286, - 286, 286, 286, 287, 287, 288, 288, 289, 289, 290, - 290, 291, 291, 292, 293, 293, 294, 294, 295, 296, - 296, 297, 297, 297, 298, 298, 299, 299, 300, 300, - 301, 301, 301, 301, 301, 302, 302, 302, 303 + 0, 220, 222, 221, 223, 223, 224, 224, 224, 224, + 224, 225, 225, 226, 226, 226, 227, 228, 228, 229, + 229, 230, 230, 230, 230, 230, 230, 231, 231, 231, + 231, 231, 231, 232, 233, 234, 234, 235, 235, 236, + 236, 237, 237, 238, 239, 239, 239, 240, 240, 241, + 241, 242, 242, 243, 244, 244, 244, 244, 245, 245, + 245, 245, 246, 246, 246, 246, 247, 247, 247, 248, + 248, 248, 249, 249, 249, 249, 249, 250, 250, 250, + 251, 251, 252, 252, 253, 253, 254, 254, 255, 255, + 256, 256, 257, 257, 258, 258, 259, 259, 259, 259, + 259, 259, 259, 259, 259, 259, 259, 260, 260, 261, + 262, 262, 262, 263, 264, 264, 265, 265, 266, 267, + 267, 268, 268, 268, 268, 269, 269, 269, 269, 270, + 271, 271, 271, 271, 271, 271, 271, 272, 272, 272, + 272, 272, 272, 272, 272, 273, 273, 274, 275, 275, + 276, 276, 277, 277, 277, 278, 279, 279, 279, 279, + 279, 279, 279, 279, 280, 280, 280, 280, 280, 280, + 280, 280, 280, 281, 281, 282, 282, 282, 283, 283, + 283, 284, 284, 284, 284, 284, 284, 284, 284, 284, + 284, 284, 284, 284, 284, 284, 284, 284, 284, 284, + 284, 284, 284, 284, 284, 284, 284, 284, 284, 284, + 284, 284, 284, 284, 284, 284, 284, 284, 284, 284, + 284, 284, 284, 284, 284, 284, 284, 284, 284, 284, + 284, 284, 285, 285, 285, 286, 286, 287, 287, 288, + 289, 289, 290, 290, 291, 292, 293, 293, 294, 294, + 294, 294, 294, 294, 294, 295, 296, 295, 297, 297, + 298, 298, 299, 299, 300, 300, 301, 302, 302, 303, + 303, 304, 305, 305, 306, 306, 306, 307, 307, 308, + 308, 309, 309, 310, 310, 310, 310, 310, 311, 311, + 311, 312 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ static const yytype_uint8 yyr2[] = { 0, 2, 0, 4, 0, 3, 2, 2, 2, 2, - 0, 2, 5, 1, 2, 1, 1, 1, 1, 1, - 1, 3, 1, 4, 1, 3, 2, 2, 1, 1, - 1, 3, 2, 2, 2, 1, 2, 3, 2, 1, - 1, 1, 1, 2, 2, 2, 1, 1, 1, 1, - 1, 3, 3, 3, 1, 3, 3, 1, 3, 3, - 1, 3, 3, 3, 3, 1, 3, 3, 1, 3, + 2, 0, 2, 1, 1, 1, 5, 1, 2, 1, + 1, 1, 1, 1, 1, 1, 3, 1, 4, 1, + 3, 2, 2, 1, 1, 1, 3, 2, 2, 2, + 1, 2, 3, 2, 1, 1, 1, 2, 2, 2, + 1, 2, 3, 2, 1, 2, 2, 2, 1, 1, + 1, 1, 1, 3, 3, 3, 1, 3, 3, 1, + 3, 3, 1, 3, 3, 3, 3, 1, 3, 3, 1, 3, 1, 3, 1, 3, 1, 3, 1, 3, - 1, 5, 1, 3, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 3, 1, 2, 2, - 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, 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, 3, 1, 5, 1, 3, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, + 2, 2, 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, 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, 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, 1, 1, 5, 4, 1, 2, 3, + 1, 3, 1, 4, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 2, 0, 4, 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 @@ -1017,614 +1036,621 @@ 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, 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, + 4, 0, 0, 11, 0, 1, 2, 5, 0, 0, + 12, 13, 14, 15, 0, 165, 164, 185, 182, 183, + 184, 189, 190, 191, 192, 193, 194, 195, 196, 197, + 186, 187, 188, 0, 168, 169, 172, 166, 154, 153, + 152, 198, 199, 200, 201, 202, 203, 204, 205, 206, + 207, 208, 210, 211, 212, 213, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, + 229, 230, 231, 0, 181, 180, 163, 234, 233, 232, + 0, 0, 0, 0, 0, 0, 0, 209, 214, 290, + 3, 289, 0, 0, 115, 125, 0, 130, 137, 157, + 159, 0, 156, 145, 173, 175, 178, 0, 179, 17, + 288, 0, 170, 171, 167, 0, 0, 19, 20, 144, + 0, 161, 0, 6, 7, 8, 9, 10, 0, 18, + 110, 0, 291, 113, 125, 155, 126, 127, 128, 116, + 0, 125, 0, 111, 13, 15, 138, 0, 158, 160, + 146, 0, 174, 0, 0, 0, 237, 0, 162, 0, + 150, 0, 148, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 24, 22, 23, 25, 46, 0, + 0, 0, 58, 59, 60, 61, 264, 256, 260, 21, + 27, 54, 29, 34, 35, 0, 0, 40, 0, 62, + 0, 66, 69, 72, 77, 80, 82, 84, 86, 88, + 90, 92, 94, 107, 0, 245, 0, 145, 248, 262, + 247, 246, 0, 249, 250, 251, 252, 253, 254, 117, + 122, 124, 129, 0, 131, 0, 0, 118, 176, 62, + 109, 0, 44, 16, 242, 0, 240, 236, 238, 0, + 112, 0, 147, 0, 284, 283, 0, 0, 0, 287, + 285, 0, 0, 0, 273, 0, 55, 56, 0, 255, + 0, 31, 32, 0, 0, 38, 37, 0, 181, 41, + 43, 97, 98, 100, 99, 102, 103, 104, 105, 106, + 101, 96, 0, 57, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 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 + 0, 0, 0, 0, 0, 265, 261, 263, 119, 121, + 123, 0, 0, 139, 0, 244, 143, 177, 0, 0, + 239, 235, 151, 149, 0, 278, 277, 280, 0, 286, + 0, 272, 163, 269, 0, 0, 26, 0, 0, 33, + 30, 0, 36, 0, 0, 50, 42, 95, 63, 64, + 65, 67, 68, 70, 71, 75, 76, 73, 74, 78, + 79, 81, 83, 85, 87, 89, 91, 0, 108, 0, + 132, 0, 136, 0, 140, 0, 241, 0, 279, 0, + 0, 0, 0, 0, 0, 257, 28, 53, 48, 47, + 0, 181, 51, 0, 0, 0, 133, 141, 0, 243, + 0, 281, 0, 268, 266, 271, 0, 259, 274, 258, + 52, 93, 120, 134, 0, 142, 0, 282, 276, 0, + 270, 135, 275, 267 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { - -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 + -1, 2, 9, 3, 89, 6, 160, 10, 90, 189, + 190, 191, 348, 192, 193, 194, 195, 196, 197, 198, + 352, 353, 354, 355, 199, 200, 201, 202, 203, 204, + 205, 206, 207, 208, 209, 210, 211, 212, 213, 292, + 214, 241, 215, 216, 93, 94, 95, 230, 139, 140, + 231, 96, 97, 98, 99, 161, 162, 100, 141, 101, + 102, 242, 104, 105, 106, 107, 108, 155, 156, 245, + 246, 326, 218, 219, 220, 221, 270, 418, 419, 222, + 223, 224, 414, 345, 225, 226, 227, 337, 389, 390, + 228, 109, 110 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ -#define YYPACT_NINF -350 +#define YYPACT_NINF -366 static const yytype_int16 yypact[] = { - -78, -56, 54, -350, -52, -350, -37, -350, 8, 3302, - -350, -26, -350, -350, -350, -350, -350, -350, -350, -350, - -350, -350, -350, -350, -350, -350, -350, -350, -350, -350, - 88, -350, -350, -350, -350, -350, -350, -350, -350, -350, - -350, -350, -350, -350, -350, -350, -350, -350, -350, -350, - -350, -350, -350, -350, -350, -350, -350, -350, -350, -350, - -350, -350, -350, -350, -350, -350, -350, -350, -350, -350, - -66, -350, -350, 42, -350, -350, -350, 70, -4, 10, - 29, 34, -79, -350, -350, -350, 3302, -350, -19, -24, - -69, 5, -154, -350, 102, 16, 16, 3490, -350, -350, - -350, 18, -350, 3562, -350, -350, -350, 108, -350, -350, - -350, -8, 3490, -350, 16, -350, 3562, -350, -350, -350, - -350, 138, -350, -350, 387, -350, -350, 24, -350, -350, - -350, -350, -350, 3490, 147, 141, -350, -166, -350, -350, - -350, 2387, -350, 106, 3490, 144, 1772, -350, -350, 7, - 11, -87, -350, 14, 15, 1243, 30, 32, 20, 2004, - 37, 2936, 25, 39, -65, -350, -350, -350, -350, -350, - 2936, 2936, 2936, -350, -350, -350, -350, -350, 601, -350, - -350, -350, -59, -350, -350, -350, 28, -82, 3119, 43, - -30, 2936, -11, -2, 118, -74, 114, 35, 31, 36, - 148, 152, -77, -350, -350, -115, -350, 40, 52, -350, - -350, -350, -350, 815, -350, -350, -350, -350, -350, -350, - -350, -350, -350, 172, 3490, -180, -350, 2570, 2936, -350, - -350, -350, 53, -350, -350, 1888, 55, -113, -350, -350, - -350, -350, 173, -350, 138, -350, -350, 178, 1656, 2936, - -350, -350, -108, 2936, -161, -350, 2204, -350, -350, -68, - -350, 1029, -350, -350, 2936, 3418, -350, -350, 2936, 61, - -350, -350, -350, -350, -350, -350, -350, -350, -350, -350, - -350, -350, -350, 2936, -350, 2936, 2936, 2936, 2936, 2936, - 2936, 2936, 2936, 2936, 2936, 2936, 2936, 2936, 2936, 2936, - 2936, 2936, 2936, 2936, 2936, 2936, -350, -350, -350, 63, - -350, -350, 2753, 2936, 46, 60, -350, -350, -350, -350, - 2936, 144, -350, -350, -350, 67, -350, -350, 2204, -55, - -350, -54, -350, 238, 65, 188, 71, -350, -350, 72, - 65, 73, -350, -350, -350, -350, -350, -350, -11, -11, - -2, -2, 118, 118, 118, 118, -74, -74, 114, 35, - 31, 36, 148, 152, -157, -350, 2936, 56, 83, -350, - 2936, 68, 84, -350, 2936, -350, 69, 90, 1243, 74, - 77, 1456, -350, 2936, 86, 2936, 79, -350, 2936, -350, - -53, 2936, 1456, 255, -350, -350, 2936, -350, -350, -350, - -350, -350, -350, 2936, -350, 80, 65, -350, 1243, -350, - -350, -350, -350 + -57, -43, 62, -366, -50, -366, -30, -366, 67, 3341, + -366, -366, -366, -366, -6, -366, -366, -366, -366, -366, + -366, -366, -366, -366, -366, -366, -366, -366, -366, -366, + -366, -366, -366, 8, -366, -366, -366, -366, -366, -366, + -366, -366, -366, -366, -366, -366, -366, -366, -366, -366, + -366, -366, -366, -366, -366, -366, -366, -366, -366, -366, + -366, -366, -366, -366, -366, -366, -366, -366, -366, -366, + -366, -366, -366, -65, -366, -366, 226, -366, -366, -366, + 51, -31, -28, 6, 13, 15, -44, -366, -366, -366, + 3341, -366, -183, -47, -29, 18, -169, -366, 140, 24, + 24, 3460, -366, -366, -366, -24, -366, 3533, -366, -366, + -366, 67, -366, -366, -366, 3460, -48, -366, -366, -366, + 24, -366, 3533, -366, -366, -366, -366, -366, 67, -366, + -366, 408, -366, -366, 55, -366, -366, -366, -366, -366, + 3460, 200, 67, -366, -20, -18, -178, 23, -366, -366, + -366, 2225, -366, 72, 67, 1598, -366, 3460, -366, 4, + 10, -84, -366, 11, 14, 1059, 40, 42, 29, 1836, + 43, 2783, 34, 54, -366, -366, -366, -366, -366, 2783, + 2783, 2783, -366, -366, -366, -366, -366, 32, -366, 56, + -366, -71, -366, -366, -366, 57, -81, 2969, 61, -27, + 2783, 35, -88, -41, -70, 33, 60, 41, 59, 181, + 180, -89, -366, -366, -168, -366, 58, 80, -366, -366, + -366, -366, 625, -366, -366, -366, -366, -366, -366, -366, + -366, -366, 67, 3460, -177, 2411, 2783, -366, -366, -366, + -366, 78, -366, -366, 81, -137, -366, -366, -366, 1717, + -366, 201, -366, 67, -366, -366, 205, 1478, 2783, -366, + -366, -134, 2783, -115, -366, 2039, -366, -366, -60, -366, + 1059, -366, -366, 2783, 140, -366, -366, 2783, 85, -366, + -366, -366, -366, -366, -366, -366, -366, -366, -366, -366, + -366, -366, 2783, -366, 2783, 2783, 2783, 2783, 2783, 2783, + 2783, 2783, 2783, 2783, 2783, 2783, 2783, 2783, 2783, 2783, + 2783, 2783, 2783, 2783, 2783, -366, -366, -366, 86, -366, + -366, 2597, 2783, 69, 87, -366, -366, -366, 2783, 67, + -366, -366, -366, -366, 91, -366, -366, 2039, -59, -366, + -46, -366, 129, 88, 67, 93, -366, 842, 89, 88, + -366, 95, -366, 96, -37, 3155, -366, -366, -366, -366, + -366, 35, 35, -88, -88, -41, -41, -41, -41, -70, + -70, 33, 60, 41, 59, 181, 180, -96, -366, 2783, + 76, 97, -366, 2783, 79, 98, -366, 2783, -366, 77, + 101, 1059, 83, 90, 1275, -366, -366, -366, -366, -366, + 2783, 102, -366, 2783, 108, 2783, 94, -366, 2783, -366, + -26, 2783, 1275, 297, -366, -366, 2783, -366, -366, -366, + -366, -366, -366, -366, 2783, -366, 100, 88, -366, 1059, + -366, -366, -366, -366 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -350, -350, -350, -350, -350, -350, -350, -350, -350, -350, - -350, -350, -350, -350, 22, -350, -350, -350, -350, -135, - -350, -83, -81, -104, -85, -13, -6, -5, -3, -1, - -7, -350, -133, -97, -350, -156, -193, 9, 12, -350, - -350, -350, 76, 170, 168, 81, -350, -350, -239, -350, - -350, 59, -71, -350, -350, -72, -9, 1, -350, -350, - 227, -350, 163, -139, -350, -12, -283, 62, -151, -349, - -67, -84, 223, 135, 66, -350, -350, -10, -350, -350, - -350, -350, -350, -350, -350, 229, -350 + -366, -366, -366, -366, -366, -366, -7, -366, -366, -62, + -366, -366, -366, -366, -366, -366, -366, -366, -366, -366, + -366, -366, -366, -366, -101, -366, -113, -109, -121, -61, + 5, 3, 9, 16, 2, 7, -366, -142, -100, -366, + -164, -225, 21, 22, -366, -366, -366, 82, 186, 173, + 92, -366, -366, -242, -366, -366, 68, -73, -366, -366, + -74, -9, -67, -366, -366, 243, -366, 170, -147, -366, + 0, -298, 73, -159, -365, -58, -366, -80, 239, 63, + 84, -366, -366, -2, -366, -366, -366, -366, -366, -366, + -366, 246, -366 }; /* 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 -169 +#define YYTABLE_NINF -115 static const yytype_int16 yytable[] = { - 99, 115, 114, 252, 247, 254, 230, 240, 231, 128, - 111, -168, 292, 293, 303, 312, 259, 335, 87, 12, - 13, 88, 4, 138, 139, 262, 263, 226, 128, 227, - 369, 1, 397, 313, 315, 257, 258, 305, 129, 130, - 131, 305, 148, 397, 135, 12, 13, 228, 30, 31, - 32, 332, 33, 34, 5, 383, 284, 129, 130, 131, - 136, 7, 308, 272, 273, 274, 275, 276, 277, 278, - 279, 280, 281, 8, 30, 31, 32, 99, 33, 34, - 35, 36, 37, 305, 11, 321, 107, 387, 140, 335, - 305, 270, 230, 329, 231, 87, 240, 331, 88, 306, - 334, 322, 402, 145, 142, 404, 330, 243, 340, 117, - 308, 244, 267, 409, 121, 208, 268, 149, 113, 368, - 410, 108, 109, 118, 223, 110, 337, 372, -40, 127, - 305, 316, 294, 295, 304, 145, 264, 145, 265, 378, - 379, 405, 119, 305, 305, 305, 208, 120, 364, 112, - 345, 346, 347, 230, 230, 230, 230, 230, 230, 230, - 230, 230, 230, 230, 230, 230, 230, 230, 230, 208, - 126, 343, 334, 384, 74, 75, 76, 230, 137, 231, - 129, 130, 131, 282, 143, 230, 344, 231, 352, 353, - 354, 355, 285, 286, 287, 123, 124, 288, 289, -102, - 290, 291, 296, 297, 208, 348, 349, 144, 365, 350, - 351, 356, 357, 141, 150, 223, 316, 225, 390, 234, - 236, 241, 266, 248, 242, 249, 145, 393, 245, 246, - 253, 230, 256, 231, 250, 406, 271, 255, 301, 208, - 299, 12, 13, 298, 302, -39, 300, 208, 309, 318, - 320, 323, 208, 325, 123, -34, 371, 412, 366, 370, - 374, 115, 114, 305, 380, 381, -40, 408, 382, 385, - 30, 31, 32, 316, 33, 34, 35, 36, 37, 386, - 389, 388, 401, 391, 392, 358, 400, 342, 316, 178, - 396, 316, 403, 359, 411, 360, 363, 220, 361, 316, - 310, 362, 224, 324, 116, 311, 316, 235, 407, 373, - 326, 125, 395, 261, 327, 122, 0, 0, 375, 208, + 103, 14, 121, 120, 312, 261, 256, 263, 248, 240, + 324, 11, 12, 13, 119, 271, 272, 268, 301, 302, + 235, 321, 135, 344, 382, 148, 149, 15, 16, 417, + 91, 92, 142, 314, 130, 131, 147, 4, 236, 322, + 152, 112, 113, 299, 300, 114, 158, 417, 143, 315, + 239, 136, 137, 138, 1, 159, 33, 34, 35, 135, + 36, 37, 5, 317, 329, 7, 116, 314, 281, 282, + 283, 284, 285, 286, 287, 288, 289, 290, 266, 267, + 330, 103, 8, 339, 123, 407, 314, 124, 136, 137, + 138, 146, 150, 240, 338, 344, 381, 279, 340, 293, + 341, 343, 248, 385, 153, 314, 154, 423, 111, 349, + 425, 91, 92, 252, 297, 298, 276, 253, 430, 403, + 277, 125, 217, 305, 306, 313, 431, 273, 126, 274, + 127, 232, 15, 16, 239, 234, 325, 346, 391, 303, + 304, 314, 314, 11, 12, 13, 154, 244, 154, 377, + 133, 392, 128, 115, 404, 314, 217, 77, 78, 79, + 399, 33, 34, 35, 400, 36, 37, 38, 39, 40, + 157, 426, 134, 343, 151, 314, -19, 356, -20, 240, + 365, 366, 367, 368, 361, 362, 240, 243, 317, 291, + 363, 364, 357, 358, 359, 360, 239, 239, 239, 239, + 239, 239, 239, 239, 239, 239, 239, 239, 239, 239, + 239, 239, 351, 217, 378, -114, 144, 12, 145, 237, + 239, 250, 325, 410, 232, 318, 251, 239, 254, 15, + 16, 255, 413, 136, 137, 138, 257, 240, 258, 262, + 154, 294, 295, 296, 369, 370, 259, 427, 217, 264, + 265, 269, -45, 308, 275, 402, 217, 280, 33, 34, + 35, 217, 36, 37, 38, 39, 40, 350, 121, 120, + 433, 307, 309, 310, 311, 130, -44, 327, 239, 328, + 334, 332, -39, 325, 379, 383, 384, 387, 396, 314, + 394, 397, 405, 398, 411, 408, 406, 409, 412, -49, + 420, 187, 117, 421, 118, 325, 416, 422, 325, 429, + 424, 372, 371, 375, 233, 319, 325, 432, 373, 376, + 229, 333, 244, 122, 325, 320, 374, 249, 217, 386, + 335, 132, 428, 347, 415, 388, 129, 393, 217, 0, + 0, 336, 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, 217, 0, 0, 217, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 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, - 70, 71, 163, 164, 165, 166, 167, 168, 169, 0, - 0, 170, 171, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 217, 0, 0, 0, 0, 0, 0, + 0, 15, 16, 17, 18, 19, 20, 163, 164, 165, + 217, 166, 167, 168, 169, 170, 171, 172, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, + 33, 34, 35, 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, 70, 71, + 72, 73, 74, 173, 117, 75, 118, 174, 175, 176, + 177, 178, 0, 0, 179, 180, 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, 76, 77, 78, 79, 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 86, 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, 87, 0, 88, 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, 181, 0, 0, 0, 0, 0, + 182, 183, 184, 185, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 186, 187, 188, 15, 16, + 17, 18, 19, 20, 163, 164, 165, 0, 166, 167, + 168, 169, 170, 171, 172, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, + 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, 70, 71, 72, 73, 74, + 173, 117, 75, 118, 174, 175, 176, 177, 178, 0, + 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 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, 70, 71, 163, 164, 165, 166, - 167, 168, 169, 0, 0, 170, 171, 0, 0, 0, + 76, 77, 78, 79, 0, 80, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 86, 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, 87, 0, 88, 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, 181, 0, 0, 0, 0, 0, 182, 183, 184, + 185, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 186, 187, 316, 15, 16, 17, 18, 19, + 20, 163, 164, 165, 0, 166, 167, 168, 169, 170, + 171, 172, 21, 22, 23, 24, 25, 26, 27, 28, + 29, 30, 31, 32, 33, 34, 35, 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, 70, 71, 72, 73, 74, 173, 117, 75, + 118, 174, 175, 176, 177, 178, 0, 0, 179, 180, 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, 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, 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, 76, 77, 78, + 79, 0, 80, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 86, 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, 0, 0, 0, 0, 0, 0, 87, + 0, 88, 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, 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, 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, 181, 0, + 0, 0, 0, 0, 182, 183, 184, 185, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 186, + 187, 395, 15, 16, 17, 18, 19, 20, 163, 164, + 165, 0, 166, 167, 168, 169, 170, 171, 172, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, + 32, 33, 34, 35, 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, 70, + 71, 72, 73, 74, 173, 117, 75, 118, 174, 175, + 176, 177, 178, 0, 0, 179, 180, 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, 76, 77, 78, 79, 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 86, 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, 87, 0, 88, 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, 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, 181, 0, 0, 0, 0, + 0, 182, 183, 184, 185, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 186, 187, 15, 16, + 17, 18, 19, 20, 163, 164, 165, 0, 166, 167, + 168, 169, 170, 171, 172, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, + 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, 70, 71, 72, 73, 74, + 173, 117, 75, 118, 174, 175, 176, 177, 178, 0, + 0, 179, 180, 0, 0, 0, 0, 0, 0, 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, + 76, 77, 78, 79, 0, 80, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 86, 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, 0, 87, 0, 88, 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, 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, 181, 0, 0, 0, 0, 0, 182, 183, 184, + 185, 15, 16, 17, 18, 19, 20, 0, 0, 0, + 0, 0, 186, 131, 0, 0, 0, 0, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, + 33, 34, 35, 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, 70, 71, + 72, 73, 74, 0, 117, 75, 118, 174, 175, 176, + 177, 178, 0, 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 76, 77, 78, 79, 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, + 0, 86, 0, 17, 18, 19, 20, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, + 0, 0, 0, 0, 0, 87, 0, 88, 0, 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, 0, 181, 75, 0, 0, 0, 0, + 182, 183, 184, 185, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 186, 0, 0, 0, 0, + 0, 0, 0, 0, 77, 78, 79, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 17, 18, 19, 20, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 0, + 0, 0, 0, 0, 0, 87, 0, 88, 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, 0, 0, 75, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 247, 0, 0, + 0, 0, 0, 77, 78, 79, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 17, 18, 19, 20, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, 32, 0, 0, + 0, 0, 0, 0, 87, 0, 88, 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, 0, 117, 75, 118, 174, 175, 176, 177, 178, + 0, 0, 179, 180, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 331, 0, 0, 0, + 0, 0, 77, 78, 79, 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, 12, - 13, 14, 15, 16, 17, 0, 0, 0, 0, 0, - 177, 124, 0, 0, 0, 0, 18, 19, 20, 21, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 87, 0, 88, 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, 181, 0, 0, 0, 0, 0, 182, 183, + 184, 185, 15, 16, 17, 18, 19, 20, 0, 0, + 0, 0, 0, 260, 0, 0, 0, 0, 0, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, - 32, 0, 33, 34, 35, 36, 37, 38, 39, 40, + 32, 33, 34, 35, 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, 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, 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, 70, 71, 0, 72, 172, - 0, 0, 0, 0, 0, 173, 174, 175, 176, 0, + 71, 72, 73, 74, 0, 117, 75, 118, 174, 175, + 176, 177, 178, 0, 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 177, 0, 0, 0, 0, 0, 74, 75, 76, 0, + 0, 0, 0, 0, 342, 77, 78, 79, 0, 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, 70, 71, 0, 72, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 239, 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, 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, 319, 0, 0, 0, 74, 75, - 76, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 86, 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, 87, 0, 88, 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, 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, + 17, 18, 19, 20, 0, 181, 0, 0, 0, 0, + 0, 182, 183, 184, 185, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, 32, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 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, + 0, 117, 75, 118, 174, 175, 176, 177, 178, 0, + 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 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, 82, 0, 0, 0, 0, 0, + 0, 77, 78, 79, 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, 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, 87, 0, 88, 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, 17, 18, 19, 20, + 0, 181, 0, 0, 238, 0, 0, 182, 183, 184, + 185, 21, 22, 23, 24, 25, 26, 27, 28, 29, + 30, 31, 32, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 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, 0, 117, 75, 118, + 174, 175, 176, 177, 178, 0, 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 77, 78, 79, 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, 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, 87, 0, + 88, 0, 0, 0, 0, 0, 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, 17, 18, 19, 20, 0, 181, 0, 0, + 323, 0, 0, 182, 183, 184, 185, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 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, 0, 117, 75, 118, 174, 175, 176, 177, + 178, 0, 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 77, 78, 79, 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, 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, 87, 0, 88, 0, 0, 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, 17, 18, + 19, 20, 0, 181, 0, 0, 380, 0, 0, 182, + 183, 184, 185, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 30, 31, 32, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 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, 0, 117, + 75, 118, 174, 175, 176, 177, 178, 0, 0, 179, + 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 77, + 78, 79, 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, 83, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 87, 0, 88, 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, + 0, 0, 0, 0, 17, 18, 19, 20, 0, 181, + 0, 0, 0, 0, 0, 182, 183, 184, 185, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, + 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, + 71, 72, 73, 278, 0, 117, 75, 118, 174, 175, + 176, 177, 178, 0, 0, 179, 180, 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, 77, 78, 79, 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, 0, 0, 87, 0, 88, 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, 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, + 17, 18, 19, 20, 0, 181, 0, 0, 0, 0, + 0, 182, 183, 184, 185, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, 32, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 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, 401, + 0, 117, 75, 118, 174, 175, 176, 177, 178, 0, + 0, 179, 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 77, 78, 79, 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, 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, 87, 0, 88, 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, 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, + 0, 0, 0, 0, 15, 16, 17, 18, 19, 20, + 0, 181, 0, 0, 0, 0, 0, 182, 183, 184, + 185, 21, 22, 23, 24, 25, 26, 27, 28, 29, + 30, 31, 32, 33, 34, 35, 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, 70, 71, 0, 341, 14, 15, 16, 17, 169, + 69, 70, 71, 72, 73, 74, 0, 0, 75, 0, 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, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 76, 77, 78, 79, + 0, 80, 0, 0, 0, 0, 0, 0, 0, 81, + 82, 83, 84, 85, 86, 17, 18, 19, 20, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, + 31, 32, 0, 0, 0, 0, 0, 0, 87, 0, + 88, 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, 0, 0, 75, 17, 18, + 19, 20, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 21, 22, 23, 24, 25, 26, 27, + 28, 29, 30, 31, 32, 0, 77, 78, 79, 0, + 0, 0, 0, 0, 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, + 67, 68, 69, 70, 71, 72, 73, 74, 0, 0, + 75, 0, 0, 0, 0, 0, 0, 87, 0, 88, + 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, 0, 0, 0, 0, 83, 0, 84 + 87, 0, 88 }; static const yytype_int16 yycheck[] = { - 9, 73, 73, 159, 155, 161, 141, 146, 141, 4, - 76, 76, 86, 87, 91, 195, 172, 256, 9, 3, - 4, 9, 78, 95, 96, 84, 85, 193, 4, 195, - 313, 109, 381, 213, 227, 170, 171, 198, 33, 34, - 35, 198, 114, 392, 198, 3, 4, 213, 32, 33, - 34, 212, 36, 37, 0, 212, 191, 33, 34, 35, - 214, 113, 213, 93, 94, 95, 96, 97, 98, 99, - 100, 101, 102, 110, 32, 33, 34, 86, 36, 37, - 38, 39, 40, 198, 76, 198, 112, 370, 97, 328, - 198, 188, 227, 249, 227, 86, 235, 253, 86, 214, - 256, 214, 385, 112, 103, 388, 214, 194, 264, 113, - 261, 198, 194, 396, 193, 124, 198, 116, 76, 312, - 403, 33, 34, 113, 133, 37, 194, 320, 193, 198, - 198, 228, 206, 207, 211, 144, 195, 146, 197, 194, - 194, 194, 113, 198, 198, 198, 155, 113, 304, 215, - 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, - 295, 296, 297, 298, 299, 300, 301, 302, 303, 178, - 194, 268, 328, 366, 104, 105, 106, 312, 76, 312, - 33, 34, 35, 213, 76, 320, 283, 320, 292, 293, - 294, 295, 203, 204, 205, 214, 215, 199, 200, 194, - 82, 83, 88, 89, 213, 288, 289, 215, 305, 290, - 291, 296, 297, 195, 76, 224, 313, 76, 374, 113, - 76, 214, 194, 193, 213, 193, 235, 378, 214, 214, - 193, 366, 193, 366, 214, 391, 193, 212, 90, 248, - 209, 3, 4, 208, 92, 193, 210, 256, 76, 196, - 195, 78, 261, 75, 214, 194, 196, 408, 195, 213, - 193, 333, 333, 198, 76, 194, 193, 12, 196, 213, - 32, 33, 34, 370, 36, 37, 38, 39, 40, 196, - 196, 213, 196, 214, 194, 298, 383, 265, 385, 215, - 213, 388, 213, 299, 214, 300, 303, 127, 301, 396, - 224, 302, 134, 244, 77, 224, 403, 144, 392, 321, - 248, 88, 379, 178, 248, 86, -1, -1, 328, 328, + 9, 8, 76, 76, 93, 169, 165, 171, 155, 151, + 235, 76, 77, 78, 76, 86, 87, 181, 88, 89, + 198, 198, 4, 265, 322, 99, 100, 3, 4, 394, + 9, 9, 201, 201, 217, 218, 98, 80, 216, 216, + 107, 33, 34, 84, 85, 37, 120, 412, 217, 217, + 151, 33, 34, 35, 111, 122, 32, 33, 34, 4, + 36, 37, 0, 222, 201, 115, 73, 201, 95, 96, + 97, 98, 99, 100, 101, 102, 103, 104, 179, 180, + 217, 90, 112, 217, 115, 383, 201, 115, 33, 34, + 35, 98, 101, 235, 258, 337, 321, 197, 262, 200, + 215, 265, 249, 328, 111, 201, 115, 405, 114, 273, + 408, 90, 90, 197, 202, 203, 197, 201, 416, 215, + 201, 115, 131, 90, 91, 214, 424, 198, 115, 200, + 115, 140, 3, 4, 235, 142, 236, 197, 197, 209, + 210, 201, 201, 76, 77, 78, 155, 154, 157, 313, + 197, 197, 196, 218, 379, 201, 165, 106, 107, 108, + 197, 32, 33, 34, 201, 36, 37, 38, 39, 40, + 218, 197, 201, 337, 198, 201, 196, 277, 196, 321, + 301, 302, 303, 304, 297, 298, 328, 115, 347, 216, + 299, 300, 292, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, 312, 274, 222, 314, 197, 76, 77, 78, 196, + 321, 217, 322, 387, 233, 232, 216, 328, 217, 3, + 4, 217, 391, 33, 34, 35, 196, 379, 196, 196, + 249, 206, 207, 208, 305, 306, 217, 411, 257, 215, + 196, 219, 196, 212, 197, 355, 265, 196, 32, 33, + 34, 270, 36, 37, 38, 39, 40, 274, 342, 342, + 429, 211, 213, 92, 94, 217, 196, 199, 379, 198, + 75, 80, 197, 383, 198, 216, 199, 196, 199, 201, + 197, 196, 216, 197, 217, 216, 199, 199, 197, 197, + 400, 218, 76, 403, 78, 405, 216, 199, 408, 12, + 216, 308, 307, 311, 141, 233, 416, 217, 309, 312, + 134, 253, 329, 80, 424, 233, 310, 157, 337, 329, + 257, 92, 412, 270, 392, 337, 90, 344, 347, -1, + -1, 257, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 391, -1, -1, 394, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, - 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, 412, -1, -1, -1, -1, -1, -1, + -1, 3, 4, 5, 6, 7, 8, 9, 10, 11, + 429, 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, + 82, 83, -1, -1, 86, 87, -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, 105, 106, 107, 108, -1, 110, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 123, -1, -1, -1, -1, -1, -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, 157, -1, 159, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 193, -1, -1, -1, -1, -1, 199, 200, 201, 202, + -1, -1, -1, -1, 196, -1, -1, -1, -1, -1, + 202, 203, 204, 205, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 217, 218, 219, 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, 82, 83, -1, + -1, 86, 87, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 214, 215, 216, 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, + 105, 106, 107, 108, -1, 110, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 123, -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, 157, -1, 159, -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, 196, -1, -1, -1, -1, -1, 202, 203, 204, + 205, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 217, 218, 219, 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, 82, 83, -1, -1, 86, 87, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 193, -1, -1, -1, -1, -1, - 199, 200, 201, 202, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 214, 215, 216, 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, 105, 106, 107, + 108, -1, 110, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 123, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, 157, + -1, 159, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 193, -1, - -1, -1, -1, -1, 199, 200, 201, 202, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 214, - 215, 216, 3, 4, 5, 6, 7, 8, 9, 10, + -1, -1, -1, -1, -1, -1, -1, -1, 196, -1, + -1, -1, -1, -1, 202, 203, 204, 205, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 217, + 218, 219, 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, @@ -1632,315 +1658,312 @@ static const yytype_int16 yycheck[] = 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, + 81, 82, 83, -1, -1, 86, 87, -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, 105, 106, 107, 108, -1, 110, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 123, -1, -1, -1, -1, -1, -1, -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, 157, -1, 159, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, 193, -1, -1, -1, -1, -1, 199, 200, - 201, 202, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 214, 215, 216, 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, 196, -1, -1, -1, -1, + -1, 202, 203, 204, 205, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 217, 218, 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, 82, 83, -1, + -1, 86, 87, -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, -1, - -1, -1, -1, 120, -1, -1, -1, -1, -1, -1, + 105, 106, 107, 108, -1, 110, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 123, -1, -1, -1, -1, -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, 157, -1, 159, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 193, -1, -1, -1, - -1, -1, 199, 200, 201, 202, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 214, 215, 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, 196, -1, -1, -1, -1, -1, 202, 203, 204, + 205, 3, 4, 5, 6, 7, 8, -1, -1, -1, + -1, -1, 217, 218, -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, + 82, 83, -1, -1, 86, 87, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 105, 106, 107, 108, -1, 110, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - 154, -1, 156, -1, -1, -1, -1, -1, -1, -1, + -1, 123, -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, 157, -1, 159, -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, 196, 77, -1, -1, -1, -1, + 202, 203, 204, 205, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 217, -1, -1, -1, -1, + -1, -1, -1, -1, 106, 107, 108, -1, -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, 157, -1, 159, 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, -1, 77, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 219, -1, -1, + -1, -1, -1, 106, 107, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 193, - -1, -1, -1, -1, -1, 199, 200, 201, 202, 3, - 4, 5, 6, 7, 8, -1, -1, -1, -1, -1, - 214, 215, -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, + -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, 157, -1, 159, 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, 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, 193, - -1, -1, -1, -1, -1, 199, 200, 201, 202, -1, + 74, -1, 76, 77, 78, 79, 80, 81, 82, 83, + -1, -1, 86, 87, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 219, -1, -1, -1, + -1, -1, 106, 107, 108, -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, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 216, -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, -1, -1, 216, -1, -1, -1, 104, 105, - 106, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 157, -1, 159, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, 196, -1, -1, -1, -1, -1, 202, 203, + 204, 205, 3, 4, 5, 6, 7, 8, -1, -1, + -1, -1, -1, 217, -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, 82, 83, -1, -1, 86, 87, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 105, 106, 107, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 193, -1, -1, - -1, -1, -1, 199, 200, 201, 202, 3, 4, 5, - 6, 7, 8, -1, -1, -1, -1, -1, 214, -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, 123, -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, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 157, -1, 159, -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, 5, 6, 7, 8, -1, 193, -1, -1, - -1, -1, -1, 199, 200, 201, 202, 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, + 5, 6, 7, 8, -1, 196, -1, -1, -1, -1, + -1, 202, 203, 204, 205, 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, 82, 83, -1, + -1, 86, 87, -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, 106, 107, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, 157, -1, 159, -1, -1, -1, -1, -1, -1, -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, - 193, -1, -1, 196, -1, -1, 199, 200, 201, 202, - 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, 5, 6, 7, 8, + -1, 196, -1, -1, 199, -1, -1, 202, 203, 204, + 205, 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, 82, 83, -1, -1, 86, 87, -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, 106, 107, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, 157, -1, + 159, -1, -1, -1, -1, -1, -1, -1, -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, 196, -1, -1, + 199, -1, -1, 202, 203, 204, 205, 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, 82, + 83, -1, -1, 86, 87, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 106, 107, 108, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 157, -1, 159, -1, -1, -1, -1, -1, -1, -1, -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, 193, -1, -1, 196, -1, -1, 199, - 200, 201, 202, 20, 21, 22, 23, 24, 25, 26, + 7, 8, -1, 196, -1, -1, 199, -1, -1, 202, + 203, 204, 205, 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, + 77, 78, 79, 80, 81, 82, 83, -1, -1, 86, + 87, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 106, + 107, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, + 157, -1, 159, -1, -1, -1, -1, -1, -1, -1, -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, 196, + -1, -1, -1, -1, -1, 202, 203, 204, 205, 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, 82, 83, -1, -1, 86, 87, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 5, 6, 7, 8, -1, 193, -1, -1, 196, - -1, -1, 199, 200, 201, 202, 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, 106, 107, 108, -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, 157, -1, 159, -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, 5, 6, 7, 8, -1, 193, - -1, -1, -1, -1, -1, 199, 200, 201, 202, 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, + 5, 6, 7, 8, -1, 196, -1, -1, -1, -1, + -1, 202, 203, 204, 205, 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, 82, 83, -1, + -1, 86, 87, -1, -1, -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, 106, 107, 108, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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, 157, -1, 159, -1, -1, -1, -1, -1, -1, -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, 193, -1, -1, -1, -1, -1, 199, 200, - 201, 202, 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, 3, 4, 5, 6, 7, 8, + -1, 196, -1, -1, -1, -1, -1, 202, 203, 204, + 205, 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, -1, 77, -1, -1, -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, 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, 105, 106, 107, 108, + -1, 110, -1, -1, -1, -1, -1, -1, -1, 118, + 119, 120, 121, 122, 123, 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, 104, 105, 106, -1, -1, -1, -1, -1, - -1, 41, 42, 43, 44, 45, 46, 47, 48, 49, + 30, 31, -1, -1, -1, -1, -1, -1, 157, -1, + 159, 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, + 70, 71, 72, 73, 74, -1, -1, 77, 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, 106, 107, 108, -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, -1, + 77, -1, -1, -1, -1, -1, -1, 157, -1, 159, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -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 + 157, -1, 159 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing symbol of state STATE-NUM. */ static const yytype_uint16 yystos[] = { - 0, 109, 218, 220, 78, 0, 222, 113, 110, 219, - 223, 76, 3, 4, 5, 6, 7, 8, 20, 21, - 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, - 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, 221, 224, 254, 255, 256, - 257, 258, 263, 264, 265, 266, 269, 271, 272, 273, - 274, 275, 276, 277, 278, 302, 303, 112, 33, 34, - 37, 76, 215, 76, 269, 272, 277, 113, 113, 113, - 113, 193, 302, 214, 215, 289, 194, 198, 4, 33, - 34, 35, 260, 261, 270, 198, 214, 76, 272, 272, - 273, 195, 274, 76, 215, 273, 279, 280, 272, 274, - 76, 267, 268, 9, 10, 11, 13, 14, 15, 16, - 17, 18, 19, 75, 76, 77, 78, 79, 80, 81, - 84, 85, 193, 199, 200, 201, 202, 214, 215, 216, - 225, 226, 227, 229, 230, 231, 232, 233, 234, 235, - 236, 237, 238, 239, 240, 241, 242, 243, 244, 245, - 246, 247, 248, 249, 250, 252, 254, 255, 273, 284, - 285, 286, 287, 290, 291, 292, 295, 296, 297, 301, - 260, 259, 262, 273, 261, 76, 193, 195, 213, 196, - 236, 249, 253, 273, 113, 279, 76, 281, 282, 216, - 280, 214, 213, 194, 198, 214, 214, 285, 193, 193, - 214, 214, 252, 193, 252, 212, 193, 236, 236, 252, - 216, 290, 84, 85, 195, 197, 194, 194, 198, 74, - 250, 193, 93, 94, 95, 96, 97, 98, 99, 100, - 101, 102, 213, 251, 236, 203, 204, 205, 199, 200, - 82, 83, 86, 87, 206, 207, 88, 89, 208, 209, - 210, 90, 92, 91, 211, 198, 214, 216, 285, 76, - 259, 262, 195, 213, 196, 253, 250, 283, 196, 216, - 195, 198, 214, 78, 268, 75, 284, 291, 298, 252, - 214, 252, 212, 103, 252, 265, 294, 194, 216, 228, - 252, 76, 231, 250, 250, 236, 236, 236, 238, 238, - 239, 239, 240, 240, 240, 240, 241, 241, 242, 243, - 244, 245, 246, 247, 252, 250, 195, 196, 253, 283, - 213, 196, 253, 282, 193, 294, 299, 300, 194, 194, - 76, 194, 196, 212, 253, 213, 196, 283, 213, 196, - 252, 214, 194, 285, 293, 287, 213, 286, 288, 289, - 250, 196, 283, 213, 283, 194, 252, 288, 12, 283, - 283, 214, 285 + 0, 111, 221, 223, 80, 0, 225, 115, 112, 222, + 227, 76, 77, 78, 226, 3, 4, 5, 6, 7, + 8, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, 30, 31, 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, 77, 105, 106, 107, 108, + 110, 118, 119, 120, 121, 122, 123, 157, 159, 224, + 228, 262, 263, 264, 265, 266, 271, 272, 273, 274, + 277, 279, 280, 281, 282, 283, 284, 285, 286, 311, + 312, 114, 33, 34, 37, 218, 226, 76, 78, 229, + 277, 280, 285, 115, 115, 115, 115, 115, 196, 311, + 217, 218, 298, 197, 201, 4, 33, 34, 35, 268, + 269, 278, 201, 217, 76, 78, 226, 229, 280, 280, + 281, 198, 282, 226, 281, 287, 288, 218, 280, 282, + 226, 275, 276, 9, 10, 11, 13, 14, 15, 16, + 17, 18, 19, 75, 79, 80, 81, 82, 83, 86, + 87, 196, 202, 203, 204, 205, 217, 218, 219, 229, + 230, 231, 233, 234, 235, 236, 237, 238, 239, 244, + 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, + 255, 256, 257, 258, 260, 262, 263, 281, 292, 293, + 294, 295, 299, 300, 301, 304, 305, 306, 310, 268, + 267, 270, 281, 269, 226, 198, 216, 196, 199, 244, + 257, 261, 281, 115, 226, 289, 290, 219, 288, 287, + 217, 216, 197, 201, 217, 217, 293, 196, 196, 217, + 217, 260, 196, 260, 215, 196, 244, 244, 260, 219, + 296, 86, 87, 198, 200, 197, 197, 201, 74, 258, + 196, 95, 96, 97, 98, 99, 100, 101, 102, 103, + 104, 216, 259, 244, 206, 207, 208, 202, 203, 84, + 85, 88, 89, 209, 210, 90, 91, 211, 212, 213, + 92, 94, 93, 214, 201, 217, 219, 293, 226, 267, + 270, 198, 216, 199, 261, 258, 291, 199, 198, 201, + 217, 219, 80, 276, 75, 292, 300, 307, 260, 217, + 260, 215, 105, 260, 273, 303, 197, 299, 232, 260, + 226, 229, 240, 241, 242, 243, 258, 258, 244, 244, + 244, 246, 246, 247, 247, 248, 248, 248, 248, 249, + 249, 250, 251, 252, 253, 254, 255, 260, 258, 198, + 199, 261, 291, 216, 199, 261, 290, 196, 303, 308, + 309, 197, 197, 226, 197, 219, 199, 196, 197, 197, + 201, 74, 258, 215, 261, 216, 199, 291, 216, 199, + 260, 217, 197, 293, 302, 295, 216, 294, 297, 298, + 258, 258, 199, 291, 216, 291, 197, 260, 297, 12, + 291, 291, 217, 293 }; #define yyerrok (yyerrstatus = 0) @@ -1955,18 +1978,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) @@ -2023,7 +2037,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, \ @@ -2565,7 +2579,7 @@ YYLTYPE yylloc; YYLTYPE *yylsp; /* The locations where the error started and ended. */ - YYLTYPE yyerror_range[3]; + YYLTYPE yyerror_range[2]; YYSIZE_T yystacksize; @@ -2612,7 +2626,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; @@ -2620,8 +2634,8 @@ YYLTYPE yylloc; /* User initialization code. */ -/* Line 1251 of yacc.c */ -#line 41 "glsl_parser.ypp" +/* Line 1242 of yacc.c */ +#line 41 "glsl_parser.yy" { yylloc.first_line = 1; yylloc.first_column = 1; @@ -2630,8 +2644,8 @@ YYLTYPE yylloc; yylloc.source = 0; } -/* Line 1251 of yacc.c */ -#line 2635 "glsl_parser.cpp" +/* Line 1242 of yacc.c */ +#line 2649 "glsl_parser.cpp" yylsp[0] = yylloc; goto yysetstate; @@ -2818,39 +2832,85 @@ yyreduce: { case 2: -/* Line 1464 of yacc.c */ -#line 212 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 218 "glsl_parser.yy" + { + _mesa_glsl_initialize_types(state); + ;} + break; + + case 3: + +/* Line 1455 of yacc.c */ +#line 222 "glsl_parser.yy" { + delete state->symbols; + state->symbols = new(ralloc_parent(state)) glsl_symbol_table; _mesa_glsl_initialize_types(state); ;} break; case 5: -/* Line 1464 of yacc.c */ -#line 221 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 232 "glsl_parser.yy" { + bool supported = false; + switch ((yyvsp[(2) - (3)].n)) { case 100: state->es_shader = true; + supported = state->Const.GLSL_100ES; + break; case 110: + supported = state->Const.GLSL_110; + break; case 120: + supported = state->Const.GLSL_120; + break; case 130: - /* FINISHME: Check against implementation support versions. */ - state->language_version = (yyvsp[(2) - (3)].n); + supported = state->Const.GLSL_130; break; default: - _mesa_glsl_error(& (yylsp[(2) - (3)]), state, "Shading language version" - "%u is not supported\n", (yyvsp[(2) - (3)].n)); + supported = false; break; } + + state->language_version = (yyvsp[(2) - (3)].n); + state->version_string = + ralloc_asprintf(state, "GLSL%s %d.%02d", + state->es_shader ? " ES" : "", + state->language_version / 100, + state->language_version % 100); + + if (!supported) { + _mesa_glsl_error(& (yylsp[(2) - (3)]), state, "%s is not supported. " + "Supported versions are: %s\n", + state->version_string, + state->supported_version_string); + } ;} break; - case 12: + case 10: -/* Line 1464 of yacc.c */ -#line 253 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 276 "glsl_parser.yy" + { + if (state->language_version < 120) { + _mesa_glsl_warning(& (yylsp[(1) - (2)]), state, + "pragma `invariant(all)' not supported in %s", + state->version_string); + } else { + state->all_invariant = true; + } + ;} + break; + + case 16: + +/* Line 1455 of yacc.c */ +#line 300 "glsl_parser.yy" { if (!_mesa_glsl_process_extension((yyvsp[(2) - (5)].identifier), & (yylsp[(2) - (5)]), (yyvsp[(4) - (5)].identifier), & (yylsp[(4) - (5)]), state)) { YYERROR; @@ -2858,36 +2918,36 @@ yyreduce: ;} break; - case 13: + case 17: -/* Line 1464 of yacc.c */ -#line 262 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 309 "glsl_parser.yy" { - /* FINISHME: The NULL test is only required because 'precision' - * FINISHME: statements are not yet supported. + /* FINISHME: The NULL test is required because pragmas are set to + * FINISHME: NULL. (See production rule for external_declaration.) */ if ((yyvsp[(1) - (1)].node) != NULL) state->translation_unit.push_tail(& (yyvsp[(1) - (1)].node)->link); ;} break; - case 14: + case 18: -/* Line 1464 of yacc.c */ -#line 270 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 317 "glsl_parser.yy" { - /* FINISHME: The NULL test is only required because 'precision' - * FINISHME: statements are not yet supported. + /* FINISHME: The NULL test is required because pragmas are set to + * FINISHME: NULL. (See production rule for external_declaration.) */ if ((yyvsp[(2) - (2)].node) != NULL) state->translation_unit.push_tail(& (yyvsp[(2) - (2)].node)->link); ;} break; - case 16: + case 21: -/* Line 1464 of yacc.c */ -#line 285 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 333 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_identifier, NULL, NULL, NULL); @@ -2896,10 +2956,10 @@ yyreduce: ;} break; - case 17: + case 22: -/* Line 1464 of yacc.c */ -#line 292 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 340 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_int_constant, NULL, NULL, NULL); @@ -2908,10 +2968,10 @@ yyreduce: ;} break; - case 18: + case 23: -/* Line 1464 of yacc.c */ -#line 299 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 347 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_uint_constant, NULL, NULL, NULL); @@ -2920,10 +2980,10 @@ yyreduce: ;} break; - case 19: + case 24: -/* Line 1464 of yacc.c */ -#line 306 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 354 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_float_constant, NULL, NULL, NULL); @@ -2932,10 +2992,10 @@ yyreduce: ;} break; - case 20: + case 25: -/* Line 1464 of yacc.c */ -#line 313 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 361 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_bool_constant, NULL, NULL, NULL); @@ -2944,19 +3004,19 @@ yyreduce: ;} break; - case 21: + case 26: -/* Line 1464 of yacc.c */ -#line 320 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 368 "glsl_parser.yy" { (yyval.expression) = (yyvsp[(2) - (3)].expression); ;} break; - case 23: + case 28: -/* Line 1464 of yacc.c */ -#line 328 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 376 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_array_index, (yyvsp[(1) - (4)].expression), (yyvsp[(3) - (4)].expression), NULL); @@ -2964,19 +3024,19 @@ yyreduce: ;} break; - case 24: + case 29: -/* Line 1464 of yacc.c */ -#line 334 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 382 "glsl_parser.yy" { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} break; - case 25: + case 30: -/* Line 1464 of yacc.c */ -#line 338 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 386 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_field_selection, (yyvsp[(1) - (3)].expression), NULL, NULL); @@ -2985,10 +3045,10 @@ yyreduce: ;} break; - case 26: + case 31: -/* Line 1464 of yacc.c */ -#line 345 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 393 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_post_inc, (yyvsp[(1) - (2)].expression), NULL, NULL); @@ -2996,10 +3056,10 @@ yyreduce: ;} break; - case 27: + case 32: -/* Line 1464 of yacc.c */ -#line 351 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 399 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_post_dec, (yyvsp[(1) - (2)].expression), NULL, NULL); @@ -3007,10 +3067,10 @@ yyreduce: ;} break; - case 31: + case 36: -/* Line 1464 of yacc.c */ -#line 369 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 417 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_field_selection, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression), NULL); @@ -3018,10 +3078,10 @@ yyreduce: ;} break; - case 36: + case 41: -/* Line 1464 of yacc.c */ -#line 388 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 436 "glsl_parser.yy" { (yyval.expression) = (yyvsp[(1) - (2)].expression); (yyval.expression)->set_location(yylloc); @@ -3029,10 +3089,10 @@ yyreduce: ;} break; - case 37: + case 42: -/* Line 1464 of yacc.c */ -#line 394 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 442 "glsl_parser.yy" { (yyval.expression) = (yyvsp[(1) - (3)].expression); (yyval.expression)->set_location(yylloc); @@ -3040,10 +3100,10 @@ yyreduce: ;} break; - case 39: + case 44: -/* Line 1464 of yacc.c */ -#line 410 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 458 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_function_expression((yyvsp[(1) - (1)].type_specifier)); @@ -3051,10 +3111,10 @@ yyreduce: ;} break; - case 40: + case 45: -/* Line 1464 of yacc.c */ -#line 416 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 464 "glsl_parser.yy" { void *ctx = state; ast_expression *callee = new(ctx) ast_expression((yyvsp[(1) - (1)].identifier)); @@ -3063,10 +3123,10 @@ yyreduce: ;} break; - case 41: + case 46: -/* Line 1464 of yacc.c */ -#line 423 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 471 "glsl_parser.yy" { void *ctx = state; ast_expression *callee = new(ctx) ast_expression((yyvsp[(1) - (1)].identifier)); @@ -3075,10 +3135,44 @@ yyreduce: ;} break; - case 43: + case 51: -/* Line 1464 of yacc.c */ -#line 435 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 491 "glsl_parser.yy" + { + (yyval.expression) = (yyvsp[(1) - (2)].expression); + (yyval.expression)->set_location(yylloc); + (yyval.expression)->expressions.push_tail(& (yyvsp[(2) - (2)].expression)->link); + ;} + break; + + case 52: + +/* Line 1455 of yacc.c */ +#line 497 "glsl_parser.yy" + { + (yyval.expression) = (yyvsp[(1) - (3)].expression); + (yyval.expression)->set_location(yylloc); + (yyval.expression)->expressions.push_tail(& (yyvsp[(3) - (3)].expression)->link); + ;} + break; + + case 53: + +/* Line 1455 of yacc.c */ +#line 509 "glsl_parser.yy" + { + void *ctx = state; + ast_expression *callee = new(ctx) ast_expression((yyvsp[(1) - (2)].identifier)); + (yyval.expression) = new(ctx) ast_function_expression(callee); + (yyval.expression)->set_location(yylloc); + ;} + break; + + case 55: + +/* Line 1455 of yacc.c */ +#line 521 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_pre_inc, (yyvsp[(2) - (2)].expression), NULL, NULL); @@ -3086,10 +3180,10 @@ yyreduce: ;} break; - case 44: + case 56: -/* Line 1464 of yacc.c */ -#line 441 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 527 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_pre_dec, (yyvsp[(2) - (2)].expression), NULL, NULL); @@ -3097,10 +3191,10 @@ yyreduce: ;} break; - case 45: + case 57: -/* Line 1464 of yacc.c */ -#line 447 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 533 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression((yyvsp[(1) - (2)].n), (yyvsp[(2) - (2)].expression), NULL, NULL); @@ -3108,38 +3202,38 @@ yyreduce: ;} break; - case 46: + case 58: -/* Line 1464 of yacc.c */ -#line 456 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 542 "glsl_parser.yy" { (yyval.n) = ast_plus; ;} break; - case 47: + case 59: -/* Line 1464 of yacc.c */ -#line 457 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 543 "glsl_parser.yy" { (yyval.n) = ast_neg; ;} break; - case 48: + case 60: -/* Line 1464 of yacc.c */ -#line 458 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 544 "glsl_parser.yy" { (yyval.n) = ast_logic_not; ;} break; - case 49: + case 61: -/* Line 1464 of yacc.c */ -#line 459 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 545 "glsl_parser.yy" { (yyval.n) = ast_bit_not; ;} break; - case 51: + case 63: -/* Line 1464 of yacc.c */ -#line 465 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 551 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_mul, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3147,10 +3241,10 @@ yyreduce: ;} break; - case 52: + case 64: -/* Line 1464 of yacc.c */ -#line 471 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 557 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_div, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3158,10 +3252,10 @@ yyreduce: ;} break; - case 53: + case 65: -/* Line 1464 of yacc.c */ -#line 477 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 563 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_mod, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3169,10 +3263,10 @@ yyreduce: ;} break; - case 55: + case 67: -/* Line 1464 of yacc.c */ -#line 487 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 573 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_add, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3180,10 +3274,10 @@ yyreduce: ;} break; - case 56: + case 68: -/* Line 1464 of yacc.c */ -#line 493 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 579 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_sub, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3191,10 +3285,10 @@ yyreduce: ;} break; - case 58: + case 70: -/* Line 1464 of yacc.c */ -#line 503 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 589 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_lshift, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3202,10 +3296,10 @@ yyreduce: ;} break; - case 59: + case 71: -/* Line 1464 of yacc.c */ -#line 509 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 595 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_rshift, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3213,10 +3307,10 @@ yyreduce: ;} break; - case 61: + case 73: -/* Line 1464 of yacc.c */ -#line 519 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 605 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_less, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3224,10 +3318,10 @@ yyreduce: ;} break; - case 62: + case 74: -/* Line 1464 of yacc.c */ -#line 525 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 611 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_greater, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3235,10 +3329,10 @@ yyreduce: ;} break; - case 63: + case 75: -/* Line 1464 of yacc.c */ -#line 531 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 617 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_lequal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3246,10 +3340,10 @@ yyreduce: ;} break; - case 64: + case 76: -/* Line 1464 of yacc.c */ -#line 537 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 623 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_gequal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3257,10 +3351,10 @@ yyreduce: ;} break; - case 66: + case 78: -/* Line 1464 of yacc.c */ -#line 547 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 633 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_equal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3268,10 +3362,10 @@ yyreduce: ;} break; - case 67: + case 79: -/* Line 1464 of yacc.c */ -#line 553 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 639 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_nequal, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3279,10 +3373,10 @@ yyreduce: ;} break; - case 69: + case 81: -/* Line 1464 of yacc.c */ -#line 563 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 649 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_bit_and, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3290,10 +3384,10 @@ yyreduce: ;} break; - case 71: + case 83: -/* Line 1464 of yacc.c */ -#line 573 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 659 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_bit_xor, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3301,10 +3395,10 @@ yyreduce: ;} break; - case 73: + case 85: -/* Line 1464 of yacc.c */ -#line 583 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 669 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_bit_or, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3312,10 +3406,10 @@ yyreduce: ;} break; - case 75: + case 87: -/* Line 1464 of yacc.c */ -#line 593 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 679 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_logic_and, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3323,10 +3417,10 @@ yyreduce: ;} break; - case 77: + case 89: -/* Line 1464 of yacc.c */ -#line 603 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 689 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_logic_xor, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3334,10 +3428,10 @@ yyreduce: ;} break; - case 79: + case 91: -/* Line 1464 of yacc.c */ -#line 613 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 699 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression_bin(ast_logic_or, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); @@ -3345,10 +3439,10 @@ yyreduce: ;} break; - case 81: + case 93: -/* Line 1464 of yacc.c */ -#line 623 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 709 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression(ast_conditional, (yyvsp[(1) - (5)].expression), (yyvsp[(3) - (5)].expression), (yyvsp[(5) - (5)].expression)); @@ -3356,10 +3450,10 @@ yyreduce: ;} break; - case 83: + case 95: -/* Line 1464 of yacc.c */ -#line 633 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 719 "glsl_parser.yy" { void *ctx = state; (yyval.expression) = new(ctx) ast_expression((yyvsp[(2) - (3)].n), (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression), NULL); @@ -3367,96 +3461,96 @@ yyreduce: ;} break; - case 84: + case 96: -/* Line 1464 of yacc.c */ -#line 641 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 727 "glsl_parser.yy" { (yyval.n) = ast_assign; ;} break; - case 85: + case 97: -/* Line 1464 of yacc.c */ -#line 642 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 728 "glsl_parser.yy" { (yyval.n) = ast_mul_assign; ;} break; - case 86: + case 98: -/* Line 1464 of yacc.c */ -#line 643 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 729 "glsl_parser.yy" { (yyval.n) = ast_div_assign; ;} break; - case 87: + case 99: -/* Line 1464 of yacc.c */ -#line 644 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 730 "glsl_parser.yy" { (yyval.n) = ast_mod_assign; ;} break; - case 88: + case 100: -/* Line 1464 of yacc.c */ -#line 645 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 731 "glsl_parser.yy" { (yyval.n) = ast_add_assign; ;} break; - case 89: + case 101: -/* Line 1464 of yacc.c */ -#line 646 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 732 "glsl_parser.yy" { (yyval.n) = ast_sub_assign; ;} break; - case 90: + case 102: -/* Line 1464 of yacc.c */ -#line 647 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 733 "glsl_parser.yy" { (yyval.n) = ast_ls_assign; ;} break; - case 91: + case 103: -/* Line 1464 of yacc.c */ -#line 648 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 734 "glsl_parser.yy" { (yyval.n) = ast_rs_assign; ;} break; - case 92: + case 104: -/* Line 1464 of yacc.c */ -#line 649 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 735 "glsl_parser.yy" { (yyval.n) = ast_and_assign; ;} break; - case 93: + case 105: -/* Line 1464 of yacc.c */ -#line 650 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 736 "glsl_parser.yy" { (yyval.n) = ast_xor_assign; ;} break; - case 94: + case 106: -/* Line 1464 of yacc.c */ -#line 651 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 737 "glsl_parser.yy" { (yyval.n) = ast_or_assign; ;} break; - case 95: + case 107: -/* Line 1464 of yacc.c */ -#line 656 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 742 "glsl_parser.yy" { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} break; - case 96: + case 108: -/* Line 1464 of yacc.c */ -#line 660 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 746 "glsl_parser.yy" { void *ctx = state; if ((yyvsp[(1) - (3)].expression)->oper != ast_sequence) { @@ -3471,77 +3565,76 @@ yyreduce: ;} break; - case 98: + case 110: -/* Line 1464 of yacc.c */ -#line 680 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 766 "glsl_parser.yy" { + state->symbols->pop_scope(); (yyval.node) = (yyvsp[(1) - (2)].function); ;} break; - case 99: + case 111: -/* Line 1464 of yacc.c */ -#line 684 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 771 "glsl_parser.yy" { (yyval.node) = (yyvsp[(1) - (2)].declarator_list); ;} break; - case 100: + case 112: -/* Line 1464 of yacc.c */ -#line 688 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 775 "glsl_parser.yy" { - if (((yyvsp[(3) - (4)].type_specifier)->type_specifier != ast_float) - && ((yyvsp[(3) - (4)].type_specifier)->type_specifier != ast_int)) { - _mesa_glsl_error(& (yylsp[(3) - (4)]), state, "global precision qualifier can " - "only be applied to `int' or `float'\n"); - YYERROR; - } - - (yyval.node) = NULL; /* FINISHME */ + (yyvsp[(3) - (4)].type_specifier)->precision = (yyvsp[(2) - (4)].n); + (yyvsp[(3) - (4)].type_specifier)->is_precision_statement = true; + (yyval.node) = (yyvsp[(3) - (4)].type_specifier); ;} break; - case 104: + case 116: -/* Line 1464 of yacc.c */ -#line 711 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 793 "glsl_parser.yy" { (yyval.function) = (yyvsp[(1) - (2)].function); (yyval.function)->parameters.push_tail(& (yyvsp[(2) - (2)].parameter_declarator)->link); ;} break; - case 105: + case 117: -/* Line 1464 of yacc.c */ -#line 716 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 798 "glsl_parser.yy" { (yyval.function) = (yyvsp[(1) - (3)].function); (yyval.function)->parameters.push_tail(& (yyvsp[(3) - (3)].parameter_declarator)->link); ;} break; - case 106: + case 118: -/* Line 1464 of yacc.c */ -#line 724 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 806 "glsl_parser.yy" { void *ctx = state; (yyval.function) = new(ctx) ast_function(); (yyval.function)->set_location(yylloc); (yyval.function)->return_type = (yyvsp[(1) - (3)].fully_specified_type); (yyval.function)->identifier = (yyvsp[(2) - (3)].identifier); + + state->symbols->add_function(new(state) ir_function((yyvsp[(2) - (3)].identifier))); + state->symbols->push_scope(); ;} break; - case 107: + case 119: -/* Line 1464 of yacc.c */ -#line 735 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 820 "glsl_parser.yy" { void *ctx = state; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); @@ -3553,10 +3646,10 @@ yyreduce: ;} break; - case 108: + case 120: -/* Line 1464 of yacc.c */ -#line 745 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 830 "glsl_parser.yy" { void *ctx = state; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); @@ -3570,10 +3663,10 @@ yyreduce: ;} break; - case 109: + case 121: -/* Line 1464 of yacc.c */ -#line 760 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 845 "glsl_parser.yy" { (yyvsp[(1) - (3)].type_qualifier).flags.i |= (yyvsp[(2) - (3)].type_qualifier).flags.i; @@ -3582,20 +3675,20 @@ yyreduce: ;} break; - case 110: + case 122: -/* Line 1464 of yacc.c */ -#line 767 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 852 "glsl_parser.yy" { (yyval.parameter_declarator) = (yyvsp[(2) - (2)].parameter_declarator); (yyval.parameter_declarator)->type->qualifier = (yyvsp[(1) - (2)].type_qualifier); ;} break; - case 111: + case 123: -/* Line 1464 of yacc.c */ -#line 772 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 857 "glsl_parser.yy" { void *ctx = state; (yyvsp[(1) - (3)].type_qualifier).flags.i |= (yyvsp[(2) - (3)].type_qualifier).flags.i; @@ -3608,10 +3701,10 @@ yyreduce: ;} break; - case 112: + case 124: -/* Line 1464 of yacc.c */ -#line 783 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 868 "glsl_parser.yy" { void *ctx = state; (yyval.parameter_declarator) = new(ctx) ast_parameter_declarator(); @@ -3622,39 +3715,39 @@ yyreduce: ;} break; - case 113: + case 125: -/* Line 1464 of yacc.c */ -#line 795 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 880 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); ;} break; - case 114: + case 126: -/* Line 1464 of yacc.c */ -#line 799 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 884 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.in = 1; ;} break; - case 115: + case 127: -/* Line 1464 of yacc.c */ -#line 804 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 889 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.out = 1; ;} break; - case 116: + case 128: -/* Line 1464 of yacc.c */ -#line 809 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 894 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.in = 1; @@ -3662,10 +3755,10 @@ yyreduce: ;} break; - case 119: + case 131: -/* Line 1464 of yacc.c */ -#line 823 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 908 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (3)].identifier), false, NULL, NULL); @@ -3673,13 +3766,14 @@ yyreduce: (yyval.declarator_list) = (yyvsp[(1) - (3)].declarator_list); (yyval.declarator_list)->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(3) - (3)].identifier), ir_var_auto)); ;} break; - case 120: + case 132: -/* Line 1464 of yacc.c */ -#line 832 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 918 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (5)].identifier), true, NULL, NULL); @@ -3687,13 +3781,14 @@ yyreduce: (yyval.declarator_list) = (yyvsp[(1) - (5)].declarator_list); (yyval.declarator_list)->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(3) - (5)].identifier), ir_var_auto)); ;} break; - case 121: + case 133: -/* Line 1464 of yacc.c */ -#line 841 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 928 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (6)].identifier), true, (yyvsp[(5) - (6)].expression), NULL); @@ -3701,13 +3796,14 @@ yyreduce: (yyval.declarator_list) = (yyvsp[(1) - (6)].declarator_list); (yyval.declarator_list)->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(3) - (6)].identifier), ir_var_auto)); ;} break; - case 122: + case 134: -/* Line 1464 of yacc.c */ -#line 850 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 938 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (7)].identifier), true, NULL, (yyvsp[(7) - (7)].expression)); @@ -3715,13 +3811,14 @@ yyreduce: (yyval.declarator_list) = (yyvsp[(1) - (7)].declarator_list); (yyval.declarator_list)->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(3) - (7)].identifier), ir_var_auto)); ;} break; - case 123: + case 135: -/* Line 1464 of yacc.c */ -#line 859 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 948 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (8)].identifier), true, (yyvsp[(5) - (8)].expression), (yyvsp[(8) - (8)].expression)); @@ -3729,13 +3826,14 @@ yyreduce: (yyval.declarator_list) = (yyvsp[(1) - (8)].declarator_list); (yyval.declarator_list)->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(3) - (8)].identifier), ir_var_auto)); ;} break; - case 124: + case 136: -/* Line 1464 of yacc.c */ -#line 868 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 958 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(3) - (5)].identifier), false, NULL, (yyvsp[(5) - (5)].expression)); @@ -3743,13 +3841,14 @@ yyreduce: (yyval.declarator_list) = (yyvsp[(1) - (5)].declarator_list); (yyval.declarator_list)->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(3) - (5)].identifier), ir_var_auto)); ;} break; - case 125: + case 137: -/* Line 1464 of yacc.c */ -#line 881 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 972 "glsl_parser.yy" { void *ctx = state; if ((yyvsp[(1) - (1)].fully_specified_type)->specifier->type_specifier != ast_struct) { @@ -3762,10 +3861,10 @@ yyreduce: ;} break; - case 126: + case 138: -/* Line 1464 of yacc.c */ -#line 892 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 983 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (2)].identifier), false, NULL, NULL); @@ -3776,10 +3875,10 @@ yyreduce: ;} break; - case 127: + case 139: -/* Line 1464 of yacc.c */ -#line 901 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 992 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (4)].identifier), true, NULL, NULL); @@ -3790,10 +3889,10 @@ yyreduce: ;} break; - case 128: + case 140: -/* Line 1464 of yacc.c */ -#line 910 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1001 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (5)].identifier), true, (yyvsp[(4) - (5)].expression), NULL); @@ -3804,10 +3903,10 @@ yyreduce: ;} break; - case 129: + case 141: -/* Line 1464 of yacc.c */ -#line 919 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1010 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (6)].identifier), true, NULL, (yyvsp[(6) - (6)].expression)); @@ -3818,10 +3917,10 @@ yyreduce: ;} break; - case 130: + case 142: -/* Line 1464 of yacc.c */ -#line 928 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1019 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (7)].identifier), true, (yyvsp[(4) - (7)].expression), (yyvsp[(7) - (7)].expression)); @@ -3832,10 +3931,10 @@ yyreduce: ;} break; - case 131: + case 143: -/* Line 1464 of yacc.c */ -#line 937 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1028 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (4)].identifier), false, NULL, (yyvsp[(4) - (4)].expression)); @@ -3846,10 +3945,10 @@ yyreduce: ;} break; - case 132: + case 144: -/* Line 1464 of yacc.c */ -#line 946 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1037 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (2)].identifier), false, NULL, NULL); @@ -3862,10 +3961,10 @@ yyreduce: ;} break; - case 133: + case 145: -/* Line 1464 of yacc.c */ -#line 960 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1051 "glsl_parser.yy" { void *ctx = state; (yyval.fully_specified_type) = new(ctx) ast_fully_specified_type(); @@ -3874,10 +3973,10 @@ yyreduce: ;} break; - case 134: + case 146: -/* Line 1464 of yacc.c */ -#line 967 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1058 "glsl_parser.yy" { void *ctx = state; (yyval.fully_specified_type) = new(ctx) ast_fully_specified_type(); @@ -3887,19 +3986,19 @@ yyreduce: ;} break; - case 135: + case 147: -/* Line 1464 of yacc.c */ -#line 978 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1069 "glsl_parser.yy" { (yyval.type_qualifier) = (yyvsp[(3) - (4)].type_qualifier); ;} break; - case 137: + case 149: -/* Line 1464 of yacc.c */ -#line 986 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1077 "glsl_parser.yy" { if (((yyvsp[(1) - (3)].type_qualifier).flags.i & (yyvsp[(3) - (3)].type_qualifier).flags.i) != 0) { _mesa_glsl_error(& (yylsp[(3) - (3)]), state, @@ -3917,16 +4016,17 @@ yyreduce: ;} break; - case 138: + case 150: -/* Line 1464 of yacc.c */ -#line 1005 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1096 "glsl_parser.yy" { bool got_one = false; memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); - if (state->ARB_fragment_coord_conventions_enable) { + /* Layout qualifiers for ARB_fragment_coord_conventions. */ + if (!got_one && state->ARB_fragment_coord_conventions_enable) { if (strcmp((yyvsp[(1) - (1)].identifier), "origin_upper_left") == 0) { got_one = true; (yyval.type_qualifier).flags.q.origin_upper_left = 1; @@ -3934,27 +4034,49 @@ yyreduce: got_one = true; (yyval.type_qualifier).flags.q.pixel_center_integer = 1; } + + if (got_one && 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)); + } + } + + /* Layout qualifiers for AMD_conservative_depth. */ + if (!got_one && state->AMD_conservative_depth_enable) { + if (strcmp((yyvsp[(1) - (1)].identifier), "depth_any") == 0) { + got_one = true; + (yyval.type_qualifier).flags.q.depth_any = 1; + } else if (strcmp((yyvsp[(1) - (1)].identifier), "depth_greater") == 0) { + got_one = true; + (yyval.type_qualifier).flags.q.depth_greater = 1; + } else if (strcmp((yyvsp[(1) - (1)].identifier), "depth_less") == 0) { + got_one = true; + (yyval.type_qualifier).flags.q.depth_less = 1; + } else if (strcmp((yyvsp[(1) - (1)].identifier), "depth_unchanged") == 0) { + got_one = true; + (yyval.type_qualifier).flags.q.depth_unchanged = 1; + } + + if (got_one && state->AMD_conservative_depth_warn) { + _mesa_glsl_warning(& (yylsp[(1) - (1)]), state, + "GL_AMD_conservative_depth " + "layout qualifier `%s' is used\n", (yyvsp[(1) - (1)].identifier)); + } } - /* If the identifier didn't match any known layout identifiers, - * emit an error. - */ 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 139: + case 151: -/* Line 1464 of yacc.c */ -#line 1034 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1148 "glsl_parser.yy" { bool got_one = false; @@ -3994,80 +4116,80 @@ yyreduce: ;} break; - case 140: + case 152: -/* Line 1464 of yacc.c */ -#line 1075 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1189 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.smooth = 1; ;} break; - case 141: + case 153: -/* Line 1464 of yacc.c */ -#line 1080 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1194 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.flat = 1; ;} break; - case 142: + case 154: -/* Line 1464 of yacc.c */ -#line 1085 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1199 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.noperspective = 1; ;} break; - case 143: + case 155: -/* Line 1464 of yacc.c */ -#line 1093 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1207 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.constant = 1; ;} break; - case 146: + case 158: -/* Line 1464 of yacc.c */ -#line 1103 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1217 "glsl_parser.yy" { (yyval.type_qualifier) = (yyvsp[(1) - (2)].type_qualifier); (yyval.type_qualifier).flags.i |= (yyvsp[(2) - (2)].type_qualifier).flags.i; ;} break; - case 148: + case 160: -/* Line 1464 of yacc.c */ -#line 1109 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1223 "glsl_parser.yy" { (yyval.type_qualifier) = (yyvsp[(1) - (2)].type_qualifier); (yyval.type_qualifier).flags.i |= (yyvsp[(2) - (2)].type_qualifier).flags.i; ;} break; - case 149: + case 161: -/* Line 1464 of yacc.c */ -#line 1114 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1228 "glsl_parser.yy" { (yyval.type_qualifier) = (yyvsp[(2) - (2)].type_qualifier); (yyval.type_qualifier).flags.q.invariant = 1; ;} break; - case 150: + case 162: -/* Line 1464 of yacc.c */ -#line 1119 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1233 "glsl_parser.yy" { (yyval.type_qualifier) = (yyvsp[(2) - (3)].type_qualifier); (yyval.type_qualifier).flags.i |= (yyvsp[(3) - (3)].type_qualifier).flags.i; @@ -4075,50 +4197,50 @@ yyreduce: ;} break; - case 151: + case 163: -/* Line 1464 of yacc.c */ -#line 1125 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1239 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.invariant = 1; ;} break; - case 152: + case 164: -/* Line 1464 of yacc.c */ -#line 1133 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1247 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.constant = 1; ;} break; - case 153: + case 165: -/* Line 1464 of yacc.c */ -#line 1138 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1252 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.attribute = 1; ;} break; - case 154: + case 166: -/* Line 1464 of yacc.c */ -#line 1143 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1257 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.varying = 1; ;} break; - case 155: + case 167: -/* Line 1464 of yacc.c */ -#line 1148 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1262 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.centroid = 1; @@ -4126,70 +4248,79 @@ yyreduce: ;} break; - case 156: + case 168: -/* Line 1464 of yacc.c */ -#line 1154 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1268 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.in = 1; ;} break; - case 157: + case 169: -/* Line 1464 of yacc.c */ -#line 1159 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1273 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.out = 1; ;} break; - case 158: + case 170: -/* Line 1464 of yacc.c */ -#line 1164 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1278 "glsl_parser.yy" { 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: + case 171: -/* Line 1464 of yacc.c */ -#line 1169 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1283 "glsl_parser.yy" { 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: + case 172: -/* Line 1464 of yacc.c */ -#line 1174 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1288 "glsl_parser.yy" { memset(& (yyval.type_qualifier), 0, sizeof((yyval.type_qualifier))); (yyval.type_qualifier).flags.q.uniform = 1; ;} break; - case 162: + case 173: -/* Line 1464 of yacc.c */ -#line 1183 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1296 "glsl_parser.yy" + { + (yyval.type_specifier) = (yyvsp[(1) - (1)].type_specifier); + ;} + break; + + case 174: + +/* Line 1455 of yacc.c */ +#line 1300 "glsl_parser.yy" { (yyval.type_specifier) = (yyvsp[(2) - (2)].type_specifier); (yyval.type_specifier)->precision = (yyvsp[(1) - (2)].n); ;} break; - case 164: + case 176: -/* Line 1464 of yacc.c */ -#line 1192 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1309 "glsl_parser.yy" { (yyval.type_specifier) = (yyvsp[(1) - (3)].type_specifier); (yyval.type_specifier)->is_array = true; @@ -4197,10 +4328,10 @@ yyreduce: ;} break; - case 165: + case 177: -/* Line 1464 of yacc.c */ -#line 1198 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1315 "glsl_parser.yy" { (yyval.type_specifier) = (yyvsp[(1) - (4)].type_specifier); (yyval.type_specifier)->is_array = true; @@ -4208,10 +4339,10 @@ yyreduce: ;} break; - case 166: + case 178: -/* Line 1464 of yacc.c */ -#line 1207 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1324 "glsl_parser.yy" { void *ctx = state; (yyval.type_specifier) = new(ctx) ast_type_specifier((yyvsp[(1) - (1)].n)); @@ -4219,10 +4350,10 @@ yyreduce: ;} break; - case 167: + case 179: -/* Line 1464 of yacc.c */ -#line 1213 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1330 "glsl_parser.yy" { void *ctx = state; (yyval.type_specifier) = new(ctx) ast_type_specifier((yyvsp[(1) - (1)].struct_specifier)); @@ -4230,10 +4361,10 @@ yyreduce: ;} break; - case 168: + case 180: -/* Line 1464 of yacc.c */ -#line 1219 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1336 "glsl_parser.yy" { void *ctx = state; (yyval.type_specifier) = new(ctx) ast_type_specifier((yyvsp[(1) - (1)].identifier)); @@ -4241,429 +4372,427 @@ yyreduce: ;} break; - case 169: + case 181: -/* Line 1464 of yacc.c */ -#line 1227 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1344 "glsl_parser.yy" { (yyval.n) = ast_void; ;} break; - case 170: + case 182: -/* Line 1464 of yacc.c */ -#line 1228 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1345 "glsl_parser.yy" { (yyval.n) = ast_float; ;} break; - case 171: + case 183: -/* Line 1464 of yacc.c */ -#line 1229 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1346 "glsl_parser.yy" { (yyval.n) = ast_int; ;} break; - case 172: + case 184: -/* Line 1464 of yacc.c */ -#line 1230 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1347 "glsl_parser.yy" { (yyval.n) = ast_uint; ;} break; - case 173: + case 185: -/* Line 1464 of yacc.c */ -#line 1231 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1348 "glsl_parser.yy" { (yyval.n) = ast_bool; ;} break; - case 174: + case 186: -/* Line 1464 of yacc.c */ -#line 1232 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1349 "glsl_parser.yy" { (yyval.n) = ast_vec2; ;} break; - case 175: + case 187: -/* Line 1464 of yacc.c */ -#line 1233 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1350 "glsl_parser.yy" { (yyval.n) = ast_vec3; ;} break; - case 176: + case 188: -/* Line 1464 of yacc.c */ -#line 1234 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1351 "glsl_parser.yy" { (yyval.n) = ast_vec4; ;} break; - case 177: + case 189: -/* Line 1464 of yacc.c */ -#line 1235 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1352 "glsl_parser.yy" { (yyval.n) = ast_bvec2; ;} break; - case 178: + case 190: -/* Line 1464 of yacc.c */ -#line 1236 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1353 "glsl_parser.yy" { (yyval.n) = ast_bvec3; ;} break; - case 179: + case 191: -/* Line 1464 of yacc.c */ -#line 1237 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1354 "glsl_parser.yy" { (yyval.n) = ast_bvec4; ;} break; - case 180: + case 192: -/* Line 1464 of yacc.c */ -#line 1238 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1355 "glsl_parser.yy" { (yyval.n) = ast_ivec2; ;} break; - case 181: + case 193: -/* Line 1464 of yacc.c */ -#line 1239 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1356 "glsl_parser.yy" { (yyval.n) = ast_ivec3; ;} break; - case 182: + case 194: -/* Line 1464 of yacc.c */ -#line 1240 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1357 "glsl_parser.yy" { (yyval.n) = ast_ivec4; ;} break; - case 183: + case 195: -/* Line 1464 of yacc.c */ -#line 1241 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1358 "glsl_parser.yy" { (yyval.n) = ast_uvec2; ;} break; - case 184: + case 196: -/* Line 1464 of yacc.c */ -#line 1242 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1359 "glsl_parser.yy" { (yyval.n) = ast_uvec3; ;} break; - case 185: + case 197: -/* Line 1464 of yacc.c */ -#line 1243 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1360 "glsl_parser.yy" { (yyval.n) = ast_uvec4; ;} break; - case 186: + case 198: -/* Line 1464 of yacc.c */ -#line 1244 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1361 "glsl_parser.yy" { (yyval.n) = ast_mat2; ;} break; - case 187: + case 199: -/* Line 1464 of yacc.c */ -#line 1245 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1362 "glsl_parser.yy" { (yyval.n) = ast_mat2x3; ;} break; - case 188: + case 200: -/* Line 1464 of yacc.c */ -#line 1246 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1363 "glsl_parser.yy" { (yyval.n) = ast_mat2x4; ;} break; - case 189: + case 201: -/* Line 1464 of yacc.c */ -#line 1247 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1364 "glsl_parser.yy" { (yyval.n) = ast_mat3x2; ;} break; - case 190: + case 202: -/* Line 1464 of yacc.c */ -#line 1248 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1365 "glsl_parser.yy" { (yyval.n) = ast_mat3; ;} break; - case 191: + case 203: -/* Line 1464 of yacc.c */ -#line 1249 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1366 "glsl_parser.yy" { (yyval.n) = ast_mat3x4; ;} break; - case 192: + case 204: -/* Line 1464 of yacc.c */ -#line 1250 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1367 "glsl_parser.yy" { (yyval.n) = ast_mat4x2; ;} break; - case 193: + case 205: -/* Line 1464 of yacc.c */ -#line 1251 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1368 "glsl_parser.yy" { (yyval.n) = ast_mat4x3; ;} break; - case 194: + case 206: -/* Line 1464 of yacc.c */ -#line 1252 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1369 "glsl_parser.yy" { (yyval.n) = ast_mat4; ;} break; - case 195: + case 207: -/* Line 1464 of yacc.c */ -#line 1253 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1370 "glsl_parser.yy" { (yyval.n) = ast_sampler1d; ;} break; - case 196: + case 208: -/* Line 1464 of yacc.c */ -#line 1254 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1371 "glsl_parser.yy" { (yyval.n) = ast_sampler2d; ;} break; - case 197: + case 209: -/* Line 1464 of yacc.c */ -#line 1255 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1372 "glsl_parser.yy" { (yyval.n) = ast_sampler2drect; ;} break; - case 198: + case 210: -/* Line 1464 of yacc.c */ -#line 1256 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1373 "glsl_parser.yy" { (yyval.n) = ast_sampler3d; ;} break; - case 199: + case 211: -/* Line 1464 of yacc.c */ -#line 1257 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1374 "glsl_parser.yy" { (yyval.n) = ast_samplercube; ;} break; - case 200: + case 212: -/* Line 1464 of yacc.c */ -#line 1258 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1375 "glsl_parser.yy" { (yyval.n) = ast_sampler1dshadow; ;} break; - case 201: + case 213: -/* Line 1464 of yacc.c */ -#line 1259 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1376 "glsl_parser.yy" { (yyval.n) = ast_sampler2dshadow; ;} break; - case 202: + case 214: -/* Line 1464 of yacc.c */ -#line 1260 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1377 "glsl_parser.yy" { (yyval.n) = ast_sampler2drectshadow; ;} break; - case 203: + case 215: -/* Line 1464 of yacc.c */ -#line 1261 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1378 "glsl_parser.yy" { (yyval.n) = ast_samplercubeshadow; ;} break; - case 204: + case 216: -/* Line 1464 of yacc.c */ -#line 1262 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1379 "glsl_parser.yy" { (yyval.n) = ast_sampler1darray; ;} break; - case 205: + case 217: -/* Line 1464 of yacc.c */ -#line 1263 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1380 "glsl_parser.yy" { (yyval.n) = ast_sampler2darray; ;} break; - case 206: + case 218: -/* Line 1464 of yacc.c */ -#line 1264 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1381 "glsl_parser.yy" { (yyval.n) = ast_sampler1darrayshadow; ;} break; - case 207: + case 219: -/* Line 1464 of yacc.c */ -#line 1265 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1382 "glsl_parser.yy" { (yyval.n) = ast_sampler2darrayshadow; ;} break; - case 208: + case 220: -/* Line 1464 of yacc.c */ -#line 1266 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1383 "glsl_parser.yy" { (yyval.n) = ast_isampler1d; ;} break; - case 209: + case 221: -/* Line 1464 of yacc.c */ -#line 1267 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1384 "glsl_parser.yy" { (yyval.n) = ast_isampler2d; ;} break; - case 210: + case 222: -/* Line 1464 of yacc.c */ -#line 1268 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1385 "glsl_parser.yy" { (yyval.n) = ast_isampler3d; ;} break; - case 211: + case 223: -/* Line 1464 of yacc.c */ -#line 1269 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1386 "glsl_parser.yy" { (yyval.n) = ast_isamplercube; ;} break; - case 212: + case 224: -/* Line 1464 of yacc.c */ -#line 1270 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1387 "glsl_parser.yy" { (yyval.n) = ast_isampler1darray; ;} break; - case 213: + case 225: -/* Line 1464 of yacc.c */ -#line 1271 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1388 "glsl_parser.yy" { (yyval.n) = ast_isampler2darray; ;} break; - case 214: + case 226: -/* Line 1464 of yacc.c */ -#line 1272 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1389 "glsl_parser.yy" { (yyval.n) = ast_usampler1d; ;} break; - case 215: + case 227: -/* Line 1464 of yacc.c */ -#line 1273 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1390 "glsl_parser.yy" { (yyval.n) = ast_usampler2d; ;} break; - case 216: + case 228: -/* Line 1464 of yacc.c */ -#line 1274 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1391 "glsl_parser.yy" { (yyval.n) = ast_usampler3d; ;} break; - case 217: + case 229: -/* Line 1464 of yacc.c */ -#line 1275 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1392 "glsl_parser.yy" { (yyval.n) = ast_usamplercube; ;} break; - case 218: + case 230: -/* Line 1464 of yacc.c */ -#line 1276 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1393 "glsl_parser.yy" { (yyval.n) = ast_usampler1darray; ;} break; - case 219: + case 231: -/* Line 1464 of yacc.c */ -#line 1277 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1394 "glsl_parser.yy" { (yyval.n) = ast_usampler2darray; ;} break; - case 220: + case 232: -/* Line 1464 of yacc.c */ -#line 1281 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1398 "glsl_parser.yy" { if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& (yylsp[(1) - (1)]), state, "precision qualifier forbidden " - "in GLSL %d.%d (1.30 or later " + "in %s (1.30 or later " "required)\n", - state->language_version / 100, - state->language_version % 100); + state->version_string); (yyval.n) = ast_precision_high; ;} break; - case 221: + case 233: -/* Line 1464 of yacc.c */ -#line 1292 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1408 "glsl_parser.yy" { if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& (yylsp[(1) - (1)]), state, "precision qualifier forbidden " - "in GLSL %d.%d (1.30 or later " + "in %s (1.30 or later " "required)\n", - state->language_version / 100, - state->language_version % 100); + state->version_string); (yyval.n) = ast_precision_medium; ;} break; - case 222: + case 234: -/* Line 1464 of yacc.c */ -#line 1303 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1418 "glsl_parser.yy" { if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& (yylsp[(1) - (1)]), state, "precision qualifier forbidden " - "in GLSL %d.%d (1.30 or later " + "in %s (1.30 or later " "required)\n", - state->language_version / 100, - state->language_version % 100); + state->version_string); (yyval.n) = ast_precision_low; ;} break; - case 223: + case 235: -/* Line 1464 of yacc.c */ -#line 1318 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1432 "glsl_parser.yy" { void *ctx = state; (yyval.struct_specifier) = new(ctx) ast_struct_specifier((yyvsp[(2) - (5)].identifier), (yyvsp[(4) - (5)].node)); (yyval.struct_specifier)->set_location(yylloc); + state->symbols->add_type((yyvsp[(2) - (5)].identifier), glsl_type::void_type); ;} break; - case 224: + case 236: -/* Line 1464 of yacc.c */ -#line 1324 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1439 "glsl_parser.yy" { void *ctx = state; (yyval.struct_specifier) = new(ctx) ast_struct_specifier(NULL, (yyvsp[(3) - (4)].node)); @@ -4671,30 +4800,30 @@ yyreduce: ;} break; - case 225: + case 237: -/* Line 1464 of yacc.c */ -#line 1333 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1448 "glsl_parser.yy" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].declarator_list); (yyvsp[(1) - (1)].declarator_list)->link.self_link(); ;} break; - case 226: + case 238: -/* Line 1464 of yacc.c */ -#line 1338 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1453 "glsl_parser.yy" { (yyval.node) = (ast_node *) (yyvsp[(1) - (2)].node); (yyval.node)->link.insert_before(& (yyvsp[(2) - (2)].declarator_list)->link); ;} break; - case 227: + case 239: -/* Line 1464 of yacc.c */ -#line 1346 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1461 "glsl_parser.yy" { void *ctx = state; ast_fully_specified_type *type = new(ctx) ast_fully_specified_type(); @@ -4708,41 +4837,42 @@ yyreduce: ;} break; - case 228: + case 240: -/* Line 1464 of yacc.c */ -#line 1361 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1476 "glsl_parser.yy" { (yyval.declaration) = (yyvsp[(1) - (1)].declaration); (yyvsp[(1) - (1)].declaration)->link.self_link(); ;} break; - case 229: + case 241: -/* Line 1464 of yacc.c */ -#line 1366 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1481 "glsl_parser.yy" { (yyval.declaration) = (yyvsp[(1) - (3)].declaration); (yyval.declaration)->link.insert_before(& (yyvsp[(3) - (3)].declaration)->link); ;} break; - case 230: + case 242: -/* Line 1464 of yacc.c */ -#line 1374 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1489 "glsl_parser.yy" { void *ctx = state; (yyval.declaration) = new(ctx) ast_declaration((yyvsp[(1) - (1)].identifier), false, NULL, NULL); (yyval.declaration)->set_location(yylloc); + state->symbols->add_variable(new(state) ir_variable(NULL, (yyvsp[(1) - (1)].identifier), ir_var_auto)); ;} break; - case 231: + case 243: -/* Line 1464 of yacc.c */ -#line 1380 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1496 "glsl_parser.yy" { void *ctx = state; (yyval.declaration) = new(ctx) ast_declaration((yyvsp[(1) - (4)].identifier), true, (yyvsp[(3) - (4)].expression), NULL); @@ -4750,31 +4880,31 @@ yyreduce: ;} break; - case 234: + case 246: -/* Line 1464 of yacc.c */ -#line 1398 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1514 "glsl_parser.yy" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].compound_statement); ;} break; - case 239: + case 251: -/* Line 1464 of yacc.c */ -#line 1406 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1522 "glsl_parser.yy" { (yyval.node) = NULL; ;} break; - case 240: + case 252: -/* Line 1464 of yacc.c */ -#line 1407 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1523 "glsl_parser.yy" { (yyval.node) = NULL; ;} break; - case 243: + case 255: -/* Line 1464 of yacc.c */ -#line 1414 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1530 "glsl_parser.yy" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(true, NULL); @@ -4782,28 +4912,38 @@ yyreduce: ;} break; - case 244: + case 256: -/* Line 1464 of yacc.c */ -#line 1420 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1536 "glsl_parser.yy" + { + state->symbols->push_scope(); + ;} + break; + + case 257: + +/* Line 1455 of yacc.c */ +#line 1540 "glsl_parser.yy" { void *ctx = state; - (yyval.compound_statement) = new(ctx) ast_compound_statement(true, (yyvsp[(2) - (3)].node)); + (yyval.compound_statement) = new(ctx) ast_compound_statement(true, (yyvsp[(3) - (4)].node)); (yyval.compound_statement)->set_location(yylloc); + state->symbols->pop_scope(); ;} break; - case 245: + case 258: -/* Line 1464 of yacc.c */ -#line 1428 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1549 "glsl_parser.yy" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].compound_statement); ;} break; - case 247: + case 260: -/* Line 1464 of yacc.c */ -#line 1434 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1555 "glsl_parser.yy" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(false, NULL); @@ -4811,10 +4951,10 @@ yyreduce: ;} break; - case 248: + case 261: -/* Line 1464 of yacc.c */ -#line 1440 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1561 "glsl_parser.yy" { void *ctx = state; (yyval.compound_statement) = new(ctx) ast_compound_statement(false, (yyvsp[(2) - (3)].node)); @@ -4822,10 +4962,10 @@ yyreduce: ;} break; - case 249: + case 262: -/* Line 1464 of yacc.c */ -#line 1449 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1570 "glsl_parser.yy" { if ((yyvsp[(1) - (1)].node) == NULL) { _mesa_glsl_error(& (yylsp[(1) - (1)]), state, "<nil> statement\n"); @@ -4837,10 +4977,10 @@ yyreduce: ;} break; - case 250: + case 263: -/* Line 1464 of yacc.c */ -#line 1459 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1580 "glsl_parser.yy" { if ((yyvsp[(2) - (2)].node) == NULL) { _mesa_glsl_error(& (yylsp[(2) - (2)]), state, "<nil> statement\n"); @@ -4851,10 +4991,10 @@ yyreduce: ;} break; - case 251: + case 264: -/* Line 1464 of yacc.c */ -#line 1471 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1592 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_expression_statement(NULL); @@ -4862,10 +5002,10 @@ yyreduce: ;} break; - case 252: + case 265: -/* Line 1464 of yacc.c */ -#line 1477 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1598 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_expression_statement((yyvsp[(1) - (2)].expression)); @@ -4873,10 +5013,10 @@ yyreduce: ;} break; - case 253: + case 266: -/* Line 1464 of yacc.c */ -#line 1486 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1607 "glsl_parser.yy" { (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); @@ -4884,39 +5024,39 @@ yyreduce: ;} break; - case 254: + case 267: -/* Line 1464 of yacc.c */ -#line 1495 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1616 "glsl_parser.yy" { (yyval.selection_rest_statement).then_statement = (yyvsp[(1) - (3)].node); (yyval.selection_rest_statement).else_statement = (yyvsp[(3) - (3)].node); ;} break; - case 255: + case 268: -/* Line 1464 of yacc.c */ -#line 1500 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1621 "glsl_parser.yy" { (yyval.selection_rest_statement).then_statement = (yyvsp[(1) - (1)].node); (yyval.selection_rest_statement).else_statement = NULL; ;} break; - case 256: + case 269: -/* Line 1464 of yacc.c */ -#line 1508 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1629 "glsl_parser.yy" { (yyval.node) = (ast_node *) (yyvsp[(1) - (1)].expression); ;} break; - case 257: + case 270: -/* Line 1464 of yacc.c */ -#line 1512 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1633 "glsl_parser.yy" { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration((yyvsp[(2) - (4)].identifier), false, NULL, (yyvsp[(4) - (4)].expression)); @@ -4929,10 +5069,10 @@ yyreduce: ;} break; - case 261: + case 274: -/* Line 1464 of yacc.c */ -#line 1535 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1656 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_iteration_statement(ast_iteration_statement::ast_while, @@ -4941,10 +5081,10 @@ yyreduce: ;} break; - case 262: + case 275: -/* Line 1464 of yacc.c */ -#line 1542 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1663 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_iteration_statement(ast_iteration_statement::ast_do_while, @@ -4953,10 +5093,10 @@ yyreduce: ;} break; - case 263: + case 276: -/* Line 1464 of yacc.c */ -#line 1549 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1670 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_iteration_statement(ast_iteration_statement::ast_for, @@ -4965,39 +5105,39 @@ yyreduce: ;} break; - case 267: + case 280: -/* Line 1464 of yacc.c */ -#line 1565 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1686 "glsl_parser.yy" { (yyval.node) = NULL; ;} break; - case 268: + case 281: -/* Line 1464 of yacc.c */ -#line 1572 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1693 "glsl_parser.yy" { (yyval.for_rest_statement).cond = (yyvsp[(1) - (2)].node); (yyval.for_rest_statement).rest = NULL; ;} break; - case 269: + case 282: -/* Line 1464 of yacc.c */ -#line 1577 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1698 "glsl_parser.yy" { (yyval.for_rest_statement).cond = (yyvsp[(1) - (3)].node); (yyval.for_rest_statement).rest = (yyvsp[(3) - (3)].expression); ;} break; - case 270: + case 283: -/* Line 1464 of yacc.c */ -#line 1586 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1707 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_continue, NULL); @@ -5005,10 +5145,10 @@ yyreduce: ;} break; - case 271: + case 284: -/* Line 1464 of yacc.c */ -#line 1592 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1713 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_break, NULL); @@ -5016,10 +5156,10 @@ yyreduce: ;} break; - case 272: + case 285: -/* Line 1464 of yacc.c */ -#line 1598 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1719 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_return, NULL); @@ -5027,10 +5167,10 @@ yyreduce: ;} break; - case 273: + case 286: -/* Line 1464 of yacc.c */ -#line 1604 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1725 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_return, (yyvsp[(2) - (3)].expression)); @@ -5038,10 +5178,10 @@ yyreduce: ;} break; - case 274: + case 287: -/* Line 1464 of yacc.c */ -#line 1610 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1731 "glsl_parser.yy" { void *ctx = state; (yyval.node) = new(ctx) ast_jump_statement(ast_jump_statement::ast_discard, NULL); @@ -5049,44 +5189,46 @@ yyreduce: ;} break; - case 275: + case 288: -/* Line 1464 of yacc.c */ -#line 1618 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1739 "glsl_parser.yy" { (yyval.node) = (yyvsp[(1) - (1)].function_definition); ;} break; - case 276: + case 289: -/* Line 1464 of yacc.c */ -#line 1619 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1740 "glsl_parser.yy" { (yyval.node) = (yyvsp[(1) - (1)].node); ;} break; - case 277: + case 290: -/* Line 1464 of yacc.c */ -#line 1620 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1741 "glsl_parser.yy" { (yyval.node) = NULL; ;} break; - case 278: + case 291: -/* Line 1464 of yacc.c */ -#line 1625 "glsl_parser.ypp" +/* Line 1455 of yacc.c */ +#line 1746 "glsl_parser.yy" { void *ctx = state; (yyval.function_definition) = new(ctx) ast_function_definition(); (yyval.function_definition)->set_location(yylloc); (yyval.function_definition)->prototype = (yyvsp[(1) - (2)].function); (yyval.function_definition)->body = (yyvsp[(2) - (2)].compound_statement); + + state->symbols->pop_scope(); ;} break; -/* Line 1464 of yacc.c */ -#line 5090 "glsl_parser.cpp" +/* Line 1455 of yacc.c */ +#line 5232 "glsl_parser.cpp" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -5158,7 +5300,7 @@ yyerrlab: #endif } - yyerror_range[1] = yylloc; + yyerror_range[0] = yylloc; if (yyerrstatus == 3) { @@ -5195,7 +5337,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); @@ -5229,7 +5371,7 @@ yyerrlab1: if (yyssp == yyss) YYABORT; - yyerror_range[1] = *yylsp; + yyerror_range[0] = *yylsp; yydestruct ("Error: popping", yystos[yystate], yyvsp, yylsp, state); YYPOPSTACK (1); @@ -5239,10 +5381,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 83aa56f7cb..091e2858a2 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 @@ -112,122 +113,125 @@ VOID_TOK = 329, WHILE = 330, IDENTIFIER = 331, - FLOATCONSTANT = 332, - INTCONSTANT = 333, - UINTCONSTANT = 334, - BOOLCONSTANT = 335, - FIELD_SELECTION = 336, - LEFT_OP = 337, - RIGHT_OP = 338, - INC_OP = 339, - DEC_OP = 340, - LE_OP = 341, - GE_OP = 342, - EQ_OP = 343, - NE_OP = 344, - AND_OP = 345, - OR_OP = 346, - XOR_OP = 347, - MUL_ASSIGN = 348, - DIV_ASSIGN = 349, - ADD_ASSIGN = 350, - MOD_ASSIGN = 351, - LEFT_ASSIGN = 352, - RIGHT_ASSIGN = 353, - AND_ASSIGN = 354, - XOR_ASSIGN = 355, - OR_ASSIGN = 356, - SUB_ASSIGN = 357, - INVARIANT = 358, - LOWP = 359, - MEDIUMP = 360, - HIGHP = 361, - SUPERP = 362, - PRECISION = 363, - VERSION = 364, - EXTENSION = 365, - LINE = 366, - COLON = 367, - EOL = 368, - INTERFACE = 369, - OUTPUT = 370, - PRAGMA_DEBUG_ON = 371, - PRAGMA_DEBUG_OFF = 372, - PRAGMA_OPTIMIZE_ON = 373, - PRAGMA_OPTIMIZE_OFF = 374, - LAYOUT_TOK = 375, - ASM = 376, - CLASS = 377, - UNION = 378, - ENUM = 379, - TYPEDEF = 380, - TEMPLATE = 381, - THIS = 382, - PACKED_TOK = 383, - GOTO = 384, - INLINE_TOK = 385, - NOINLINE = 386, - VOLATILE = 387, - PUBLIC_TOK = 388, - STATIC = 389, - EXTERN = 390, - EXTERNAL = 391, - LONG_TOK = 392, - SHORT_TOK = 393, - DOUBLE_TOK = 394, - HALF = 395, - FIXED_TOK = 396, - UNSIGNED = 397, - INPUT_TOK = 398, - OUPTUT = 399, - HVEC2 = 400, - HVEC3 = 401, - HVEC4 = 402, - DVEC2 = 403, - DVEC3 = 404, - DVEC4 = 405, - FVEC2 = 406, - FVEC3 = 407, - FVEC4 = 408, - SAMPLER2DRECT = 409, - SAMPLER3DRECT = 410, - SAMPLER2DRECTSHADOW = 411, - SIZEOF = 412, - CAST = 413, - NAMESPACE = 414, - USING = 415, - ERROR_TOK = 416, - COMMON = 417, - PARTITION = 418, - ACTIVE = 419, - SAMPLERBUFFER = 420, - FILTER = 421, - IMAGE1D = 422, - IMAGE2D = 423, - IMAGE3D = 424, - IMAGECUBE = 425, - IMAGE1DARRAY = 426, - IMAGE2DARRAY = 427, - IIMAGE1D = 428, - IIMAGE2D = 429, - IIMAGE3D = 430, - IIMAGECUBE = 431, - IIMAGE1DARRAY = 432, - IIMAGE2DARRAY = 433, - UIMAGE1D = 434, - UIMAGE2D = 435, - UIMAGE3D = 436, - UIMAGECUBE = 437, - UIMAGE1DARRAY = 438, - UIMAGE2DARRAY = 439, - IMAGE1DSHADOW = 440, - IMAGE2DSHADOW = 441, - IMAGEBUFFER = 442, - IIMAGEBUFFER = 443, - UIMAGEBUFFER = 444, - IMAGE1DARRAYSHADOW = 445, - IMAGE2DARRAYSHADOW = 446, - ROW_MAJOR = 447 + TYPE_IDENTIFIER = 332, + NEW_IDENTIFIER = 333, + FLOATCONSTANT = 334, + INTCONSTANT = 335, + UINTCONSTANT = 336, + BOOLCONSTANT = 337, + FIELD_SELECTION = 338, + LEFT_OP = 339, + RIGHT_OP = 340, + INC_OP = 341, + DEC_OP = 342, + LE_OP = 343, + GE_OP = 344, + EQ_OP = 345, + NE_OP = 346, + AND_OP = 347, + OR_OP = 348, + XOR_OP = 349, + MUL_ASSIGN = 350, + DIV_ASSIGN = 351, + ADD_ASSIGN = 352, + MOD_ASSIGN = 353, + LEFT_ASSIGN = 354, + RIGHT_ASSIGN = 355, + AND_ASSIGN = 356, + XOR_ASSIGN = 357, + OR_ASSIGN = 358, + SUB_ASSIGN = 359, + INVARIANT = 360, + LOWP = 361, + MEDIUMP = 362, + HIGHP = 363, + SUPERP = 364, + PRECISION = 365, + VERSION = 366, + EXTENSION = 367, + LINE = 368, + COLON = 369, + EOL = 370, + INTERFACE = 371, + OUTPUT = 372, + PRAGMA_DEBUG_ON = 373, + PRAGMA_DEBUG_OFF = 374, + PRAGMA_OPTIMIZE_ON = 375, + PRAGMA_OPTIMIZE_OFF = 376, + PRAGMA_INVARIANT_ALL = 377, + LAYOUT_TOK = 378, + ASM = 379, + CLASS = 380, + UNION = 381, + ENUM = 382, + TYPEDEF = 383, + TEMPLATE = 384, + THIS = 385, + PACKED_TOK = 386, + GOTO = 387, + INLINE_TOK = 388, + NOINLINE = 389, + VOLATILE = 390, + PUBLIC_TOK = 391, + STATIC = 392, + EXTERN = 393, + EXTERNAL = 394, + LONG_TOK = 395, + SHORT_TOK = 396, + DOUBLE_TOK = 397, + HALF = 398, + FIXED_TOK = 399, + UNSIGNED = 400, + INPUT_TOK = 401, + OUPTUT = 402, + HVEC2 = 403, + HVEC3 = 404, + HVEC4 = 405, + DVEC2 = 406, + DVEC3 = 407, + DVEC4 = 408, + FVEC2 = 409, + FVEC3 = 410, + FVEC4 = 411, + SAMPLER2DRECT = 412, + SAMPLER3DRECT = 413, + SAMPLER2DRECTSHADOW = 414, + SIZEOF = 415, + CAST = 416, + NAMESPACE = 417, + USING = 418, + ERROR_TOK = 419, + COMMON = 420, + PARTITION = 421, + ACTIVE = 422, + SAMPLERBUFFER = 423, + FILTER = 424, + IMAGE1D = 425, + IMAGE2D = 426, + IMAGE3D = 427, + IMAGECUBE = 428, + IMAGE1DARRAY = 429, + IMAGE2DARRAY = 430, + IIMAGE1D = 431, + IIMAGE2D = 432, + IIMAGE3D = 433, + IIMAGECUBE = 434, + IIMAGE1DARRAY = 435, + IIMAGE2DARRAY = 436, + UIMAGE1D = 437, + UIMAGE2D = 438, + UIMAGE3D = 439, + UIMAGECUBE = 440, + UIMAGE1DARRAY = 441, + UIMAGE2DARRAY = 442, + IMAGE1DSHADOW = 443, + IMAGE2DSHADOW = 444, + IMAGEBUFFER = 445, + IIMAGEBUFFER = 446, + UIMAGEBUFFER = 447, + IMAGE1DARRAYSHADOW = 448, + IMAGE2DARRAYSHADOW = 449, + ROW_MAJOR = 450 }; #endif @@ -237,8 +241,8 @@ typedef union YYSTYPE { -/* Line 1685 of yacc.c */ -#line 52 "glsl_parser.ypp" +/* Line 1676 of yacc.c */ +#line 52 "glsl_parser.yy" int n; float real; @@ -270,8 +274,8 @@ typedef union YYSTYPE -/* Line 1685 of yacc.c */ -#line 275 "glsl_parser.h" +/* Line 1676 of yacc.c */ +#line 279 "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.yy index 6d7d148eb0..2c0498ece7 100644 --- a/src/glsl/glsl_parser.ypp +++ b/src/glsl/glsl_parser.yy @@ -93,7 +93,8 @@ %token ISAMPLER1DARRAY ISAMPLER2DARRAY USAMPLER1D USAMPLER2D USAMPLER3D %token USAMPLERCUBE USAMPLER1DARRAY USAMPLER2DARRAY %token STRUCT VOID_TOK WHILE -%token <identifier> IDENTIFIER +%token <identifier> IDENTIFIER TYPE_IDENTIFIER NEW_IDENTIFIER +%type <identifier> any_identifier %token <real> FLOATCONSTANT %token <n> INTCONSTANT UINTCONSTANT BOOLCONSTANT %token <identifier> FIELD_SELECTION @@ -108,6 +109,7 @@ %token VERSION EXTENSION LINE COLON EOL INTERFACE OUTPUT %token PRAGMA_DEBUG_ON PRAGMA_DEBUG_OFF %token PRAGMA_OPTIMIZE_ON PRAGMA_OPTIMIZE_OFF +%token PRAGMA_INVARIANT_ALL %token LAYOUT_TOK /* Reserved words that are not actually used in the grammar. @@ -183,6 +185,10 @@ %type <expression> function_call_generic %type <expression> function_call_or_method %type <expression> function_call +%type <expression> method_call_generic +%type <expression> method_call_header_with_parameters +%type <expression> method_call_header_no_parameters +%type <expression> method_call_header %type <n> assignment_operator %type <n> unary_operator %type <expression> function_identifier @@ -213,26 +219,51 @@ translation_unit: _mesa_glsl_initialize_types(state); } external_declaration_list + { + delete state->symbols; + state->symbols = new(ralloc_parent(state)) glsl_symbol_table; + _mesa_glsl_initialize_types(state); + } ; version_statement: /* blank - no #version specified: defaults are already set */ | VERSION INTCONSTANT EOL { + bool supported = false; + switch ($2) { case 100: state->es_shader = true; + supported = state->Const.GLSL_100ES; + break; case 110: + supported = state->Const.GLSL_110; + break; case 120: + supported = state->Const.GLSL_120; + break; case 130: - /* FINISHME: Check against implementation support versions. */ - state->language_version = $2; + supported = state->Const.GLSL_130; break; default: - _mesa_glsl_error(& @2, state, "Shading language version" - "%u is not supported\n", $2); + supported = false; break; } + + state->language_version = $2; + state->version_string = + ralloc_asprintf(state, "GLSL%s %d.%02d", + state->es_shader ? " ES" : "", + state->language_version / 100, + state->language_version % 100); + + if (!supported) { + _mesa_glsl_error(& @2, state, "%s is not supported. " + "Supported versions are: %s\n", + state->version_string, + state->supported_version_string); + } } ; @@ -241,6 +272,16 @@ pragma_statement: | PRAGMA_DEBUG_OFF EOL | PRAGMA_OPTIMIZE_ON EOL | PRAGMA_OPTIMIZE_OFF EOL + | PRAGMA_INVARIANT_ALL EOL + { + if (state->language_version < 120) { + _mesa_glsl_warning(& @1, state, + "pragma `invariant(all)' not supported in %s", + state->version_string); + } else { + state->all_invariant = true; + } + } ; extension_statement_list: @@ -248,8 +289,14 @@ extension_statement_list: | extension_statement_list extension_statement ; +any_identifier: + IDENTIFIER + | TYPE_IDENTIFIER + | NEW_IDENTIFIER + ; + extension_statement: - EXTENSION IDENTIFIER COLON IDENTIFIER EOL + EXTENSION any_identifier COLON any_identifier EOL { if (!_mesa_glsl_process_extension($2, & @2, $4, & @4, state)) { YYERROR; @@ -260,16 +307,16 @@ extension_statement: external_declaration_list: external_declaration { - /* FINISHME: The NULL test is only required because 'precision' - * FINISHME: statements are not yet supported. + /* FINISHME: The NULL test is required because pragmas are set to + * FINISHME: NULL. (See production rule for external_declaration.) */ if ($1 != NULL) state->translation_unit.push_tail(& $1->link); } | external_declaration_list external_declaration { - /* FINISHME: The NULL test is only required because 'precision' - * FINISHME: statements are not yet supported. + /* FINISHME: The NULL test is required because pragmas are set to + * FINISHME: NULL. (See production rule for external_declaration.) */ if ($2 != NULL) state->translation_unit.push_tail(& $2->link); @@ -278,6 +325,7 @@ external_declaration_list: variable_identifier: IDENTIFIER + | NEW_IDENTIFIER ; primary_expression: @@ -334,7 +382,7 @@ postfix_expression: { $$ = $1; } - | postfix_expression '.' IDENTIFIER + | postfix_expression '.' any_identifier { void *ctx = state; $$ = new(ctx) ast_expression(ast_field_selection, $1, NULL, NULL); @@ -365,7 +413,7 @@ function_call: function_call_or_method: function_call_generic - | postfix_expression '.' function_call_generic + | postfix_expression '.' method_call_generic { void *ctx = state; $$ = new(ctx) ast_expression(ast_field_selection, $1, $3, NULL); @@ -412,7 +460,7 @@ function_identifier: $$ = new(ctx) ast_function_expression($1); $$->set_location(yylloc); } - | IDENTIFIER + | variable_identifier { void *ctx = state; ast_expression *callee = new(ctx) ast_expression($1); @@ -428,6 +476,44 @@ function_identifier: } ; +method_call_generic: + method_call_header_with_parameters ')' + | method_call_header_no_parameters ')' + ; + +method_call_header_no_parameters: + method_call_header VOID_TOK + | method_call_header + ; + +method_call_header_with_parameters: + method_call_header assignment_expression + { + $$ = $1; + $$->set_location(yylloc); + $$->expressions.push_tail(& $2->link); + } + | method_call_header_with_parameters ',' assignment_expression + { + $$ = $1; + $$->set_location(yylloc); + $$->expressions.push_tail(& $3->link); + } + ; + + // Grammar Note: Constructors look like methods, but lexical + // analysis recognized most of them as keywords. They are now + // recognized through "type_specifier". +method_call_header: + variable_identifier '(' + { + void *ctx = state; + ast_expression *callee = new(ctx) ast_expression($1); + $$ = new(ctx) ast_function_expression(callee); + $$->set_location(yylloc); + } + ; + // Grammar Note: No traditional style type casts. unary_expression: postfix_expression @@ -678,6 +764,7 @@ constant_expression: declaration: function_prototype ';' { + state->symbols->pop_scope(); $$ = $1; } | init_declarator_list ';' @@ -686,14 +773,9 @@ declaration: } | PRECISION precision_qualifier type_specifier_no_prec ';' { - if (($3->type_specifier != ast_float) - && ($3->type_specifier != ast_int)) { - _mesa_glsl_error(& @3, state, "global precision qualifier can " - "only be applied to `int' or `float'\n"); - YYERROR; - } - - $$ = NULL; /* FINISHME */ + $3->precision = $2; + $3->is_precision_statement = true; + $$ = $3; } ; @@ -720,18 +802,21 @@ function_header_with_parameters: ; function_header: - fully_specified_type IDENTIFIER '(' + fully_specified_type variable_identifier '(' { void *ctx = state; $$ = new(ctx) ast_function(); $$->set_location(yylloc); $$->return_type = $1; $$->identifier = $2; + + state->symbols->add_function(new(state) ir_function($2)); + state->symbols->push_scope(); } ; parameter_declarator: - type_specifier IDENTIFIER + type_specifier any_identifier { void *ctx = state; $$ = new(ctx) ast_parameter_declarator(); @@ -741,7 +826,7 @@ parameter_declarator: $$->type->specifier = $1; $$->identifier = $2; } - | type_specifier IDENTIFIER '[' constant_expression ']' + | type_specifier any_identifier '[' constant_expression ']' { void *ctx = state; $$ = new(ctx) ast_parameter_declarator(); @@ -819,7 +904,7 @@ parameter_type_specifier: init_declarator_list: single_declaration - | init_declarator_list ',' IDENTIFIER + | init_declarator_list ',' any_identifier { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($3, false, NULL, NULL); @@ -827,8 +912,9 @@ init_declarator_list: $$ = $1; $$->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, $3, ir_var_auto)); } - | init_declarator_list ',' IDENTIFIER '[' ']' + | init_declarator_list ',' any_identifier '[' ']' { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($3, true, NULL, NULL); @@ -836,8 +922,9 @@ init_declarator_list: $$ = $1; $$->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, $3, ir_var_auto)); } - | init_declarator_list ',' IDENTIFIER '[' constant_expression ']' + | init_declarator_list ',' any_identifier '[' constant_expression ']' { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($3, true, $5, NULL); @@ -845,8 +932,9 @@ init_declarator_list: $$ = $1; $$->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, $3, ir_var_auto)); } - | init_declarator_list ',' IDENTIFIER '[' ']' '=' initializer + | init_declarator_list ',' any_identifier '[' ']' '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($3, true, NULL, $7); @@ -854,8 +942,9 @@ init_declarator_list: $$ = $1; $$->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, $3, ir_var_auto)); } - | init_declarator_list ',' IDENTIFIER '[' constant_expression ']' '=' initializer + | init_declarator_list ',' any_identifier '[' constant_expression ']' '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($3, true, $5, $8); @@ -863,8 +952,9 @@ init_declarator_list: $$ = $1; $$->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, $3, ir_var_auto)); } - | init_declarator_list ',' IDENTIFIER '=' initializer + | init_declarator_list ',' any_identifier '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($3, false, NULL, $5); @@ -872,6 +962,7 @@ init_declarator_list: $$ = $1; $$->declarations.push_tail(&decl->link); + state->symbols->add_variable(new(state) ir_variable(NULL, $3, ir_var_auto)); } ; @@ -888,7 +979,7 @@ single_declaration: $$->set_location(yylloc); } } - | fully_specified_type IDENTIFIER + | fully_specified_type any_identifier { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, false, NULL, NULL); @@ -897,7 +988,7 @@ single_declaration: $$->set_location(yylloc); $$->declarations.push_tail(&decl->link); } - | fully_specified_type IDENTIFIER '[' ']' + | fully_specified_type any_identifier '[' ']' { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, true, NULL, NULL); @@ -906,7 +997,7 @@ single_declaration: $$->set_location(yylloc); $$->declarations.push_tail(&decl->link); } - | fully_specified_type IDENTIFIER '[' constant_expression ']' + | fully_specified_type any_identifier '[' constant_expression ']' { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, true, $4, NULL); @@ -915,7 +1006,7 @@ single_declaration: $$->set_location(yylloc); $$->declarations.push_tail(&decl->link); } - | fully_specified_type IDENTIFIER '[' ']' '=' initializer + | fully_specified_type any_identifier '[' ']' '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, true, NULL, $6); @@ -924,7 +1015,7 @@ single_declaration: $$->set_location(yylloc); $$->declarations.push_tail(&decl->link); } - | fully_specified_type IDENTIFIER '[' constant_expression ']' '=' initializer + | fully_specified_type any_identifier '[' constant_expression ']' '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, true, $4, $7); @@ -933,7 +1024,7 @@ single_declaration: $$->set_location(yylloc); $$->declarations.push_tail(&decl->link); } - | fully_specified_type IDENTIFIER '=' initializer + | fully_specified_type any_identifier '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, false, NULL, $4); @@ -942,7 +1033,7 @@ single_declaration: $$->set_location(yylloc); $$->declarations.push_tail(&decl->link); } - | INVARIANT IDENTIFIER // Vertex only. + | INVARIANT variable_identifier // Vertex only. { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, false, NULL, NULL); @@ -1001,13 +1092,14 @@ layout_qualifier_id_list: ; layout_qualifier_id: - IDENTIFIER + any_identifier { bool got_one = false; memset(& $$, 0, sizeof($$)); - if (state->ARB_fragment_coord_conventions_enable) { + /* Layout qualifiers for ARB_fragment_coord_conventions. */ + if (!got_one && state->ARB_fragment_coord_conventions_enable) { if (strcmp($1, "origin_upper_left") == 0) { got_one = true; $$.flags.q.origin_upper_left = 1; @@ -1015,22 +1107,44 @@ layout_qualifier_id: got_one = true; $$.flags.q.pixel_center_integer = 1; } + + if (got_one && state->ARB_fragment_coord_conventions_warn) { + _mesa_glsl_warning(& @1, state, + "GL_ARB_fragment_coord_conventions layout " + "identifier `%s' used\n", $1); + } + } + + /* Layout qualifiers for AMD_conservative_depth. */ + if (!got_one && state->AMD_conservative_depth_enable) { + if (strcmp($1, "depth_any") == 0) { + got_one = true; + $$.flags.q.depth_any = 1; + } else if (strcmp($1, "depth_greater") == 0) { + got_one = true; + $$.flags.q.depth_greater = 1; + } else if (strcmp($1, "depth_less") == 0) { + got_one = true; + $$.flags.q.depth_less = 1; + } else if (strcmp($1, "depth_unchanged") == 0) { + got_one = true; + $$.flags.q.depth_unchanged = 1; + } + + if (got_one && state->AMD_conservative_depth_warn) { + _mesa_glsl_warning(& @1, state, + "GL_AMD_conservative_depth " + "layout qualifier `%s' is 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 + | any_identifier '=' INTCONSTANT { bool got_one = false; @@ -1179,6 +1293,9 @@ storage_qualifier: type_specifier: type_specifier_no_prec + { + $$ = $1; + } | precision_qualifier type_specifier_no_prec { $$ = $2; @@ -1215,7 +1332,7 @@ type_specifier_nonarray: $$ = new(ctx) ast_type_specifier($1); $$->set_location(yylloc); } - | IDENTIFIER + | TYPE_IDENTIFIER { void *ctx = state; $$ = new(ctx) ast_type_specifier($1); @@ -1282,10 +1399,9 @@ precision_qualifier: if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& @1, state, "precision qualifier forbidden " - "in GLSL %d.%d (1.30 or later " + "in %s (1.30 or later " "required)\n", - state->language_version / 100, - state->language_version % 100); + state->version_string); $$ = ast_precision_high; } @@ -1293,10 +1409,9 @@ precision_qualifier: if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& @1, state, "precision qualifier forbidden " - "in GLSL %d.%d (1.30 or later " + "in %s (1.30 or later " "required)\n", - state->language_version / 100, - state->language_version % 100); + state->version_string); $$ = ast_precision_medium; } @@ -1304,21 +1419,21 @@ precision_qualifier: if (!state->es_shader && state->language_version < 130) _mesa_glsl_error(& @1, state, "precision qualifier forbidden " - "in GLSL %d.%d (1.30 or later " + "in %s (1.30 or later " "required)\n", - state->language_version / 100, - state->language_version % 100); + state->version_string); $$ = ast_precision_low; } ; struct_specifier: - STRUCT IDENTIFIER '{' struct_declaration_list '}' + STRUCT any_identifier '{' struct_declaration_list '}' { void *ctx = state; $$ = new(ctx) ast_struct_specifier($2, $4); $$->set_location(yylloc); + state->symbols->add_type($2, glsl_type::void_type); } | STRUCT '{' struct_declaration_list '}' { @@ -1370,13 +1485,14 @@ struct_declarator_list: ; struct_declarator: - IDENTIFIER + any_identifier { void *ctx = state; $$ = new(ctx) ast_declaration($1, false, NULL, NULL); $$->set_location(yylloc); + state->symbols->add_variable(new(state) ir_variable(NULL, $1, ir_var_auto)); } - | IDENTIFIER '[' constant_expression ']' + | any_identifier '[' constant_expression ']' { void *ctx = state; $$ = new(ctx) ast_declaration($1, true, $3, NULL); @@ -1416,11 +1532,16 @@ compound_statement: $$ = new(ctx) ast_compound_statement(true, NULL); $$->set_location(yylloc); } - | '{' statement_list '}' + | '{' + { + state->symbols->push_scope(); + } + statement_list '}' { void *ctx = state; - $$ = new(ctx) ast_compound_statement(true, $2); + $$ = new(ctx) ast_compound_statement(true, $3); $$->set_location(yylloc); + state->symbols->pop_scope(); } ; @@ -1508,7 +1629,7 @@ condition: { $$ = (ast_node *) $1; } - | fully_specified_type IDENTIFIER '=' initializer + | fully_specified_type any_identifier '=' initializer { void *ctx = state; ast_declaration *decl = new(ctx) ast_declaration($2, false, NULL, $4); @@ -1628,5 +1749,7 @@ function_definition: $$->set_location(yylloc); $$->prototype = $1; $$->body = $2; + + state->symbols->pop_scope(); } ; diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp index 8dbe66927d..e8c60936fb 100644 --- a/src/glsl/glsl_parser_extras.cpp +++ b/src/glsl/glsl_parser_extras.cpp @@ -26,10 +26,10 @@ #include <assert.h> extern "C" { -#include <talloc.h> #include "main/core.h" /* for struct gl_context */ } +#include "ralloc.h" #include "ast.h" #include "glsl_parser_extras.h" #include "glsl_parser.h" @@ -48,7 +48,7 @@ _mesa_glsl_parse_state::_mesa_glsl_parse_state(struct gl_context *ctx, this->scanner = NULL; this->translation_unit.make_empty(); this->symbols = new(mem_ctx) glsl_symbol_table; - this->info_log = talloc_strdup(mem_ctx, ""); + this->info_log = ralloc_strdup(mem_ctx, ""); this->error = false; this->loop_or_switch_nesting = NULL; @@ -79,6 +79,38 @@ _mesa_glsl_parse_state::_mesa_glsl_parse_state(struct gl_context *ctx, this->Const.MaxFragmentUniformComponents = ctx->Const.FragmentProgram.MaxUniformComponents; this->Const.MaxDrawBuffers = ctx->Const.MaxDrawBuffers; + + /* Note: Once the OpenGL 3.0 'forward compatible' context or the OpenGL 3.2 + * Core context is supported, this logic will need change. Older versions of + * GLSL are no longer supported outside the compatibility contexts of 3.x. + */ + this->Const.GLSL_100ES = (ctx->API == API_OPENGLES2) + || ctx->Extensions.ARB_ES2_compatibility; + this->Const.GLSL_110 = (ctx->API == API_OPENGL); + this->Const.GLSL_120 = (ctx->API == API_OPENGL) + && (ctx->Const.GLSLVersion >= 120); + this->Const.GLSL_130 = (ctx->API == API_OPENGL) + && (ctx->Const.GLSLVersion >= 130); + + const unsigned lowest_version = + (ctx->API == API_OPENGLES2) || ctx->Extensions.ARB_ES2_compatibility + ? 100 : 110; + const unsigned highest_version = + (ctx->API == API_OPENGL) ? ctx->Const.GLSLVersion : 100; + char *supported = ralloc_strdup(this, ""); + + for (unsigned ver = lowest_version; ver <= highest_version; ver += 10) { + const char *const prefix = (ver == lowest_version) + ? "" + : ((ver == highest_version) ? ", and " : ", "); + + ralloc_asprintf_append(& supported, "%s%d.%02d%s", + prefix, + ver / 100, ver % 100, + (ver == 100) ? " ES" : ""); + } + + this->supported_version_string = supported; } const char * @@ -104,15 +136,14 @@ _mesa_glsl_error(YYLTYPE *locp, _mesa_glsl_parse_state *state, state->error = true; assert(state->info_log != NULL); - state->info_log = talloc_asprintf_append(state->info_log, - "%u:%u(%u): error: ", + ralloc_asprintf_append(&state->info_log, "%u:%u(%u): error: ", locp->source, locp->first_line, locp->first_column); va_start(ap, fmt); - state->info_log = talloc_vasprintf_append(state->info_log, fmt, ap); + ralloc_vasprintf_append(&state->info_log, fmt, ap); va_end(ap); - state->info_log = talloc_strdup_append(state->info_log, "\n"); + ralloc_strcat(&state->info_log, "\n"); } @@ -123,15 +154,14 @@ _mesa_glsl_warning(const YYLTYPE *locp, _mesa_glsl_parse_state *state, va_list ap; assert(state->info_log != NULL); - state->info_log = talloc_asprintf_append(state->info_log, - "%u:%u(%u): warning: ", + ralloc_asprintf_append(&state->info_log, "%u:%u(%u): warning: ", locp->source, locp->first_line, locp->first_column); va_start(ap, fmt); - state->info_log = talloc_vasprintf_append(state->info_log, fmt, ap); + ralloc_vasprintf_append(&state->info_log, fmt, ap); va_end(ap); - state->info_log = talloc_strdup_append(state->info_log, "\n"); + ralloc_strcat(&state->info_log, "\n"); } @@ -180,6 +210,15 @@ _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_draw_instanced") == 0) { + /* This extension is only supported in vertex shaders. + */ + if (state->target != vertex_shader) { + unsupported = true; + } else { + state->ARB_draw_instanced_enable = (ext_mode != extension_disable); + state->ARB_draw_instanced_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); @@ -210,6 +249,18 @@ _mesa_glsl_process_extension(const char *name, YYLTYPE *name_locp, state->ARB_shader_stencil_export_warn = (ext_mode == extension_warn); unsupported = !state->extensions->ARB_shader_stencil_export; } + } else if (strcmp(name, "GL_AMD_conservative_depth") == 0) { + /* The AMD_conservative spec does not forbid requiring the extension in + * the vertex shader. + */ + state->AMD_conservative_depth_enable = (ext_mode != extension_disable); + state->AMD_conservative_depth_warn = (ext_mode == extension_warn); + unsupported = !state->extensions->AMD_conservative_depth; + } else if (strcmp(name, "GL_OES_texture_3D") == 0 && state->es_shader) { + state->OES_texture_3D_enable = (ext_mode != extension_disable); + state->OES_texture_3D_warn = (ext_mode == extension_warn); + + unsupported = !state->extensions->EXT_texture3D; } else { unsupported = true; } @@ -696,7 +747,7 @@ ast_struct_specifier::ast_struct_specifier(char *identifier, { if (identifier == NULL) { static unsigned anon_count = 1; - identifier = talloc_asprintf(this, "#anon_struct_%04x", anon_count); + identifier = ralloc_asprintf(this, "#anon_struct_%04x", anon_count); anon_count++; } name = identifier; @@ -718,6 +769,7 @@ do_common_optimization(exec_list *ir, bool linked, unsigned max_unroll_iteration progress = do_if_simplification(ir) || progress; progress = do_discard_simplification(ir) || progress; progress = do_copy_propagation(ir) || progress; + /*progress = do_copy_propagation_elements(ir) || progress;*/ if (linked) progress = do_dead_code(ir) || progress; else @@ -739,8 +791,10 @@ do_common_optimization(exec_list *ir, bool linked, unsigned max_unroll_iteration progress = optimize_redundant_jumps(ir) || progress; loop_state *ls = analyze_loop_variables(ir); - progress = set_loop_controls(ir, ls) || progress; - progress = unroll_loops(ir, ls, max_unroll_iterations) || progress; + if (ls->loop_found) { + progress = set_loop_controls(ir, ls) || progress; + progress = unroll_loops(ir, ls, max_unroll_iterations) || progress; + } delete ls; return progress; diff --git a/src/glsl/glsl_parser_extras.h b/src/glsl/glsl_parser_extras.h index 98c4e70173..b5c016fb39 100644 --- a/src/glsl/glsl_parser_extras.h +++ b/src/glsl/glsl_parser_extras.h @@ -31,7 +31,7 @@ #ifdef __cplusplus -#include <cstdlib> +#include <stdlib.h> #include "glsl_symbol_table.h" enum _mesa_glsl_parser_targets { @@ -46,21 +46,21 @@ struct _mesa_glsl_parse_state { _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 - * easier to just talloc_free 'ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'ctx' (or any of its ancestors). */ static void* operator new(size_t size, void *ctx) { - void *mem = talloc_zero_size(ctx, size); + void *mem = rzalloc_size(ctx, size); assert(mem != NULL); return mem; } /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. */ + * ralloc_free in that case. */ static void operator delete(void *mem) { - talloc_free(mem); + ralloc_free(mem); } void *scanner; @@ -69,9 +69,20 @@ struct _mesa_glsl_parse_state { bool es_shader; unsigned language_version; + const char *version_string; enum _mesa_glsl_parser_targets target; /** + * Printable list of GLSL versions supported by the current context + * + * \note + * This string should probably be generated per-context instead of per + * invokation of the compiler. This should be changed when the method of + * tracking supported GLSL versions changes. + */ + const char *supported_version_string; + + /** * Implementation defined limits that affect built-in variables, etc. * * \sa struct gl_constants (in mtypes.h) @@ -92,6 +103,22 @@ struct _mesa_glsl_parse_state { /* ARB_draw_buffers */ unsigned MaxDrawBuffers; + + /** + * Set of GLSL versions supported by the current context + * + * Knowing that version X is supported doesn't mean that versions before + * X are also supported. Version 1.00 is only supported in an ES2 + * context or when GL_ARB_ES2_compatibility is supported. In an OpenGL + * 3.0 "forward compatible" context, GLSL 1.10 and 1.20 are \b not + * supported. + */ + /*@{*/ + unsigned GLSL_100ES:1; + unsigned GLSL_110:1; + unsigned GLSL_120:1; + unsigned GLSL_130:1; + /*@}*/ } Const; /** @@ -108,6 +135,13 @@ struct _mesa_glsl_parse_state { /** Was there an error during compilation? */ bool error; + /** + * Are all shader inputs / outputs invariant? + * + * This is set when the 'STDGL invariant(all)' pragma is used. + */ + bool all_invariant; + /** Loop or switch statement containing the current instructions. */ class ir_instruction *loop_or_switch_nesting; class ast_iteration_statement *loop_or_switch_nesting_ast; @@ -124,6 +158,8 @@ struct _mesa_glsl_parse_state { /*@{*/ unsigned ARB_draw_buffers_enable:1; unsigned ARB_draw_buffers_warn:1; + unsigned ARB_draw_instanced_enable:1; + unsigned ARB_draw_instanced_warn:1; unsigned ARB_explicit_attrib_location_enable:1; unsigned ARB_explicit_attrib_location_warn:1; unsigned ARB_fragment_coord_conventions_enable:1; @@ -134,6 +170,10 @@ struct _mesa_glsl_parse_state { unsigned EXT_texture_array_warn:1; unsigned ARB_shader_stencil_export_enable:1; unsigned ARB_shader_stencil_export_warn:1; + unsigned AMD_conservative_depth_enable:1; + unsigned AMD_conservative_depth_warn:1; + unsigned OES_texture_3D_enable:1; + unsigned OES_texture_3D_warn:1; /*@}*/ /** Extensions supported by the OpenGL implementation. */ diff --git a/src/glsl/glsl_symbol_table.cpp b/src/glsl/glsl_symbol_table.cpp index 3dcd928016..2f291d4f97 100644 --- a/src/glsl/glsl_symbol_table.cpp +++ b/src/glsl/glsl_symbol_table.cpp @@ -26,22 +26,19 @@ class symbol_table_entry { public: - /* Callers of this talloc-based new need not call delete. It's - * easier to just talloc_free 'ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'ctx' (or any of its ancestors). */ static void* operator new(size_t size, void *ctx) { - void *entry = talloc_size(ctx, size); + void *entry = ralloc_size(ctx, size); assert(entry != NULL); return entry; } - /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. Here, C++ will have already called the - * destructor so tell talloc not to do that again. */ - static void operator delete(void *table) + /* If the user *does* call delete, that's OK, we will just ralloc_free. */ + static void operator delete(void *entry) { - talloc_set_destructor(table, NULL); - talloc_free(table); + ralloc_free(entry); } symbol_table_entry(ir_variable *v) : v(v), f(0), t(0) {} @@ -57,13 +54,13 @@ glsl_symbol_table::glsl_symbol_table() { this->language_version = 120; this->table = _mesa_symbol_table_ctor(); - this->mem_ctx = talloc_init("symbol table entries"); + this->mem_ctx = ralloc_context(NULL); } glsl_symbol_table::~glsl_symbol_table() { _mesa_symbol_table_dtor(table); - talloc_free(mem_ctx); + ralloc_free(mem_ctx); } void glsl_symbol_table::push_scope() diff --git a/src/glsl/glsl_symbol_table.h b/src/glsl/glsl_symbol_table.h index 28a44ebe91..637bc033b9 100644 --- a/src/glsl/glsl_symbol_table.h +++ b/src/glsl/glsl_symbol_table.h @@ -44,36 +44,34 @@ class symbol_table_entry; */ struct glsl_symbol_table { private: - static int + static void _glsl_symbol_table_destructor (glsl_symbol_table *table) { table->~glsl_symbol_table(); - - return 0; } public: - /* Callers of this talloc-based new need not call delete. It's - * easier to just talloc_free 'ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'ctx' (or any of its ancestors). */ static void* operator new(size_t size, void *ctx) { void *table; - table = talloc_size(ctx, size); + table = ralloc_size(ctx, size); assert(table != NULL); - talloc_set_destructor(table, (int (*)(void*)) _glsl_symbol_table_destructor); + ralloc_set_destructor(table, (void (*)(void*)) _glsl_symbol_table_destructor); return table; } /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. Here, C++ will have already called the - * destructor so tell talloc not to do that again. */ + * ralloc_free in that case. Here, C++ will have already called the + * destructor so tell ralloc not to do that again. */ static void operator delete(void *table) { - talloc_set_destructor(table, NULL); - talloc_free(table); + ralloc_set_destructor(table, NULL); + ralloc_free(table); } glsl_symbol_table(); diff --git a/src/glsl/glsl_types.cpp b/src/glsl/glsl_types.cpp index 8c33cfa20d..78d10bd938 100644 --- a/src/glsl/glsl_types.cpp +++ b/src/glsl/glsl_types.cpp @@ -21,7 +21,7 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> +#include <stdio.h> #include <stdlib.h> #include "main/core.h" /* for Elements */ #include "glsl_symbol_table.h" @@ -37,10 +37,10 @@ hash_table *glsl_type::record_types = NULL; void *glsl_type::mem_ctx = NULL; void -glsl_type::init_talloc_type_ctx(void) +glsl_type::init_ralloc_type_ctx(void) { if (glsl_type::mem_ctx == NULL) { - glsl_type::mem_ctx = talloc_autofree_context(); + glsl_type::mem_ctx = ralloc_autofree_context(); assert(glsl_type::mem_ctx != NULL); } } @@ -55,8 +55,8 @@ glsl_type::glsl_type(GLenum gl_type, vector_elements(vector_elements), matrix_columns(matrix_columns), length(0) { - init_talloc_type_ctx(); - this->name = talloc_strdup(this->mem_ctx, name); + init_ralloc_type_ctx(); + this->name = ralloc_strdup(this->mem_ctx, name); /* Neither dimension is zero or both dimensions are zero. */ assert((vector_elements == 0) == (matrix_columns == 0)); @@ -73,8 +73,8 @@ glsl_type::glsl_type(GLenum gl_type, vector_elements(0), matrix_columns(0), length(0) { - init_talloc_type_ctx(); - this->name = talloc_strdup(this->mem_ctx, name); + init_ralloc_type_ctx(); + this->name = ralloc_strdup(this->mem_ctx, name); memset(& fields, 0, sizeof(fields)); } @@ -88,13 +88,13 @@ glsl_type::glsl_type(const glsl_struct_field *fields, unsigned num_fields, { unsigned int i; - init_talloc_type_ctx(); - this->name = talloc_strdup(this->mem_ctx, name); - this->fields.structure = talloc_array(this->mem_ctx, + init_ralloc_type_ctx(); + this->name = ralloc_strdup(this->mem_ctx, name); + this->fields.structure = ralloc_array(this->mem_ctx, glsl_struct_field, length); for (i = 0; i < length; i++) { this->fields.structure[i].type = fields[i].type; - this->fields.structure[i].name = talloc_strdup(this->fields.structure, + this->fields.structure[i].name = ralloc_strdup(this->fields.structure, fields[i].name); } } @@ -120,7 +120,7 @@ glsl_type::generate_100ES_types(glsl_symbol_table *symtab) add_types_to_symbol_table(symtab, builtin_structure_types, Elements(builtin_structure_types), false); - add_types_to_symbol_table(symtab, &void_type, 1, false); + add_types_to_symbol_table(symtab, void_type, 1, false); } void @@ -131,6 +131,7 @@ glsl_type::generate_110_types(glsl_symbol_table *symtab) add_types_to_symbol_table(symtab, builtin_110_types, Elements(builtin_110_types), false); + add_types_to_symbol_table(symtab, &_sampler3D_type, 1, false); add_types_to_symbol_table(symtab, builtin_110_deprecated_structure_types, Elements(builtin_110_deprecated_structure_types), false); @@ -179,6 +180,13 @@ glsl_type::generate_EXT_texture_array_types(glsl_symbol_table *symtab, void +glsl_type::generate_OES_texture_3D_types(glsl_symbol_table *symtab, bool warn) +{ + add_types_to_symbol_table(symtab, &_sampler3D_type, 1, warn); +} + + +void _mesa_glsl_initialize_types(struct _mesa_glsl_parse_state *state) { switch (state->language_version) { @@ -204,6 +212,10 @@ _mesa_glsl_initialize_types(struct _mesa_glsl_parse_state *state) glsl_type::generate_ARB_texture_rectangle_types(state->symbols, state->ARB_texture_rectangle_warn); } + if (state->OES_texture_3D_enable && state->language_version == 100) { + glsl_type::generate_OES_texture_3D_types(state->symbols, + state->OES_texture_3D_warn); + } if (state->EXT_texture_array_enable && state->language_version < 130) { // These are already included in 130; don't create twice. @@ -264,7 +276,7 @@ glsl_type::glsl_type(const glsl_type *array, unsigned length) : * NUL. */ const unsigned name_length = strlen(array->name) + 10 + 3; - char *const n = (char *) talloc_size(this->mem_ctx, name_length); + char *const n = (char *) ralloc_size(this->mem_ctx, name_length); if (length == 0) snprintf(n, name_length, "%s[]", array->name); @@ -279,7 +291,7 @@ const glsl_type * glsl_type::get_instance(unsigned base_type, unsigned rows, unsigned columns) { if (base_type == GLSL_TYPE_VOID) - return &void_type; + return void_type; if ((rows < 1) || (rows > 4) || (columns < 1) || (columns > 4)) return error_type; @@ -354,7 +366,7 @@ glsl_type::get_array_instance(const glsl_type *base, unsigned array_size) if (t == NULL) { t = new glsl_type(base, array_size); - hash_table_insert(array_types, (void *) t, talloc_strdup(mem_ctx, key)); + hash_table_insert(array_types, (void *) t, ralloc_strdup(mem_ctx, key)); } assert(t->base_type == GLSL_TYPE_ARRAY); diff --git a/src/glsl/glsl_types.h b/src/glsl/glsl_types.h index d62d493c8e..1b069df74f 100644 --- a/src/glsl/glsl_types.h +++ b/src/glsl/glsl_types.h @@ -26,14 +26,15 @@ #ifndef GLSL_TYPES_H #define GLSL_TYPES_H -#include <cstring> -#include <cassert> +#include <string.h> +#include <assert.h> extern "C" { #include "GL/gl.h" -#include <talloc.h> } +#include "ralloc.h" + struct _mesa_glsl_parse_state; struct glsl_symbol_table; @@ -69,7 +70,7 @@ struct glsl_type { GLenum gl_type; glsl_base_type base_type; - unsigned sampler_dimensionality:3; + unsigned sampler_dimensionality:3; /**< \see glsl_sampler_dim */ unsigned sampler_shadow:1; unsigned sampler_array:1; unsigned sampler_type:2; /**< Type of data returned using this sampler. @@ -77,28 +78,28 @@ struct glsl_type { * and \c GLSL_TYPE_UINT are valid. */ - /* Callers of this talloc-based new need not call delete. It's - * easier to just talloc_free 'mem_ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'mem_ctx' (or any of its ancestors). */ static void* operator new(size_t size) { if (glsl_type::mem_ctx == NULL) { - glsl_type::mem_ctx = talloc_init("glsl_type"); + glsl_type::mem_ctx = ralloc_context(NULL); assert(glsl_type::mem_ctx != NULL); } void *type; - type = talloc_size(glsl_type::mem_ctx, size); + type = ralloc_size(glsl_type::mem_ctx, size); assert(type != NULL); return type; } /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. */ + * ralloc_free in that case. */ static void operator delete(void *type) { - talloc_free(type); + ralloc_free(type); } /** @@ -142,6 +143,7 @@ struct glsl_type { */ /*@{*/ static const glsl_type *const error_type; + static const glsl_type *const void_type; static const glsl_type *const int_type; static const glsl_type *const ivec4_type; static const glsl_type *const uint_type; @@ -385,13 +387,13 @@ struct glsl_type { private: /** - * talloc context for all glsl_type allocations + * ralloc context for all glsl_type allocations * * Set on the first call to \c glsl_type::new. */ static void *mem_ctx; - void init_talloc_type_ctx(void); + void init_ralloc_type_ctx(void); /** Constructor for vector and matrix types */ glsl_type(GLenum gl_type, @@ -424,7 +426,8 @@ private: */ /*@{*/ static const glsl_type _error_type; - static const glsl_type void_type; + static const glsl_type _void_type; + static const glsl_type _sampler3D_type; static const glsl_type builtin_core_types[]; static const glsl_type builtin_structure_types[]; static const glsl_type builtin_110_deprecated_structure_types[]; @@ -451,6 +454,7 @@ private: static void generate_130_types(glsl_symbol_table *); static void generate_ARB_texture_rectangle_types(glsl_symbol_table *, bool); static void generate_EXT_texture_array_types(glsl_symbol_table *, bool); + static void generate_OES_texture_3D_types(glsl_symbol_table *, bool); /*@}*/ /** diff --git a/src/glsl/ir.cpp b/src/glsl/ir.cpp index b8b0fed9d1..a3623b31e5 100644 --- a/src/glsl/ir.cpp +++ b/src/glsl/ir.cpp @@ -261,12 +261,38 @@ ir_expression::ir_expression(int op, ir_rvalue *op0) case ir_unop_floor: case ir_unop_fract: case ir_unop_round_even: + case ir_unop_sin: case ir_unop_cos: + case ir_unop_sin_reduced: + case ir_unop_cos_reduced: case ir_unop_dFdx: case ir_unop_dFdy: this->type = op0->type; break; + case ir_unop_f2i: + case ir_unop_b2i: + this->type = glsl_type::get_instance(GLSL_TYPE_INT, + op0->type->vector_elements, 1); + break; + + case ir_unop_b2f: + case ir_unop_i2f: + case ir_unop_u2f: + this->type = glsl_type::get_instance(GLSL_TYPE_FLOAT, + op0->type->vector_elements, 1); + break; + + case ir_unop_f2b: + case ir_unop_i2b: + this->type = glsl_type::get_instance(GLSL_TYPE_BOOL, + op0->type->vector_elements, 1); + break; + + case ir_unop_noise: + this->type = glsl_type::float_type; + break; + case ir_unop_any: this->type = glsl_type::bool_type; break; @@ -302,6 +328,8 @@ ir_expression::ir_expression(int op, ir_rvalue *op0, ir_rvalue *op1) case ir_binop_max: case ir_binop_pow: case ir_binop_mul: + case ir_binop_div: + case ir_binop_mod: if (op0->type->is_scalar()) { this->type = op1->type; } else if (op1->type->is_scalar()) { @@ -315,7 +343,11 @@ ir_expression::ir_expression(int op, ir_rvalue *op0, ir_rvalue *op1) break; case ir_binop_logic_and: + case ir_binop_logic_xor: case ir_binop_logic_or: + case ir_binop_bit_and: + case ir_binop_bit_xor: + case ir_binop_bit_or: if (op0->type->is_scalar()) { this->type = op1->type; } else if (op1->type->is_scalar()) { @@ -323,10 +355,26 @@ ir_expression::ir_expression(int op, ir_rvalue *op0, ir_rvalue *op1) } break; + case ir_binop_equal: + case ir_binop_nequal: + case ir_binop_lequal: + case ir_binop_gequal: + case ir_binop_less: + case ir_binop_greater: + assert(op0->type == op1->type); + this->type = glsl_type::get_instance(GLSL_TYPE_BOOL, + op0->type->vector_elements, 1); + break; + case ir_binop_dot: this->type = glsl_type::float_type; break; + case ir_binop_lshift: + case ir_binop_rshift: + this->type = op0->type; + break; + default: assert(!"not reached: missing automatic type setup for ir_expression"); this->type = glsl_type::float_type; @@ -424,6 +472,22 @@ const char *ir_expression::operator_string() return operator_string(this->operation); } +const char* +depth_layout_string(ir_depth_layout layout) +{ + switch(layout) { + case ir_depth_layout_none: return ""; + case ir_depth_layout_any: return "depth_any"; + case ir_depth_layout_greater: return "depth_greater"; + case ir_depth_layout_less: return "depth_less"; + case ir_depth_layout_unchanged: return "depth_unchanged"; + + default: + assert(0); + return ""; + } +} + ir_expression_operation ir_expression::get_operator(const char *str) { @@ -514,7 +578,7 @@ ir_constant::ir_constant(const struct glsl_type *type, exec_list *value_list) || type->is_record() || type->is_array()); if (type->is_array()) { - this->array_elements = talloc_array(this, ir_constant *, type->length); + this->array_elements = ralloc_array(this, ir_constant *, type->length); unsigned i = 0; foreach_list(node, value_list) { ir_constant *value = (ir_constant *) node; @@ -972,7 +1036,7 @@ ir_dereference_array::ir_dereference_array(ir_rvalue *value, ir_dereference_array::ir_dereference_array(ir_variable *var, ir_rvalue *array_index) { - void *ctx = talloc_parent(var); + void *ctx = ralloc_parent(var); this->ir_type = ir_type_dereference_array; this->array_index = array_index; @@ -1005,7 +1069,7 @@ ir_dereference_record::ir_dereference_record(ir_rvalue *value, { this->ir_type = ir_type_dereference_record; this->record = value; - this->field = talloc_strdup(this, field); + this->field = ralloc_strdup(this, field); this->type = (this->record != NULL) ? this->record->type->field_type(field) : glsl_type::error_type; } @@ -1014,11 +1078,11 @@ ir_dereference_record::ir_dereference_record(ir_rvalue *value, ir_dereference_record::ir_dereference_record(ir_variable *var, const char *field) { - void *ctx = talloc_parent(var); + void *ctx = ralloc_parent(var); this->ir_type = ir_type_dereference_record; this->record = new(ctx) ir_dereference_variable(var); - this->field = talloc_strdup(this, field); + this->field = ralloc_strdup(this, field); this->type = (this->record != NULL) ? this->record->type->field_type(field) : glsl_type::error_type; } @@ -1086,22 +1150,18 @@ ir_texture::get_opcode(const char *str) void -ir_texture::set_sampler(ir_dereference *sampler) +ir_texture::set_sampler(ir_dereference *sampler, const glsl_type *type) { assert(sampler != NULL); + assert(type != NULL); this->sampler = sampler; + this->type = type; - switch (sampler->type->sampler_type) { - case GLSL_TYPE_FLOAT: - this->type = glsl_type::vec4_type; - break; - case GLSL_TYPE_INT: - this->type = glsl_type::ivec4_type; - break; - case GLSL_TYPE_UINT: - this->type = glsl_type::uvec4_type; - break; - } + assert(sampler->type->sampler_type == (int) type->base_type); + if (sampler->type->sampler_shadow) + assert(type->vector_elements == 4 || type->vector_elements == 1); + else + assert(type->vector_elements == 4); } @@ -1181,7 +1241,7 @@ ir_swizzle::ir_swizzle(ir_rvalue *val, ir_swizzle_mask mask) ir_swizzle * ir_swizzle::create(ir_rvalue *val, const char *str, unsigned vector_length) { - void *ctx = talloc_parent(val); + void *ctx = ralloc_parent(val); /* For each possible swizzle character, this table encodes the value in * \c idx_map that represents the 0th element of the vector. For invalid @@ -1270,13 +1330,15 @@ 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->name = ralloc_strdup(this, name); this->explicit_location = false; this->location = -1; this->warn_extension = NULL; this->constant_value = NULL; this->origin_upper_left = false; this->pixel_center_integer = false; + this->depth_layout = ir_depth_layout_none; + this->used = false; if (type && type->base_type == GLSL_TYPE_SAMPLER) this->read_only = true; @@ -1313,6 +1375,21 @@ ir_function_signature::ir_function_signature(const glsl_type *return_type) } +static bool +modes_match(unsigned a, unsigned b) +{ + if (a == b) + return true; + + /* Accept "in" vs. "const in" */ + if ((a == ir_var_const_in && b == ir_var_in) || + (b == ir_var_const_in && a == ir_var_in)) + return true; + + return false; +} + + const char * ir_function_signature::qualifiers_match(exec_list *params) { @@ -1325,7 +1402,7 @@ ir_function_signature::qualifiers_match(exec_list *params) ir_variable *b = (ir_variable *)iter_b.get(); if (a->read_only != b->read_only || - a->mode != b->mode || + !modes_match(a->mode, b->mode) || a->interpolation != b->interpolation || a->centroid != b->centroid) { @@ -1360,7 +1437,7 @@ ir_function_signature::replace_parameters(exec_list *new_params) ir_function::ir_function(const char *name) { this->ir_type = ir_type_function; - this->name = talloc_strdup(this, name); + this->name = ralloc_strdup(this, name); } @@ -1426,7 +1503,7 @@ steal_memory(ir_instruction *ir, void *new_ctx) } } - talloc_steal(new_ctx, ir); + ralloc_steal(new_ctx, ir); } diff --git a/src/glsl/ir.h b/src/glsl/ir.h index f3c1d42108..39d4ebc710 100644 --- a/src/glsl/ir.h +++ b/src/glsl/ir.h @@ -26,13 +26,10 @@ #ifndef IR_H #define IR_H -#include <cstdio> -#include <cstdlib> - -extern "C" { -#include <talloc.h> -} +#include <stdio.h> +#include <stdlib.h> +#include "ralloc.h" #include "glsl_types.h" #include "list.h" #include "ir_visitor.h" @@ -131,7 +128,6 @@ protected: ir_type = ir_type_unset; type = NULL; } - virtual ~ir_instruction() {} }; @@ -226,6 +222,8 @@ enum ir_variable_mode { ir_var_in, ir_var_out, ir_var_inout, + ir_var_const_in, /**< "in" param that must be a constant expression */ + ir_var_system_value, /**< Ex: front-face, instance-id, etc. */ ir_var_temporary /**< Temporary variable generated during compilation. */ }; @@ -235,6 +233,25 @@ enum ir_variable_interpolation { ir_var_noperspective }; +/** + * \brief Layout qualifiers for gl_FragDepth. + * + * The AMD_conservative_depth extension allows gl_FragDepth to be redeclared + * with a layout qualifier. + */ +enum ir_depth_layout { + ir_depth_layout_none, /**< No depth layout is specified. */ + ir_depth_layout_any, + ir_depth_layout_greater, + ir_depth_layout_less, + ir_depth_layout_unchanged +}; + +/** + * \brief Convert depth layout qualifier to string. + */ +const char* +depth_layout_string(ir_depth_layout layout); class ir_variable : public ir_instruction { public: @@ -296,6 +313,15 @@ public: unsigned invariant:1; /** + * Has this variable been used for reading or writing? + * + * Several GLSL semantic checks require knowledge of whether or not a + * variable has been used. For example, it is an error to redeclare a + * variable as invariant after it has been used. + */ + unsigned used:1; + + /** * Storage class of the variable. * * \sa ir_variable_mode @@ -326,6 +352,14 @@ public: /*@}*/ /** + * \brief Layout qualifier for gl_FragDepth. + * + * This is not equal to \c ir_depth_layout_none if and only if this + * variable is \c gl_FragDepth and a layout qualifier is specified. + */ + ir_depth_layout depth_layout; + + /** * Was the location explicitly set in the shader? * * If the location is explicitly set in the shader, it \b cannot be changed @@ -950,7 +984,7 @@ public: /** * Get a generic ir_call object when an error occurs * - * Any allocation will be performed with 'ctx' as talloc owner. + * Any allocation will be performed with 'ctx' as ralloc owner. */ static ir_call *get_error_instruction(void *ctx); @@ -1157,21 +1191,21 @@ enum ir_texture_opcode { * selected from \c ir_texture_opcodes. In the printed IR, these will * appear as: * - * Texel offset - * | Projection divisor - * | | Shadow comparitor - * | | | - * v v v - * (tex (sampler) (coordinate) (0 0 0) (1) ( )) - * (txb (sampler) (coordinate) (0 0 0) (1) ( ) (bias)) - * (txl (sampler) (coordinate) (0 0 0) (1) ( ) (lod)) - * (txd (sampler) (coordinate) (0 0 0) (1) ( ) (dPdx dPdy)) - * (txf (sampler) (coordinate) (0 0 0) (lod)) + * Texel offset (0 or an expression) + * | Projection divisor + * | | Shadow comparitor + * | | | + * v v v + * (tex <type> <sampler> <coordinate> 0 1 ( )) + * (txb <type> <sampler> <coordinate> 0 1 ( ) <bias>) + * (txl <type> <sampler> <coordinate> 0 1 ( ) <lod>) + * (txd <type> <sampler> <coordinate> 0 1 ( ) (dPdx dPdy)) + * (txf <type> <sampler> <coordinate> 0 <lod>) */ class ir_texture : public ir_rvalue { public: ir_texture(enum ir_texture_opcode op) - : op(op), projector(NULL), shadow_comparitor(NULL) + : op(op), projector(NULL), shadow_comparitor(NULL), offset(NULL) { this->ir_type = ir_type_texture; } @@ -1192,8 +1226,8 @@ public: */ const char *opcode_string(); - /** Set the sampler and infer the type. */ - void set_sampler(ir_dereference *sampler); + /** Set the sampler and type. */ + void set_sampler(ir_dereference *sampler, const glsl_type *type); /** * Do a reverse-lookup to translate a string into an ir_texture_opcode. @@ -1225,8 +1259,8 @@ public: */ ir_rvalue *shadow_comparitor; - /** Explicit texel offsets. */ - signed char offsets[3]; + /** Texel offset. */ + ir_rvalue *offset; union { ir_rvalue *lod; /**< Floating point LOD */ @@ -1583,8 +1617,7 @@ _mesa_glsl_initialize_variables(exec_list *instructions, struct _mesa_glsl_parse_state *state); extern void -_mesa_glsl_initialize_functions(exec_list *instructions, - struct _mesa_glsl_parse_state *state); +_mesa_glsl_initialize_functions(_mesa_glsl_parse_state *state); extern void _mesa_glsl_release_functions(void); diff --git a/src/glsl/ir_clone.cpp b/src/glsl/ir_clone.cpp index 1522af682b..2c0574dc6b 100644 --- a/src/glsl/ir_clone.cpp +++ b/src/glsl/ir_clone.cpp @@ -217,8 +217,8 @@ ir_texture::clone(void *mem_ctx, struct hash_table *ht) const new_tex->shadow_comparitor = this->shadow_comparitor->clone(mem_ctx, ht); } - for (int i = 0; i < 3; i++) - new_tex->offsets[i] = this->offsets[i]; + if (this->offset != NULL) + new_tex->offset = this->offset->clone(mem_ctx, ht); switch (this->op) { case ir_tex: @@ -346,7 +346,7 @@ ir_constant::clone(void *mem_ctx, struct hash_table *ht) const ir_constant *c = new(mem_ctx) ir_constant; c->type = this->type; - c->array_elements = talloc_array(c, ir_constant *, this->type->length); + c->array_elements = ralloc_array(c, ir_constant *, this->type->length); for (unsigned i = 0; i < this->type->length; i++) { c->array_elements[i] = this->array_elements[i]->clone(mem_ctx, NULL); } diff --git a/src/glsl/ir_constant_expression.cpp b/src/glsl/ir_constant_expression.cpp index 4fd6d09a3a..2a30848965 100644 --- a/src/glsl/ir_constant_expression.cpp +++ b/src/glsl/ir_constant_expression.cpp @@ -86,7 +86,7 @@ ir_expression::constant_expression_value() components = op[1]->type->components(); } - void *ctx = talloc_parent(this); + void *ctx = ralloc_parent(this); /* Handle array operations here, rather than below. */ if (op[0]->type->is_array()) { @@ -507,6 +507,7 @@ ir_expression::constant_expression_value() break; case ir_binop_div: + /* FINISHME: Emit warning when division-by-zero is detected. */ assert(op[0]->type == op[1]->type || op0_scalar || op1_scalar); for (unsigned c = 0, c0 = 0, c1 = 0; c < components; @@ -514,10 +515,18 @@ ir_expression::constant_expression_value() switch (op[0]->type->base_type) { case GLSL_TYPE_UINT: - data.u[c] = op[0]->value.u[c0] / op[1]->value.u[c1]; + if (op[1]->value.u[c1] == 0) { + data.u[c] = 0; + } else { + data.u[c] = op[0]->value.u[c0] / op[1]->value.u[c1]; + } break; case GLSL_TYPE_INT: - data.i[c] = op[0]->value.i[c0] / op[1]->value.i[c1]; + if (op[1]->value.i[c1] == 0) { + data.i[c] = 0; + } else { + data.i[c] = op[0]->value.i[c0] / op[1]->value.i[c1]; + } break; case GLSL_TYPE_FLOAT: data.f[c] = op[0]->value.f[c0] / op[1]->value.f[c1]; @@ -529,6 +538,7 @@ ir_expression::constant_expression_value() break; case ir_binop_mod: + /* FINISHME: Emit warning when division-by-zero is detected. */ assert(op[0]->type == op[1]->type || op0_scalar || op1_scalar); for (unsigned c = 0, c0 = 0, c1 = 0; c < components; @@ -536,10 +546,18 @@ ir_expression::constant_expression_value() switch (op[0]->type->base_type) { case GLSL_TYPE_UINT: - data.u[c] = op[0]->value.u[c0] % op[1]->value.u[c1]; + if (op[1]->value.u[c1] == 0) { + data.u[c] = 0; + } else { + data.u[c] = op[0]->value.u[c0] % op[1]->value.u[c1]; + } break; case GLSL_TYPE_INT: - data.i[c] = op[0]->value.i[c0] % op[1]->value.i[c1]; + if (op[1]->value.i[c1] == 0) { + data.i[c] = 0; + } else { + data.i[c] = op[0]->value.i[c0] % op[1]->value.i[c1]; + } break; case GLSL_TYPE_FLOAT: /* We don't use fmod because it rounds toward zero; GLSL specifies @@ -845,7 +863,7 @@ ir_swizzle::constant_expression_value() } } - void *ctx = talloc_parent(this); + void *ctx = ralloc_parent(this); return new(ctx) ir_constant(this->type, &data); } return NULL; @@ -868,7 +886,7 @@ ir_dereference_variable::constant_expression_value() if (!var->constant_value) return NULL; - return var->constant_value->clone(talloc_parent(var), NULL); + return var->constant_value->clone(ralloc_parent(var), NULL); } @@ -879,7 +897,7 @@ ir_dereference_array::constant_expression_value() ir_constant *idx = this->array_index->constant_expression_value(); if ((array != NULL) && (idx != NULL)) { - void *ctx = talloc_parent(this); + void *ctx = ralloc_parent(this); if (array->type->is_matrix()) { /* Array access of a matrix results in a vector. */ @@ -984,7 +1002,7 @@ ir_call::constant_expression_value() * - Fill "data" with appopriate constant data * - Return an ir_constant directly. */ - void *mem_ctx = talloc_parent(this); + void *mem_ctx = ralloc_parent(this); ir_expression *expr = NULL; ir_constant_data data; diff --git a/src/glsl/ir_expression_flattening.cpp b/src/glsl/ir_expression_flattening.cpp index 7b1b8dbfef..0b7c537bd8 100644 --- a/src/glsl/ir_expression_flattening.cpp +++ b/src/glsl/ir_expression_flattening.cpp @@ -78,7 +78,7 @@ ir_expression_flattening_visitor::handle_rvalue(ir_rvalue **rvalue) if (!ir || !this->predicate(ir)) return; - void *ctx = talloc_parent(ir); + void *ctx = ralloc_parent(ir); var = new(ctx) ir_variable(ir->type, "flattening_tmp", ir_var_temporary); base_ir->insert_before(var); diff --git a/src/glsl/ir_function.cpp b/src/glsl/ir_function.cpp index 8db70119ec..caee9296af 100644 --- a/src/glsl/ir_function.cpp +++ b/src/glsl/ir_function.cpp @@ -123,6 +123,7 @@ parameter_lists_match(const exec_list *list_a, const exec_list *list_b) assert(0); return -1; + case ir_var_const_in: case ir_var_in: score = type_compare(param->type, actual->type); break; diff --git a/src/glsl/ir_hierarchical_visitor.h b/src/glsl/ir_hierarchical_visitor.h index 387563f113..dc177f5eb0 100644 --- a/src/glsl/ir_hierarchical_visitor.h +++ b/src/glsl/ir_hierarchical_visitor.h @@ -77,7 +77,6 @@ enum ir_visitor_status { class ir_hierarchical_visitor { public: ir_hierarchical_visitor(); - virtual ~ir_hierarchical_visitor() {} /** * \name Visit methods for leaf-node classes diff --git a/src/glsl/ir_hv_accept.cpp b/src/glsl/ir_hv_accept.cpp index be8b36a7cf..4a607dc874 100644 --- a/src/glsl/ir_hv_accept.cpp +++ b/src/glsl/ir_hv_accept.cpp @@ -187,6 +187,12 @@ ir_texture::accept(ir_hierarchical_visitor *v) return (s == visit_continue_with_parent) ? visit_continue : s; } + if (this->offset) { + s = this->offset->accept(v); + if (s != visit_continue) + return (s == visit_continue_with_parent) ? visit_continue : s; + } + switch (this->op) { case ir_tex: break; diff --git a/src/glsl/ir_import_prototypes.cpp b/src/glsl/ir_import_prototypes.cpp index 4e0b30aa90..3585bf6b24 100644 --- a/src/glsl/ir_import_prototypes.cpp +++ b/src/glsl/ir_import_prototypes.cpp @@ -27,7 +27,6 @@ * * \author Ian Romanick */ -#include <cstdio> #include "ir.h" #include "glsl_symbol_table.h" @@ -109,7 +108,7 @@ private: * \param dest Destination instruction stream where new \c ir_function and * \c ir_function_signature nodes will be stored * \param symbols Symbol table where new functions will be stored - * \param mem_ctx talloc memory context used for new allocations + * \param mem_ctx ralloc memory context used for new allocations */ void import_prototypes(const exec_list *source, exec_list *dest, diff --git a/src/glsl/ir_optimization.h b/src/glsl/ir_optimization.h index f264265f4b..dd265673c5 100644 --- a/src/glsl/ir_optimization.h +++ b/src/glsl/ir_optimization.h @@ -43,6 +43,7 @@ bool do_constant_folding(exec_list *instructions); bool do_constant_variable(exec_list *instructions); bool do_constant_variable_unlinked(exec_list *instructions); bool do_copy_propagation(exec_list *instructions); +bool do_copy_propagation_elements(exec_list *instructions); bool do_constant_propagation(exec_list *instructions); bool do_dead_code(exec_list *instructions); bool do_dead_code_local(exec_list *instructions); @@ -53,7 +54,7 @@ bool do_lower_jumps(exec_list *instructions, bool pull_out_jumps = true, bool lo bool do_lower_texture_projection(exec_list *instructions); bool do_if_simplification(exec_list *instructions); bool do_discard_simplification(exec_list *instructions); -bool do_if_to_cond_assign(exec_list *instructions); +bool lower_if_to_cond_assign(exec_list *instructions, unsigned max_depth = 0); bool do_mat_op_to_vec(exec_list *instructions); bool do_mod_to_fract(exec_list *instructions); bool do_noop_swizzle(exec_list *instructions); diff --git a/src/glsl/ir_print_visitor.cpp b/src/glsl/ir_print_visitor.cpp index 0aa0b0a5d3..a84f8dfc8a 100644 --- a/src/glsl/ir_print_visitor.cpp +++ b/src/glsl/ir_print_visitor.cpp @@ -97,7 +97,7 @@ void ir_print_visitor::visit(ir_variable *ir) const char *const cent = (ir->centroid) ? "centroid " : ""; const char *const inv = (ir->invariant) ? "invariant " : ""; const char *const mode[] = { "", "uniform ", "in ", "out ", "inout ", - "temporary " }; + "const_in ", "sys ", "temporary " }; const char *const interp[] = { "", "flat", "noperspective" }; printf("(%s%s%s%s) ", @@ -187,12 +187,23 @@ void ir_print_visitor::visit(ir_texture *ir) { printf("(%s ", ir->opcode_string()); + print_type(ir->type); + printf(" "); + ir->sampler->accept(this); printf(" "); ir->coordinate->accept(this); - printf(" (%d %d %d) ", ir->offsets[0], ir->offsets[1], ir->offsets[2]); + printf(" "); + + if (ir->offset != NULL) { + ir->offset->accept(this); + } else { + printf("0"); + } + + printf(" "); if (ir->op != ir_txf) { if (ir->projector) @@ -281,9 +292,6 @@ void ir_print_visitor::visit(ir_assignment *ir) if (ir->condition) ir->condition->accept(this); - else - printf("(constant bool (1))"); - char mask[5]; unsigned j = 0; diff --git a/src/glsl/ir_reader.cpp b/src/glsl/ir_reader.cpp index b9d9d8639f..30df257be2 100644 --- a/src/glsl/ir_reader.cpp +++ b/src/glsl/ir_reader.cpp @@ -21,12 +21,6 @@ * DEALINGS IN THE SOFTWARE. */ - -extern "C" { -#include <stdarg.h> -#include <talloc.h> -} - #include "ir_reader.h" #include "glsl_parser_extras.h" #include "glsl_types.h" @@ -34,155 +28,137 @@ extern "C" { const static bool debug = false; -static void ir_read_error(_mesa_glsl_parse_state *, s_expression *, - const char *fmt, ...); -static const glsl_type *read_type(_mesa_glsl_parse_state *, s_expression *); - -static void scan_for_prototypes(_mesa_glsl_parse_state *, exec_list *, - s_expression *); -static ir_function *read_function(_mesa_glsl_parse_state *, s_list *, - bool skip_body); -static void read_function_sig(_mesa_glsl_parse_state *, ir_function *, - s_list *, bool skip_body); - -static void read_instructions(_mesa_glsl_parse_state *, exec_list *, - s_expression *, ir_loop *); -static ir_instruction *read_instruction(_mesa_glsl_parse_state *, - s_expression *, ir_loop *); -static ir_variable *read_declaration(_mesa_glsl_parse_state *, s_list *); -static ir_if *read_if(_mesa_glsl_parse_state *, s_list *, ir_loop *); -static ir_loop *read_loop(_mesa_glsl_parse_state *st, s_list *list); -static ir_return *read_return(_mesa_glsl_parse_state *, s_list *); - -static ir_rvalue *read_rvalue(_mesa_glsl_parse_state *, s_expression *); -static ir_assignment *read_assignment(_mesa_glsl_parse_state *, s_list *); -static ir_expression *read_expression(_mesa_glsl_parse_state *, s_list *); -static ir_call *read_call(_mesa_glsl_parse_state *, s_list *); -static ir_swizzle *read_swizzle(_mesa_glsl_parse_state *, s_list *); -static ir_constant *read_constant(_mesa_glsl_parse_state *, s_list *); -static ir_texture *read_texture(_mesa_glsl_parse_state *, s_list *); - -static ir_dereference *read_dereference(_mesa_glsl_parse_state *, - s_expression *); -static ir_dereference_variable * -read_var_ref(_mesa_glsl_parse_state *, s_list *); -static ir_dereference_array * -read_array_ref(_mesa_glsl_parse_state *, s_list *); -static ir_dereference_record * -read_record_ref(_mesa_glsl_parse_state *, s_list *); +class ir_reader { +public: + ir_reader(_mesa_glsl_parse_state *); + + void read(exec_list *instructions, const char *src, bool scan_for_protos); + +private: + void *mem_ctx; + _mesa_glsl_parse_state *state; + + void ir_read_error(s_expression *, const char *fmt, ...); + + const glsl_type *read_type(s_expression *); + + void scan_for_prototypes(exec_list *, s_expression *); + ir_function *read_function(s_expression *, bool skip_body); + void read_function_sig(ir_function *, s_expression *, bool skip_body); + + void read_instructions(exec_list *, s_expression *, ir_loop *); + ir_instruction *read_instruction(s_expression *, ir_loop *); + ir_variable *read_declaration(s_expression *); + ir_if *read_if(s_expression *, ir_loop *); + ir_loop *read_loop(s_expression *); + ir_return *read_return(s_expression *); + ir_rvalue *read_rvalue(s_expression *); + ir_assignment *read_assignment(s_expression *); + ir_expression *read_expression(s_expression *); + ir_call *read_call(s_expression *); + ir_swizzle *read_swizzle(s_expression *); + ir_constant *read_constant(s_expression *); + ir_texture *read_texture(s_expression *); + + ir_dereference *read_dereference(s_expression *); +}; + +ir_reader::ir_reader(_mesa_glsl_parse_state *state) : state(state) +{ + this->mem_ctx = state; +} void _mesa_glsl_read_ir(_mesa_glsl_parse_state *state, exec_list *instructions, const char *src, bool scan_for_protos) { - s_expression *expr = s_expression::read_expression(state, src); + ir_reader r(state); + r.read(instructions, src, scan_for_protos); +} + +void +ir_reader::read(exec_list *instructions, const char *src, bool scan_for_protos) +{ + s_expression *expr = s_expression::read_expression(mem_ctx, src); if (expr == NULL) { - ir_read_error(state, NULL, "couldn't parse S-Expression."); + ir_read_error(NULL, "couldn't parse S-Expression."); return; } if (scan_for_protos) { - scan_for_prototypes(state, instructions, expr); + scan_for_prototypes(instructions, expr); if (state->error) return; } - read_instructions(state, instructions, expr, NULL); - talloc_free(expr); + read_instructions(instructions, expr, NULL); + ralloc_free(expr); if (debug) validate_ir_tree(instructions); } -static void -ir_read_error(_mesa_glsl_parse_state *state, s_expression *expr, - const char *fmt, ...) +void +ir_reader::ir_read_error(s_expression *expr, const char *fmt, ...) { va_list ap; state->error = true; if (state->current_function != NULL) - state->info_log = talloc_asprintf_append(state->info_log, - "In function %s:\n", - state->current_function->function_name()); - state->info_log = talloc_strdup_append(state->info_log, "error: "); + ralloc_asprintf_append(&state->info_log, "In function %s:\n", + state->current_function->function_name()); + ralloc_strcat(&state->info_log, "error: "); va_start(ap, fmt); - state->info_log = talloc_vasprintf_append(state->info_log, fmt, ap); + ralloc_vasprintf_append(&state->info_log, fmt, ap); va_end(ap); - state->info_log = talloc_strdup_append(state->info_log, "\n"); + ralloc_strcat(&state->info_log, "\n"); if (expr != NULL) { - state->info_log = talloc_strdup_append(state->info_log, - "...in this context:\n "); + ralloc_strcat(&state->info_log, "...in this context:\n "); expr->print(); - state->info_log = talloc_strdup_append(state->info_log, "\n\n"); + ralloc_strcat(&state->info_log, "\n\n"); } } -static const glsl_type * -read_type(_mesa_glsl_parse_state *st, s_expression *expr) +const glsl_type * +ir_reader::read_type(s_expression *expr) { - s_list *list = SX_AS_LIST(expr); - if (list != NULL) { - s_symbol *type_sym = SX_AS_SYMBOL(list->subexpressions.get_head()); - if (type_sym == NULL) { - ir_read_error(st, expr, "expected type (array ...) or (struct ...)"); + s_expression *s_base_type; + s_int *s_size; + + s_pattern pat[] = { "array", s_base_type, s_size }; + if (MATCH(expr, pat)) { + const glsl_type *base_type = read_type(s_base_type); + if (base_type == NULL) { + ir_read_error(NULL, "when reading base type of array type"); return NULL; } - if (strcmp(type_sym->value(), "array") == 0) { - if (list->length() != 3) { - ir_read_error(st, expr, "expected type (array <type> <int>)"); - return NULL; - } - // Read base type - s_expression *base_expr = (s_expression*) type_sym->next; - const glsl_type *base_type = read_type(st, base_expr); - if (base_type == NULL) { - ir_read_error(st, NULL, "when reading base type of array"); - return NULL; - } - - // Read array size - s_int *size = SX_AS_INT(base_expr->next); - if (size == NULL) { - ir_read_error(st, expr, "found non-integer array size"); - return NULL; - } - - return glsl_type::get_array_instance(base_type, size->value()); - } else if (strcmp(type_sym->value(), "struct") == 0) { - assert(false); // FINISHME - } else { - ir_read_error(st, expr, "expected (array ...) or (struct ...); " - "found (%s ...)", type_sym->value()); - return NULL; - } + return glsl_type::get_array_instance(base_type, s_size->value()); } s_symbol *type_sym = SX_AS_SYMBOL(expr); if (type_sym == NULL) { - ir_read_error(st, expr, "expected <type> (symbol or list)"); + ir_read_error(expr, "expected <type>"); return NULL; } - const glsl_type *type = st->symbols->get_type(type_sym->value()); + const glsl_type *type = state->symbols->get_type(type_sym->value()); if (type == NULL) - ir_read_error(st, expr, "invalid type: %s", type_sym->value()); + ir_read_error(expr, "invalid type: %s", type_sym->value()); return type; } -static void -scan_for_prototypes(_mesa_glsl_parse_state *st, exec_list *instructions, - s_expression *expr) +void +ir_reader::scan_for_prototypes(exec_list *instructions, s_expression *expr) { s_list *list = SX_AS_LIST(expr); if (list == NULL) { - ir_read_error(st, expr, "Expected (<instruction> ...); found an atom."); + ir_read_error(expr, "Expected (<instruction> ...); found an atom."); return; } @@ -195,94 +171,73 @@ scan_for_prototypes(_mesa_glsl_parse_state *st, exec_list *instructions, if (tag == NULL || strcmp(tag->value(), "function") != 0) continue; // not a (function ...); ignore it. - ir_function *f = read_function(st, sub, true); + ir_function *f = read_function(sub, true); if (f == NULL) return; instructions->push_tail(f); } } -static ir_function * -read_function(_mesa_glsl_parse_state *st, s_list *list, bool skip_body) +ir_function * +ir_reader::read_function(s_expression *expr, bool skip_body) { - void *ctx = st; bool added = false; - if (list->length() < 3) { - ir_read_error(st, list, "Expected (function <name> (signature ...) ...)"); - return NULL; - } + s_symbol *name; - s_symbol *name = SX_AS_SYMBOL(list->subexpressions.head->next); - if (name == NULL) { - ir_read_error(st, list, "Expected (function <name> ...)"); + s_pattern pat[] = { "function", name }; + if (!PARTIAL_MATCH(expr, pat)) { + ir_read_error(expr, "Expected (function <name> (signature ...) ...)"); return NULL; } - ir_function *f = st->symbols->get_function(name->value()); + ir_function *f = state->symbols->get_function(name->value()); if (f == NULL) { - f = new(ctx) ir_function(name->value()); - added = st->symbols->add_function(f); + f = new(mem_ctx) ir_function(name->value()); + added = state->symbols->add_function(f); assert(added); } - exec_list_iterator it = list->subexpressions.iterator(); + exec_list_iterator it = ((s_list *) expr)->subexpressions.iterator(); it.next(); // skip "function" tag it.next(); // skip function name for (/* nothing */; it.has_next(); it.next()) { - s_list *siglist = SX_AS_LIST(it.get()); - if (siglist == NULL) { - ir_read_error(st, list, "Expected (function (signature ...) ...)"); - return NULL; - } - - s_symbol *tag = SX_AS_SYMBOL(siglist->subexpressions.get_head()); - if (tag == NULL || strcmp(tag->value(), "signature") != 0) { - ir_read_error(st, siglist, "Expected (signature ...)"); - return NULL; - } - - read_function_sig(st, f, siglist, skip_body); + s_expression *s_sig = (s_expression *) it.get(); + read_function_sig(f, s_sig, skip_body); } return added ? f : NULL; } -static void -read_function_sig(_mesa_glsl_parse_state *st, ir_function *f, s_list *list, - bool skip_body) +void +ir_reader::read_function_sig(ir_function *f, s_expression *expr, bool skip_body) { - void *ctx = st; - if (list->length() != 4) { - ir_read_error(st, list, "Expected (signature <type> (parameters ...) " - "(<instruction> ...))"); + s_expression *type_expr; + s_list *paramlist; + s_list *body_list; + + s_pattern pat[] = { "signature", type_expr, paramlist, body_list }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "Expected (signature <type> (parameters ...) " + "(<instruction> ...))"); return; } - s_expression *type_expr = (s_expression*) list->subexpressions.head->next; - const glsl_type *return_type = read_type(st, type_expr); + const glsl_type *return_type = read_type(type_expr); if (return_type == NULL) return; - s_list *paramlist = SX_AS_LIST(type_expr->next); - s_list *body_list = SX_AS_LIST(type_expr->next->next); - if (paramlist == NULL || body_list == NULL) { - ir_read_error(st, list, "Expected (signature <type> (parameters ...) " - "(<instruction> ...))"); - return; - } s_symbol *paramtag = SX_AS_SYMBOL(paramlist->subexpressions.get_head()); if (paramtag == NULL || strcmp(paramtag->value(), "parameters") != 0) { - ir_read_error(st, paramlist, "Expected (parameters ...)"); + ir_read_error(paramlist, "Expected (parameters ...)"); return; } // Read the parameters list into a temporary place. exec_list hir_parameters; - st->symbols->push_scope(); + state->symbols->push_scope(); exec_list_iterator it = paramlist->subexpressions.iterator(); for (it.next() /* skip "parameters" */; it.has_next(); it.next()) { - s_list *decl = SX_AS_LIST(it.get()); - ir_variable *var = read_declaration(st, decl); + ir_variable *var = read_declaration((s_expression *) it.get()); if (var == NULL) return; @@ -292,25 +247,25 @@ read_function_sig(_mesa_glsl_parse_state *st, ir_function *f, s_list *list, ir_function_signature *sig = f->exact_matching_signature(&hir_parameters); if (sig == NULL && skip_body) { /* If scanning for prototypes, generate a new signature. */ - sig = new(ctx) ir_function_signature(return_type); + sig = new(mem_ctx) ir_function_signature(return_type); sig->is_builtin = true; f->add_signature(sig); } else if (sig != NULL) { const char *badvar = sig->qualifiers_match(&hir_parameters); if (badvar != NULL) { - ir_read_error(st, list, "function `%s' parameter `%s' qualifiers " + ir_read_error(expr, "function `%s' parameter `%s' qualifiers " "don't match prototype", f->name, badvar); return; } if (sig->return_type != return_type) { - ir_read_error(st, list, "function `%s' return type doesn't " + ir_read_error(expr, "function `%s' return type doesn't " "match prototype", f->name); return; } } else { /* No prototype for this body exists - skip it. */ - st->symbols->pop_scope(); + state->symbols->pop_scope(); return; } assert(sig != NULL); @@ -319,39 +274,39 @@ read_function_sig(_mesa_glsl_parse_state *st, ir_function *f, s_list *list, if (!skip_body && !body_list->subexpressions.is_empty()) { if (sig->is_defined) { - ir_read_error(st, list, "function %s redefined", f->name); + ir_read_error(expr, "function %s redefined", f->name); return; } - st->current_function = sig; - read_instructions(st, &sig->body, body_list, NULL); - st->current_function = NULL; + state->current_function = sig; + read_instructions(&sig->body, body_list, NULL); + state->current_function = NULL; sig->is_defined = true; } - st->symbols->pop_scope(); + state->symbols->pop_scope(); } -static void -read_instructions(_mesa_glsl_parse_state *st, exec_list *instructions, - s_expression *expr, ir_loop *loop_ctx) +void +ir_reader::read_instructions(exec_list *instructions, s_expression *expr, + ir_loop *loop_ctx) { // Read in a list of instructions s_list *list = SX_AS_LIST(expr); if (list == NULL) { - ir_read_error(st, expr, "Expected (<instruction> ...); found an atom."); + ir_read_error(expr, "Expected (<instruction> ...); found an atom."); return; } foreach_iter(exec_list_iterator, it, list->subexpressions) { s_expression *sub = (s_expression*) it.get(); - ir_instruction *ir = read_instruction(st, sub, loop_ctx); + ir_instruction *ir = read_instruction(sub, loop_ctx); if (ir != NULL) { /* Global variable declarations should be moved to the top, before * any functions that might use them. Functions are added to the * instruction stream when scanning for prototypes, so without this * hack, they always appear before variable declarations. */ - if (st->current_function == NULL && ir->as_variable() != NULL) + if (state->current_function == NULL && ir->as_variable() != NULL) instructions->push_head(ir); else instructions->push_tail(ir); @@ -360,88 +315,74 @@ read_instructions(_mesa_glsl_parse_state *st, exec_list *instructions, } -static ir_instruction * -read_instruction(_mesa_glsl_parse_state *st, s_expression *expr, - ir_loop *loop_ctx) +ir_instruction * +ir_reader::read_instruction(s_expression *expr, ir_loop *loop_ctx) { - void *ctx = st; s_symbol *symbol = SX_AS_SYMBOL(expr); if (symbol != NULL) { if (strcmp(symbol->value(), "break") == 0 && loop_ctx != NULL) - return new(ctx) ir_loop_jump(ir_loop_jump::jump_break); + return new(mem_ctx) ir_loop_jump(ir_loop_jump::jump_break); if (strcmp(symbol->value(), "continue") == 0 && loop_ctx != NULL) - return new(ctx) ir_loop_jump(ir_loop_jump::jump_continue); + return new(mem_ctx) ir_loop_jump(ir_loop_jump::jump_continue); } s_list *list = SX_AS_LIST(expr); if (list == NULL || list->subexpressions.is_empty()) { - ir_read_error(st, expr, "Invalid instruction.\n"); + ir_read_error(expr, "Invalid instruction.\n"); return NULL; } s_symbol *tag = SX_AS_SYMBOL(list->subexpressions.get_head()); if (tag == NULL) { - ir_read_error(st, expr, "expected instruction tag"); + ir_read_error(expr, "expected instruction tag"); return NULL; } ir_instruction *inst = NULL; if (strcmp(tag->value(), "declare") == 0) { - inst = read_declaration(st, list); + inst = read_declaration(list); } else if (strcmp(tag->value(), "assign") == 0) { - inst = read_assignment(st, list); + inst = read_assignment(list); } else if (strcmp(tag->value(), "if") == 0) { - inst = read_if(st, list, loop_ctx); + inst = read_if(list, loop_ctx); } else if (strcmp(tag->value(), "loop") == 0) { - inst = read_loop(st, list); + inst = read_loop(list); } else if (strcmp(tag->value(), "return") == 0) { - inst = read_return(st, list); + inst = read_return(list); } else if (strcmp(tag->value(), "function") == 0) { - inst = read_function(st, list, false); + inst = read_function(list, false); } else { - inst = read_rvalue(st, list); + inst = read_rvalue(list); if (inst == NULL) - ir_read_error(st, NULL, "when reading instruction"); + ir_read_error(NULL, "when reading instruction"); } return inst; } - -static ir_variable * -read_declaration(_mesa_glsl_parse_state *st, s_list *list) +ir_variable * +ir_reader::read_declaration(s_expression *expr) { - void *ctx = st; - if (list->length() != 4) { - ir_read_error(st, list, "expected (declare (<qualifiers>) <type> " - "<name>)"); - return NULL; - } + s_list *s_quals; + s_expression *s_type; + s_symbol *s_name; - s_list *quals = SX_AS_LIST(list->subexpressions.head->next); - if (quals == NULL) { - ir_read_error(st, list, "expected a list of variable qualifiers"); + s_pattern pat[] = { "declare", s_quals, s_type, s_name }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (declare (<qualifiers>) <type> <name>)"); return NULL; } - s_expression *type_expr = (s_expression*) quals->next; - const glsl_type *type = read_type(st, type_expr); + const glsl_type *type = read_type(s_type); if (type == NULL) return NULL; - s_symbol *var_name = SX_AS_SYMBOL(type_expr->next); - if (var_name == NULL) { - ir_read_error(st, list, "expected variable name, found non-symbol"); - return NULL; - } - - ir_variable *var = new(ctx) ir_variable(type, var_name->value(), - ir_var_auto); + ir_variable *var = new(mem_ctx) ir_variable(type, s_name->value(), + ir_var_auto); - foreach_iter(exec_list_iterator, it, quals->subexpressions) { + foreach_iter(exec_list_iterator, it, s_quals->subexpressions) { s_symbol *qualifier = SX_AS_SYMBOL(it.get()); if (qualifier == NULL) { - ir_read_error(st, list, "qualifier list must contain only symbols"); - delete var; + ir_read_error(expr, "qualifier list must contain only symbols"); return NULL; } @@ -456,6 +397,8 @@ read_declaration(_mesa_glsl_parse_state *st, s_list *list) var->mode = ir_var_auto; } else if (strcmp(qualifier->value(), "in") == 0) { var->mode = ir_var_in; + } else if (strcmp(qualifier->value(), "const_in") == 0) { + var->mode = ir_var_const_in; } else if (strcmp(qualifier->value(), "out") == 0) { var->mode = ir_var_out; } else if (strcmp(qualifier->value(), "inout") == 0) { @@ -467,44 +410,42 @@ read_declaration(_mesa_glsl_parse_state *st, s_list *list) } else if (strcmp(qualifier->value(), "noperspective") == 0) { var->interpolation = ir_var_noperspective; } else { - ir_read_error(st, list, "unknown qualifier: %s", qualifier->value()); - delete var; + ir_read_error(expr, "unknown qualifier: %s", qualifier->value()); return NULL; } } // Add the variable to the symbol table - st->symbols->add_variable(var); + state->symbols->add_variable(var); return var; } -static ir_if * -read_if(_mesa_glsl_parse_state *st, s_list *list, ir_loop *loop_ctx) +ir_if * +ir_reader::read_if(s_expression *expr, ir_loop *loop_ctx) { - void *ctx = st; - if (list->length() != 4) { - ir_read_error(st, list, "expected (if <condition> (<then> ...) " - "(<else> ...))"); + s_expression *s_cond; + s_expression *s_then; + s_expression *s_else; + + s_pattern pat[] = { "if", s_cond, s_then, s_else }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (if <condition> (<then>...) (<else>...))"); return NULL; } - s_expression *cond_expr = (s_expression*) list->subexpressions.head->next; - ir_rvalue *condition = read_rvalue(st, cond_expr); + ir_rvalue *condition = read_rvalue(s_cond); if (condition == NULL) { - ir_read_error(st, NULL, "when reading condition of (if ...)"); + ir_read_error(NULL, "when reading condition of (if ...)"); return NULL; } - s_expression *then_expr = (s_expression*) cond_expr->next; - s_expression *else_expr = (s_expression*) then_expr->next; - - ir_if *iff = new(ctx) ir_if(condition); + ir_if *iff = new(mem_ctx) ir_if(condition); - read_instructions(st, &iff->then_instructions, then_expr, loop_ctx); - read_instructions(st, &iff->else_instructions, else_expr, loop_ctx); - if (st->error) { + read_instructions(&iff->then_instructions, s_then, loop_ctx); + read_instructions(&iff->else_instructions, s_else, loop_ctx); + if (state->error) { delete iff; iff = NULL; } @@ -512,27 +453,23 @@ read_if(_mesa_glsl_parse_state *st, s_list *list, ir_loop *loop_ctx) } -static ir_loop * -read_loop(_mesa_glsl_parse_state *st, s_list *list) +ir_loop * +ir_reader::read_loop(s_expression *expr) { - void *ctx = st; - if (list->length() != 6) { - ir_read_error(st, list, "expected (loop <counter> <from> <to> " - "<increment> <body>)"); + s_expression *s_counter, *s_from, *s_to, *s_inc, *s_body; + + s_pattern pat[] = { "loop", s_counter, s_from, s_to, s_inc, s_body }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (loop <counter> <from> <to> " + "<increment> <body>)"); return NULL; } - s_expression *count_expr = (s_expression*) list->subexpressions.head->next; - s_expression *from_expr = (s_expression*) count_expr->next; - s_expression *to_expr = (s_expression*) from_expr->next; - s_expression *inc_expr = (s_expression*) to_expr->next; - s_expression *body_expr = (s_expression*) inc_expr->next; - // FINISHME: actually read the count/from/to fields. - ir_loop *loop = new(ctx) ir_loop; - read_instructions(st, &loop->body_instructions, body_expr, loop); - if (st->error) { + ir_loop *loop = new(mem_ctx) ir_loop; + read_instructions(&loop->body_instructions, s_body, loop); + if (state->error) { delete loop; loop = NULL; } @@ -540,29 +477,29 @@ read_loop(_mesa_glsl_parse_state *st, s_list *list) } -static ir_return * -read_return(_mesa_glsl_parse_state *st, s_list *list) +ir_return * +ir_reader::read_return(s_expression *expr) { - void *ctx = st; - if (list->length() != 2) { - ir_read_error(st, list, "expected (return <rvalue>)"); + s_expression *s_retval; + + s_pattern pat[] = { "return", s_retval}; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (return <rvalue>)"); return NULL; } - s_expression *expr = (s_expression*) list->subexpressions.head->next; - - ir_rvalue *retval = read_rvalue(st, expr); + ir_rvalue *retval = read_rvalue(s_retval); if (retval == NULL) { - ir_read_error(st, NULL, "when reading return value"); + ir_read_error(NULL, "when reading return value"); return NULL; } - return new(ctx) ir_return(retval); + return new(mem_ctx) ir_return(retval); } -static ir_rvalue * -read_rvalue(_mesa_glsl_parse_state *st, s_expression *expr) +ir_rvalue * +ir_reader::read_rvalue(s_expression *expr) { s_list *list = SX_AS_LIST(expr); if (list == NULL || list->subexpressions.is_empty()) @@ -570,68 +507,63 @@ read_rvalue(_mesa_glsl_parse_state *st, s_expression *expr) s_symbol *tag = SX_AS_SYMBOL(list->subexpressions.get_head()); if (tag == NULL) { - ir_read_error(st, expr, "expected rvalue tag"); + ir_read_error(expr, "expected rvalue tag"); return NULL; } - ir_rvalue *rvalue = read_dereference(st, list); - if (rvalue != NULL || st->error) + ir_rvalue *rvalue = read_dereference(list); + if (rvalue != NULL || state->error) return rvalue; else if (strcmp(tag->value(), "swiz") == 0) { - rvalue = read_swizzle(st, list); + rvalue = read_swizzle(list); } else if (strcmp(tag->value(), "expression") == 0) { - rvalue = read_expression(st, list); + rvalue = read_expression(list); } else if (strcmp(tag->value(), "call") == 0) { - rvalue = read_call(st, list); + rvalue = read_call(list); } else if (strcmp(tag->value(), "constant") == 0) { - rvalue = read_constant(st, list); + rvalue = read_constant(list); } else { - rvalue = read_texture(st, list); - if (rvalue == NULL && !st->error) - ir_read_error(st, expr, "unrecognized rvalue tag: %s", tag->value()); + rvalue = read_texture(list); + if (rvalue == NULL && !state->error) + ir_read_error(expr, "unrecognized rvalue tag: %s", tag->value()); } return rvalue; } -static ir_assignment * -read_assignment(_mesa_glsl_parse_state *st, s_list *list) +ir_assignment * +ir_reader::read_assignment(s_expression *expr) { - void *ctx = st; - if (list->length() != 5) { - ir_read_error(st, list, "expected (assign <condition> (<write mask>) " - "<lhs> <rhs>)"); - return NULL; - } + s_expression *cond_expr = NULL; + s_expression *lhs_expr, *rhs_expr; + s_list *mask_list; - s_expression *cond_expr = (s_expression*) list->subexpressions.head->next; - s_list *mask_list = SX_AS_LIST(cond_expr->next); - s_expression *lhs_expr = (s_expression*) cond_expr->next->next; - s_expression *rhs_expr = (s_expression*) lhs_expr->next; - - ir_rvalue *condition = read_rvalue(st, cond_expr); - if (condition == NULL) { - ir_read_error(st, NULL, "when reading condition of assignment"); + s_pattern pat4[] = { "assign", mask_list, lhs_expr, rhs_expr }; + s_pattern pat5[] = { "assign", cond_expr, mask_list, lhs_expr, rhs_expr }; + if (!MATCH(expr, pat4) && !MATCH(expr, pat5)) { + ir_read_error(expr, "expected (assign [<condition>] (<write mask>) " + "<lhs> <rhs>)"); return NULL; } - if (mask_list == NULL || mask_list->length() > 1) { - ir_read_error(st, mask_list, "expected () or (<write mask>)"); - return NULL; + ir_rvalue *condition = NULL; + if (cond_expr != NULL) { + condition = read_rvalue(cond_expr); + if (condition == NULL) { + ir_read_error(NULL, "when reading condition of assignment"); + return NULL; + } } unsigned mask = 0; - if (mask_list->length() == 1) { - s_symbol *mask_symbol = SX_AS_SYMBOL(mask_list->subexpressions.head); - if (mask_symbol == NULL) { - ir_read_error(st, list, "expected a write mask; found non-symbol"); - return NULL; - } + s_symbol *mask_symbol; + s_pattern mask_pat[] = { mask_symbol }; + if (MATCH(mask_list, mask_pat)) { const char *mask_str = mask_symbol->value(); unsigned mask_length = strlen(mask_str); if (mask_length > 4) { - ir_read_error(st, list, "invalid write mask: %s", mask_str); + ir_read_error(expr, "invalid write mask: %s", mask_str); return NULL; } @@ -639,47 +571,46 @@ read_assignment(_mesa_glsl_parse_state *st, s_list *list) for (unsigned i = 0; i < mask_length; i++) { if (mask_str[i] < 'w' || mask_str[i] > 'z') { - ir_read_error(st, list, "write mask contains invalid character: %c", + ir_read_error(expr, "write mask contains invalid character: %c", mask_str[i]); return NULL; } mask |= 1 << idx_map[mask_str[i] - 'w']; } + } else if (!mask_list->subexpressions.is_empty()) { + ir_read_error(mask_list, "expected () or (<write mask>)"); + return NULL; } - ir_dereference *lhs = read_dereference(st, lhs_expr); + ir_dereference *lhs = read_dereference(lhs_expr); if (lhs == NULL) { - ir_read_error(st, NULL, "when reading left-hand side of assignment"); + ir_read_error(NULL, "when reading left-hand side of assignment"); return NULL; } - ir_rvalue *rhs = read_rvalue(st, rhs_expr); + ir_rvalue *rhs = read_rvalue(rhs_expr); if (rhs == NULL) { - ir_read_error(st, NULL, "when reading right-hand side of assignment"); + ir_read_error(NULL, "when reading right-hand side of assignment"); return NULL; } if (mask == 0 && (lhs->type->is_vector() || lhs->type->is_scalar())) { - ir_read_error(st, list, "non-zero write mask required."); + ir_read_error(expr, "non-zero write mask required."); return NULL; } - return new(ctx) ir_assignment(lhs, rhs, condition, mask); + return new(mem_ctx) ir_assignment(lhs, rhs, condition, mask); } -static ir_call * -read_call(_mesa_glsl_parse_state *st, s_list *list) +ir_call * +ir_reader::read_call(s_expression *expr) { - void *ctx = st; - if (list->length() != 3) { - ir_read_error(st, list, "expected (call <name> (<param> ...))"); - return NULL; - } + s_symbol *name; + s_list *params; - s_symbol *name = SX_AS_SYMBOL(list->subexpressions.head->next); - s_list *params = SX_AS_LIST(list->subexpressions.head->next->next); - if (name == NULL || params == NULL) { - ir_read_error(st, list, "expected (call <name> (<param> ...))"); + s_pattern pat[] = { "call", name, params }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (call <name> (<param> ...))"); return NULL; } @@ -687,173 +618,156 @@ read_call(_mesa_glsl_parse_state *st, s_list *list) foreach_iter(exec_list_iterator, it, params->subexpressions) { s_expression *expr = (s_expression*) it.get(); - ir_rvalue *param = read_rvalue(st, expr); + ir_rvalue *param = read_rvalue(expr); if (param == NULL) { - ir_read_error(st, list, "when reading parameter to function call"); + ir_read_error(expr, "when reading parameter to function call"); return NULL; } parameters.push_tail(param); } - ir_function *f = st->symbols->get_function(name->value()); + ir_function *f = state->symbols->get_function(name->value()); if (f == NULL) { - ir_read_error(st, list, "found call to undefined function %s", + ir_read_error(expr, "found call to undefined function %s", name->value()); return NULL; } ir_function_signature *callee = f->matching_signature(¶meters); if (callee == NULL) { - ir_read_error(st, list, "couldn't find matching signature for function " + ir_read_error(expr, "couldn't find matching signature for function " "%s", name->value()); return NULL; } - return new(ctx) ir_call(callee, ¶meters); + return new(mem_ctx) ir_call(callee, ¶meters); } -static ir_expression * -read_expression(_mesa_glsl_parse_state *st, s_list *list) +ir_expression * +ir_reader::read_expression(s_expression *expr) { - void *ctx = st; - const unsigned list_length = list->length(); - if (list_length < 4) { - ir_read_error(st, list, "expected (expression <type> <operator> " - "<operand> [<operand>])"); + s_expression *s_type; + s_symbol *s_op; + s_expression *s_arg1; + + s_pattern pat[] = { "expression", s_type, s_op, s_arg1 }; + if (!PARTIAL_MATCH(expr, pat)) { + ir_read_error(expr, "expected (expression <type> <operator> " + "<operand> [<operand>])"); return NULL; } + s_expression *s_arg2 = (s_expression *) s_arg1->next; // may be tail sentinel - s_expression *type_expr = (s_expression*) list->subexpressions.head->next; - const glsl_type *type = read_type(st, type_expr); + const glsl_type *type = read_type(s_type); if (type == NULL) return NULL; /* Read the operator */ - s_symbol *op_sym = SX_AS_SYMBOL(type_expr->next); - if (op_sym == NULL) { - ir_read_error(st, list, "expected operator, found non-symbol"); - return NULL; - } - - ir_expression_operation op = ir_expression::get_operator(op_sym->value()); + ir_expression_operation op = ir_expression::get_operator(s_op->value()); if (op == (ir_expression_operation) -1) { - ir_read_error(st, list, "invalid operator: %s", op_sym->value()); + ir_read_error(expr, "invalid operator: %s", s_op->value()); return NULL; } - /* Now that we know the operator, check for the right number of operands */ - if (ir_expression::get_num_operands(op) == 2) { - if (list_length != 5) { - ir_read_error(st, list, "expected (expression <type> %s <operand> " - " <operand>)", op_sym->value()); - return NULL; - } - } else { - if (list_length != 4) { - ir_read_error(st, list, "expected (expression <type> %s <operand>)", - op_sym->value()); - return NULL; - } + unsigned num_operands = ir_expression::get_num_operands(op); + if (num_operands == 1 && !s_arg1->next->is_tail_sentinel()) { + ir_read_error(expr, "expected (expression <type> %s <operand>)", + s_op->value()); + return NULL; } - s_expression *exp1 = (s_expression*) (op_sym->next); - ir_rvalue *arg1 = read_rvalue(st, exp1); + ir_rvalue *arg1 = read_rvalue(s_arg1); + ir_rvalue *arg2 = NULL; if (arg1 == NULL) { - ir_read_error(st, NULL, "when reading first operand of %s", - op_sym->value()); + ir_read_error(NULL, "when reading first operand of %s", s_op->value()); return NULL; } - ir_rvalue *arg2 = NULL; - if (ir_expression::get_num_operands(op) == 2) { - s_expression *exp2 = (s_expression*) (exp1->next); - arg2 = read_rvalue(st, exp2); + if (num_operands == 2) { + if (s_arg2->is_tail_sentinel() || !s_arg2->next->is_tail_sentinel()) { + ir_read_error(expr, "expected (expression <type> %s <operand> " + "<operand>)", s_op->value()); + return NULL; + } + arg2 = read_rvalue(s_arg2); if (arg2 == NULL) { - ir_read_error(st, NULL, "when reading second operand of %s", - op_sym->value()); + ir_read_error(NULL, "when reading second operand of %s", + s_op->value()); return NULL; } } - return new(ctx) ir_expression(op, type, arg1, arg2); + return new(mem_ctx) ir_expression(op, type, arg1, arg2); } -static ir_swizzle * -read_swizzle(_mesa_glsl_parse_state *st, s_list *list) +ir_swizzle * +ir_reader::read_swizzle(s_expression *expr) { - if (list->length() != 3) { - ir_read_error(st, list, "expected (swiz <swizzle> <rvalue>)"); - return NULL; - } + s_symbol *swiz; + s_expression *sub; - s_symbol *swiz = SX_AS_SYMBOL(list->subexpressions.head->next); - if (swiz == NULL) { - ir_read_error(st, list, "expected a valid swizzle; found non-symbol"); + s_pattern pat[] = { "swiz", swiz, sub }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (swiz <swizzle> <rvalue>)"); return NULL; } if (strlen(swiz->value()) > 4) { - ir_read_error(st, list, "expected a valid swizzle; found %s", - swiz->value()); + ir_read_error(expr, "expected a valid swizzle; found %s", swiz->value()); return NULL; } - s_expression *sub = (s_expression*) swiz->next; - ir_rvalue *rvalue = read_rvalue(st, sub); + ir_rvalue *rvalue = read_rvalue(sub); if (rvalue == NULL) return NULL; ir_swizzle *ir = ir_swizzle::create(rvalue, swiz->value(), rvalue->type->vector_elements); if (ir == NULL) - ir_read_error(st, list, "invalid swizzle"); + ir_read_error(expr, "invalid swizzle"); return ir; } -static ir_constant * -read_constant(_mesa_glsl_parse_state *st, s_list *list) +ir_constant * +ir_reader::read_constant(s_expression *expr) { - void *ctx = st; - if (list->length() != 3) { - ir_read_error(st, list, "expected (constant <type> (...))"); + s_expression *type_expr; + s_list *values; + + s_pattern pat[] = { "constant", type_expr, values }; + if (!MATCH(expr, pat)) { + ir_read_error(expr, "expected (constant <type> (...))"); return NULL; } - s_expression *type_expr = (s_expression*) list->subexpressions.head->next; - const glsl_type *type = read_type(st, type_expr); + const glsl_type *type = read_type(type_expr); if (type == NULL) return NULL; - s_list *values = SX_AS_LIST(type_expr->next); if (values == NULL) { - ir_read_error(st, list, "expected (constant <type> (...))"); + ir_read_error(expr, "expected (constant <type> (...))"); return NULL; } if (type->is_array()) { - const unsigned elements_supplied = values->length(); - if (elements_supplied != type->length) { - ir_read_error(st, values, "expected exactly %u array elements, " - "given %u", type->length, elements_supplied); - return NULL; - } - + unsigned elements_supplied = 0; exec_list elements; foreach_iter(exec_list_iterator, it, values->subexpressions) { - s_expression *expr = (s_expression *) it.get(); - s_list *elt = SX_AS_LIST(expr); - if (elt == NULL) { - ir_read_error(st, expr, "expected (constant ...) array element"); - return NULL; - } - - ir_constant *ir_elt = read_constant(st, elt); + s_expression *elt = (s_expression *) it.get(); + ir_constant *ir_elt = read_constant(elt); if (ir_elt == NULL) return NULL; elements.push_tail(ir_elt); + elements_supplied++; + } + + if (elements_supplied != type->length) { + ir_read_error(values, "expected exactly %u array elements, " + "given %u", type->length, elements_supplied); + return NULL; } - return new(ctx) ir_constant(type, &elements); + return new(mem_ctx) ir_constant(type, &elements); } const glsl_type *const base_type = type->get_base_type(); @@ -864,7 +778,7 @@ read_constant(_mesa_glsl_parse_state *st, s_list *list) int k = 0; foreach_iter(exec_list_iterator, it, values->subexpressions) { if (k >= 16) { - ir_read_error(st, values, "expected at most 16 numbers"); + ir_read_error(values, "expected at most 16 numbers"); return NULL; } @@ -873,14 +787,14 @@ read_constant(_mesa_glsl_parse_state *st, s_list *list) if (base_type->base_type == GLSL_TYPE_FLOAT) { s_number *value = SX_AS_NUMBER(expr); if (value == NULL) { - ir_read_error(st, values, "expected numbers"); + ir_read_error(values, "expected numbers"); return NULL; } data.f[k] = value->fvalue(); } else { s_int *value = SX_AS_INT(expr); if (value == NULL) { - ir_read_error(st, values, "expected integers"); + ir_read_error(values, "expected integers"); return NULL; } @@ -898,246 +812,194 @@ read_constant(_mesa_glsl_parse_state *st, s_list *list) break; } default: - ir_read_error(st, values, "unsupported constant type"); + ir_read_error(values, "unsupported constant type"); return NULL; } } ++k; } - return new(ctx) ir_constant(type, &data); + return new(mem_ctx) ir_constant(type, &data); } -static ir_dereference * -read_dereference(_mesa_glsl_parse_state *st, s_expression *expr) +ir_dereference * +ir_reader::read_dereference(s_expression *expr) { - s_list *list = SX_AS_LIST(expr); - if (list == NULL || list->subexpressions.is_empty()) - return NULL; - - s_symbol *tag = SX_AS_SYMBOL(list->subexpressions.head); - assert(tag != NULL); - - if (strcmp(tag->value(), "var_ref") == 0) - return read_var_ref(st, list); - if (strcmp(tag->value(), "array_ref") == 0) - return read_array_ref(st, list); - if (strcmp(tag->value(), "record_ref") == 0) - return read_record_ref(st, list); - return NULL; -} - -static ir_dereference_variable * -read_var_ref(_mesa_glsl_parse_state *st, s_list *list) -{ - void *ctx = st; - if (list->length() != 2) { - ir_read_error(st, list, "expected (var_ref <variable name>)"); - return NULL; - } - s_symbol *var_name = SX_AS_SYMBOL(list->subexpressions.head->next); - if (var_name == NULL) { - ir_read_error(st, list, "expected (var_ref <variable name>)"); - return NULL; - } - - ir_variable *var = st->symbols->get_variable(var_name->value()); - if (var == NULL) { - ir_read_error(st, list, "undeclared variable: %s", var_name->value()); - return NULL; - } - - return new(ctx) ir_dereference_variable(var); -} - -static ir_dereference_array * -read_array_ref(_mesa_glsl_parse_state *st, s_list *list) -{ - void *ctx = st; - if (list->length() != 3) { - ir_read_error(st, list, "expected (array_ref <rvalue> <index>)"); - return NULL; - } + s_symbol *s_var; + s_expression *s_subject; + s_expression *s_index; + s_symbol *s_field; + + s_pattern var_pat[] = { "var_ref", s_var }; + s_pattern array_pat[] = { "array_ref", s_subject, s_index }; + s_pattern record_pat[] = { "record_ref", s_subject, s_field }; + + if (MATCH(expr, var_pat)) { + ir_variable *var = state->symbols->get_variable(s_var->value()); + if (var == NULL) { + ir_read_error(expr, "undeclared variable: %s", s_var->value()); + return NULL; + } + return new(mem_ctx) ir_dereference_variable(var); + } else if (MATCH(expr, array_pat)) { + ir_rvalue *subject = read_rvalue(s_subject); + if (subject == NULL) { + ir_read_error(NULL, "when reading the subject of an array_ref"); + return NULL; + } - s_expression *subj_expr = (s_expression*) list->subexpressions.head->next; - ir_rvalue *subject = read_rvalue(st, subj_expr); - if (subject == NULL) { - ir_read_error(st, NULL, "when reading the subject of an array_ref"); - return NULL; + ir_rvalue *idx = read_rvalue(s_index); + if (subject == NULL) { + ir_read_error(NULL, "when reading the index of an array_ref"); + return NULL; + } + return new(mem_ctx) ir_dereference_array(subject, idx); + } else if (MATCH(expr, record_pat)) { + ir_rvalue *subject = read_rvalue(s_subject); + if (subject == NULL) { + ir_read_error(NULL, "when reading the subject of a record_ref"); + return NULL; + } + return new(mem_ctx) ir_dereference_record(subject, s_field->value()); } - - s_expression *idx_expr = (s_expression*) subj_expr->next; - ir_rvalue *idx = read_rvalue(st, idx_expr); - return new(ctx) ir_dereference_array(subject, idx); + return NULL; } -static ir_dereference_record * -read_record_ref(_mesa_glsl_parse_state *st, s_list *list) +ir_texture * +ir_reader::read_texture(s_expression *expr) { - void *ctx = st; - if (list->length() != 3) { - ir_read_error(st, list, "expected (record_ref <rvalue> <field>)"); - return NULL; - } - - s_expression *subj_expr = (s_expression*) list->subexpressions.head->next; - ir_rvalue *subject = read_rvalue(st, subj_expr); - if (subject == NULL) { - ir_read_error(st, NULL, "when reading the subject of a record_ref"); - return NULL; - } - - s_symbol *field = SX_AS_SYMBOL(subj_expr->next); - if (field == NULL) { - ir_read_error(st, list, "expected (record_ref ... <field name>)"); + s_symbol *tag = NULL; + s_expression *s_type = NULL; + s_expression *s_sampler = NULL; + s_expression *s_coord = NULL; + s_expression *s_offset = NULL; + s_expression *s_proj = NULL; + s_list *s_shadow = NULL; + s_expression *s_lod = NULL; + + ir_texture_opcode op = ir_tex; /* silence warning */ + + s_pattern tex_pattern[] = + { "tex", s_type, s_sampler, s_coord, s_offset, s_proj, s_shadow }; + s_pattern txf_pattern[] = + { "txf", s_type, s_sampler, s_coord, s_offset, s_lod }; + s_pattern other_pattern[] = + { tag, s_type, s_sampler, s_coord, s_offset, s_proj, s_shadow, s_lod }; + + if (MATCH(expr, tex_pattern)) { + op = ir_tex; + } else if (MATCH(expr, txf_pattern)) { + op = ir_txf; + } else if (MATCH(expr, other_pattern)) { + op = ir_texture::get_opcode(tag->value()); + if (op == -1) + return NULL; + } else { + ir_read_error(NULL, "unexpected texture pattern"); return NULL; } - return new(ctx) ir_dereference_record(subject, field->value()); -} - -static bool -valid_texture_list_length(ir_texture_opcode op, s_list *list) -{ - unsigned required_length = 7; - if (op == ir_txf) - required_length = 5; - else if (op == ir_tex) - required_length = 6; - return list->length() == required_length; -} - -static ir_texture * -read_texture(_mesa_glsl_parse_state *st, s_list *list) -{ - void *ctx = st; - s_symbol *tag = SX_AS_SYMBOL(list->subexpressions.head); - assert(tag != NULL); + ir_texture *tex = new(mem_ctx) ir_texture(op); - ir_texture_opcode op = ir_texture::get_opcode(tag->value()); - if (op == (ir_texture_opcode) -1) - return NULL; - - if (!valid_texture_list_length(op, list)) { - ir_read_error(st, NULL, "invalid list size in (%s ...)", tag->value()); + // Read return type + const glsl_type *type = read_type(s_type); + if (type == NULL) { + ir_read_error(NULL, "when reading type in (%s ...)", + tex->opcode_string()); return NULL; } - ir_texture *tex = new(ctx) ir_texture(op); - // Read sampler (must be a deref) - s_expression *sampler_expr = (s_expression *) tag->next; - ir_dereference *sampler = read_dereference(st, sampler_expr); + ir_dereference *sampler = read_dereference(s_sampler); if (sampler == NULL) { - ir_read_error(st, NULL, "when reading sampler in (%s ...)", tag->value()); + ir_read_error(NULL, "when reading sampler in (%s ...)", + tex->opcode_string()); return NULL; } - tex->set_sampler(sampler); + tex->set_sampler(sampler, type); // Read coordinate (any rvalue) - s_expression *coordinate_expr = (s_expression *) sampler_expr->next; - tex->coordinate = read_rvalue(st, coordinate_expr); + tex->coordinate = read_rvalue(s_coord); if (tex->coordinate == NULL) { - ir_read_error(st, NULL, "when reading coordinate in (%s ...)", - tag->value()); + ir_read_error(NULL, "when reading coordinate in (%s ...)", + tex->opcode_string()); return NULL; } - // Read texel offset, i.e. (0 0 0) - s_list *offset_list = SX_AS_LIST(coordinate_expr->next); - if (offset_list == NULL || offset_list->length() != 3) { - ir_read_error(st, offset_list, "expected (<int> <int> <int>)"); - return NULL; - } - s_int *offset_x = SX_AS_INT(offset_list->subexpressions.head); - s_int *offset_y = SX_AS_INT(offset_list->subexpressions.head->next); - s_int *offset_z = SX_AS_INT(offset_list->subexpressions.head->next->next); - if (offset_x == NULL || offset_y == NULL || offset_z == NULL) { - ir_read_error(st, offset_list, "expected (<int> <int> <int>)"); - return NULL; - } - tex->offsets[0] = offset_x->value(); - tex->offsets[1] = offset_y->value(); - tex->offsets[2] = offset_z->value(); - - if (op == ir_txf) { - s_expression *lod_expr = (s_expression *) offset_list->next; - tex->lod_info.lod = read_rvalue(st, lod_expr); - if (tex->lod_info.lod == NULL) { - ir_read_error(st, NULL, "when reading LOD in (txf ...)"); + // Read texel offset - either 0 or an rvalue. + s_int *si_offset = SX_AS_INT(s_offset); + if (si_offset == NULL || si_offset->value() != 0) { + tex->offset = read_rvalue(s_offset); + if (tex->offset == NULL) { + ir_read_error(s_offset, "expected 0 or an expression"); return NULL; } - } else { - s_expression *proj_expr = (s_expression *) offset_list->next; - s_int *proj_as_int = SX_AS_INT(proj_expr); + } + + if (op != ir_txf) { + s_int *proj_as_int = SX_AS_INT(s_proj); if (proj_as_int && proj_as_int->value() == 1) { tex->projector = NULL; } else { - tex->projector = read_rvalue(st, proj_expr); + tex->projector = read_rvalue(s_proj); if (tex->projector == NULL) { - ir_read_error(st, NULL, "when reading projective divide in (%s ..)", - tag->value()); + ir_read_error(NULL, "when reading projective divide in (%s ..)", + tex->opcode_string()); return NULL; } } - s_list *shadow_list = SX_AS_LIST(proj_expr->next); - if (shadow_list == NULL) { - ir_read_error(st, NULL, "shadow comparitor must be a list"); - return NULL; - } - if (shadow_list->subexpressions.is_empty()) { - tex->shadow_comparitor= NULL; + if (s_shadow->subexpressions.is_empty()) { + tex->shadow_comparitor = NULL; } else { - tex->shadow_comparitor = read_rvalue(st, shadow_list); + tex->shadow_comparitor = read_rvalue(s_shadow); if (tex->shadow_comparitor == NULL) { - ir_read_error(st, NULL, "when reading shadow comparitor in (%s ..)", - tag->value()); + ir_read_error(NULL, "when reading shadow comparitor in (%s ..)", + tex->opcode_string()); return NULL; } } - s_expression *lod_expr = (s_expression *) shadow_list->next; - - switch (op) { - case ir_txb: - tex->lod_info.bias = read_rvalue(st, lod_expr); - if (tex->lod_info.bias == NULL) { - ir_read_error(st, NULL, "when reading LOD bias in (txb ...)"); - return NULL; - } - break; - case ir_txl: - tex->lod_info.lod = read_rvalue(st, lod_expr); - if (tex->lod_info.lod == NULL) { - ir_read_error(st, NULL, "when reading LOD in (txl ...)"); - return NULL; - } - break; - case ir_txd: { - s_list *lod_list = SX_AS_LIST(lod_expr); - if (lod_list->length() != 2) { - ir_read_error(st, lod_expr, "expected (dPdx dPdy) in (txd ...)"); - return NULL; - } - s_expression *dx_expr = (s_expression *) lod_list->subexpressions.head; - s_expression *dy_expr = (s_expression *) dx_expr->next; + } - tex->lod_info.grad.dPdx = read_rvalue(st, dx_expr); - if (tex->lod_info.grad.dPdx == NULL) { - ir_read_error(st, NULL, "when reading dPdx in (txd ...)"); - return NULL; - } - tex->lod_info.grad.dPdy = read_rvalue(st, dy_expr); - if (tex->lod_info.grad.dPdy == NULL) { - ir_read_error(st, NULL, "when reading dPdy in (txd ...)"); - return NULL; - } - break; + switch (op) { + case ir_txb: + tex->lod_info.bias = read_rvalue(s_lod); + if (tex->lod_info.bias == NULL) { + ir_read_error(NULL, "when reading LOD bias in (txb ...)"); + return NULL; + } + break; + case ir_txl: + case ir_txf: + tex->lod_info.lod = read_rvalue(s_lod); + if (tex->lod_info.lod == NULL) { + ir_read_error(NULL, "when reading LOD in (%s ...)", + tex->opcode_string()); + return NULL; + } + break; + case ir_txd: { + s_expression *s_dx, *s_dy; + s_pattern dxdy_pat[] = { s_dx, s_dy }; + if (!MATCH(s_lod, dxdy_pat)) { + ir_read_error(s_lod, "expected (dPdx dPdy) in (txd ...)"); + return NULL; + } + tex->lod_info.grad.dPdx = read_rvalue(s_dx); + if (tex->lod_info.grad.dPdx == NULL) { + ir_read_error(NULL, "when reading dPdx in (txd ...)"); + return NULL; + } + tex->lod_info.grad.dPdy = read_rvalue(s_dy); + if (tex->lod_info.grad.dPdy == NULL) { + ir_read_error(NULL, "when reading dPdy in (txd ...)"); + return NULL; } - default: - // tex doesn't have any extra parameters and txf was handled earlier. - break; - }; + break; } + default: + // tex doesn't have any extra parameters. + break; + }; return tex; } diff --git a/src/glsl/ir_rvalue_visitor.cpp b/src/glsl/ir_rvalue_visitor.cpp index 773bfcfa3e..ed6c7cb6a1 100644 --- a/src/glsl/ir_rvalue_visitor.cpp +++ b/src/glsl/ir_rvalue_visitor.cpp @@ -53,6 +53,7 @@ ir_rvalue_visitor::visit_leave(ir_texture *ir) handle_rvalue(&ir->coordinate); handle_rvalue(&ir->projector); handle_rvalue(&ir->shadow_comparitor); + handle_rvalue(&ir->offset); switch (ir->op) { case ir_tex: diff --git a/src/glsl/ir_set_program_inouts.cpp b/src/glsl/ir_set_program_inouts.cpp index b3f1cc0d8b..085456533c 100644 --- a/src/glsl/ir_set_program_inouts.cpp +++ b/src/glsl/ir_set_program_inouts.cpp @@ -66,7 +66,7 @@ public: }; static void -mark(struct gl_program *prog, ir_variable *var, int index) +mark(struct gl_program *prog, ir_variable *var, int offset, int len) { /* As of GLSL 1.20, varyings can only be floats, floating-point * vectors or matrices, or arrays of them. For Mesa programs using @@ -75,25 +75,14 @@ mark(struct gl_program *prog, ir_variable *var, int index) * something doing a more clever packing would use something other * than InputsRead/OutputsWritten. */ - const glsl_type *element_type; - int element_size; - if (var->type->is_array()) - element_type = var->type->fields.array; - else - element_type = var->type; - - if (element_type->is_matrix()) - element_size = element_type->matrix_columns; - else - element_size = 1; - - index *= element_size; - for (int i = 0; i < element_size; i++) { + for (int i = 0; i < len; i++) { if (var->mode == ir_var_in) - prog->InputsRead |= BITFIELD64_BIT(var->location + index + i); + prog->InputsRead |= BITFIELD64_BIT(var->location + offset + i); + else if (var->mode == ir_var_system_value) + prog->SystemValuesRead |= (1 << (var->location + offset + i)); else - prog->OutputsWritten |= BITFIELD64_BIT(var->location + index + i); + prog->OutputsWritten |= BITFIELD64_BIT(var->location + offset + i); } } @@ -106,10 +95,11 @@ ir_set_program_inouts_visitor::visit(ir_dereference_variable *ir) if (ir->type->is_array()) { for (unsigned int i = 0; i < ir->type->length; i++) { - mark(this->prog, ir->var, i); + mark(this->prog, ir->var, i, + ir->type->length * ir->type->fields.array->matrix_columns); } } else { - mark(this->prog, ir->var, 0); + mark(this->prog, ir->var, 0, ir->type->matrix_columns); } return visit_continue; @@ -128,7 +118,14 @@ ir_set_program_inouts_visitor::visit_enter(ir_dereference_array *ir) var = (ir_variable *)hash_table_find(this->ht, deref_var->var); if (index && var) { - mark(this->prog, var, index->value.i[0]); + int width = 1; + + if (deref_var->type->is_array() && + deref_var->type->fields.array->is_matrix()) { + width = deref_var->type->fields.array->matrix_columns; + } + + mark(this->prog, var, index->value.i[0] * width, width); return visit_continue_with_parent; } @@ -139,7 +136,8 @@ ir_visitor_status ir_set_program_inouts_visitor::visit(ir_variable *ir) { if (ir->mode == ir_var_in || - ir->mode == ir_var_out) { + ir->mode == ir_var_out || + ir->mode == ir_var_system_value) { hash_table_insert(this->ht, ir, ir); } @@ -163,5 +161,6 @@ do_set_program_inouts(exec_list *instructions, struct gl_program *prog) prog->InputsRead = 0; prog->OutputsWritten = 0; + prog->SystemValuesRead = 0; visit_list_elements(&v, instructions); } diff --git a/src/glsl/ir_validate.cpp b/src/glsl/ir_validate.cpp index 5b055f64d3..0fc3baf869 100644 --- a/src/glsl/ir_validate.cpp +++ b/src/glsl/ir_validate.cpp @@ -70,6 +70,7 @@ public: virtual ir_visitor_status visit_leave(ir_swizzle *ir); virtual ir_visitor_status visit_enter(ir_assignment *ir); + virtual ir_visitor_status visit_enter(ir_call *ir); static void validate_ir(ir_instruction *ir, void *data); @@ -173,13 +174,26 @@ ir_validate::visit_enter(ir_function *ir) this->validate_ir(ir, this->data); + /* Verify that all of the things stored in the list of signatures are, + * in fact, function signatures. + */ + foreach_list(node, &ir->signatures) { + ir_instruction *sig = (ir_instruction *) node; + + if (sig->ir_type != ir_type_function_signature) { + printf("Non-signature in signature list of function `%s'\n", + ir->name); + abort(); + } + } + return visit_continue; } ir_visitor_status ir_validate::visit_leave(ir_function *ir) { - assert(talloc_parent(ir->name) == ir); + assert(ralloc_parent(ir->name) == ir); this->current_function = NULL; return visit_continue; @@ -198,6 +212,12 @@ ir_validate::visit_enter(ir_function_signature *ir) abort(); } + if (ir->return_type == NULL) { + printf("Function signature %p for function %s has NULL return type.\n", + (void *) ir, ir->function_name()); + abort(); + } + this->validate_ir(ir, this->data); return visit_continue; @@ -450,7 +470,7 @@ ir_validate::visit(ir_variable *ir) * declared before it is dereferenced. */ if (ir->name) - assert(talloc_parent(ir->name) == ir); + assert(ralloc_parent(ir->name) == ir); hash_table_insert(ht, ir, ir); return visit_continue; @@ -488,6 +508,19 @@ ir_validate::visit_enter(ir_assignment *ir) return visit_continue; } +ir_visitor_status +ir_validate::visit_enter(ir_call *ir) +{ + ir_function_signature *const callee = ir->get_callee(); + + if (callee->ir_type != ir_type_function_signature) { + printf("IR called by ir_call is not ir_function_signature!\n"); + abort(); + } + + return visit_continue; +} + void ir_validate::validate_ir(ir_instruction *ir, void *data) { diff --git a/src/glsl/ir_variable.cpp b/src/glsl/ir_variable.cpp index 5b8281e16e..18a3e0fb0d 100644 --- a/src/glsl/ir_variable.cpp +++ b/src/glsl/ir_variable.cpp @@ -30,6 +30,11 @@ static void generate_ARB_draw_buffers_variables(exec_list *, struct _mesa_glsl_parse_state *, bool, _mesa_glsl_parser_targets); +static void +generate_ARB_draw_instanced_variables(exec_list *, + struct _mesa_glsl_parse_state *, + bool, _mesa_glsl_parser_targets); + static ir_variable * add_variable(const char *name, enum ir_variable_mode mode, int slot, const glsl_type *type, exec_list *instructions, @@ -40,7 +45,9 @@ add_variable(const char *name, enum ir_variable_mode mode, int slot, switch (var->mode) { case ir_var_auto: case ir_var_in: + case ir_var_const_in: case ir_var_uniform: + case ir_var_system_value: var->read_only = true; break; case ir_var_inout: @@ -324,8 +331,13 @@ initialize_vs_variables(exec_list *instructions, generate_130_vs_variables(instructions, state); break; } + + if (state->ARB_draw_instanced_enable) + generate_ARB_draw_instanced_variables(instructions, state, false, + vertex_shader); } + /* This function should only be called for ES, not desktop GL. */ static void generate_100ES_fs_variables(exec_list *instructions, @@ -422,6 +434,27 @@ generate_ARB_draw_buffers_variables(exec_list *instructions, } } + +static void +generate_ARB_draw_instanced_variables(exec_list *instructions, + struct _mesa_glsl_parse_state *state, + bool warn, + _mesa_glsl_parser_targets target) +{ + /* gl_InstanceIDARB is only available in the vertex shader. + */ + if (target == vertex_shader) { + ir_variable *const inst = + add_variable("gl_InstanceIDARB", ir_var_system_value, + SYSTEM_VALUE_INSTANCE_ID, + glsl_type::int_type, instructions, state->symbols); + + if (warn) + inst->warn_extension = "GL_ARB_draw_instanced"; + } +} + + static void generate_ARB_shader_stencil_export_variables(exec_list *instructions, struct _mesa_glsl_parse_state *state, diff --git a/src/glsl/ir_variable_refcount.h b/src/glsl/ir_variable_refcount.h index 8b43bad71f..906135a9e1 100644 --- a/src/glsl/ir_variable_refcount.h +++ b/src/glsl/ir_variable_refcount.h @@ -54,13 +54,13 @@ class ir_variable_refcount_visitor : public ir_hierarchical_visitor { public: ir_variable_refcount_visitor(void) { - this->mem_ctx = talloc_new(NULL); + this->mem_ctx = ralloc_context(NULL); this->variable_list.make_empty(); } ~ir_variable_refcount_visitor(void) { - talloc_free(this->mem_ctx); + ralloc_free(this->mem_ctx); } virtual ir_visitor_status visit(ir_variable *); diff --git a/src/glsl/link_functions.cpp b/src/glsl/link_functions.cpp index c6339abf23..ae8818be87 100644 --- a/src/glsl/link_functions.cpp +++ b/src/glsl/link_functions.cpp @@ -21,14 +21,6 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdlib> -#include <cstdio> - -extern "C" { -#include <stdarg.h> -#include <talloc.h> -} - #include "main/core.h" #include "glsl_symbol_table.h" #include "glsl_parser_extras.h" @@ -107,9 +99,15 @@ public: * details that may be missing. */ ir_function *f = linked->symbols->get_function(name); - if (f == NULL) + if (f == NULL) { f = new(linked) ir_function(name); + /* Add the new function to the linked IR. + */ + linked->symbols->add_function(f); + linked->ir->push_head(f); + } + ir_function_signature *linked_sig = f->exact_matching_signature(&callee->parameters); if (linked_sig == NULL) { @@ -185,6 +183,18 @@ public: var = ir->var->clone(linked, NULL); linked->symbols->add_variable(var); linked->ir->push_head(var); + } else if (var->type->is_array()) { + /* It is possible to have a global array declared in multiple + * shaders without a size. The array is implicitly sized by the + * maximal access to it in *any* shader. Because of this, we + * need to track the maximal access to the array as linking pulls + * more functions in that access the array. + */ + var->max_array_access = + MAX2(var->max_array_access, ir->var->max_array_access); + + if (var->type->length == 0 && ir->var->type->length != 0) + var->type = ir->var->type; } ir->var = var; diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index a219ab7e66..7db5c5e8d5 100644 --- a/src/glsl/linker.cpp +++ b/src/glsl/linker.cpp @@ -63,14 +63,6 @@ * * \author Ian Romanick <ian.d.romanick@intel.com> */ -#include <cstdlib> -#include <cstdio> -#include <climits> - -extern "C" { -#include <stdarg.h> -#include <talloc.h> -} #include "main/core.h" #include "glsl_symbol_table.h" @@ -176,9 +168,9 @@ linker_error_printf(gl_shader_program *prog, const char *fmt, ...) { va_list ap; - prog->InfoLog = talloc_strdup_append(prog->InfoLog, "error: "); + ralloc_strcat(&prog->InfoLog, "error: "); va_start(ap, fmt); - prog->InfoLog = talloc_vasprintf_append(prog->InfoLog, fmt, ap); + ralloc_vasprintf_append(&prog->InfoLog, fmt, ap); va_end(ap); } @@ -303,6 +295,7 @@ mode_string(const ir_variable *var) case ir_var_out: return "shader output"; case ir_var_inout: return "shader inout"; + case ir_var_const_in: case ir_var_temporary: default: assert(!"Should not get here."); @@ -360,11 +353,8 @@ cross_validate_globals(struct gl_shader_program *prog, && (var->type->fields.array == existing->type->fields.array) && ((var->type->length == 0) || (existing->type->length == 0))) { - if (existing->type->length == 0) { + if (var->type->length != 0) { existing->type = var->type; - existing->max_array_access = - MAX2(existing->max_array_access, - var->max_array_access); } } else { linker_error_printf(prog, "%s `%s' declared as type " @@ -389,6 +379,32 @@ cross_validate_globals(struct gl_shader_program *prog, existing->explicit_location = true; } + /* Validate layout qualifiers for gl_FragDepth. + * + * From the AMD_conservative_depth spec: + * "If gl_FragDepth is redeclared in any fragment shader in + * a program, it must be redeclared in all fragment shaders in that + * program that have static assignments to gl_FragDepth. All + * redeclarations of gl_FragDepth in all fragment shaders in + * a single program must have the same set of qualifiers." + */ + if (strcmp(var->name, "gl_FragDepth") == 0) { + bool layout_declared = var->depth_layout != ir_depth_layout_none; + bool layout_differs = var->depth_layout != existing->depth_layout; + if (layout_declared && layout_differs) { + linker_error_printf(prog, + "All redeclarations of gl_FragDepth in all fragment shaders " + "in a single program must have the same set of qualifiers."); + } + if (var->used && layout_differs) { + linker_error_printf(prog, + "If gl_FragDepth is redeclared with a layout qualifier in" + "any fragment shader, it must be redeclared with the same" + "layout qualifier in all fragment shaders that have" + "assignments to gl_FragDepth"); + } + } + /* FINISHME: Handle non-constant initializers. */ if (var->constant_value != NULL) { @@ -413,7 +429,7 @@ cross_validate_globals(struct gl_shader_program *prog, * FINISHME: will fail. */ existing->constant_value = - var->constant_value->clone(talloc_parent(existing), NULL); + var->constant_value->clone(ralloc_parent(existing), NULL); } if (existing->invariant != var->invariant) { @@ -422,6 +438,12 @@ cross_validate_globals(struct gl_shader_program *prog, mode_string(var), var->name); return false; } + if (existing->centroid != var->centroid) { + linker_error_printf(prog, "declarations for %s `%s' have " + "mismatching centroid qualifiers\n", + mode_string(var), var->name); + return false; + } } else variables.add_variable(var); } @@ -487,14 +509,35 @@ cross_validate_outputs_to_inputs(struct gl_shader_program *prog, /* Check that the types match between stages. */ if (input->type != output->type) { - linker_error_printf(prog, - "%s shader output `%s' declared as " - "type `%s', but %s shader input declared " - "as type `%s'\n", - producer_stage, output->name, - output->type->name, - consumer_stage, input->type->name); - return false; + /* There is a bit of a special case for gl_TexCoord. This + * built-in is unsized by default. Appliations that variable + * access it must redeclare it with a size. There is some + * language in the GLSL spec that implies the fragment shader + * and vertex shader do not have to agree on this size. Other + * driver behave this way, and one or two applications seem to + * rely on it. + * + * Neither declaration needs to be modified here because the array + * sizes are fixed later when update_array_sizes is called. + * + * From page 48 (page 54 of the PDF) of the GLSL 1.10 spec: + * + * "Unlike user-defined varying variables, the built-in + * varying variables don't have a strict one-to-one + * correspondence between the vertex language and the + * fragment language." + */ + if (!output->type->is_array() + || (strncmp("gl_", output->name, 3) != 0)) { + linker_error_printf(prog, + "%s shader output `%s' declared as " + "type `%s', but %s shader input declared " + "as type `%s'\n", + producer_stage, output->name, + output->type->name, + consumer_stage, input->type->name); + return false; + } } /* Check that all of the qualifiers match between stages. @@ -867,30 +910,29 @@ link_intrastage_shaders(void *mem_ctx, free(linking_shaders); - /* Make a pass over all global variables to ensure that arrays with + /* Make a pass over all variable declarations to ensure that arrays with * unspecified sizes have a size specified. The size is inferred from the * max_array_access field. */ if (linked != NULL) { - foreach_list(node, linked->ir) { - ir_variable *const var = ((ir_instruction *) node)->as_variable(); - - if (var == NULL) - continue; - - if ((var->mode != ir_var_auto) && (var->mode != ir_var_temporary)) - continue; - - if (!var->type->is_array() || (var->type->length != 0)) - continue; + class array_sizing_visitor : public ir_hierarchical_visitor { + public: + virtual ir_visitor_status visit(ir_variable *var) + { + if (var->type->is_array() && (var->type->length == 0)) { + const glsl_type *type = + glsl_type::get_array_instance(var->type->fields.array, + var->max_array_access + 1); + + assert(type != NULL); + var->type = type; + } - const glsl_type *type = - glsl_type::get_array_instance(var->type->fields.array, - var->max_array_access); + return visit_continue; + } + } v; - assert(type != NULL); - var->type = type; - } + v.run(linked->ir); } return linked; @@ -970,7 +1012,7 @@ add_uniform(void *mem_ctx, exec_list *uniforms, struct hash_table *ht, if (type->is_record()) { for (unsigned int i = 0; i < type->length; i++) { const glsl_type *field_type = type->fields.structure[i].type; - char *field_name = talloc_asprintf(mem_ctx, "%s.%s", name, + char *field_name = ralloc_asprintf(mem_ctx, "%s.%s", name, type->fields.structure[i].name); add_uniform(mem_ctx, uniforms, ht, field_name, field_type, @@ -986,7 +1028,7 @@ add_uniform(void *mem_ctx, exec_list *uniforms, struct hash_table *ht, /* Array of structures. */ if (array_elem_type->is_record()) { for (unsigned int i = 0; i < type->length; i++) { - char *elem_name = talloc_asprintf(mem_ctx, "%s[%d]", name, i); + char *elem_name = ralloc_asprintf(mem_ctx, "%s[%d]", name, i); add_uniform(mem_ctx, uniforms, ht, elem_name, array_elem_type, shader_type, next_shader_pos, total_uniforms); } @@ -1048,7 +1090,7 @@ assign_uniform_locations(struct gl_shader_program *prog) unsigned total_uniforms = 0; hash_table *ht = hash_table_ctor(32, hash_table_string_hash, hash_table_string_compare); - void *mem_ctx = talloc_new(NULL); + void *mem_ctx = ralloc_context(NULL); for (unsigned i = 0; i < MESA_SHADER_TYPES; i++) { if (prog->_LinkedShaders[i] == NULL) @@ -1077,7 +1119,7 @@ assign_uniform_locations(struct gl_shader_program *prog) } } - talloc_free(mem_ctx); + ralloc_free(mem_ctx); gl_uniform_list *ul = (gl_uniform_list *) calloc(1, sizeof(gl_uniform_list)); @@ -1445,16 +1487,16 @@ assign_varying_locations(struct gl_shader_program *prog, void link_shaders(struct gl_context *ctx, struct gl_shader_program *prog) { - void *mem_ctx = talloc_init("temporary linker context"); + void *mem_ctx = ralloc_context(NULL); // temporary linker context prog->LinkStatus = false; prog->Validated = false; prog->_Used = false; if (prog->InfoLog != NULL) - talloc_free(prog->InfoLog); + ralloc_free(prog->InfoLog); - prog->InfoLog = talloc_strdup(NULL, ""); + prog->InfoLog = ralloc_strdup(NULL, ""); /* Separate the shaders into groups based on their type. */ @@ -1636,6 +1678,20 @@ link_shaders(struct gl_context *ctx, struct gl_shader_program *prog) demote_shader_inputs_and_outputs(sh, ir_var_in); } + /* OpenGL ES requires that a vertex shader and a fragment shader both be + * present in a linked program. By checking for use of shading language + * version 1.00, we also catch the GL_ARB_ES2_compatibility case. + */ + if (ctx->API == API_OPENGLES2 || prog->Version == 100) { + if (prog->_LinkedShaders[MESA_SHADER_VERTEX] == NULL) { + linker_error_printf(prog, "program lacks a vertex shader\n"); + prog->LinkStatus = false; + } else if (prog->_LinkedShaders[MESA_SHADER_FRAGMENT] == NULL) { + linker_error_printf(prog, "program lacks a fragment shader\n"); + prog->LinkStatus = false; + } + } + /* FINISHME: Assign fragment shader output locations. */ done: @@ -1649,5 +1705,5 @@ done: reparent_ir(prog->_LinkedShaders[i]->ir, prog->_LinkedShaders[i]->ir); } - talloc_free(mem_ctx); + ralloc_free(mem_ctx); } diff --git a/src/glsl/list.h b/src/glsl/list.h index 3197b03cf2..1d46365fae 100644 --- a/src/glsl/list.h +++ b/src/glsl/list.h @@ -66,37 +66,33 @@ #ifndef __cplusplus #include <stddef.h> -#include <talloc.h> -#else -extern "C" { -#include <talloc.h> -} #endif - #include <assert.h> +#include "ralloc.h" + struct exec_node { struct exec_node *next; struct exec_node *prev; #ifdef __cplusplus - /* Callers of this talloc-based new need not call delete. It's - * easier to just talloc_free 'ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'ctx' (or any of its ancestors). */ static void* operator new(size_t size, void *ctx) { void *node; - node = talloc_size(ctx, size); + node = ralloc_size(ctx, size); assert(node != NULL); return node; } /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. */ + * ralloc_free in that case. */ static void operator delete(void *node) { - talloc_free(node); + ralloc_free(node); } exec_node() : next(NULL), prev(NULL) @@ -289,23 +285,23 @@ struct exec_list { struct exec_node *tail_pred; #ifdef __cplusplus - /* Callers of this talloc-based new need not call delete. It's - * easier to just talloc_free 'ctx' (or any of its ancestors). */ + /* Callers of this ralloc-based new need not call delete. It's + * easier to just ralloc_free 'ctx' (or any of its ancestors). */ static void* operator new(size_t size, void *ctx) { void *node; - node = talloc_size(ctx, size); + node = ralloc_size(ctx, size); assert(node != NULL); return node; } /* If the user *does* call delete, that's OK, we will just - * talloc_free in that case. */ + * ralloc_free in that case. */ static void operator delete(void *node) { - talloc_free(node); + ralloc_free(node); } exec_list() diff --git a/src/glsl/loop_analysis.cpp b/src/glsl/loop_analysis.cpp index ff7adf00a2..9bba6a97c4 100644 --- a/src/glsl/loop_analysis.cpp +++ b/src/glsl/loop_analysis.cpp @@ -37,14 +37,15 @@ loop_state::loop_state() { this->ht = hash_table_ctor(0, hash_table_pointer_hash, hash_table_pointer_compare); - this->mem_ctx = talloc_init("loop state"); + this->mem_ctx = ralloc_context(NULL); + this->loop_found = false; } loop_state::~loop_state() { hash_table_dtor(this->ht); - talloc_free(this->mem_ctx); + ralloc_free(this->mem_ctx); } @@ -52,7 +53,9 @@ loop_variable_state * loop_state::insert(ir_loop *ir) { loop_variable_state *ls = new(this->mem_ctx) loop_variable_state; + hash_table_insert(this->ht, ls, ir); + this->loop_found = true; return ls; } @@ -75,8 +78,8 @@ loop_variable_state::get(const ir_variable *ir) loop_variable * loop_variable_state::insert(ir_variable *var) { - void *mem_ctx = talloc_parent(this); - loop_variable *lv = talloc_zero(mem_ctx, loop_variable); + void *mem_ctx = ralloc_parent(this); + loop_variable *lv = rzalloc(mem_ctx, loop_variable); lv->var = var; @@ -90,8 +93,8 @@ loop_variable_state::insert(ir_variable *var) loop_terminator * loop_variable_state::insert(ir_if *if_stmt) { - void *mem_ctx = talloc_parent(this); - loop_terminator *t = talloc_zero(mem_ctx, loop_terminator); + void *mem_ctx = ralloc_parent(this); + loop_terminator *t = rzalloc(mem_ctx, loop_terminator); t->ir = if_stmt; this->terminators.push_tail(t); @@ -447,7 +450,7 @@ get_basic_induction_increment(ir_assignment *ir, hash_table *var_hash) } if ((inc != NULL) && (rhs->operation == ir_binop_sub)) { - void *mem_ctx = talloc_parent(ir); + void *mem_ctx = ralloc_parent(ir); inc = new(mem_ctx) ir_expression(ir_unop_neg, inc->type, diff --git a/src/glsl/loop_analysis.h b/src/glsl/loop_analysis.h index 7b0511fbbe..229730836a 100644 --- a/src/glsl/loop_analysis.h +++ b/src/glsl/loop_analysis.h @@ -214,6 +214,8 @@ public: loop_variable_state *insert(ir_loop *ir); + bool loop_found; + private: loop_state(); diff --git a/src/glsl/loop_controls.cpp b/src/glsl/loop_controls.cpp index b528810f40..9acbadc50e 100644 --- a/src/glsl/loop_controls.cpp +++ b/src/glsl/loop_controls.cpp @@ -21,7 +21,7 @@ * DEALINGS IN THE SOFTWARE. */ -#include <climits> +#include <limits.h> #include "main/compiler.h" #include "glsl_types.h" #include "loop_analysis.h" @@ -88,7 +88,7 @@ calculate_iterations(ir_rvalue *from, ir_rvalue *to, ir_rvalue *increment, if (from == NULL || to == NULL || increment == NULL) return -1; - void *mem_ctx = talloc_init("%s", __func__); + void *mem_ctx = ralloc_context(NULL); ir_expression *const sub = new(mem_ctx) ir_expression(ir_binop_sub, from->type, to, from); @@ -147,7 +147,7 @@ calculate_iterations(ir_rvalue *from, ir_rvalue *to, ir_rvalue *increment, } } - talloc_free(mem_ctx); + ralloc_free(mem_ctx); return (valid_loop) ? iter_value : -1; } diff --git a/src/glsl/loop_unroll.cpp b/src/glsl/loop_unroll.cpp index 11709587e2..5b84e10147 100644 --- a/src/glsl/loop_unroll.cpp +++ b/src/glsl/loop_unroll.cpp @@ -43,6 +43,14 @@ public: }; +static bool +is_break(ir_instruction *ir) +{ + return ir != NULL && ir->ir_type == ir_type_loop_jump + && ((ir_loop_jump *) ir)->is_break(); +} + + ir_visitor_status loop_unroll_visitor::visit_leave(ir_loop *ir) { @@ -73,46 +81,76 @@ loop_unroll_visitor::visit_leave(ir_loop *ir) if (ls->num_loop_jumps > 1) return visit_continue; else if (ls->num_loop_jumps) { - /* recognize loops in the form produced by ir_lower_jumps */ - ir_instruction *last_ir = - ((ir_instruction*)ir->body_instructions.get_tail()); - + ir_instruction *last_ir = (ir_instruction *) ir->body_instructions.get_tail(); assert(last_ir != NULL); - ir_if *last_if = last_ir->as_if(); - if (last_if) { - bool continue_from_then_branch; - - /* Determine which if-statement branch, if any, ends with a break. - * The branch that did *not* have the break will get a temporary - * continue inserted in each iteration of the loop unroll. - * - * Note that since ls->num_loop_jumps is <= 1, it is impossible for - * both branches to end with a break. - */ - ir_instruction *last = - (ir_instruction *) last_if->then_instructions.get_tail(); - - if (last && last->ir_type == ir_type_loop_jump - && ((ir_loop_jump*) last)->is_break()) { - continue_from_then_branch = false; - } else { - last = (ir_instruction *) last_if->then_instructions.get_tail(); - - if (last && last->ir_type == ir_type_loop_jump - && ((ir_loop_jump*) last)->is_break()) - continue_from_then_branch = true; - else - /* Bail out if neither if-statement branch ends with a break. + if (is_break(last_ir)) { + /* If the only loop-jump is a break at the end of the loop, the loop + * will execute exactly once. Remove the break, set the iteration + * count, and fall through to the normal unroller. + */ + last_ir->remove(); + iterations = 1; + + this->progress = true; + } else { + ir_if *ir_if = NULL; + ir_instruction *break_ir = NULL; + bool continue_from_then_branch = false; + + foreach_list(node, &ir->body_instructions) { + /* recognize loops in the form produced by ir_lower_jumps */ + ir_instruction *cur_ir = (ir_instruction *) node; + + ir_if = cur_ir->as_if(); + if (ir_if != NULL) { + /* Determine which if-statement branch, if any, ends with a + * break. The branch that did *not* have the break will get a + * temporary continue inserted in each iteration of the loop + * unroll. + * + * Note that since ls->num_loop_jumps is <= 1, it is impossible + * for both branches to end with a break. */ - return visit_continue; - } + ir_instruction *ir_if_last = + (ir_instruction *) ir_if->then_instructions.get_tail(); + + if (is_break(ir_if_last)) { + continue_from_then_branch = false; + break_ir = ir_if_last; + break; + } else { + ir_if_last = + (ir_instruction *) ir_if->else_instructions.get_tail(); + + if (is_break(ir_if_last)) { + break_ir = ir_if_last; + continue_from_then_branch = true; + break; + } + } + } + } + + if (break_ir == NULL) + return visit_continue; + + /* move instructions after then if in the continue branch */ + while (!ir_if->get_next()->is_tail_sentinel()) { + ir_instruction *move_ir = (ir_instruction *) ir_if->get_next(); + + move_ir->remove(); + if (continue_from_then_branch) + ir_if->then_instructions.push_tail(move_ir); + else + ir_if->else_instructions.push_tail(move_ir); + } - /* Remove the break from the if-statement. - */ - last->remove(); + /* Remove the break from the if-statement. + */ + break_ir->remove(); - void *const mem_ctx = talloc_parent(ir); + void *const mem_ctx = ralloc_parent(ir); ir_instruction *ir_to_replace = ir; for (int i = 0; i < iterations; i++) { @@ -121,8 +159,8 @@ loop_unroll_visitor::visit_leave(ir_loop *ir) copy_list.make_empty(); clone_ir_list(mem_ctx, ©_list, &ir->body_instructions); - last_if = ((ir_instruction*)copy_list.get_tail())->as_if(); - assert(last_if); + ir_if = ((ir_instruction *) copy_list.get_tail())->as_if(); + assert(ir_if != NULL); ir_to_replace->insert_before(©_list); ir_to_replace->remove(); @@ -132,7 +170,7 @@ loop_unroll_visitor::visit_leave(ir_loop *ir) new(mem_ctx) ir_loop_jump(ir_loop_jump::jump_continue); exec_list *const list = (continue_from_then_branch) - ? &last_if->then_instructions : &last_if->else_instructions; + ? &ir_if->then_instructions : &ir_if->else_instructions; list->push_tail(ir_to_replace); } @@ -141,21 +179,10 @@ loop_unroll_visitor::visit_leave(ir_loop *ir) this->progress = true; return visit_continue; - } else if (last_ir->ir_type == ir_type_loop_jump - && ((ir_loop_jump *)last_ir)->is_break()) { - /* If the only loop-jump is a break at the end of the loop, the loop - * will execute exactly once. Remove the break, set the iteration - * count, and fall through to the normal unroller. - */ - last_ir->remove(); - iterations = 1; - - this->progress = true; - } else - return visit_continue; + } } - void *const mem_ctx = talloc_parent(ir); + void *const mem_ctx = ralloc_parent(ir); for (int i = 0; i < iterations; i++) { exec_list copy_list; diff --git a/src/glsl/lower_discard.cpp b/src/glsl/lower_discard.cpp index b95313df8c..cafd2dd3b4 100644 --- a/src/glsl/lower_discard.cpp +++ b/src/glsl/lower_discard.cpp @@ -170,7 +170,7 @@ lower_discard_visitor::visit_leave(ir_if *ir) if (then_discard == NULL && else_discard == NULL) return visit_continue; - void *mem_ctx = talloc_parent(ir); + void *mem_ctx = ralloc_parent(ir); ir_variable *temp = new(mem_ctx) ir_variable(glsl_type::bool_type, "discard_cond_temp", diff --git a/src/glsl/lower_if_to_cond_assign.cpp b/src/glsl/lower_if_to_cond_assign.cpp index cf48cfb8d6..e3a1065d99 100644 --- a/src/glsl/lower_if_to_cond_assign.cpp +++ b/src/glsl/lower_if_to_cond_assign.cpp @@ -24,12 +24,25 @@ /** * \file lower_if_to_cond_assign.cpp * - * This attempts to flatten all if statements to conditional - * assignments for GPUs that don't do control flow. + * This attempts to flatten if-statements to conditional assignments for + * GPUs with limited or no flow control support. * * It can't handle other control flow being inside of its block, such * as calls or loops. Hopefully loop unrolling and inlining will take * care of those. + * + * Drivers for GPUs with no control flow support should simply call + * + * lower_if_to_cond_assign(instructions) + * + * to attempt to flatten all if-statements. + * + * Some GPUs (such as i965 prior to gen6) do support control flow, but have a + * maximum nesting depth N. Drivers for such hardware can call + * + * lower_if_to_cond_assign(instructions, N) + * + * to attempt to flatten any if-statements appearing at depth > N. */ #include "glsl_types.h" @@ -37,20 +50,25 @@ class ir_if_to_cond_assign_visitor : public ir_hierarchical_visitor { public: - ir_if_to_cond_assign_visitor() + ir_if_to_cond_assign_visitor(unsigned max_depth) { this->progress = false; + this->max_depth = max_depth; + this->depth = 0; } + ir_visitor_status visit_enter(ir_if *); ir_visitor_status visit_leave(ir_if *); bool progress; + unsigned max_depth; + unsigned depth; }; bool -do_if_to_cond_assign(exec_list *instructions) +lower_if_to_cond_assign(exec_list *instructions, unsigned max_depth) { - ir_if_to_cond_assign_visitor v; + ir_if_to_cond_assign_visitor v(max_depth); visit_list_elements(&v, instructions); @@ -120,8 +138,22 @@ move_block_to_cond_assign(void *mem_ctx, } ir_visitor_status +ir_if_to_cond_assign_visitor::visit_enter(ir_if *ir) +{ + (void) ir; + this->depth++; + return visit_continue; +} + +ir_visitor_status ir_if_to_cond_assign_visitor::visit_leave(ir_if *ir) { + /* Only flatten when beyond the GPU's maximum supported nesting depth. */ + if (this->depth <= this->max_depth) + return visit_continue; + + this->depth--; + bool found_control_flow = false; ir_variable *cond_var; ir_assignment *assign; @@ -139,7 +171,7 @@ ir_if_to_cond_assign_visitor::visit_leave(ir_if *ir) if (found_control_flow) return visit_continue; - void *mem_ctx = talloc_parent(ir); + void *mem_ctx = ralloc_parent(ir); /* Store the condition to a variable so the assignment conditions are * simpler. diff --git a/src/glsl/lower_jumps.cpp b/src/glsl/lower_jumps.cpp index 9cd15ef736..dd2601d1aa 100644 --- a/src/glsl/lower_jumps.cpp +++ b/src/glsl/lower_jumps.cpp @@ -66,7 +66,7 @@ enum jump_strength strength_always_clears_execute_flag, strength_continue, strength_break, - strength_return, + strength_return }; struct block_record @@ -512,7 +512,11 @@ lower_continue: if(this->loop.may_set_return_flag) { assert(this->function.return_flag); ir_if* return_if = new(ir) ir_if(new(ir) ir_dereference_variable(this->function.return_flag)); - return_if->then_instructions.push_tail(new(ir) ir_loop_jump(saved_loop.loop ? ir_loop_jump::jump_break : ir_loop_jump::jump_continue)); + saved_loop.may_set_return_flag = true; + if(saved_loop.loop) + return_if->then_instructions.push_tail(new(ir) ir_loop_jump(ir_loop_jump::jump_break)); + else + move_outer_block_inside(ir, &return_if->else_instructions); ir->insert_after(return_if); } diff --git a/src/glsl/lower_mat_op_to_vec.cpp b/src/glsl/lower_mat_op_to_vec.cpp index 7065fdec35..8cbbfa713c 100644 --- a/src/glsl/lower_mat_op_to_vec.cpp +++ b/src/glsl/lower_mat_op_to_vec.cpp @@ -368,7 +368,7 @@ ir_mat_op_to_vec_visitor::visit_leave(ir_assignment *orig_assign) assert(orig_expr->get_num_operands() <= 2); - mem_ctx = talloc_parent(orig_assign); + mem_ctx = ralloc_parent(orig_assign); ir_dereference_variable *lhs_deref = orig_assign->lhs->as_dereference_variable(); diff --git a/src/glsl/lower_noise.cpp b/src/glsl/lower_noise.cpp index cb32d28348..85f59b675e 100644 --- a/src/glsl/lower_noise.cpp +++ b/src/glsl/lower_noise.cpp @@ -51,7 +51,7 @@ public: * that implements noise. No hardware has a noise instruction. */ if (expr->operation == ir_unop_noise) { - *rvalue = ir_constant::zero(talloc_parent(expr), expr->type); + *rvalue = ir_constant::zero(ralloc_parent(expr), expr->type); this->progress = true; } } diff --git a/src/glsl/lower_texture_projection.cpp b/src/glsl/lower_texture_projection.cpp index 1fd26a7a2b..6e3aaeccee 100644 --- a/src/glsl/lower_texture_projection.cpp +++ b/src/glsl/lower_texture_projection.cpp @@ -55,7 +55,7 @@ lower_texture_projection_visitor::visit_leave(ir_texture *ir) if (!ir->projector) return visit_continue; - void *mem_ctx = talloc_parent(ir); + void *mem_ctx = ralloc_parent(ir); ir_variable *var = new(mem_ctx) ir_variable(ir->projector->type, "projector", ir_var_auto); diff --git a/src/glsl/lower_variable_index_to_cond_assign.cpp b/src/glsl/lower_variable_index_to_cond_assign.cpp index 5f0dd73113..8eb1612f0a 100644 --- a/src/glsl/lower_variable_index_to_cond_assign.cpp +++ b/src/glsl/lower_variable_index_to_cond_assign.cpp @@ -42,6 +42,7 @@ struct assignment_generator ir_instruction* base_ir; ir_rvalue* array; bool is_write; + unsigned int write_mask; ir_variable* var; assignment_generator() @@ -53,15 +54,19 @@ struct assignment_generator /* Just clone the rest of the deref chain when trying to get at the * underlying variable. */ - void *mem_ctx = talloc_parent(base_ir); - ir_rvalue *element = + void *mem_ctx = ralloc_parent(base_ir); + ir_dereference *element = new(mem_ctx) ir_dereference_array(this->array->clone(mem_ctx, NULL), new(mem_ctx) ir_constant(i)); ir_rvalue *variable = new(mem_ctx) ir_dereference_variable(this->var); - ir_assignment *assignment = (is_write) - ? new(mem_ctx) ir_assignment(element, variable, condition) - : new(mem_ctx) ir_assignment(variable, element, condition); + ir_assignment *assignment; + if (is_write) { + assignment = new(mem_ctx) ir_assignment(element, variable, condition, + write_mask); + } else { + assignment = new(mem_ctx) ir_assignment(variable, element, condition); + } list->push_tail(assignment); } @@ -86,7 +91,7 @@ struct switch_generator linear_sequence_max_length(linear_sequence_max_length), condition_components(condition_components) { - this->mem_ctx = talloc_parent(index); + this->mem_ctx = ralloc_parent(index); } void linear_sequence(unsigned begin, unsigned end, exec_list *list) @@ -250,6 +255,7 @@ public: case ir_var_uniform: return this->lower_uniforms; case ir_var_in: + case ir_var_const_in: return (var->location == -1) ? this->lower_temps : this->lower_inputs; case ir_var_out: return (var->location == -1) ? this->lower_temps : this->lower_outputs; @@ -262,7 +268,7 @@ public: } ir_variable *convert_dereference_array(ir_dereference_array *orig_deref, - ir_rvalue* value) + ir_assignment* orig_assign) { assert(is_array_or_matrix(orig_deref->array)); @@ -270,17 +276,31 @@ public: ? orig_deref->array->type->length : orig_deref->array->type->matrix_columns; - void *const mem_ctx = talloc_parent(base_ir); - ir_variable *var = - new(mem_ctx) ir_variable(orig_deref->type, "dereference_array_value", - ir_var_temporary); - base_ir->insert_before(var); + void *const mem_ctx = ralloc_parent(base_ir); + + /* Temporary storage for either the result of the dereference of + * the array, or the RHS that's being assigned into the + * dereference of the array. + */ + ir_variable *var; + + if (orig_assign) { + var = new(mem_ctx) ir_variable(orig_assign->rhs->type, + "dereference_array_value", + ir_var_temporary); + base_ir->insert_before(var); - if (value) { ir_dereference *lhs = new(mem_ctx) ir_dereference_variable(var); - ir_assignment *assign = new(mem_ctx) ir_assignment(lhs, value, NULL); + ir_assignment *assign = new(mem_ctx) ir_assignment(lhs, + orig_assign->rhs, + NULL); base_ir->insert_before(assign); + } else { + var = new(mem_ctx) ir_variable(orig_deref->type, + "dereference_array_value", + ir_var_temporary); + base_ir->insert_before(var); } /* Store the index to a temporary to avoid reusing its tree. */ @@ -298,7 +318,12 @@ public: ag.array = orig_deref->array; ag.base_ir = base_ir; ag.var = var; - ag.is_write = !!value; + if (orig_assign) { + ag.is_write = true; + ag.write_mask = orig_assign->write_mask; + } else { + ag.is_write = false; + } switch_generator sg(ag, index, 4, 4); @@ -318,7 +343,7 @@ public: if (needs_lowering(orig_deref)) { ir_variable* var = convert_dereference_array(orig_deref, 0); assert(var); - *pir = new(talloc_parent(base_ir)) ir_dereference_variable(var); + *pir = new(ralloc_parent(base_ir)) ir_dereference_variable(var); this->progress = true; } } @@ -331,7 +356,7 @@ public: ir_dereference_array *orig_deref = ir->lhs->as_dereference_array(); if (needs_lowering(orig_deref)) { - convert_dereference_array(orig_deref, ir->rhs); + convert_dereference_array(orig_deref, ir); ir->remove(); this->progress = true; } diff --git a/src/glsl/lower_vec_index_to_cond_assign.cpp b/src/glsl/lower_vec_index_to_cond_assign.cpp index f8011a16e5..3c4d93201d 100644 --- a/src/glsl/lower_vec_index_to_cond_assign.cpp +++ b/src/glsl/lower_vec_index_to_cond_assign.cpp @@ -82,7 +82,7 @@ ir_vec_index_to_cond_assign_visitor::convert_vec_index_to_cond_assign(ir_rvalue orig_deref->array->type->is_array()) return ir; - void *mem_ctx = talloc_parent(ir); + void *mem_ctx = ralloc_parent(ir); assert(orig_deref->array_index->type->base_type == GLSL_TYPE_INT); @@ -167,7 +167,7 @@ ir_vec_index_to_cond_assign_visitor::visit_leave(ir_assignment *ir) orig_deref->array->type->is_array()) return visit_continue; - void *mem_ctx = talloc_parent(ir); + void *mem_ctx = ralloc_parent(ir); assert(orig_deref->array_index->type->base_type == GLSL_TYPE_INT); diff --git a/src/glsl/lower_vec_index_to_swizzle.cpp b/src/glsl/lower_vec_index_to_swizzle.cpp index 9ae43c0db1..c7630c28a8 100644 --- a/src/glsl/lower_vec_index_to_swizzle.cpp +++ b/src/glsl/lower_vec_index_to_swizzle.cpp @@ -74,7 +74,7 @@ ir_vec_index_to_swizzle_visitor::convert_vec_index_to_swizzle(ir_rvalue *ir) if (!ir_constant) return ir; - void *ctx = talloc_parent(ir); + void *ctx = ralloc_parent(ir); this->progress = true; return new(ctx) ir_swizzle(deref->array, ir_constant->value.i[0], 0, 0, 0, 1); diff --git a/src/glsl/lower_vector.cpp b/src/glsl/lower_vector.cpp index 93c37638bb..57963a121a 100644 --- a/src/glsl/lower_vector.cpp +++ b/src/glsl/lower_vector.cpp @@ -125,7 +125,7 @@ lower_vector_visitor::handle_rvalue(ir_rvalue **rvalue) if (this->dont_lower_swz && is_extended_swizzle(expr)) return; - /* FINISHME: Is this the right thing to use for the talloc context? + /* FINISHME: Is this the right thing to use for the ralloc context? */ void *const mem_ctx = expr; diff --git a/src/glsl/main.cpp b/src/glsl/main.cpp index c8fc267625..096da93dce 100644 --- a/src/glsl/main.cpp +++ b/src/glsl/main.cpp @@ -20,15 +20,8 @@ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER * DEALINGS IN THE SOFTWARE. */ -#include <cstdlib> -#include <cstdio> #include <getopt.h> -#include <sys/types.h> -#include <sys/stat.h> -#include <fcntl.h> -#include <unistd.h> - #include "ast.h" #include "glsl_parser_extras.h" #include "glsl_parser.h" @@ -61,7 +54,7 @@ _mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type) (void) ctx; assert(type == GL_FRAGMENT_SHADER || type == GL_VERTEX_SHADER); - shader = talloc_zero(NULL, struct gl_shader); + shader = rzalloc(NULL, struct gl_shader); if (shader) { shader->Type = type; shader->Name = name; @@ -77,11 +70,18 @@ initialize_context(struct gl_context *ctx, gl_api api) ctx->API = api; + ctx->Extensions.ARB_ES2_compatibility = GL_TRUE; ctx->Extensions.ARB_draw_buffers = GL_TRUE; + ctx->Extensions.ARB_draw_instanced = GL_TRUE; ctx->Extensions.ARB_fragment_coord_conventions = GL_TRUE; ctx->Extensions.EXT_texture_array = GL_TRUE; ctx->Extensions.NV_texture_rectangle = GL_TRUE; + /* GLSL 1.30 isn't fully supported, but we need to advertise 1.30 so that + * the built-in functions for 1.30 can be built. + */ + ctx->Const.GLSLVersion = 130; + /* 1.10 minimums. */ ctx->Const.MaxLights = 8; ctx->Const.MaxClipPlanes = 8; @@ -105,43 +105,45 @@ initialize_context(struct gl_context *ctx, gl_api api) ctx->Driver.NewShader = _mesa_new_shader; } -/* Returned string will have 'ctx' as its talloc owner. */ +/* Returned string will have 'ctx' as its ralloc owner. */ static char * load_text_file(void *ctx, const char *file_name) { char *text = NULL; - struct stat st; - ssize_t total_read = 0; - int fd = open(file_name, O_RDONLY); + size_t size; + size_t total_read = 0; + FILE *fp = fopen(file_name, "rb"); - if (fd < 0) { + if (!fp) { return NULL; } - if (fstat(fd, & st) == 0) { - text = (char *) talloc_size(ctx, st.st_size + 1); - if (text != NULL) { - do { - ssize_t bytes = read(fd, text + total_read, - st.st_size - total_read); - if (bytes < 0) { - free(text); - text = NULL; - break; - } - - if (bytes == 0) { - break; - } - - total_read += bytes; - } while (total_read < st.st_size); - - text[total_read] = '\0'; - } + fseek(fp, 0L, SEEK_END); + size = ftell(fp); + fseek(fp, 0L, SEEK_SET); + + text = (char *) ralloc_size(ctx, size + 1); + if (text != NULL) { + do { + size_t bytes = fread(text + total_read, + 1, size - total_read, fp); + if (bytes < size - total_read) { + free(text); + text = NULL; + break; + } + + if (bytes == 0) { + break; + } + + total_read += bytes; + } while (total_read < size); + + text[total_read] = '\0'; } - close(fd); + fclose(fp); return text; } @@ -188,7 +190,7 @@ compile_shader(struct gl_context *ctx, struct gl_shader *shader) const char *source = shader->Source; state->error = preprocess(state, &source, &state->info_log, - state->extensions, ctx->API); + state->extensions, ctx->API) != 0; if (!state->error) { _mesa_glsl_lexer_ctor(state, source); @@ -238,14 +240,14 @@ compile_shader(struct gl_context *ctx, struct gl_shader *shader) shader->num_builtins_to_link = state->num_builtins_to_link; if (shader->InfoLog) - talloc_free(shader->InfoLog); + ralloc_free(shader->InfoLog); shader->InfoLog = state->info_log; /* Retain any live IR, but trash the rest. */ reparent_ir(shader->ir, shader); - talloc_free(state); + ralloc_free(state); return; } @@ -270,16 +272,16 @@ main(int argc, char **argv) struct gl_shader_program *whole_program; - whole_program = talloc_zero (NULL, struct gl_shader_program); + whole_program = rzalloc (NULL, struct gl_shader_program); assert(whole_program != NULL); for (/* empty */; argc > optind; optind++) { - whole_program->Shaders = (struct gl_shader **) - talloc_realloc(whole_program, whole_program->Shaders, - struct gl_shader *, whole_program->NumShaders + 1); + whole_program->Shaders = + reralloc(whole_program, whole_program->Shaders, + struct gl_shader *, whole_program->NumShaders + 1); assert(whole_program->Shaders != NULL); - struct gl_shader *shader = talloc_zero(whole_program, gl_shader); + struct gl_shader *shader = rzalloc(whole_program, gl_shader); whole_program->Shaders[whole_program->NumShaders] = shader; whole_program->NumShaders++; @@ -322,9 +324,9 @@ main(int argc, char **argv) } for (unsigned i = 0; i < MESA_SHADER_TYPES; i++) - talloc_free(whole_program->_LinkedShaders[i]); + ralloc_free(whole_program->_LinkedShaders[i]); - talloc_free(whole_program); + ralloc_free(whole_program); _mesa_glsl_release_types(); _mesa_glsl_release_functions(); diff --git a/src/glsl/opt_algebraic.cpp b/src/glsl/opt_algebraic.cpp index 20f6159f0e..cade9611db 100644 --- a/src/glsl/opt_algebraic.cpp +++ b/src/glsl/opt_algebraic.cpp @@ -191,7 +191,7 @@ ir_algebraic_visitor::handle_expression(ir_expression *ir) } if (this->mem_ctx == NULL) - this->mem_ctx = talloc_parent(ir); + this->mem_ctx = ralloc_parent(ir); switch (ir->operation) { case ir_unop_logic_not: { diff --git a/src/glsl/opt_constant_folding.cpp b/src/glsl/opt_constant_folding.cpp index d69ca75fe0..599b21525d 100644 --- a/src/glsl/opt_constant_folding.cpp +++ b/src/glsl/opt_constant_folding.cpp @@ -122,7 +122,7 @@ ir_constant_folding_visitor::visit_enter(ir_call *ir) ir_rvalue *param_rval = (ir_rvalue *)iter.get(); ir_variable *sig_param = (ir_variable *)sig_iter.get(); - if (sig_param->mode == ir_var_in) { + if (sig_param->mode == ir_var_in || sig_param->mode == ir_var_const_in) { ir_rvalue *new_param = param_rval; handle_rvalue(&new_param); diff --git a/src/glsl/opt_constant_propagation.cpp b/src/glsl/opt_constant_propagation.cpp index 6719fc8186..4425f42119 100644 --- a/src/glsl/opt_constant_propagation.cpp +++ b/src/glsl/opt_constant_propagation.cpp @@ -78,13 +78,13 @@ public: ir_constant_propagation_visitor() { progress = false; - mem_ctx = talloc_new(0); + mem_ctx = ralloc_context(0); this->acp = new(mem_ctx) exec_list; this->kills = new(mem_ctx) exec_list; } ~ir_constant_propagation_visitor() { - talloc_free(mem_ctx); + ralloc_free(mem_ctx); } virtual ir_visitor_status visit_enter(class ir_loop *); @@ -195,7 +195,7 @@ ir_constant_propagation_visitor::handle_rvalue(ir_rvalue **rvalue) } } - *rvalue = new(talloc_parent(deref)) ir_constant(type, &data); + *rvalue = new(ralloc_parent(deref)) ir_constant(type, &data); this->progress = true; } @@ -398,11 +398,8 @@ ir_constant_propagation_visitor::add_constant(ir_assignment *ir) { acp_entry *entry; - if (ir->condition) { - ir_constant *condition = ir->condition->as_constant(); - if (!condition || !condition->value.b[0]) - return; - } + if (ir->condition) + return; if (!ir->write_mask) return; diff --git a/src/glsl/opt_constant_variable.cpp b/src/glsl/opt_constant_variable.cpp index 8068d0c143..3fa7c3badc 100644 --- a/src/glsl/opt_constant_variable.cpp +++ b/src/glsl/opt_constant_variable.cpp @@ -104,11 +104,8 @@ ir_constant_variable_visitor::visit_enter(ir_assignment *ir) /* OK, now find if we actually have all the right conditions for * this to be a constant value assigned to the var. */ - if (ir->condition) { - constval = ir->condition->constant_expression_value(); - if (!constval || !constval->value.b[0]) - return visit_continue; - } + if (ir->condition) + return visit_continue; ir_variable *var = ir->whole_variable_written(); if (!var) diff --git a/src/glsl/opt_copy_propagation.cpp b/src/glsl/opt_copy_propagation.cpp index 8d07fefbfd..efa3afda35 100644 --- a/src/glsl/opt_copy_propagation.cpp +++ b/src/glsl/opt_copy_propagation.cpp @@ -71,13 +71,13 @@ public: ir_copy_propagation_visitor() { progress = false; - mem_ctx = talloc_new(0); + mem_ctx = ralloc_context(0); this->acp = new(mem_ctx) exec_list; this->kills = new(mem_ctx) exec_list; } ~ir_copy_propagation_visitor() { - talloc_free(mem_ctx); + ralloc_free(mem_ctx); } virtual ir_visitor_status visit(class ir_dereference_variable *); @@ -191,7 +191,7 @@ ir_copy_propagation_visitor::visit_enter(ir_call *ir) sig_param_iter.next(); } - /* Since we're unlinked, we don't (necssarily) know the side effects of + /* Since we're unlinked, we don't (necessarily) know the side effects of * this call. So kill all copies. */ acp->make_empty(); @@ -309,11 +309,8 @@ ir_copy_propagation_visitor::add_copy(ir_assignment *ir) { acp_entry *entry; - if (ir->condition) { - ir_constant *condition = ir->condition->as_constant(); - if (!condition || !condition->value.b[0]) - return; - } + if (ir->condition) + return; ir_variable *lhs_var = ir->whole_variable_written(); ir_variable *rhs_var = ir->rhs->whole_variable_referenced(); @@ -325,7 +322,7 @@ ir_copy_propagation_visitor::add_copy(ir_assignment *ir) * calling us. Just flag it to not execute, and someone else * will clean up the mess. */ - ir->condition = new(talloc_parent(ir)) ir_constant(false); + ir->condition = new(ralloc_parent(ir)) ir_constant(false); this->progress = true; } else { entry = new(this->mem_ctx) acp_entry(lhs_var, rhs_var); diff --git a/src/glsl/opt_copy_propagation_elements.cpp b/src/glsl/opt_copy_propagation_elements.cpp new file mode 100644 index 0000000000..8541d9a8ee --- /dev/null +++ b/src/glsl/opt_copy_propagation_elements.cpp @@ -0,0 +1,458 @@ +/* + * 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 opt_copy_propagation_elements.cpp + * + * Replaces usage of recently-copied components of variables with the + * previous copy of the variable. + * + * This pass can be compared with opt_copy_propagation, which operands + * on arbitrary whole-variable copies. However, in order to handle + * the copy propagation of swizzled variables or writemasked writes, + * we want to track things on a channel-wise basis. I found that + * trying to mix the swizzled/writemasked support here with the + * whole-variable stuff in opt_copy_propagation.cpp just made a mess, + * so this is separate despite the ACP handling being somewhat + * similar. + * + * This should reduce the number of MOV instructions in the generated + * programs unless copy propagation is also done on the LIR, and may + * help anyway by triggering other optimizations that live in the HIR. + */ + +#include "ir.h" +#include "ir_rvalue_visitor.h" +#include "ir_basic_block.h" +#include "ir_optimization.h" +#include "glsl_types.h" + +static bool debug = false; + +class acp_entry : public exec_node +{ +public: + acp_entry(ir_variable *lhs, ir_variable *rhs, int write_mask, int swizzle[4]) + { + this->lhs = lhs; + this->rhs = rhs; + this->write_mask = write_mask; + memcpy(this->swizzle, swizzle, sizeof(this->swizzle)); + } + + acp_entry(acp_entry *a) + { + this->lhs = a->lhs; + this->rhs = a->rhs; + this->write_mask = a->write_mask; + memcpy(this->swizzle, a->swizzle, sizeof(this->swizzle)); + } + + ir_variable *lhs; + ir_variable *rhs; + unsigned int write_mask; + int swizzle[4]; +}; + + +class kill_entry : public exec_node +{ +public: + kill_entry(ir_variable *var, int write_mask) + { + this->var = var; + this->write_mask = write_mask; + } + + ir_variable *var; + unsigned int write_mask; +}; + +class ir_copy_propagation_elements_visitor : public ir_rvalue_visitor { +public: + ir_copy_propagation_elements_visitor() + { + this->progress = false; + this->mem_ctx = ralloc_context(NULL); + this->shader_mem_ctx = NULL; + this->acp = new(mem_ctx) exec_list; + this->kills = new(mem_ctx) exec_list; + } + ~ir_copy_propagation_elements_visitor() + { + ralloc_free(mem_ctx); + } + + virtual ir_visitor_status visit_enter(class ir_loop *); + virtual ir_visitor_status visit_enter(class ir_function_signature *); + virtual ir_visitor_status visit_leave(class ir_assignment *); + virtual ir_visitor_status visit_enter(class ir_call *); + virtual ir_visitor_status visit_enter(class ir_if *); + + void handle_rvalue(ir_rvalue **rvalue); + + void add_copy(ir_assignment *ir); + void kill(kill_entry *k); + void handle_if_block(exec_list *instructions); + + /** List of acp_entry: The available copies to propagate */ + exec_list *acp; + /** + * List of kill_entry: The variables whose values were killed in this + * block. + */ + exec_list *kills; + + bool progress; + + bool killed_all; + + /* Context for our local data structures. */ + void *mem_ctx; + /* Context for allocating new shader nodes. */ + void *shader_mem_ctx; +}; + +ir_visitor_status +ir_copy_propagation_elements_visitor::visit_enter(ir_function_signature *ir) +{ + /* Treat entry into a function signature as a completely separate + * block. Any instructions at global scope will be shuffled into + * main() at link time, so they're irrelevant to us. + */ + exec_list *orig_acp = this->acp; + exec_list *orig_kills = this->kills; + bool orig_killed_all = this->killed_all; + + this->acp = new(mem_ctx) exec_list; + this->kills = new(mem_ctx) exec_list; + this->killed_all = false; + + visit_list_elements(this, &ir->body); + + this->kills = orig_kills; + this->acp = orig_acp; + this->killed_all = orig_killed_all; + + return visit_continue_with_parent; +} + +ir_visitor_status +ir_copy_propagation_elements_visitor::visit_leave(ir_assignment *ir) +{ + ir_dereference_variable *lhs = ir->lhs->as_dereference_variable(); + + if (lhs && (lhs->type->is_scalar() || lhs->type->is_vector())) { + kill_entry *k = new(mem_ctx) kill_entry(lhs->var, ir->write_mask); + kill(k); + } + + add_copy(ir); + + return visit_continue; +} + +/** + * Replaces dereferences of ACP RHS variables with ACP LHS variables. + * + * This is where the actual copy propagation occurs. Note that the + * rewriting of ir_dereference means that the ir_dereference instance + * must not be shared by multiple IR operations! + */ +void +ir_copy_propagation_elements_visitor::handle_rvalue(ir_rvalue **ir) +{ + int swizzle_chan[4]; + ir_dereference_variable *deref_var; + ir_variable *source[4] = {NULL, NULL, NULL, NULL}; + int source_chan[4]; + int chans; + + if (!*ir) + return; + + ir_swizzle *swizzle = (*ir)->as_swizzle(); + if (swizzle) { + deref_var = swizzle->val->as_dereference_variable(); + if (!deref_var) + return; + + swizzle_chan[0] = swizzle->mask.x; + swizzle_chan[1] = swizzle->mask.y; + swizzle_chan[2] = swizzle->mask.z; + swizzle_chan[3] = swizzle->mask.w; + chans = swizzle->type->vector_elements; + } else { + deref_var = (*ir)->as_dereference_variable(); + if (!deref_var) + return; + + swizzle_chan[0] = 0; + swizzle_chan[1] = 1; + swizzle_chan[2] = 2; + swizzle_chan[3] = 3; + chans = deref_var->type->vector_elements; + } + + if (this->in_assignee) + return; + + ir_variable *var = deref_var->var; + + /* Try to find ACP entries covering swizzle_chan[], hoping they're + * the same source variable. + */ + foreach_iter(exec_list_iterator, iter, *this->acp) { + acp_entry *entry = (acp_entry *)iter.get(); + + if (var == entry->lhs) { + for (int c = 0; c < chans; c++) { + if (entry->write_mask & (1 << swizzle_chan[c])) { + source[c] = entry->rhs; + source_chan[c] = entry->swizzle[swizzle_chan[c]]; + } + } + } + } + + /* Make sure all channels are copying from the same source variable. */ + if (!source[0]) + return; + for (int c = 1; c < chans; c++) { + if (source[c] != source[0]) + return; + } + + if (!shader_mem_ctx) + shader_mem_ctx = ralloc_parent(deref_var); + + if (debug) { + printf("Copy propagation from:\n"); + (*ir)->print(); + } + + deref_var = new(shader_mem_ctx) ir_dereference_variable(source[0]); + *ir = new(shader_mem_ctx) ir_swizzle(deref_var, + source_chan[0], + source_chan[1], + source_chan[2], + source_chan[3], + chans); + + if (debug) { + printf("to:\n"); + (*ir)->print(); + printf("\n"); + } +} + + +ir_visitor_status +ir_copy_propagation_elements_visitor::visit_enter(ir_call *ir) +{ + /* Do copy propagation on call parameters, but skip any out params */ + exec_list_iterator sig_param_iter = ir->get_callee()->parameters.iterator(); + foreach_iter(exec_list_iterator, iter, ir->actual_parameters) { + ir_variable *sig_param = (ir_variable *)sig_param_iter.get(); + ir_instruction *ir = (ir_instruction *)iter.get(); + if (sig_param->mode != ir_var_out && sig_param->mode != ir_var_inout) { + ir->accept(this); + } + sig_param_iter.next(); + } + + /* Since we're unlinked, we don't (necessarily) know the side effects of + * this call. So kill all copies. + */ + acp->make_empty(); + this->killed_all = true; + + return visit_continue_with_parent; +} + +void +ir_copy_propagation_elements_visitor::handle_if_block(exec_list *instructions) +{ + exec_list *orig_acp = this->acp; + exec_list *orig_kills = this->kills; + bool orig_killed_all = this->killed_all; + + this->acp = new(mem_ctx) exec_list; + this->kills = new(mem_ctx) exec_list; + this->killed_all = false; + + /* Populate the initial acp with a copy of the original */ + foreach_iter(exec_list_iterator, iter, *orig_acp) { + acp_entry *a = (acp_entry *)iter.get(); + this->acp->push_tail(new(this->mem_ctx) acp_entry(a)); + } + + visit_list_elements(this, instructions); + + if (this->killed_all) { + orig_acp->make_empty(); + } + + exec_list *new_kills = this->kills; + this->kills = orig_kills; + this->acp = orig_acp; + this->killed_all = this->killed_all || orig_killed_all; + + /* Move the new kills into the parent block's list, removing them + * from the parent's ACP list in the process. + */ + foreach_list_safe(node, new_kills) { + kill_entry *k = (kill_entry *)node; + kill(k); + } +} + +ir_visitor_status +ir_copy_propagation_elements_visitor::visit_enter(ir_if *ir) +{ + ir->condition->accept(this); + + handle_if_block(&ir->then_instructions); + handle_if_block(&ir->else_instructions); + + /* handle_if_block() already descended into the children. */ + return visit_continue_with_parent; +} + +ir_visitor_status +ir_copy_propagation_elements_visitor::visit_enter(ir_loop *ir) +{ + exec_list *orig_acp = this->acp; + exec_list *orig_kills = this->kills; + bool orig_killed_all = this->killed_all; + + /* FINISHME: For now, the initial acp for loops is totally empty. + * We could go through once, then go through again with the acp + * cloned minus the killed entries after the first run through. + */ + this->acp = new(mem_ctx) exec_list; + this->kills = new(mem_ctx) exec_list; + this->killed_all = false; + + visit_list_elements(this, &ir->body_instructions); + + if (this->killed_all) { + orig_acp->make_empty(); + } + + exec_list *new_kills = this->kills; + this->kills = orig_kills; + this->acp = orig_acp; + this->killed_all = this->killed_all || orig_killed_all; + + foreach_list_safe(node, new_kills) { + kill_entry *k = (kill_entry *)node; + kill(k); + } + + /* already descended into the children. */ + return visit_continue_with_parent; +} + +/* Remove any entries currently in the ACP for this kill. */ +void +ir_copy_propagation_elements_visitor::kill(kill_entry *k) +{ + foreach_list_safe(node, acp) { + acp_entry *entry = (acp_entry *)node; + + if (entry->lhs == k->var) { + entry->write_mask = entry->write_mask & ~k->write_mask; + if (entry->write_mask == 0) + entry->remove(); + } + if (entry->rhs == k->var) { + entry->remove(); + } + } + + /* If we were on a list, remove ourselves before inserting */ + if (k->next) + k->remove(); + + this->kills->push_tail(k); +} + +/** + * Adds directly-copied channels between vector variables to the available + * copy propagation list. + */ +void +ir_copy_propagation_elements_visitor::add_copy(ir_assignment *ir) +{ + acp_entry *entry; + int orig_swizzle[4] = {0, 1, 2, 3}; + int swizzle[4]; + + if (ir->condition) + return; + + ir_dereference_variable *lhs = ir->lhs->as_dereference_variable(); + if (!lhs || !(lhs->type->is_scalar() || lhs->type->is_vector())) + return; + + ir_dereference_variable *rhs = ir->rhs->as_dereference_variable(); + if (!rhs) { + ir_swizzle *swiz = ir->rhs->as_swizzle(); + if (!swiz) + return; + + rhs = swiz->val->as_dereference_variable(); + if (!rhs) + return; + + orig_swizzle[0] = swiz->mask.x; + orig_swizzle[1] = swiz->mask.y; + orig_swizzle[2] = swiz->mask.z; + orig_swizzle[3] = swiz->mask.w; + } + + /* Move the swizzle channels out to the positions they match in the + * destination. We don't want to have to rewrite the swizzle[] + * array every time we clear a bit of the write_mask. + */ + int j = 0; + for (int i = 0; i < 4; i++) { + if (ir->write_mask & (1 << i)) + swizzle[i] = orig_swizzle[j++]; + } + + entry = new(this->mem_ctx) acp_entry(lhs->var, rhs->var, ir->write_mask, + swizzle); + this->acp->push_tail(entry); +} + +bool +do_copy_propagation_elements(exec_list *instructions) +{ + ir_copy_propagation_elements_visitor v; + + visit_list_elements(&v, instructions); + + return v.progress; +} diff --git a/src/glsl/opt_dead_code_local.cpp b/src/glsl/opt_dead_code_local.cpp index 5689e7d20d..39962bd602 100644 --- a/src/glsl/opt_dead_code_local.cpp +++ b/src/glsl/opt_dead_code_local.cpp @@ -129,15 +129,8 @@ process_assignment(void *ctx, ir_assignment *ir, exec_list *assignments) var = ir->lhs->variable_referenced(); assert(var); - bool always_assign = true; - if (ir->condition) { - ir_constant *condition = ir->condition->as_constant(); - if (!condition || !condition->value.b[0]) - always_assign = false; - } - /* Now, check if we did a whole-variable assignment. */ - if (always_assign && (ir->whole_variable_written() != NULL)) { + if (!ir->condition && (ir->whole_variable_written() != NULL)) { /* We did a whole-variable assignment. So, any instruction in * the assignment list with the same LHS is dead. */ @@ -190,7 +183,7 @@ dead_code_local_basic_block(ir_instruction *first, bool *out_progress = (bool *)data; bool progress = false; - void *ctx = talloc_new(NULL); + void *ctx = ralloc_context(NULL); /* Safe looping, since process_assignment */ for (ir = first, ir_next = (ir_instruction *)first->next;; ir = ir_next, ir_next = (ir_instruction *)ir->next) { @@ -212,7 +205,7 @@ dead_code_local_basic_block(ir_instruction *first, break; } *out_progress = progress; - talloc_free(ctx); + ralloc_free(ctx); } /** diff --git a/src/glsl/opt_dead_functions.cpp b/src/glsl/opt_dead_functions.cpp index cf91cb6d36..7c64c618c0 100644 --- a/src/glsl/opt_dead_functions.cpp +++ b/src/glsl/opt_dead_functions.cpp @@ -1,109 +1,120 @@ - /* - * 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 opt_dead_functions.cpp - * - * Eliminates unused functions from the linked program. - */ - - #include "ir.h" - #include "ir_visitor.h" - #include "ir_expression_flattening.h" - #include "glsl_types.h" - - class signature_entry : public exec_node - { - public: - signature_entry(ir_function_signature *sig) - { - this->signature = sig; - this->used = false; - } - - ir_function_signature *signature; - bool used; - }; - - class ir_dead_functions_visitor : public ir_hierarchical_visitor { - public: - ir_dead_functions_visitor() - { - this->mem_ctx = talloc_new(NULL); - } - - ~ir_dead_functions_visitor() - { - talloc_free(this->mem_ctx); - } - - virtual ir_visitor_status visit_enter(ir_function_signature *); - virtual ir_visitor_status visit_enter(ir_call *); - - signature_entry *get_signature_entry(ir_function_signature *var); - - bool (*predicate)(ir_instruction *ir); - - /* List of signature_entry */ - exec_list signature_list; - void *mem_ctx; - }; - - - signature_entry * - ir_dead_functions_visitor::get_signature_entry(ir_function_signature *sig) - { - foreach_iter(exec_list_iterator, iter, this->signature_list) { - signature_entry *entry = (signature_entry *)iter.get(); - if (entry->signature == sig) - return entry; - } - - signature_entry *entry = new(mem_ctx) signature_entry(sig); - this->signature_list.push_tail(entry); - return entry; - } - - - ir_visitor_status - ir_dead_functions_visitor::visit_enter(ir_function_signature *ir) - { - signature_entry *entry = this->get_signature_entry(ir); - - if (strcmp(ir->function_name(), "main") == 0) { - entry->used = true; - } - - return visit_continue; - } - - - ir_visitor_status - ir_dead_functions_visitor::visit_enter(ir_call *ir) - { - signature_entry *entry = this->get_signature_entry(ir->get_callee()); - - entry->used = true; +/* + * 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 opt_dead_functions.cpp + * + * Eliminates unused functions from the linked program. + */ + +#include "ir.h" +#include "ir_visitor.h" +#include "ir_expression_flattening.h" +#include "glsl_types.h" + +class signature_entry : public exec_node +{ +public: + signature_entry(ir_function_signature *sig) + { + this->signature = sig; + this->used = false; + } + + ir_function_signature *signature; + bool used; +}; + +class ir_dead_functions_visitor : public ir_hierarchical_visitor { +public: + ir_dead_functions_visitor() + { + this->mem_ctx = ralloc_context(NULL); + this->seen_another_function_signature = false; + } + + ~ir_dead_functions_visitor() + { + ralloc_free(this->mem_ctx); + } + + virtual ir_visitor_status visit_enter(ir_function_signature *); + virtual ir_visitor_status visit_enter(ir_call *); + + signature_entry *get_signature_entry(ir_function_signature *var); + + bool (*predicate)(ir_instruction *ir); + + bool seen_another_function_signature; + + /* List of signature_entry */ + exec_list signature_list; + void *mem_ctx; +}; + + +signature_entry * +ir_dead_functions_visitor::get_signature_entry(ir_function_signature *sig) +{ + foreach_iter(exec_list_iterator, iter, this->signature_list) { + signature_entry *entry = (signature_entry *)iter.get(); + if (entry->signature == sig) + return entry; + } + + signature_entry *entry = new(mem_ctx) signature_entry(sig); + this->signature_list.push_tail(entry); + return entry; +} + + +ir_visitor_status +ir_dead_functions_visitor::visit_enter(ir_function_signature *ir) +{ + signature_entry *entry = this->get_signature_entry(ir); + + if (strcmp(ir->function_name(), "main") == 0) { + entry->used = true; + } + + /* If this is the first signature to look at, no need to descend to see + * if it has calls to another function signature. + */ + if (!this->seen_another_function_signature) { + this->seen_another_function_signature = true; + return visit_continue_with_parent; + } + + return visit_continue; +} + + +ir_visitor_status +ir_dead_functions_visitor::visit_enter(ir_call *ir) +{ + signature_entry *entry = this->get_signature_entry(ir->get_callee()); + + entry->used = true; return visit_continue; } diff --git a/src/glsl/opt_discard_simplification.cpp b/src/glsl/opt_discard_simplification.cpp index 0e577c478a..7c2928d271 100644 --- a/src/glsl/opt_discard_simplification.cpp +++ b/src/glsl/opt_discard_simplification.cpp @@ -95,6 +95,7 @@ public: ir_visitor_status visit_enter(ir_if *); ir_visitor_status visit_enter(ir_loop *); + ir_visitor_status visit_enter(ir_assignment *); bool progress; }; @@ -117,6 +118,15 @@ is_only_instruction(ir_discard *discard) discard->next->is_tail_sentinel()); } +/* We only care about the top level instructions, so don't descend + * into expressions. + */ +ir_visitor_status +discard_simplifier::visit_enter(ir_assignment *ir) +{ + return visit_continue_with_parent; +} + ir_visitor_status discard_simplifier::visit_enter(ir_if *ir) { diff --git a/src/glsl/opt_function_inlining.cpp b/src/glsl/opt_function_inlining.cpp index 169fd82688..8fef358cc9 100644 --- a/src/glsl/opt_function_inlining.cpp +++ b/src/glsl/opt_function_inlining.cpp @@ -89,7 +89,7 @@ do_function_inlining(exec_list *instructions) static void replace_return_with_assignment(ir_instruction *ir, void *data) { - void *ctx = talloc_parent(ir); + void *ctx = ralloc_parent(ir); ir_variable *retval = (ir_variable *)data; ir_return *ret = ir->as_return(); @@ -110,7 +110,7 @@ replace_return_with_assignment(ir_instruction *ir, void *data) ir_rvalue * ir_call::generate_inline(ir_instruction *next_ir) { - void *ctx = talloc_parent(this); + void *ctx = ralloc_parent(this); ir_variable **parameters; int num_parameters; int i; @@ -126,7 +126,7 @@ ir_call::generate_inline(ir_instruction *next_ir) parameters = new ir_variable *[num_parameters]; /* Generate storage for the return value. */ - if (this->callee->return_type) { + if (!this->callee->return_type->is_void()) { retval = new(ctx) ir_variable(this->callee->return_type, "_ret_val", ir_var_auto); next_ir->insert_before(retval); @@ -165,6 +165,7 @@ ir_call::generate_inline(ir_instruction *next_ir) /* Move the actual param into our param variable if it's an 'in' type. */ if (parameters[i] && (sig_param->mode == ir_var_in || + sig_param->mode == ir_var_const_in || sig_param->mode == ir_var_inout)) { ir_assignment *assign; @@ -208,10 +209,7 @@ ir_call::generate_inline(ir_instruction *next_ir) } /* Now push those new instructions in. */ - foreach_iter(exec_list_iterator, iter, new_instructions) { - ir_instruction *ir = (ir_instruction *)iter.get(); - next_ir->insert_before(ir); - } + next_ir->insert_before(&new_instructions); /* Copy back the value of any 'out' parameters from the function body * variables to our own. @@ -357,7 +355,7 @@ ir_sampler_replacement_visitor::replace_deref(ir_dereference **deref) { ir_dereference_variable *deref_var = (*deref)->as_dereference_variable(); if (deref_var && deref_var->var == this->sampler) { - *deref = this->deref->clone(talloc_parent(*deref), NULL); + *deref = this->deref->clone(ralloc_parent(*deref), NULL); } } diff --git a/src/glsl/opt_if_simplification.cpp b/src/glsl/opt_if_simplification.cpp index 618bacfecf..29b1d18aa5 100644 --- a/src/glsl/opt_if_simplification.cpp +++ b/src/glsl/opt_if_simplification.cpp @@ -38,10 +38,20 @@ public: } ir_visitor_status visit_leave(ir_if *); + ir_visitor_status visit_enter(ir_assignment *); bool made_progress; }; +/* We only care about the top level "if" instructions, so don't + * descend into expressions. + */ +ir_visitor_status +ir_if_simplification_visitor::visit_enter(ir_assignment *ir) +{ + return visit_continue_with_parent; +} + bool do_if_simplification(exec_list *instructions) { diff --git a/src/glsl/opt_redundant_jumps.cpp b/src/glsl/opt_redundant_jumps.cpp index edf4bb6c22..f350fa947c 100644 --- a/src/glsl/opt_redundant_jumps.cpp +++ b/src/glsl/opt_redundant_jumps.cpp @@ -37,10 +37,19 @@ public: virtual ir_visitor_status visit_leave(ir_if *); virtual ir_visitor_status visit_leave(ir_loop *); + virtual ir_visitor_status visit_enter(ir_assignment *); bool progress; }; +/* We only care about the top level instructions, so don't descend + * into expressions. + */ +ir_visitor_status +redundant_jumps_visitor::visit_enter(ir_assignment *ir) +{ + return visit_continue_with_parent; +} ir_visitor_status redundant_jumps_visitor::visit_leave(ir_if *ir) diff --git a/src/glsl/opt_structure_splitting.cpp b/src/glsl/opt_structure_splitting.cpp index d6191002c2..2c1f6bb227 100644 --- a/src/glsl/opt_structure_splitting.cpp +++ b/src/glsl/opt_structure_splitting.cpp @@ -65,7 +65,7 @@ public: ir_variable **components; - /** talloc_parent(this->var) -- the shader's talloc context. */ + /** ralloc_parent(this->var) -- the shader's ralloc context. */ void *mem_ctx; }; @@ -74,13 +74,13 @@ class ir_structure_reference_visitor : public ir_hierarchical_visitor { public: ir_structure_reference_visitor(void) { - this->mem_ctx = talloc_new(NULL); + this->mem_ctx = ralloc_context(NULL); this->variable_list.make_empty(); } ~ir_structure_reference_visitor(void) { - talloc_free(mem_ctx); + ralloc_free(mem_ctx); } virtual ir_visitor_status visit(ir_variable *); @@ -151,6 +151,12 @@ ir_structure_reference_visitor::visit_enter(ir_dereference_record *ir) ir_visitor_status ir_structure_reference_visitor::visit_enter(ir_assignment *ir) { + /* If there are no structure references yet, no need to bother with + * processing the expression tree. + */ + if (this->variable_list.is_empty()) + return visit_continue_with_parent; + if (ir->lhs->as_dereference_variable() && ir->rhs->as_dereference_variable() && !ir->condition) { @@ -322,7 +328,7 @@ do_structure_splitting(exec_list *instructions) if (refs.variable_list.is_empty()) return false; - void *mem_ctx = talloc_new(NULL); + void *mem_ctx = ralloc_context(NULL); /* Replace the decls of the structures to be split with their split * components. @@ -331,14 +337,14 @@ do_structure_splitting(exec_list *instructions) variable_entry2 *entry = (variable_entry2 *)iter.get(); const struct glsl_type *type = entry->var->type; - entry->mem_ctx = talloc_parent(entry->var); + entry->mem_ctx = ralloc_parent(entry->var); - entry->components = talloc_array(mem_ctx, + entry->components = ralloc_array(mem_ctx, ir_variable *, type->length); for (unsigned int i = 0; i < entry->var->type->length; i++) { - const char *name = talloc_asprintf(mem_ctx, "%s_%s", + const char *name = ralloc_asprintf(mem_ctx, "%s_%s", entry->var->name, type->fields.structure[i].name); @@ -355,7 +361,7 @@ do_structure_splitting(exec_list *instructions) ir_structure_splitting_visitor split(&refs.variable_list); visit_list_elements(&split, instructions); - talloc_free(mem_ctx); + ralloc_free(mem_ctx); return true; } diff --git a/src/glsl/opt_tree_grafting.cpp b/src/glsl/opt_tree_grafting.cpp index 9917c045b1..1ef940f9c7 100644 --- a/src/glsl/opt_tree_grafting.cpp +++ b/src/glsl/opt_tree_grafting.cpp @@ -195,7 +195,7 @@ ir_tree_grafting_visitor::visit_enter(ir_call *ir) ir_rvalue *ir = (ir_rvalue *)iter.get(); ir_rvalue *new_ir = ir; - if (sig_param->mode != ir_var_in) + if (sig_param->mode != ir_var_in && sig_param->mode != ir_var_const_in) continue; if (do_graft(&new_ir)) { @@ -245,6 +245,7 @@ ir_tree_grafting_visitor::visit_enter(ir_texture *ir) { if (do_graft(&ir->coordinate) || do_graft(&ir->projector) || + do_graft(&ir->offset) || do_graft(&ir->shadow_comparitor)) return visit_stop; diff --git a/src/glsl/ralloc.c b/src/glsl/ralloc.c new file mode 100644 index 0000000000..757ab5c76b --- /dev/null +++ b/src/glsl/ralloc.c @@ -0,0 +1,462 @@ +/* + * 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. + */ + +#include <assert.h> +#include <stdlib.h> +#include <stdarg.h> +#include <stdio.h> +#include <string.h> +#include <stdint.h> + +#include "ralloc.h" + +#ifdef __GNUC__ +#define likely(x) __builtin_expect(!!(x),1) +#define unlikely(x) __builtin_expect(!!(x),0) +#else +#define likely(x) !!(x) +#define unlikely(x) !!(x) +#endif + +#ifndef va_copy +#ifdef __va_copy +#define va_copy(dest, src) __va_copy((dest), (src)) +#else +#define va_copy(dest, src) (dest) = (src) +#endif +#endif + +#ifdef ANDROID +#define SIZE_MAX UINT32_MAX +#endif + +#define CANARY 0x5A1106 + +struct ralloc_header +{ + /* A canary value used to determine whether a pointer is ralloc'd. */ + unsigned canary; + + struct ralloc_header *parent; + + /* The first child (head of a linked list) */ + struct ralloc_header *child; + + /* Linked list of siblings */ + struct ralloc_header *prev; + struct ralloc_header *next; + + void (*destructor)(void *); +}; + +typedef struct ralloc_header ralloc_header; + +static void unlink_block(ralloc_header *info); +static void unsafe_free(ralloc_header *info); + +static ralloc_header * +get_header(const void *ptr) +{ + ralloc_header *info = (ralloc_header *) (((char *) ptr) - + sizeof(ralloc_header)); + assert(info->canary == CANARY); + return info; +} + +#define PTR_FROM_HEADER(info) (((char *) info) + sizeof(ralloc_header)) + +static void +add_child(ralloc_header *parent, ralloc_header *info) +{ + if (parent != NULL) { + info->parent = parent; + info->next = parent->child; + parent->child = info; + + if (info->next != NULL) + info->next->prev = info; + } +} + +void * +ralloc_context(const void *ctx) +{ + return ralloc_size(ctx, 0); +} + +void * +ralloc_size(const void *ctx, size_t size) +{ + void *block = calloc(1, size + sizeof(ralloc_header)); + + ralloc_header *info = (ralloc_header *) block; + ralloc_header *parent = ctx != NULL ? get_header(ctx) : NULL; + + add_child(parent, info); + + info->canary = CANARY; + + return PTR_FROM_HEADER(info); +} + +void * +rzalloc_size(const void *ctx, size_t size) +{ + void *ptr = ralloc_size(ctx, size); + if (likely(ptr != NULL)) + memset(ptr, 0, size); + return ptr; +} + +/* helper function - assumes ptr != NULL */ +static void * +resize(void *ptr, size_t size) +{ + ralloc_header *child, *old, *info; + + old = get_header(ptr); + info = realloc(old, size + sizeof(ralloc_header)); + + if (info == NULL) + return NULL; + + /* Update parent and sibling's links to the reallocated node. */ + if (info != old && info->parent != NULL) { + if (info->parent->child == old) + info->parent->child = info; + + if (info->prev != NULL) + info->prev->next = info; + + if (info->next != NULL) + info->next->prev = info; + } + + /* Update child->parent links for all children */ + for (child = info->child; child != NULL; child = child->next) + child->parent = info; + + return PTR_FROM_HEADER(info); +} + +void * +reralloc_size(const void *ctx, void *ptr, size_t size) +{ + if (unlikely(ptr == NULL)) + return ralloc_size(ctx, size); + + assert(ralloc_parent(ptr) == ctx); + return resize(ptr, size); +} + +void * +ralloc_array_size(const void *ctx, size_t size, unsigned count) +{ + if (count > SIZE_MAX/size) + return NULL; + + return ralloc_size(ctx, size * count); +} + +void * +rzalloc_array_size(const void *ctx, size_t size, unsigned count) +{ + if (count > SIZE_MAX/size) + return NULL; + + return rzalloc_size(ctx, size * count); +} + +void * +reralloc_array_size(const void *ctx, void *ptr, size_t size, unsigned count) +{ + if (count > SIZE_MAX/size) + return NULL; + + return reralloc_size(ctx, ptr, size * count); +} + +void +ralloc_free(void *ptr) +{ + ralloc_header *info; + + if (ptr == NULL) + return; + + info = get_header(ptr); + unlink_block(info); + unsafe_free(info); +} + +static void +unlink_block(ralloc_header *info) +{ + /* Unlink from parent & siblings */ + if (info->parent != NULL) { + if (info->parent->child == info) + info->parent->child = info->next; + + if (info->prev != NULL) + info->prev->next = info->next; + + if (info->next != NULL) + info->next->prev = info->prev; + } + info->parent = NULL; + info->prev = NULL; + info->next = NULL; +} + +static void +unsafe_free(ralloc_header *info) +{ + /* Recursively free any children...don't waste time unlinking them. */ + ralloc_header *temp; + while (info->child != NULL) { + temp = info->child; + info->child = temp->next; + unsafe_free(temp); + } + + /* Free the block itself. Call the destructor first, if any. */ + if (info->destructor != NULL) + info->destructor(PTR_FROM_HEADER(info)); + + free(info); +} + +void +ralloc_steal(const void *new_ctx, void *ptr) +{ + ralloc_header *info, *parent; + + if (unlikely(ptr == NULL)) + return; + + info = get_header(ptr); + parent = get_header(new_ctx); + + unlink_block(info); + + add_child(parent, info); +} + +void * +ralloc_parent(const void *ptr) +{ + ralloc_header *info; + + if (unlikely(ptr == NULL)) + return NULL; + + info = get_header(ptr); + return PTR_FROM_HEADER(info->parent); +} + +static void *autofree_context = NULL; + +static void +autofree(void) +{ + ralloc_free(autofree_context); +} + +void * +ralloc_autofree_context(void) +{ + if (unlikely(autofree_context == NULL)) { + autofree_context = ralloc_context(NULL); + atexit(autofree); + } + return autofree_context; +} + +void +ralloc_set_destructor(const void *ptr, void(*destructor)(void *)) +{ + ralloc_header *info = get_header(ptr); + info->destructor = destructor; +} + +char * +ralloc_strdup(const void *ctx, const char *str) +{ + size_t n; + char *ptr; + + if (unlikely(str == NULL)) + return NULL; + + n = strlen(str); + ptr = ralloc_array(ctx, char, n + 1); + memcpy(ptr, str, n); + ptr[n] = '\0'; + return ptr; +} + +char * +ralloc_strndup(const void *ctx, const char *str, size_t max) +{ + size_t n; + char *ptr; + + if (unlikely(str == NULL)) + return NULL; + + n = strlen(str); + if (n > max) + n = max; + + ptr = ralloc_array(ctx, char, n + 1); + memcpy(ptr, str, n); + ptr[n] = '\0'; + return ptr; +} + +/* helper routine for strcat/strncat - n is the exact amount to copy */ +static bool +cat(char **dest, const char *str, size_t n) +{ + char *both; + size_t existing_length; + assert(dest != NULL && *dest != NULL); + + existing_length = strlen(*dest); + both = resize(*dest, existing_length + n + 1); + if (unlikely(both == NULL)) + return false; + + memcpy(both + existing_length, str, n); + both[existing_length + n] = '\0'; + + *dest = both; + return true; +} + + +bool +ralloc_strcat(char **dest, const char *str) +{ + return cat(dest, str, strlen(str)); +} + +bool +ralloc_strncat(char **dest, const char *str, size_t n) +{ + /* Clamp n to the string length */ + size_t str_length = strlen(str); + if (str_length < n) + n = str_length; + + return cat(dest, str, n); +} + +char * +ralloc_asprintf(const void *ctx, const char *fmt, ...) +{ + char *ptr; + va_list args; + va_start(args, fmt); + ptr = ralloc_vasprintf(ctx, fmt, args); + va_end(args); + return ptr; +} + +/* Return the length of the string that would be generated by a printf-style + * format and argument list, not including the \0 byte. + */ +static size_t +printf_length(const char *fmt, va_list untouched_args) +{ + int size; + char junk; + + /* Make a copy of the va_list so the original caller can still use it */ + va_list args; + va_copy(args, untouched_args); + +#ifdef _MSC_VER + /* We need to use _vcsprintf to calculate the size as vsnprintf returns -1 + * if the number of characters to write is greater than count. + */ + size = _vscprintf(fmt, args); + (void)junk; +#else + size = vsnprintf(&junk, 1, fmt, args); +#endif + assert(size >= 0); + + va_end(args); + + return size; +} + +char * +ralloc_vasprintf(const void *ctx, const char *fmt, va_list args) +{ + size_t size = printf_length(fmt, args) + 1; + + char *ptr = ralloc_size(ctx, size); + if (ptr != NULL) + vsnprintf(ptr, size, fmt, args); + + return ptr; +} + +bool +ralloc_asprintf_append(char **str, const char *fmt, ...) +{ + bool success; + va_list args; + va_start(args, fmt); + success = ralloc_vasprintf_append(str, fmt, args); + va_end(args); + return success; +} + +bool +ralloc_vasprintf_append(char **str, const char *fmt, va_list args) +{ + size_t existing_length, new_length; + char *ptr; + + assert(str != NULL); + + if (unlikely(*str == NULL)) { + // Assuming a NULL context is probably bad, but it's expected behavior. + *str = ralloc_vasprintf(NULL, fmt, args); + return true; + } + + existing_length = strlen(*str); + new_length = printf_length(fmt, args); + + ptr = resize(*str, existing_length + new_length + 1); + if (unlikely(ptr == NULL)) + return false; + + vsnprintf(ptr + existing_length, new_length + 1, fmt, args); + *str = ptr; + return true; +} diff --git a/src/glsl/ralloc.h b/src/glsl/ralloc.h new file mode 100644 index 0000000000..d5338152f1 --- /dev/null +++ b/src/glsl/ralloc.h @@ -0,0 +1,345 @@ +/* + * 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 ralloc.h + * + * ralloc: a recursive memory allocator + * + * The ralloc memory allocator creates a hierarchy of allocated + * objects. Every allocation is in reference to some parent, and + * every allocated object can in turn be used as the parent of a + * subsequent allocation. This allows for extremely convenient + * discarding of an entire tree/sub-tree of allocations by calling + * ralloc_free on any particular object to free it and all of its + * children. + * + * The conceptual working of ralloc was directly inspired by Andrew + * Tridgell's talloc, but ralloc is an independent implementation + * released under the MIT license and tuned for Mesa. + * + * The talloc implementation is available under the GNU Lesser + * General Public License (GNU LGPL), version 3 or later. It is + * more sophisticated than ralloc in that it includes reference + * counting and debugging features. See: http://talloc.samba.org/ + */ + +#ifndef RALLOC_H +#define RALLOC_H + +#ifdef __cplusplus +extern "C" { +#endif + +#include <stddef.h> +#include <stdarg.h> +#include <stdbool.h> + +/** + * \def ralloc(ctx, type) + * Allocate a new object chained off of the given context. + * + * This is equivalent to: + * \code + * ((type *) ralloc_size(ctx, sizeof(type)) + * \endcode + */ +#define ralloc(ctx, type) ((type *) ralloc_size(ctx, sizeof(type))) + +/** + * \def rzalloc(ctx, type) + * Allocate a new object out of the given context and initialize it to zero. + * + * This is equivalent to: + * \code + * ((type *) rzalloc_size(ctx, sizeof(type)) + * \endcode + */ +#define rzalloc(ctx, type) ((type *) rzalloc_size(ctx, sizeof(type))) + +/** + * Allocate a new ralloc context. + * + * While any ralloc'd pointer can be used as a context, sometimes it is useful + * to simply allocate a context with no associated memory. + * + * It is equivalent to: + * \code + * ((type *) ralloc_size(ctx, 0) + * \endcode + */ +void *ralloc_context(const void *ctx); + +/** + * Allocate memory chained off of the given context. + * + * This is the core allocation routine which is used by all others. It + * simply allocates storage for \p size bytes and returns the pointer, + * similar to \c malloc. + */ +void *ralloc_size(const void *ctx, size_t size); + +/** + * Allocate zero-initialized memory chained off of the given context. + * + * This is similar to \c calloc with a size of 1. + */ +void *rzalloc_size(const void *ctx, size_t size); + +/** + * Resize a piece of ralloc-managed memory, preserving data. + * + * Similar to \c realloc. Unlike C89, passing 0 for \p size does not free the + * memory. Instead, it resizes it to a 0-byte ralloc context, just like + * calling ralloc_size(ctx, 0). This is different from talloc. + * + * \param ctx The context to use for new allocation. If \p ptr != NULL, + * it must be the same as ralloc_parent(\p ptr). + * \param ptr Pointer to the memory to be resized. May be NULL. + * \param size The amount of memory to allocate, in bytes. + */ +void *reralloc_size(const void *ctx, void *ptr, size_t size); + +/// \defgroup array Array Allocators @{ + +/** + * \def ralloc_array(ctx, type, count) + * Allocate an array of objects chained off the given context. + * + * Similar to \c calloc, but does not initialize the memory to zero. + * + * More than a convenience function, this also checks for integer overflow when + * multiplying \c sizeof(type) and \p count. This is necessary for security. + * + * This is equivalent to: + * \code + * ((type *) ralloc_array_size(ctx, sizeof(type), count) + * \endcode + */ +#define ralloc_array(ctx, type, count) \ + ((type *) ralloc_array_size(ctx, sizeof(type), count)) + +/** + * \def rzalloc_array(ctx, type, count) + * Allocate a zero-initialized array chained off the given context. + * + * Similar to \c calloc. + * + * More than a convenience function, this also checks for integer overflow when + * multiplying \c sizeof(type) and \p count. This is necessary for security. + * + * This is equivalent to: + * \code + * ((type *) rzalloc_array_size(ctx, sizeof(type), count) + * \endcode + */ +#define rzalloc_array(ctx, type, count) \ + ((type *) rzalloc_array_size(ctx, sizeof(type), count)) + +/** + * \def reralloc(ctx, ptr, type, count) + * Resize a ralloc-managed array, preserving data. + * + * Similar to \c realloc. Unlike C89, passing 0 for \p size does not free the + * memory. Instead, it resizes it to a 0-byte ralloc context, just like + * calling ralloc_size(ctx, 0). This is different from talloc. + * + * More than a convenience function, this also checks for integer overflow when + * multiplying \c sizeof(type) and \p count. This is necessary for security. + * + * \param ctx The context to use for new allocation. If \p ptr != NULL, + * it must be the same as ralloc_parent(\p ptr). + * \param ptr Pointer to the array to be resized. May be NULL. + * \param type The element type. + * \param count The number of elements to allocate. + */ +#define reralloc(ctx, ptr, type, count) \ + ((type *) reralloc_array_size(ctx, ptr, sizeof(type), count)) + +/** + * Allocate memory for an array chained off the given context. + * + * Similar to \c calloc, but does not initialize the memory to zero. + * + * More than a convenience function, this also checks for integer overflow when + * multiplying \p size and \p count. This is necessary for security. + */ +void *ralloc_array_size(const void *ctx, size_t size, unsigned count); + +/** + * Allocate a zero-initialized array chained off the given context. + * + * Similar to \c calloc. + * + * More than a convenience function, this also checks for integer overflow when + * multiplying \p size and \p count. This is necessary for security. + */ +void *rzalloc_array_size(const void *ctx, size_t size, unsigned count); + +/** + * Resize a ralloc-managed array, preserving data. + * + * Similar to \c realloc. Unlike C89, passing 0 for \p size does not free the + * memory. Instead, it resizes it to a 0-byte ralloc context, just like + * calling ralloc_size(ctx, 0). This is different from talloc. + * + * More than a convenience function, this also checks for integer overflow when + * multiplying \c sizeof(type) and \p count. This is necessary for security. + * + * \param ctx The context to use for new allocation. If \p ptr != NULL, + * it must be the same as ralloc_parent(\p ptr). + * \param ptr Pointer to the array to be resized. May be NULL. + * \param size The size of an individual element. + * \param count The number of elements to allocate. + * + * \return True unless allocation failed. + */ +void *reralloc_array_size(const void *ctx, void *ptr, size_t size, + unsigned count); +/// @} + +/** + * Free a piece of ralloc-managed memory. + * + * This will also free the memory of any children allocated this context. + */ +void ralloc_free(void *ptr); + +/** + * "Steal" memory from one context, changing it to another. + * + * This changes \p ptr's context to \p new_ctx. This is quite useful if + * memory is allocated out of a temporary context. + */ +void ralloc_steal(const void *new_ctx, void *ptr); + +/** + * Return the given pointer's ralloc context. + */ +void *ralloc_parent(const void *ptr); + +/** + * Return a context whose memory will be automatically freed at program exit. + * + * The first call to this function creates a context and registers a handler + * to free it using \c atexit. This may cause trouble if used in a library + * loaded with \c dlopen. + */ +void *ralloc_autofree_context(void); + +/** + * Set a callback to occur just before an object is freed. + */ +void ralloc_set_destructor(const void *ptr, void(*destructor)(void *)); + +/// \defgroup array String Functions @{ +/** + * Duplicate a string, allocating the memory from the given context. + */ +char *ralloc_strdup(const void *ctx, const char *str); + +/** + * Duplicate a string, allocating the memory from the given context. + * + * Like \c strndup, at most \p n characters are copied. If \p str is longer + * than \p n characters, \p n are copied, and a termining \c '\0' byte is added. + */ +char *ralloc_strndup(const void *ctx, const char *str, size_t n); + +/** + * Concatenate two strings, allocating the necessary space. + * + * This appends \p str to \p *dest, similar to \c strcat, using ralloc_resize + * to expand \p *dest to the appropriate size. \p dest will be updated to the + * new pointer unless allocation fails. + * + * The result will always be null-terminated. + * + * \return True unless allocation failed. + */ +bool ralloc_strcat(char **dest, const char *str); + +/** + * Concatenate two strings, allocating the necessary space. + * + * This appends at most \p n bytes of \p str to \p *dest, using ralloc_resize + * to expand \p *dest to the appropriate size. \p dest will be updated to the + * new pointer unless allocation fails. + * + * The result will always be null-terminated; \p str does not need to be null + * terminated if it is longer than \p n. + * + * \return True unless allocation failed. + */ +bool ralloc_strncat(char **dest, const char *str, size_t n); + +/** + * Print to a string. + * + * This is analogous to \c sprintf, but allocates enough space (using \p ctx + * as the context) for the resulting string. + * + * \return The newly allocated string. + */ +char *ralloc_asprintf (const void *ctx, const char *fmt, ...); + +/** + * Print to a string, given a va_list. + * + * This is analogous to \c vsprintf, but allocates enough space (using \p ctx + * as the context) for the resulting string. + * + * \return The newly allocated string. + */ +char *ralloc_vasprintf(const void *ctx, const char *fmt, va_list args); + +/** + * Append formatted text to the supplied string. + * + * \sa ralloc_asprintf + * \sa ralloc_strcat + * + * \p str will be updated to the new pointer unless allocation fails. + * + * \return True unless allocation failed. + */ +bool ralloc_asprintf_append (char **str, const char *fmt, ...); + +/** + * Append formatted text to the supplied string, given a va_list. + * + * \sa ralloc_vasprintf + * \sa ralloc_strcat + * + * \p str will be updated to the new pointer unless allocation fails. + * + * \return True unless allocation failed. + */ +bool ralloc_vasprintf_append(char **str, const char *fmt, va_list args); +/// @} + +#ifdef __cplusplus +} /* end of extern "C" */ +#endif + +#endif diff --git a/src/glsl/s_expression.cpp b/src/glsl/s_expression.cpp index 4c8829fea9..a922a50d3b 100644 --- a/src/glsl/s_expression.cpp +++ b/src/glsl/s_expression.cpp @@ -22,15 +22,12 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> -#include <cstdlib> -#include <cstring> #include <assert.h> #include "s_expression.h" s_symbol::s_symbol(const char *tmp, size_t n) { - this->str = talloc_strndup (this, tmp, n); + this->str = ralloc_strndup (this, tmp, n); assert(this->str != NULL); } @@ -38,14 +35,15 @@ s_list::s_list() { } -unsigned -s_list::length() const +static void +skip_whitespace(const char *& src) { - unsigned i = 0; - foreach_iter(exec_list_iterator, it, this->subexpressions) { - i++; + src += strspn(src, " \v\t\r\n"); + /* Also skip Scheme-style comments: semi-colon 'til end of line */ + if (src[0] == ';') { + src += strcspn(src, "\n"); + skip_whitespace(src); } - return i; } static s_expression * @@ -53,16 +51,15 @@ read_atom(void *ctx, const char *& src) { s_expression *expr = NULL; - // Skip leading spaces. - src += strspn(src, " \v\t\r\n"); + skip_whitespace(src); - size_t n = strcspn(src, "( \v\t\r\n)"); + size_t n = strcspn(src, "( \v\t\r\n);"); if (n == 0) return NULL; // no atom // Check if the atom is a number. char *float_end = NULL; - double f = strtod(src, &float_end); + double f = glsl_strtod(src, &float_end); if (float_end != src) { char *int_end = NULL; int i = strtol(src, &int_end, 10); @@ -90,8 +87,7 @@ s_expression::read_expression(void *ctx, const char *&src) if (atom != NULL) return atom; - // Skip leading spaces. - src += strspn(src, " \v\t\r\n"); + skip_whitespace(src); if (src[0] == '(') { ++src; @@ -101,7 +97,7 @@ s_expression::read_expression(void *ctx, const char *&src) while ((expr = read_expression(ctx, src)) != NULL) { list->subexpressions.push_tail(expr); } - src += strspn(src, " \v\t\r\n"); + skip_whitespace(src); if (src[0] != ')') { printf("Unclosed expression (check your parenthesis).\n"); return NULL; @@ -139,3 +135,49 @@ void s_list::print() printf(")"); } +// -------------------------------------------------- + +bool +s_pattern::match(s_expression *expr) +{ + switch (type) + { + case EXPR: *p_expr = expr; break; + case LIST: if (expr->is_list()) *p_list = (s_list *) expr; break; + case SYMBOL: if (expr->is_symbol()) *p_symbol = (s_symbol *) expr; break; + case NUMBER: if (expr->is_number()) *p_number = (s_number *) expr; break; + case INT: if (expr->is_int()) *p_int = (s_int *) expr; break; + case STRING: + s_symbol *sym = SX_AS_SYMBOL(expr); + if (sym != NULL && strcmp(sym->value(), literal) == 0) + return true; + return false; + }; + + return *p_expr == expr; +} + +bool +s_match(s_expression *top, unsigned n, s_pattern *pattern, bool partial) +{ + s_list *list = SX_AS_LIST(top); + if (list == NULL) + return false; + + unsigned i = 0; + foreach_iter(exec_list_iterator, it, list->subexpressions) { + if (i >= n) + return partial; /* More actual items than the pattern expected */ + + s_expression *expr = (s_expression *) it.get(); + if (expr == NULL || !pattern[i].match(expr)) + return false; + + i++; + } + + if (i < n) + return false; /* Less actual items than the pattern expected */ + + return true; +} diff --git a/src/glsl/s_expression.h b/src/glsl/s_expression.h index aa22475a1b..c9dc676b31 100644 --- a/src/glsl/s_expression.h +++ b/src/glsl/s_expression.h @@ -26,8 +26,11 @@ #ifndef S_EXPRESSION_H #define S_EXPRESSION_H +#include "main/core.h" /* for Elements */ +#include "strtod.h" #include "list.h" +/* Type-safe downcasting macros (also safe to pass NULL) */ #define SX_AS_(t,x) ((x) && ((s_expression*) x)->is_##t()) ? ((s_##t*) (x)) \ : NULL #define SX_AS_LIST(x) SX_AS_(list, x) @@ -35,6 +38,10 @@ #define SX_AS_NUMBER(x) SX_AS_(number, x) #define SX_AS_INT(x) SX_AS_(int, x) +/* Pattern matching macros */ +#define MATCH(list, pat) s_match(list, Elements(pat), pat, false) +#define PARTIAL_MATCH(list, pat) s_match(list, Elements(pat), pat, true) + /* For our purposes, S-Expressions are: * - <int> * - <float> @@ -50,7 +57,7 @@ public: * Read an S-Expression from the given string. * Advances the supplied pointer to just after the expression read. * - * Any allocation will be performed with 'ctx' as the talloc owner. + * Any allocation will be performed with 'ctx' as the ralloc owner. */ static s_expression *read_expression(void *ctx, const char *&src); @@ -132,11 +139,42 @@ public: s_list(); virtual bool is_list() const { return true; } - unsigned length() const; void print(); exec_list subexpressions; }; +// ------------------------------------------------------------ + +/** + * Part of a pattern to match - essentially a record holding a pointer to the + * storage for the component to match, along with the appropriate type. + */ +class s_pattern { +public: + s_pattern(s_expression *&s) : p_expr(&s), type(EXPR) { } + s_pattern(s_list *&s) : p_list(&s), type(LIST) { } + s_pattern(s_symbol *&s) : p_symbol(&s), type(SYMBOL) { } + s_pattern(s_number *&s) : p_number(&s), type(NUMBER) { } + s_pattern(s_int *&s) : p_int(&s), type(INT) { } + s_pattern(const char *str) : literal(str), type(STRING) { } + + bool match(s_expression *expr); + +private: + union { + s_expression **p_expr; + s_list **p_list; + s_symbol **p_symbol; + s_number **p_number; + s_int **p_int; + const char *literal; + }; + enum { EXPR, LIST, SYMBOL, NUMBER, INT, STRING } type; +}; + +bool +s_match(s_expression *top, unsigned n, s_pattern *pattern, bool partial); + #endif /* S_EXPRESSION_H */ diff --git a/src/glsl/strtod.c b/src/glsl/strtod.c new file mode 100644 index 0000000000..ff34591488 --- /dev/null +++ b/src/glsl/strtod.c @@ -0,0 +1,56 @@ +/* + * Copyright 2010 VMware, Inc. + * All Rights Reserved. + * + * 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, sub license, 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 NON-INFRINGEMENT. + * IN NO EVENT SHALL VMWARE AND/OR ITS SUPPLIERS 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. + */ + + +#include <stdlib.h> + +#ifdef _GNU_SOURCE +#include <locale.h> +#ifdef __APPLE__ +#include <xlocale.h> +#endif +#endif + +#include "strtod.h" + + + +/** + * Wrapper around strtod which uses the "C" locale so the decimal + * point is always '.' + */ +double +glsl_strtod(const char *s, char **end) +{ +#if defined(_GNU_SOURCE) && !defined(__CYGWIN__) && !defined(__FreeBSD__) + static locale_t loc = NULL; + if (!loc) { + loc = newlocale(LC_CTYPE_MASK, "C", NULL); + } + return strtod_l(s, end, loc); +#else + return strtod(s, end); +#endif +} diff --git a/src/glsl/strtod.h b/src/glsl/strtod.h new file mode 100644 index 0000000000..0cf6409d42 --- /dev/null +++ b/src/glsl/strtod.h @@ -0,0 +1,43 @@ +/* + * Copyright 2010 VMware, Inc. + * All Rights Reserved. + * + * 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, sub license, 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 NON-INFRINGEMENT. + * IN NO EVENT SHALL VMWARE AND/OR ITS SUPPLIERS 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. + */ + + +#ifndef STRTOD_H +#define STRTOD_H + +#ifdef __cplusplus +extern "C" { +#endif + +extern double +glsl_strtod(const char *s, char **end); + + +#ifdef __cplusplus +} +#endif + + +#endif diff --git a/src/glsl/tests/array-01.glsl b/src/glsl/tests/array-01.glsl deleted file mode 100644 index d14135fb3a..0000000000 --- a/src/glsl/tests/array-01.glsl +++ /dev/null @@ -1,3 +0,0 @@ -#version 120 -/* FAIL - array size type must be int */ -uniform vec4 [3.2] a; diff --git a/src/glsl/tests/array-02.glsl b/src/glsl/tests/array-02.glsl deleted file mode 100644 index d743617158..0000000000 --- a/src/glsl/tests/array-02.glsl +++ /dev/null @@ -1,3 +0,0 @@ -#version 120 -/* FAIL - array size type must be scalar */ -uniform vec4 [ivec4(3)] a; diff --git a/src/glsl/tests/array-03.glsl b/src/glsl/tests/array-03.glsl deleted file mode 100644 index 0026913f01..0000000000 --- a/src/glsl/tests/array-03.glsl +++ /dev/null @@ -1,3 +0,0 @@ -#version 120 -/* PASS */ -uniform vec4 [3] a; diff --git a/src/glsl/tests/array-04.glsl b/src/glsl/tests/array-04.glsl deleted file mode 100644 index 70f434d8ab..0000000000 --- a/src/glsl/tests/array-04.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - array size type must be int */ -uniform vec4 a[3.2]; diff --git a/src/glsl/tests/array-05.glsl b/src/glsl/tests/array-05.glsl deleted file mode 100644 index 168704096b..0000000000 --- a/src/glsl/tests/array-05.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - array size type must be scalar */ -uniform vec4 a[ivec4(3)]; diff --git a/src/glsl/tests/array-06.glsl b/src/glsl/tests/array-06.glsl deleted file mode 100644 index 46b43795be..0000000000 --- a/src/glsl/tests/array-06.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* PASS */ -uniform vec4 a[3]; diff --git a/src/glsl/tests/array-07.glsl b/src/glsl/tests/array-07.glsl deleted file mode 100644 index 161ffbf2f2..0000000000 --- a/src/glsl/tests/array-07.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - array size must be > 0 */ -uniform vec4 a[0]; diff --git a/src/glsl/tests/array-08.glsl b/src/glsl/tests/array-08.glsl deleted file mode 100644 index 4bf0c6bd51..0000000000 --- a/src/glsl/tests/array-08.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - array size must be > 0 */ -uniform vec4 a[-1]; diff --git a/src/glsl/tests/array-09.glsl b/src/glsl/tests/array-09.glsl deleted file mode 100644 index cad6d0e54e..0000000000 --- a/src/glsl/tests/array-09.glsl +++ /dev/null @@ -1,9 +0,0 @@ -#version 120 -/* PASS */ - -void main() -{ - vec4 a[2] = vec4 [2] (vec4(1.0), vec4(2.0)); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/array-10.glsl b/src/glsl/tests/array-10.glsl deleted file mode 100644 index 019aa21150..0000000000 --- a/src/glsl/tests/array-10.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* FAIL - array constructors forbidden in GLSL 1.10 - * - * This can also generate an error because the 'vec4[]' style syntax is - * illegal in GLSL 1.10. - */ -void main() -{ - vec4 a[2] = vec4 [2] (vec4(1.0), vec4(2.0)); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/array-11.glsl b/src/glsl/tests/array-11.glsl deleted file mode 100644 index 51d94e9477..0000000000 --- a/src/glsl/tests/array-11.glsl +++ /dev/null @@ -1,9 +0,0 @@ -#version 120 -/* PASS */ - -void main() -{ - vec4 a[] = vec4 [] (vec4(1.0), vec4(2.0)); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/array-12.glsl b/src/glsl/tests/array-12.glsl deleted file mode 100644 index 7fc9579452..0000000000 --- a/src/glsl/tests/array-12.glsl +++ /dev/null @@ -1,11 +0,0 @@ -#version 120 -/* FAIL - array must have an implicit or explicit size */ - -void main() -{ - vec4 a[]; - - a = vec4 [2] (vec4(1.0), vec4(2.0)); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/array-13.glsl b/src/glsl/tests/array-13.glsl deleted file mode 100644 index cc7e29a5f7..0000000000 --- a/src/glsl/tests/array-13.glsl +++ /dev/null @@ -1,11 +0,0 @@ -#version 120 -/* PASS */ - -void main() -{ - vec4 a[2]; - - a = vec4 [] (vec4(1.0), vec4(2.0)); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/attribute-01.glsl b/src/glsl/tests/attribute-01.glsl deleted file mode 100644 index 18e9e4468a..0000000000 --- a/src/glsl/tests/attribute-01.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type int */ -attribute int i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-02.glsl b/src/glsl/tests/attribute-02.glsl deleted file mode 100644 index 6b6df74d25..0000000000 --- a/src/glsl/tests/attribute-02.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type ivec2 */ -attribute ivec2 i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-03.glsl b/src/glsl/tests/attribute-03.glsl deleted file mode 100644 index 870de9e814..0000000000 --- a/src/glsl/tests/attribute-03.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type ivec3 */ -attribute ivec3 i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-04.glsl b/src/glsl/tests/attribute-04.glsl deleted file mode 100644 index 14af2fcaad..0000000000 --- a/src/glsl/tests/attribute-04.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type ivec4 */ -attribute ivec4 i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-05.glsl b/src/glsl/tests/attribute-05.glsl deleted file mode 100644 index 18822c7854..0000000000 --- a/src/glsl/tests/attribute-05.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type bool */ -attribute bool i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-06.glsl b/src/glsl/tests/attribute-06.glsl deleted file mode 100644 index f18027b81a..0000000000 --- a/src/glsl/tests/attribute-06.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type bvec2 */ -attribute bvec2 i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-07.glsl b/src/glsl/tests/attribute-07.glsl deleted file mode 100644 index 0af13ba84b..0000000000 --- a/src/glsl/tests/attribute-07.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type bvec3 */ -attribute bvec3 i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-08.glsl b/src/glsl/tests/attribute-08.glsl deleted file mode 100644 index b069c04d1b..0000000000 --- a/src/glsl/tests/attribute-08.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have type bvec4 */ -attribute bvec4 i; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-09.glsl b/src/glsl/tests/attribute-09.glsl deleted file mode 100644 index 6a607244b9..0000000000 --- a/src/glsl/tests/attribute-09.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - attribute cannot have array type in GLSL 1.10 */ -attribute vec4 i[10]; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-10.glsl b/src/glsl/tests/attribute-10.glsl deleted file mode 100644 index 6f5ef63a01..0000000000 --- a/src/glsl/tests/attribute-10.glsl +++ /dev/null @@ -1,8 +0,0 @@ -#version 120 -/* FAIL - attribute cannot have array type in GLSL 1.20 */ -attribute vec4 i[10]; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/attribute-11.glsl b/src/glsl/tests/attribute-11.glsl deleted file mode 100644 index 47cb5a0583..0000000000 --- a/src/glsl/tests/attribute-11.glsl +++ /dev/null @@ -1,8 +0,0 @@ -#version 130 -/* FAIL - attribute cannot have array type in GLSL 1.30 */ -attribute vec4 i[10]; - -void main() -{ - gl_Position = vec4(1.0); -} diff --git a/src/glsl/tests/condition-01.glsl b/src/glsl/tests/condition-01.glsl deleted file mode 100644 index d89c313117..0000000000 --- a/src/glsl/tests/condition-01.glsl +++ /dev/null @@ -1,8 +0,0 @@ -/* FAIL - :? condition is not bool scalar */ - -uniform bvec4 a; - -void main() -{ - gl_Position = (a) ? vec4(1.0, 0.0, 0.0, 1.0) : vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/condition-02.glsl b/src/glsl/tests/condition-02.glsl deleted file mode 100644 index cbd0e18d9a..0000000000 --- a/src/glsl/tests/condition-02.glsl +++ /dev/null @@ -1,8 +0,0 @@ -/* FAIL - :? condition is not bool scalar */ - -uniform float a; - -void main() -{ - gl_Position = (a) ? vec4(1.0, 0.0, 0.0, 1.0) : vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/condition-03.glsl b/src/glsl/tests/condition-03.glsl deleted file mode 100644 index 9af5d7aa47..0000000000 --- a/src/glsl/tests/condition-03.glsl +++ /dev/null @@ -1,8 +0,0 @@ -/* PASS */ - -uniform bool a; - -void main() -{ - gl_Position = (a) ? vec4(1.0, 0.0, 0.0, 1.0) : vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/condition-04.glsl b/src/glsl/tests/condition-04.glsl deleted file mode 100644 index f440b7e995..0000000000 --- a/src/glsl/tests/condition-04.glsl +++ /dev/null @@ -1,8 +0,0 @@ -/* FAIL - type of second two operands must match */ - -uniform bool a; - -void main() -{ - gl_Position = (a) ? vec4(1.0, 0.0, 0.0, 1.0) : vec3(0.0, 1.0, 0.0); -} diff --git a/src/glsl/tests/condition-05.glsl b/src/glsl/tests/condition-05.glsl deleted file mode 100644 index 3dff18f519..0000000000 --- a/src/glsl/tests/condition-05.glsl +++ /dev/null @@ -1,13 +0,0 @@ -#version 120 -/* PASS */ - -uniform bool a; -uniform int b; - -void main() -{ - float x; - - x = (a) ? 2.0 : b; - gl_Position = vec4(x); -} diff --git a/src/glsl/tests/constructor-01.glsl b/src/glsl/tests/constructor-01.glsl deleted file mode 100644 index fdfaf89866..0000000000 --- a/src/glsl/tests/constructor-01.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* PASS */ - -void main() -{ - gl_Position = vec4(1.0, 1.0, 1.0, 0.0);; -} diff --git a/src/glsl/tests/constructor-02.glsl b/src/glsl/tests/constructor-02.glsl deleted file mode 100644 index 47acbe9db1..0000000000 --- a/src/glsl/tests/constructor-02.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - cannot construct samplers */ -void main() -{ - int i; - - i = sampler2D(0); -} diff --git a/src/glsl/tests/constructor-03.glsl b/src/glsl/tests/constructor-03.glsl deleted file mode 100644 index 07ec225633..0000000000 --- a/src/glsl/tests/constructor-03.glsl +++ /dev/null @@ -1,12 +0,0 @@ -/* FAIL - cannot construct a matrix from a matrix in GLSL 1.10 */ - -uniform mat2 a; - -void main() -{ - mat2 b; - - b = mat2(a); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/constructor-04.glsl b/src/glsl/tests/constructor-04.glsl deleted file mode 100644 index 19d5e011de..0000000000 --- a/src/glsl/tests/constructor-04.glsl +++ /dev/null @@ -1,14 +0,0 @@ -#version 120 -/* FAIL - matrix must be only parameter to matrix constructor */ - -uniform mat2 a; -uniform float x; - -void main() -{ - mat2 b; - - b = mat2(a, x); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/constructor-05.glsl b/src/glsl/tests/constructor-05.glsl deleted file mode 100644 index 9c74f75a40..0000000000 --- a/src/glsl/tests/constructor-05.glsl +++ /dev/null @@ -1,13 +0,0 @@ -/* FAIL - too few components supplied to constructor */ - -uniform vec2 a; -uniform float x; - -void main() -{ - mat2 b; - - b = mat2(a, x); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/constructor-06.glsl b/src/glsl/tests/constructor-06.glsl deleted file mode 100644 index d77a5f9e89..0000000000 --- a/src/glsl/tests/constructor-06.glsl +++ /dev/null @@ -1,13 +0,0 @@ -#version 120 -/* PASS */ - -uniform mat2 a; - -void main() -{ - mat2 b; - - b = mat2(a); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/constructor-07.glsl b/src/glsl/tests/constructor-07.glsl deleted file mode 100644 index 92322506ed..0000000000 --- a/src/glsl/tests/constructor-07.glsl +++ /dev/null @@ -1,13 +0,0 @@ -/* PASS */ - -uniform ivec2 a; -uniform ivec2 b; - -void main() -{ - mat2 c; - - c = mat2(a, b); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/constructor-08.glsl b/src/glsl/tests/constructor-08.glsl deleted file mode 100644 index 27153f0cda..0000000000 --- a/src/glsl/tests/constructor-08.glsl +++ /dev/null @@ -1,13 +0,0 @@ -/* PASS */ - -uniform float a; -uniform float b; - -void main() -{ - ivec2 c; - - c = ivec2(a, b); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/constructor-09.glsl b/src/glsl/tests/constructor-09.glsl deleted file mode 100644 index 1985699b30..0000000000 --- a/src/glsl/tests/constructor-09.glsl +++ /dev/null @@ -1,26 +0,0 @@ -/* PASS */ - -uniform int a; -uniform float b; -uniform bool c; - -void main() -{ - float x; - int y; - bool z; - - x = float(a); - x = float(b); - x = float(c); - - y = int(a); - y = int(b); - y = int(c); - - z = bool(a); - z = bool(b); - z = bool(c); - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/function-01.glsl b/src/glsl/tests/function-01.glsl deleted file mode 100644 index 0eaa2397ab..0000000000 --- a/src/glsl/tests/function-01.glsl +++ /dev/null @@ -1,16 +0,0 @@ -/* FAIL - no function named 'foo' exists */ - -vec4 bar(float x, float y, float z, float w) -{ - vec4 v; - v.x = x; - v.y = y; - v.z = z; - v.w = w; - return v; -} - -void main() -{ - gl_Position = foo(1.0, 1.0, 1.0, 0.0); -} diff --git a/src/glsl/tests/function-02.glsl b/src/glsl/tests/function-02.glsl deleted file mode 100644 index 941fcc1ef7..0000000000 --- a/src/glsl/tests/function-02.glsl +++ /dev/null @@ -1,16 +0,0 @@ -/* FAIL - no version of 'foo' matches the call to 'foo' */ - -vec4 foo(float x, float y, float z, float w) -{ - vec4 v; - v.x = x; - v.y = y; - v.z = z; - v.w = w; - return v; -} - -void main() -{ - gl_Position = foo(1.0, 1.0, 1.0); -} diff --git a/src/glsl/tests/function-03.glsl b/src/glsl/tests/function-03.glsl deleted file mode 100644 index b0da42f8e9..0000000000 --- a/src/glsl/tests/function-03.glsl +++ /dev/null @@ -1,16 +0,0 @@ -/* PASS */ - -vec4 foo(in float x, in float y, float z, float w) -{ - vec4 v; - v.x = x; - v.y = y; - v.z = z; - v.w = w; - return v; -} - -void main() -{ - gl_Position = foo(1.0, 1.0, 1.0, 0.0); -} diff --git a/src/glsl/tests/function-04.glsl b/src/glsl/tests/function-04.glsl deleted file mode 100644 index dfc0d2b7a6..0000000000 --- a/src/glsl/tests/function-04.glsl +++ /dev/null @@ -1,15 +0,0 @@ -/* FAIL - type mismatch in assignment */ - -vec3 foo(float x, float y, float z) -{ - vec3 v; - v.x = x; - v.y = y; - v.z = z; - return v; -} - -void main() -{ - gl_Position = foo(1.0, 1.0, 1.0); -} diff --git a/src/glsl/tests/function-05.glsl b/src/glsl/tests/function-05.glsl deleted file mode 100644 index 43365bf606..0000000000 --- a/src/glsl/tests/function-05.glsl +++ /dev/null @@ -1,26 +0,0 @@ -/* PASS */ - -vec4 foo(in float x, in float y, float z, float w) -{ - vec4 v; - v.x = x; - v.y = y; - v.z = z; - v.w = w; - return v; -} - -vec4 foo(in float x) -{ - vec4 v; - v.x = x; - v.y = x; - v.z = x; - v.w = x; -} - -void main() -{ - gl_Position = foo(1.0, 1.0, 1.0, 0.0); - gl_Position = foo(2.0); -} diff --git a/src/glsl/tests/if-01.glsl b/src/glsl/tests/if-01.glsl deleted file mode 100644 index ca9abd54f7..0000000000 --- a/src/glsl/tests/if-01.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* FAIL - if-statement condition is not bool scalar */ - -uniform bvec4 a; - -void main() -{ - if (a) - gl_Position = vec4(1.0, 0.0, 0.0, 1.0); - else - gl_Position = vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/if-02.glsl b/src/glsl/tests/if-02.glsl deleted file mode 100644 index 7adccea043..0000000000 --- a/src/glsl/tests/if-02.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* FAIL - if-statement condition is not bool scalar */ - -uniform float a; - -void main() -{ - if (a) - gl_Position = vec4(1.0, 0.0, 0.0, 1.0); - else - gl_Position = vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/if-03.glsl b/src/glsl/tests/if-03.glsl deleted file mode 100644 index 179618c716..0000000000 --- a/src/glsl/tests/if-03.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* PASS */ - -uniform bool a; - -void main() -{ - if (a) - gl_Position = vec4(1.0, 0.0, 0.0, 1.0); - else - gl_Position = vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/if-04.glsl b/src/glsl/tests/if-04.glsl deleted file mode 100644 index 7b711fb7ed..0000000000 --- a/src/glsl/tests/if-04.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* PASS */ - -uniform bvec4 a; - -void main() -{ - if (a.x) - gl_Position = vec4(1.0, 0.0, 0.0, 1.0); - else - gl_Position = vec4(0.0, 1.0, 0.0, 1.0); -} diff --git a/src/glsl/tests/matrix-01.glsl b/src/glsl/tests/matrix-01.glsl deleted file mode 100644 index f46416c8f6..0000000000 --- a/src/glsl/tests/matrix-01.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* FAIL - non-square matrices are not available in GLSL 1.10 */ - -void main() -{ - mat2x3 m; -} diff --git a/src/glsl/tests/matrix-02.glsl b/src/glsl/tests/matrix-02.glsl deleted file mode 100644 index 0630722b79..0000000000 --- a/src/glsl/tests/matrix-02.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* FAIL - non-square matrices are not available in GLSL 1.10 */ - -void main() -{ - mat2x4 m; -} diff --git a/src/glsl/tests/matrix-03.glsl b/src/glsl/tests/matrix-03.glsl deleted file mode 100644 index 925dc80625..0000000000 --- a/src/glsl/tests/matrix-03.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* FAIL - non-square matrices are not available in GLSL 1.10 */ - -void main() -{ - mat3x2 m; -} diff --git a/src/glsl/tests/matrix-04.glsl b/src/glsl/tests/matrix-04.glsl deleted file mode 100644 index 5275619b31..0000000000 --- a/src/glsl/tests/matrix-04.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* FAIL - non-square matrices are not available in GLSL 1.10 */ - -void main() -{ - mat3x4 m; -} diff --git a/src/glsl/tests/matrix-05.glsl b/src/glsl/tests/matrix-05.glsl deleted file mode 100644 index 74e1fd2514..0000000000 --- a/src/glsl/tests/matrix-05.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* FAIL - non-square matrices are not available in GLSL 1.10 */ - -void main() -{ - mat4x2 m; -} diff --git a/src/glsl/tests/matrix-06.glsl b/src/glsl/tests/matrix-06.glsl deleted file mode 100644 index 0a512b8523..0000000000 --- a/src/glsl/tests/matrix-06.glsl +++ /dev/null @@ -1,6 +0,0 @@ -/* FAIL - non-square matrices are not available in GLSL 1.10 */ - -void main() -{ - mat4x3 m; -} diff --git a/src/glsl/tests/matrix-07.glsl b/src/glsl/tests/matrix-07.glsl deleted file mode 100644 index 0b59aa69d5..0000000000 --- a/src/glsl/tests/matrix-07.glsl +++ /dev/null @@ -1,27 +0,0 @@ -/* PASS */ - -uniform mat2 a; -uniform mat2 b; -uniform mat2 c; -uniform mat2 d; -uniform mat3 e; -uniform mat3 f; -uniform mat3 g; -uniform mat3 h; -uniform mat4 i; -uniform mat4 j; -uniform mat4 k; -uniform mat4 l; - -void main() -{ - mat2 x; - mat3 y; - mat4 z; - - x = a * b + c / d; - y = e * f + g / h; - z = i * j + k / l; - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/matrix-08.glsl b/src/glsl/tests/matrix-08.glsl deleted file mode 100644 index 38138d22de..0000000000 --- a/src/glsl/tests/matrix-08.glsl +++ /dev/null @@ -1,19 +0,0 @@ -#version 120 -/* PASS */ - -uniform mat2x3 a; -uniform mat3x2 b; -uniform mat3x3 c; -uniform mat3x3 d; - -void main() -{ - mat3x3 x; - - /* Multiplying a 2 column, 3 row matrix with a 3 column, 2 row matrix - * results in a 3 column, 3 row matrix. - */ - x = (a * b) + c / d; - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/matrix-09.glsl b/src/glsl/tests/matrix-09.glsl deleted file mode 100644 index 18afbcacea..0000000000 --- a/src/glsl/tests/matrix-09.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* FAIL - matrix-to-matrix constructors are not available in GLSL 1.10 */ - -uniform mat3 a; - -void main() -{ - mat2 m; - - m = mat2(a); - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/matrix-10.glsl b/src/glsl/tests/matrix-10.glsl deleted file mode 100644 index 20b55180cb..0000000000 --- a/src/glsl/tests/matrix-10.glsl +++ /dev/null @@ -1,12 +0,0 @@ -#version 120 -/* PASS */ - -uniform mat3 a; - -void main() -{ - mat2 m; - - m = mat2(a); - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/parameters-01.glsl b/src/glsl/tests/parameters-01.glsl deleted file mode 100644 index b485106e9d..0000000000 --- a/src/glsl/tests/parameters-01.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* FAIL: redefinition of a() */ - -void a() -{ - ; -} - -void a() -{ - ; -} diff --git a/src/glsl/tests/parameters-02.glsl b/src/glsl/tests/parameters-02.glsl deleted file mode 100644 index 7ff5f59ab7..0000000000 --- a/src/glsl/tests/parameters-02.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* PASS */ - -void a() -{ - ; -} - -void a(float x) -{ - ; -} diff --git a/src/glsl/tests/parameters-03.glsl b/src/glsl/tests/parameters-03.glsl deleted file mode 100644 index 7ec30f80cc..0000000000 --- a/src/glsl/tests/parameters-03.glsl +++ /dev/null @@ -1,9 +0,0 @@ -/* FAIL - x is redeclared in the function body at the same scope as the - * parameter - */ -void a(float x, float y) -{ - float x; - - x = y; -} diff --git a/src/glsl/tests/qualifier-01.glsl b/src/glsl/tests/qualifier-01.glsl deleted file mode 100644 index 54ec3572a2..0000000000 --- a/src/glsl/tests/qualifier-01.glsl +++ /dev/null @@ -1,3 +0,0 @@ -#version 130 -/* FAIL - inout only allowed in parameter list */ -inout vec4 foo; diff --git a/src/glsl/tests/qualifier-02.glsl b/src/glsl/tests/qualifier-02.glsl deleted file mode 100644 index b635d52aa2..0000000000 --- a/src/glsl/tests/qualifier-02.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - in only allowed in parameter list in GLSL 1.10 */ -in foo; diff --git a/src/glsl/tests/qualifier-03.glsl b/src/glsl/tests/qualifier-03.glsl deleted file mode 100644 index 7e448034a7..0000000000 --- a/src/glsl/tests/qualifier-03.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - out only allowed in parameter list in GLSL 1.10 */ -out vec4 foo; diff --git a/src/glsl/tests/qualifier-04.glsl b/src/glsl/tests/qualifier-04.glsl deleted file mode 100644 index d03cafc1db..0000000000 --- a/src/glsl/tests/qualifier-04.glsl +++ /dev/null @@ -1,3 +0,0 @@ -#version 130 -/* PASS */ -in vec4 foo; diff --git a/src/glsl/tests/qualifier-05.glsl b/src/glsl/tests/qualifier-05.glsl deleted file mode 100644 index 15281f3384..0000000000 --- a/src/glsl/tests/qualifier-05.glsl +++ /dev/null @@ -1,3 +0,0 @@ -#version 130 -/* PASS */ -out vec4 foo; diff --git a/src/glsl/tests/qualifier-06.glsl b/src/glsl/tests/qualifier-06.glsl deleted file mode 100644 index 1907a087c8..0000000000 --- a/src/glsl/tests/qualifier-06.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - in only allowed in parameter list in GLSL 1.10 */ -void main() -{ - in vec4 foo; - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/qualifier-07.glsl b/src/glsl/tests/qualifier-07.glsl deleted file mode 100644 index 12568a57db..0000000000 --- a/src/glsl/tests/qualifier-07.glsl +++ /dev/null @@ -1,7 +0,0 @@ -/* FAIL - out only allowed in parameter list in GLSL 1.10 */ -void main() -{ - out vec4 foo; - - gl_Position = gl_Vertex; -} diff --git a/src/glsl/tests/swiz-01.glsl b/src/glsl/tests/swiz-01.glsl deleted file mode 100644 index 3268fa178c..0000000000 --- a/src/glsl/tests/swiz-01.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* PASS */ -#version 120 - -void main() -{ - float a; - vec4 b; - - b.x = 6.0; - a = b.x; -} diff --git a/src/glsl/tests/swiz-02.glsl b/src/glsl/tests/swiz-02.glsl deleted file mode 100644 index e3f043c47b..0000000000 --- a/src/glsl/tests/swiz-02.glsl +++ /dev/null @@ -1,11 +0,0 @@ -/* FAIL: assignment of a vec2 to a float */ -#version 120 - -void main() -{ - float a; - vec4 b; - - b.x = 6.0; - a = b.xy; -} diff --git a/src/glsl/tests/void-01.glsl b/src/glsl/tests/void-01.glsl deleted file mode 100644 index 5719edc0b6..0000000000 --- a/src/glsl/tests/void-01.glsl +++ /dev/null @@ -1,2 +0,0 @@ -/* FAIL - cannot declare a variable as having type `void' */ -void foo; |