From d91bd8651bd6ee5e9087ebc6558e3446e3e8d270 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Sat, 5 Mar 2016 10:48:54 -0800 Subject: [PATCH] Upgraded glsl-optimizer. --- 3rdparty/glsl-optimizer/Changelog.md | 9 + .../src/glsl/glsl_optimizer.cpp | 6 +- .../src/glsl/ir_print_metal_visitor.cpp | 12 +- 3rdparty/glsl-optimizer/src/glsl/list.h | 6 +- .../glsl-optimizer/src/glsl/loop_analysis.cpp | 175 +++++++++--------- .../glsl-optimizer/src/glsl/loop_analysis.h | 3 + .../src/mesa/program/prog_hash_table.c | 2 + .../fragment/array-const-outES3Metal.txt | 1 + .../fragment/array-constconst-outES3Metal.txt | 1 + .../tests/fragment/ast-outES3Metal.txt | 1 + ...ug-loop-undeclaredinductor-outES3Metal.txt | 1 + .../bug-sampler-highp-outES3Metal.txt | 1 + .../bug-sampler-highpfull-outES3Metal.txt | 1 + .../fragment/builtin-vars-outES3Metal.txt | 1 + .../tests/fragment/fragdepth-outES3Metal.txt | 1 + .../framebuffer_fetch-outES3Metal.txt | 1 + .../fragment/glsl120-basic-outES3Metal.txt | 1 + .../tests/fragment/intrinsics-outES3Metal.txt | 1 + .../tests/fragment/loop-for-outES3Metal.txt | 1 + .../loop-forafterdiscard-outES3Metal.txt | 1 + .../matrix-cast-types-outES3Metal.txt | 1 + .../tests/fragment/matrix-ops-outES3Metal.txt | 1 + .../fragment/mrt-mixed-array-outES3Metal.txt | 1 + .../tests/fragment/mrt-outES3Metal.txt | 1 + .../tests/fragment/mrt-unused-outES3Metal.txt | 1 + ...pt-dead-texloadstreeshadow-outES3Metal.txt | 1 + .../opt-grafting-precision-outES3Metal.txt | 1 + .../fragment/prec-expressions-outES3Metal.txt | 1 + .../prec-matrix-constr-outES3Metal.txt | 1 + .../qualifiers-layout-outES3Metal.txt | 1 + .../sampler-precision-outES3Metal.txt | 1 + .../tests/fragment/ternary-outES3Metal.txt | 1 + .../fragment/ternary-vec4-outES3Metal.txt | 1 + .../tests/fragment/tex2DArray-outES3Metal.txt | 1 + .../tests/fragment/tex2dgrad-outES3Metal.txt | 1 + .../tests/fragment/tex2dlod-outES3Metal.txt | 1 + .../fragment/tex2dshadow-outES3Metal.txt | 1 + .../tests/fragment/tex3D-outES3Metal.txt | 1 + .../fragment/texCubeShadow-outES3Metal.txt | 1 + .../tests/fragment/texOffset-outES3Metal.txt | 1 + .../tests/fragment/texProj-outES3Metal.txt | 1 + .../fragment/z-DirLMBasis-outES3Metal.txt | 1 + .../z-LightShaftsCoord-outES3Metal.txt | 1 + .../fragment/z-alphabumpspec-outES3Metal.txt | 1 + .../fragment/z-collectshadows-outES3Metal.txt | 1 + .../fragment/z-fxaa-preset3-outES3Metal.txt | 1 + .../fragment/z-prepasslight-outES3Metal.txt | 1 + .../z-tonemap-usercurve-outES3Metal.txt | 1 + .../fragment/z-treeleafloop-outES3Metal.txt | 1 + .../z-unishader-dirlm-outES3Metal.txt | 1 + .../fragment/z-unity-spot-outES3Metal.txt | 1 + .../zun-MobileBumpSpec-outES3Metal.txt | 1 + .../tests/fragment/zun-SSAO24-outES3Metal.txt | 1 + .../tests/glsl_optimizer_tests.cpp | 5 +- .../tests/vertex/MF-GodRays-outES3Metal.txt | 1 + .../bug-swizzle-lhs-cast-outES3Metal.txt | 1 + .../tests/vertex/builtin-vars-outES3Metal.txt | 1 + .../tests/vertex/inputs-outES3Metal.txt | 1 + .../vertex/loops-for-withvec4-outES3Metal.txt | 1 + ...oops-for-withvec4inductorW-outES3Metal.txt | 1 + .../loops-forlimitbreak-outES3Metal.txt | 1 + .../vertex/loops-forvarious-outES3Metal.txt | 1 + .../tests/vertex/matrix-casts-outES3Metal.txt | 1 + .../opt-matrix-transpose-mul-outES3Metal.txt | 1 + .../vertex/swizzle-casts-outES3Metal.txt | 1 + .../tests/vertex/types-outES3Metal.txt | 1 + .../vertex/uniforms-arrays-outES3Metal.txt | 1 + ...HybridLightVectorInsertBug-outES3Metal.txt | 1 + .../vertex/z-prepasslight-outES3Metal.txt | 1 + .../tests/vertex/z-treeleaf-outES3Metal.txt | 1 + 70 files changed, 181 insertions(+), 99 deletions(-) diff --git a/3rdparty/glsl-optimizer/Changelog.md b/3rdparty/glsl-optimizer/Changelog.md index ee09e025..39ce18b2 100644 --- a/3rdparty/glsl-optimizer/Changelog.md +++ b/3rdparty/glsl-optimizer/Changelog.md @@ -1,6 +1,14 @@ GLSL optimizer Change Log ========================= +2016 03 +------- + +Fixed: + +* Fixed translation performance regression in loop analysis (regressed in 2015 06 fixes). + + 2015 08 ------- @@ -35,6 +43,7 @@ Fixes: ------- Goodies: + * GLES2: support EXT_draw_instanced / gl_InstanceIDEXT. * Support gl_VertexID in GLSL < 1.30 when EXT_gpu_shader4 is used. diff --git a/3rdparty/glsl-optimizer/src/glsl/glsl_optimizer.cpp b/3rdparty/glsl-optimizer/src/glsl/glsl_optimizer.cpp index c4e7a03c..e91b86a9 100644 --- a/3rdparty/glsl-optimizer/src/glsl/glsl_optimizer.cpp +++ b/3rdparty/glsl-optimizer/src/glsl/glsl_optimizer.cpp @@ -440,8 +440,12 @@ static bool propagate_precision(exec_list* list, bool assign_high_to_undefined) static void do_optimization_passes(exec_list* ir, bool linked, _mesa_glsl_parse_state* state, void* mem_ctx) { bool progress; + // FIXME: Shouldn't need to bound the number of passes + int passes = 0, + kMaximumPasses = 1000; do { progress = false; + ++passes; bool progress2; debug_print_ir ("Initial", ir, state, mem_ctx); if (linked) { @@ -497,7 +501,7 @@ static void do_optimization_passes(exec_list* ir, bool linked, _mesa_glsl_parse_ } delete ls; } - } while (progress); + } while (progress && passes < kMaximumPasses); if (!state->metal_target) { diff --git a/3rdparty/glsl-optimizer/src/glsl/ir_print_metal_visitor.cpp b/3rdparty/glsl-optimizer/src/glsl/ir_print_metal_visitor.cpp index 9f7071d9..f9988a31 100644 --- a/3rdparty/glsl-optimizer/src/glsl/ir_print_metal_visitor.cpp +++ b/3rdparty/glsl-optimizer/src/glsl/ir_print_metal_visitor.cpp @@ -1020,17 +1020,7 @@ void ir_print_metal_visitor::visit(ir_expression *ir) const bool halfCast = (arg_prec == glsl_precision_medium || arg_prec == glsl_precision_low); buffer.asprintf_append (halfCast ? "((half)1.0/(" : "(1.0/("); } else { - switch(ir->operation) { - case ir_unop_dFdy: - case ir_unop_dFdy_coarse: - case ir_unop_dFdy_fine: - buffer.asprintf_append ("%s(-", operator_glsl_strs[ir->operation]); - break; - - default: - buffer.asprintf_append ("%s(", operator_glsl_strs[ir->operation]); - break; - } + buffer.asprintf_append ("%s(", operator_glsl_strs[ir->operation]); } if (ir->operands[0]) ir->operands[0]->accept(this); diff --git a/3rdparty/glsl-optimizer/src/glsl/list.h b/3rdparty/glsl-optimizer/src/glsl/list.h index b6c32bcc..ae0a15ca 100644 --- a/3rdparty/glsl-optimizer/src/glsl/list.h +++ b/3rdparty/glsl-optimizer/src/glsl/list.h @@ -163,8 +163,10 @@ exec_node_get_prev(struct exec_node *n) static inline void exec_node_remove(struct exec_node *n) { - n->next->prev = n->prev; - n->prev->next = n->next; + if (n->next) + n->next->prev = n->prev; + if (n->prev) + n->prev->next = n->next; n->next = NULL; n->prev = NULL; } diff --git a/3rdparty/glsl-optimizer/src/glsl/loop_analysis.cpp b/3rdparty/glsl-optimizer/src/glsl/loop_analysis.cpp index 240ffc73..b0d3e306 100644 --- a/3rdparty/glsl-optimizer/src/glsl/loop_analysis.cpp +++ b/3rdparty/glsl-optimizer/src/glsl/loop_analysis.cpp @@ -25,11 +25,10 @@ #include "loop_analysis.h" #include "ir_hierarchical_visitor.h" #include "ir_variable_refcount.h" +#include "util/hash_table.h" static bool is_loop_terminator(ir_if *ir); -static bool used_outside_loops(exec_node *head, ir_variable *var, bool first_assignment); - static bool all_expression_operands_are_loop_constant(ir_rvalue *, hash_table *); @@ -84,6 +83,8 @@ loop_state::loop_state() hash_table_pointer_compare); this->ht_non_inductors = hash_table_ctor(0, hash_table_pointer_hash, hash_table_pointer_compare); + this->ht_variables = hash_table_ctor(0, hash_table_pointer_hash, + hash_table_pointer_compare); this->mem_ctx = ralloc_context(NULL); this->loop_found = false; } @@ -94,6 +95,7 @@ loop_state::~loop_state() hash_table_dtor(this->ht); hash_table_dtor(this->ht_inductors); hash_table_dtor(this->ht_non_inductors); + hash_table_dtor(this->ht_variables); ralloc_free(this->mem_ctx); } @@ -122,10 +124,36 @@ loop_state::get_for_inductor(const ir_variable *ir) return (loop_variable_state *) hash_table_find(this->ht_inductors, ir); } +static void *unreferenced_variable = (void *)1; +static void *assigned_variable = (void *)2; + void -loop_state::insert_non_inductor(ir_variable *var) +loop_state::insert_variable(ir_variable *var) { - // key doesn't matter, just needs to be non-NULL + // data starts as 1. If an assignment is seen, it's replaced with 2. + // this way we can mark a variable as a non-inductor if it's referenced + // other than the first assignment + hash_table_insert(this->ht_variables, unreferenced_variable, var); +} + +void +loop_state::reference_variable(ir_variable *var, bool assignment) +{ + void *ref = hash_table_find(this->ht_variables, var); + + // variable declaration was not seen or already discarded, just ignore + if (ref == NULL) + return; + + if (ref == unreferenced_variable && assignment) + { + hash_table_replace(this->ht_variables, assigned_variable, var); + return; + } + + // variable is referenced and not just in an initial assignment, + // so it cannot be an inductor + hash_table_remove(this->ht_variables, var); hash_table_insert(this->ht_non_inductors, this, var); } @@ -266,10 +294,14 @@ public: virtual ir_visitor_status visit_enter(ir_if *); virtual ir_visitor_status visit_leave(ir_if *); + void visit_general(ir_instruction *); + loop_state *loops; int if_statement_depth; + bool first_pass; + ir_assignment *current_assignment; exec_list state; @@ -277,10 +309,17 @@ public: } /* anonymous namespace */ +void loop_enter_callback(class ir_instruction *ir, void *data) +{ + ((loop_analysis *)data)->visit_general(ir); +} + loop_analysis::loop_analysis(loop_state *loops) - : loops(loops), if_statement_depth(0), current_assignment(NULL) + : loops(loops), if_statement_depth(0), current_assignment(NULL), first_pass(false) { /* empty */ + data_enter = this; + callback_enter = &loop_enter_callback; } @@ -308,16 +347,11 @@ loop_analysis::visit(ir_variable *var) if (!this->state.is_empty()) return visit_continue; - // Check if this variable is used outside a loop anywhere. If it is, it can't be a - // variable that's private to the loop, so can't be an inductor. - // This doesn't reject all possible non-inductors, notably anything declared in an - // outer loop that isn't an inductor in an inner loop, but it can eliminate some - // problem cases - if (used_outside_loops(var->next, var, false)) - { - // add to list of "non inductors" - loops->insert_non_inductor(var); - } + // In the first pass over the instructions we look at variables declared and + // examine their references to determine if they can be an inductor or not + // for the second pass + if (this->first_pass) + loops->insert_variable(var); return visit_continue; } @@ -339,10 +373,15 @@ loop_analysis::visit_enter(ir_call *) ir_visitor_status loop_analysis::visit(ir_dereference_variable *ir) { - /* If we're not somewhere inside a loop, there's nothing to do. + /* If we're not somewhere inside a loop, just check for + * non-inductors */ - if (this->state.is_empty()) + if (this->state.is_empty() || this->first_pass) + { + if (this->state.is_empty() && this->first_pass) + loops->reference_variable(ir->variable_referenced(), this->in_assignee); return visit_continue; + } bool nested = false; @@ -382,8 +421,11 @@ loop_analysis::visit_leave(ir_loop *ir) * We could perform some conservative analysis (prove there's no statically * possible assignment, etc.) but it isn't worth it for now; function * inlining will allow us to unroll loops anyway. + * + * We also skip doing any work in the first pass, where we are just identifying + * variables that cannot be inductors. */ - if (ls->contains_calls) + if (ls->contains_calls || this->first_pass) return visit_continue; foreach_in_list(ir_instruction, node, &ir->body_instructions) { @@ -591,7 +633,7 @@ loop_analysis::visit_enter(ir_assignment *ir) /* If we're not somewhere inside a loop, there's nothing to do. */ if (this->state.is_empty()) - return visit_continue_with_parent; + return visit_continue; this->current_assignment = ir; @@ -601,10 +643,8 @@ loop_analysis::visit_enter(ir_assignment *ir) ir_visitor_status loop_analysis::visit_leave(ir_assignment *ir) { - /* Since the visit_enter exits with visit_continue_with_parent for this - * case, the loop state stack should never be empty here. - */ - assert(!this->state.is_empty()); + if (this->state.is_empty()) + return visit_continue; assert(this->current_assignment == ir); this->current_assignment = NULL; @@ -612,6 +652,24 @@ loop_analysis::visit_leave(ir_assignment *ir) return visit_continue; } +void +loop_analysis::visit_general(ir_instruction *ir) +{ + /* If we're inside a loop, we can't start marking things as non-inductors + * Likewise in the second pass we've done all this work, so return early + */ + if (!this->state.is_empty() || !this->first_pass) + return; + + ir_variable_refcount_visitor refs; + ir->accept (&refs); + + struct hash_entry *referenced_var; + hash_table_foreach (refs.ht, referenced_var) { + ir_variable *var = (ir_variable *)referenced_var->key; + loops->reference_variable(var, false); + } +} class examine_rhs : public ir_hierarchical_visitor { public: @@ -733,72 +791,23 @@ is_loop_terminator(ir_if *ir) return true; } - -bool -used_outside_loops(exec_node *head, ir_variable *var, bool first_assignment) -{ - ir_variable_refcount_visitor refs; - for (exec_node* node = head; - !node->is_tail_sentinel(); - node = node->next) - { - ir_instruction *ir = (ir_instruction *) node; - if (ir->ir_type == ir_type_variable) - continue; - - // ignore the first assignment - if (!first_assignment && ir->ir_type == ir_type_assignment) - { - ir_assignment *assign = ir->as_assignment(); - ir_variable *assignee = assign->lhs->whole_variable_referenced(); - - if(assignee == var) - { - first_assignment = true; - continue; - } - } - - // we don't want to recurse into loops - if (ir->ir_type == ir_type_loop) - continue; - - // recurse only for if statements, the other case we would need to recurse is - // loops, but we are looking for uses outside of loops. - if (ir->ir_type == ir_type_if) - { - ir_if *irif = ir->as_if(); - if (used_outside_loops(irif->then_instructions.head, var, first_assignment)) - return true; - if (used_outside_loops(irif->else_instructions.head, var, first_assignment)) - return true; - - // if we didn't find in each branch with our recursion, skip - // otherwise the accept (&refs) below will recurse into loops - // and may give a false positive. - continue; - } - - // we know that we're not inside a loop as we haven't recursed inside, - // and we started outside of a loop, so any references to this variable - // mean it is used outside of any loops - ir->accept (&refs); - if (refs.find_variable_entry(var)) - { - return true; - } - } - - return false; -} - - loop_state * analyze_loop_variables(exec_list *instructions) { loop_state *loops = new loop_state; loop_analysis v(loops); + /* Do two passes over the instructions. The first pass builds a view + * of the variables declared and whether or not they're used outside + * of loops (if so, they cannot be inductors). + * + * In the second pass we apply this information to do the loop analysis + * itself. + */ + v.first_pass = true; v.run(instructions); + v.first_pass = false; + v.run(instructions); + return v.loops; } diff --git a/3rdparty/glsl-optimizer/src/glsl/loop_analysis.h b/3rdparty/glsl-optimizer/src/glsl/loop_analysis.h index 299dbcfc..3b6b2d01 100644 --- a/3rdparty/glsl-optimizer/src/glsl/loop_analysis.h +++ b/3rdparty/glsl-optimizer/src/glsl/loop_analysis.h @@ -251,6 +251,8 @@ public: loop_variable_state* get_for_inductor (const ir_variable*); bool insert_inductor(loop_variable* loopvar, loop_variable_state* state, ir_loop* loop); void insert_non_inductor(ir_variable *var); + void insert_variable(ir_variable *var); + void reference_variable(ir_variable *var, bool assignment); bool loop_found; @@ -267,6 +269,7 @@ private: */ hash_table *ht_inductors; hash_table *ht_non_inductors; + hash_table *ht_variables; void *mem_ctx; diff --git a/3rdparty/glsl-optimizer/src/mesa/program/prog_hash_table.c b/3rdparty/glsl-optimizer/src/mesa/program/prog_hash_table.c index 3b2152b6..680699b5 100644 --- a/3rdparty/glsl-optimizer/src/mesa/program/prog_hash_table.c +++ b/3rdparty/glsl-optimizer/src/mesa/program/prog_hash_table.c @@ -84,6 +84,8 @@ hash_table_ctor(unsigned num_buckets, hash_func_t hash, void hash_table_dtor(struct hash_table *ht) { + if (!ht) + return; hash_table_clear(ht); free(ht); } diff --git a/3rdparty/glsl-optimizer/tests/fragment/array-const-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/array-const-outES3Metal.txt index cb270ab7..3021d1f2 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/array-const-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/array-const-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/array-constconst-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/array-constconst-outES3Metal.txt index cb270ab7..3021d1f2 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/array-constconst-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/array-constconst-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/ast-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/ast-outES3Metal.txt index 0069dadf..4bd58f32 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/ast-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/ast-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 gl_FragCoord [[position]]; diff --git a/3rdparty/glsl-optimizer/tests/fragment/bug-loop-undeclaredinductor-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/bug-loop-undeclaredinductor-outES3Metal.txt index 79614415..c794c125 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/bug-loop-undeclaredinductor-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/bug-loop-undeclaredinductor-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highp-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highp-outES3Metal.txt index 993c7370..424ef016 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highp-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highp-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 varUV; diff --git a/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highpfull-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highpfull-outES3Metal.txt index 504f13c2..f6753627 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highpfull-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/bug-sampler-highpfull-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; constant float2 _xlat_mtl_const1[12] = {float2(-0.326212, -0.40581), float2(-0.840144, -0.07358), float2(-0.695914, 0.457137), float2(-0.203345, 0.620716), float2(0.96234, -0.194983), float2(0.473434, -0.480026), float2(0.519456, 0.767022), float2(0.185461, -0.893124), float2(0.507431, 0.064425), float2(0.89642, 0.412458), float2(-0.32194, -0.932615), float2(-0.791559, -0.59771)}; struct xlatMtlShaderInput { diff --git a/3rdparty/glsl-optimizer/tests/fragment/builtin-vars-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/builtin-vars-outES3Metal.txt index c9a6e790..82058c23 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/builtin-vars-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/builtin-vars-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 gl_PointCoord [[point_coord]]; diff --git a/3rdparty/glsl-optimizer/tests/fragment/fragdepth-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/fragdepth-outES3Metal.txt index 4e428db7..b3ab3030 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/fragdepth-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/fragdepth-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/framebuffer_fetch-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/framebuffer_fetch-outES3Metal.txt index 1d924da0..c2470caf 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/framebuffer_fetch-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/framebuffer_fetch-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half4 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/glsl120-basic-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/glsl120-basic-outES3Metal.txt index 94760a64..4f5521cd 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/glsl120-basic-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/glsl120-basic-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/intrinsics-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/intrinsics-outES3Metal.txt index ef6d9b45..223b512f 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/intrinsics-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/intrinsics-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/loop-for-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/loop-for-outES3Metal.txt index 00177859..87ded88a 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/loop-for-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/loop-for-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_uv; diff --git a/3rdparty/glsl-optimizer/tests/fragment/loop-forafterdiscard-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/loop-forafterdiscard-outES3Metal.txt index 171650fb..562cb9ac 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/loop-forafterdiscard-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/loop-forafterdiscard-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_uv; diff --git a/3rdparty/glsl-optimizer/tests/fragment/matrix-cast-types-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/matrix-cast-types-outES3Metal.txt index bb6013bd..f0df5674 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/matrix-cast-types-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/matrix-cast-types-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; inline float4x4 _xlcast_float4x4(half4x4 v) { return float4x4(float4(v[0]), float4(v[1]), float4(v[2]), float4(v[3])); } inline float3x3 _xlcast_float3x3(half3x3 v) { return float3x3(float3(v[0]), float3(v[1]), float3(v[2])); } diff --git a/3rdparty/glsl-optimizer/tests/fragment/matrix-ops-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/matrix-ops-outES3Metal.txt index 458ecd3d..1fbb32d9 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/matrix-ops-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/matrix-ops-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; inline float4x4 _xlinit_float4x4(float v) { return float4x4(float4(v), float4(v), float4(v), float4(v)); } inline float3x3 _xlinit_float3x3(float v) { return float3x3(float3(v), float3(v), float3(v)); } diff --git a/3rdparty/glsl-optimizer/tests/fragment/mrt-mixed-array-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/mrt-mixed-array-outES3Metal.txt index 3e3ab125..4c9c30d5 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/mrt-mixed-array-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/mrt-mixed-array-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/mrt-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/mrt-outES3Metal.txt index fed2b03d..e4b3f820 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/mrt-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/mrt-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/mrt-unused-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/mrt-unused-outES3Metal.txt index 1f1a28a9..a39c1b7d 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/mrt-unused-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/mrt-unused-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half4 xlv_COLOR0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/opt-dead-texloadstreeshadow-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/opt-dead-texloadstreeshadow-outES3Metal.txt index 31df0dfe..369965c5 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/opt-dead-texloadstreeshadow-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/opt-dead-texloadstreeshadow-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/opt-grafting-precision-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/opt-grafting-precision-outES3Metal.txt index 5c809e60..0d959ebe 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/opt-grafting-precision-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/opt-grafting-precision-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half3 normal; diff --git a/3rdparty/glsl-optimizer/tests/fragment/prec-expressions-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/prec-expressions-outES3Metal.txt index ddfda4d4..eb189493 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/prec-expressions-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/prec-expressions-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/prec-matrix-constr-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/prec-matrix-constr-outES3Metal.txt index 80891a9b..3462062a 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/prec-matrix-constr-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/prec-matrix-constr-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half3 inNormal; diff --git a/3rdparty/glsl-optimizer/tests/fragment/qualifiers-layout-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/qualifiers-layout-outES3Metal.txt index 64f92a1e..5edc1f20 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/qualifiers-layout-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/qualifiers-layout-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { }; diff --git a/3rdparty/glsl-optimizer/tests/fragment/sampler-precision-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/sampler-precision-outES3Metal.txt index 7d8a5f94..82d78249 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/sampler-precision-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/sampler-precision-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 varUV; diff --git a/3rdparty/glsl-optimizer/tests/fragment/ternary-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/ternary-outES3Metal.txt index aff9cd48..ca234064 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/ternary-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/ternary-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/ternary-vec4-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/ternary-vec4-outES3Metal.txt index 314f5f7c..4471023a 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/ternary-vec4-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/ternary-vec4-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/tex2DArray-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/tex2DArray-outES3Metal.txt index f74638ff..606d3bb3 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/tex2DArray-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/tex2DArray-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 uv; diff --git a/3rdparty/glsl-optimizer/tests/fragment/tex2dgrad-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/tex2dgrad-outES3Metal.txt index 3c81d626..a070be52 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/tex2dgrad-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/tex2dgrad-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half3 uv1; diff --git a/3rdparty/glsl-optimizer/tests/fragment/tex2dlod-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/tex2dlod-outES3Metal.txt index bbe17239..e8f1746e 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/tex2dlod-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/tex2dlod-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 uvHi; diff --git a/3rdparty/glsl-optimizer/tests/fragment/tex2dshadow-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/tex2dshadow-outES3Metal.txt index 2d85a7fc..3171b51a 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/tex2dshadow-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/tex2dshadow-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; constexpr sampler _mtl_xl_shadow_sampler(address::clamp_to_edge, filter::linear, compare_func::less); struct xlatMtlShaderInput { diff --git a/3rdparty/glsl-optimizer/tests/fragment/tex3D-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/tex3D-outES3Metal.txt index 59999473..91d9515c 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/tex3D-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/tex3D-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float3 uv; diff --git a/3rdparty/glsl-optimizer/tests/fragment/texCubeShadow-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/texCubeShadow-outES3Metal.txt index 68ec1601..e98663c9 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/texCubeShadow-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/texCubeShadow-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; constexpr sampler _mtl_xl_shadow_sampler(address::clamp_to_edge, filter::linear, compare_func::less); struct xlatMtlShaderInput { diff --git a/3rdparty/glsl-optimizer/tests/fragment/texOffset-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/texOffset-outES3Metal.txt index 2a1b68ce..282db076 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/texOffset-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/texOffset-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half3 uv; diff --git a/3rdparty/glsl-optimizer/tests/fragment/texProj-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/texProj-outES3Metal.txt index 961349b0..454f4127 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/texProj-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/texProj-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; constexpr sampler _mtl_xl_shadow_sampler(address::clamp_to_edge, filter::linear, compare_func::less); struct xlatMtlShaderInput { diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-DirLMBasis-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-DirLMBasis-outES3Metal.txt index 88dbe7f7..2fefeb70 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-DirLMBasis-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-DirLMBasis-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-LightShaftsCoord-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-LightShaftsCoord-outES3Metal.txt index 1ae45cf3..a336ad7a 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-LightShaftsCoord-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-LightShaftsCoord-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-alphabumpspec-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-alphabumpspec-outES3Metal.txt index 40f554b1..46530468 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-alphabumpspec-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-alphabumpspec-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _uv0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-collectshadows-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-collectshadows-outES3Metal.txt index 39ecc369..1d2fdeae 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-collectshadows-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-collectshadows-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-fxaa-preset3-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-fxaa-preset3-outES3Metal.txt index 852c4e0d..6fa4138a 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-fxaa-preset3-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-fxaa-preset3-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-prepasslight-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-prepasslight-outES3Metal.txt index 1e43ec7a..57b1c341 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-prepasslight-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-prepasslight-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-tonemap-usercurve-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-tonemap-usercurve-outES3Metal.txt index ccff9b03..97b273a9 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-tonemap-usercurve-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-tonemap-usercurve-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-treeleafloop-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-treeleafloop-outES3Metal.txt index bbec809e..4a8dc6d4 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-treeleafloop-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-treeleafloop-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-unishader-dirlm-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-unishader-dirlm-outES3Metal.txt index 86355a1c..0984cae0 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-unishader-dirlm-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-unishader-dirlm-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/z-unity-spot-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/z-unity-spot-outES3Metal.txt index a488e9fe..5a77ed42 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/z-unity-spot-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/z-unity-spot-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/zun-MobileBumpSpec-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/zun-MobileBumpSpec-outES3Metal.txt index 469afd23..4743f651 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/zun-MobileBumpSpec-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/zun-MobileBumpSpec-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { half2 xlv_TEXCOORD0; diff --git a/3rdparty/glsl-optimizer/tests/fragment/zun-SSAO24-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/fragment/zun-SSAO24-outES3Metal.txt index de7007b9..3e2c3d4f 100644 --- a/3rdparty/glsl-optimizer/tests/fragment/zun-SSAO24-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/fragment/zun-SSAO24-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; constant float3 _xlat_mtl_const1[8] = {float3(0.0130572, 0.587232, -0.119337), float3(0.323078, 0.0220727, -0.418873), float3(-0.310725, -0.191367, 0.0561369), float3(-0.479646, 0.0939877, -0.580265), float3(0.139999, -0.33577, 0.559679), float3(-0.248458, 0.255532, 0.348944), float3(0.18719, -0.702764, -0.231748), float3(0.884915, 0.284208, 0.368524)}; struct xlatMtlShaderInput { diff --git a/3rdparty/glsl-optimizer/tests/glsl_optimizer_tests.cpp b/3rdparty/glsl-optimizer/tests/glsl_optimizer_tests.cpp index ddca5d1f..caf87f26 100644 --- a/3rdparty/glsl-optimizer/tests/glsl_optimizer_tests.cpp +++ b/3rdparty/glsl-optimizer/tests/glsl_optimizer_tests.cpp @@ -315,9 +315,9 @@ static bool CheckGLSL (bool vertex, bool gles, const std::string& testName, cons static bool CheckMetal (bool vertex, bool gles, const std::string& testName, const char* prefix, const std::string& source) { -#if !GOT_GFX +#if !GOT_GFX || !defined(__APPLE__) return true; // just assume it's ok -#endif +#else FILE* f = fopen ("metalTemp.metal", "wb"); fwrite (source.c_str(), source.size(), 1, f); @@ -333,6 +333,7 @@ static bool CheckMetal (bool vertex, bool gles, const std::string& testName, con #endif // return true; +#endif } diff --git a/3rdparty/glsl-optimizer/tests/vertex/MF-GodRays-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/MF-GodRays-outES3Metal.txt index 36efe5b0..c52c31b9 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/MF-GodRays-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/MF-GodRays-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _inVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/bug-swizzle-lhs-cast-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/bug-swizzle-lhs-cast-outES3Metal.txt index d2b15808..1da74693 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/bug-swizzle-lhs-cast-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/bug-swizzle-lhs-cast-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _glesVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/builtin-vars-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/builtin-vars-outES3Metal.txt index 3c5b6e33..8d3e95e4 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/builtin-vars-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/builtin-vars-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float3 _inPos [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/inputs-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/inputs-outES3Metal.txt index 69cc59a3..f896ff66 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/inputs-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/inputs-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _glesVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4-outES3Metal.txt index 8976a675..fc95a3de 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 dcl_Input0_POSITION0 [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4inductorW-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4inductorW-outES3Metal.txt index a6e6c9b7..00690e14 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4inductorW-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/loops-for-withvec4inductorW-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 in_POSITION0 [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/loops-forlimitbreak-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/loops-forlimitbreak-outES3Metal.txt index 4fff005a..097f161d 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/loops-forlimitbreak-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/loops-forlimitbreak-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _glesVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/loops-forvarious-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/loops-forvarious-outES3Metal.txt index 6e94ee11..a87dcb78 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/loops-forvarious-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/loops-forvarious-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _inVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/matrix-casts-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/matrix-casts-outES3Metal.txt index 8e8bf350..b888c4c9 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/matrix-casts-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/matrix-casts-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; inline float4x4 _xlcast_float4x4(half4x4 v) { return float4x4(float4(v[0]), float4(v[1]), float4(v[2]), float4(v[3])); } inline float3x3 _xlcast_float3x3(half3x3 v) { return float3x3(float3(v[0]), float3(v[1]), float3(v[2])); } diff --git a/3rdparty/glsl-optimizer/tests/vertex/opt-matrix-transpose-mul-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/opt-matrix-transpose-mul-outES3Metal.txt index 98b2075b..78a49f1c 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/opt-matrix-transpose-mul-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/opt-matrix-transpose-mul-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 attrVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/swizzle-casts-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/swizzle-casts-outES3Metal.txt index b657adeb..0667465c 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/swizzle-casts-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/swizzle-casts-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _glesVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/types-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/types-outES3Metal.txt index 40a4d863..310cef2d 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/types-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/types-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _inVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/uniforms-arrays-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/uniforms-arrays-outES3Metal.txt index 979ea561..c6557d37 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/uniforms-arrays-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/uniforms-arrays-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _glesVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/z-NichsHybridLightVectorInsertBug-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/z-NichsHybridLightVectorInsertBug-outES3Metal.txt index a56f7df0..680204bd 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/z-NichsHybridLightVectorInsertBug-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/z-NichsHybridLightVectorInsertBug-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _glesVertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/z-prepasslight-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/z-prepasslight-outES3Metal.txt index a6f6f5c0..36a8c79b 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/z-prepasslight-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/z-prepasslight-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _vertex [[attribute(0)]]; diff --git a/3rdparty/glsl-optimizer/tests/vertex/z-treeleaf-outES3Metal.txt b/3rdparty/glsl-optimizer/tests/vertex/z-treeleaf-outES3Metal.txt index f825c2f8..3d9bc6f8 100644 --- a/3rdparty/glsl-optimizer/tests/vertex/z-treeleaf-outES3Metal.txt +++ b/3rdparty/glsl-optimizer/tests/vertex/z-treeleaf-outES3Metal.txt @@ -1,4 +1,5 @@ #include +#pragma clang diagnostic ignored "-Wparentheses-equality" using namespace metal; struct xlatMtlShaderInput { float4 _inVertex [[attribute(0)]];