Revert "glsl: don't try to lower non-gl builtins as if they were gl_FragData"
authorMarek Olšák <marek.olsak@amd.com>
Mon, 8 Aug 2016 20:05:29 +0000 (22:05 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Mon, 8 Aug 2016 21:24:20 +0000 (23:24 +0200)
This reverts commit a37e46323c7e18bec4160f2f66847c10b7041dc1.

It broke the game Overlord such that it hung a GCN GNU. While I don't know
how the hang happened because of its randomness and gfx corruption precedes
it, many of the shaders contain this:

out vec4 FragData[gl_MaxDrawBuffers];

src/compiler/glsl/opt_dead_builtin_varyings.cpp

index 900a09697bb48cd56c42265e5c9c76171c754d91..33648d72cbfe18c0bc51410e94ca3ded8d480201 100644 (file)
@@ -85,8 +85,7 @@ public:
    {
       ir_variable *var = ir->variable_referenced();
 
-      if (!var || var->data.mode != this->mode || !var->type->is_array() ||
-          !is_gl_identifier(var->name))
+      if (!var || var->data.mode != this->mode || !var->type->is_array())
          return visit_continue;
 
       /* Only match gl_FragData[], not gl_SecondaryFragDataEXT[] */