i915: Force lowering of all types of indirect array accesses in the FS
authorIan Romanick <ian.d.romanick@intel.com>
Thu, 10 Feb 2011 19:51:28 +0000 (11:51 -0800)
committerIan Romanick <ian.d.romanick@intel.com>
Thu, 10 Feb 2011 21:26:49 +0000 (13:26 -0800)
NOTE: This is a candidate for the 7.9 and 7.10 branches.

src/mesa/drivers/dri/i915/i915_context.c

index 474252b640d0aa4bab106b5a98465f544d220974..7389a1d57a90750b54eaa2153290b43fa629ca80 100644 (file)
@@ -188,9 +188,17 @@ i915CreateContext(int api,
     * FINISHME: vertex shaders?
     */
    ctx->ShaderCompilerOptions[MESA_SHADER_VERTEX].EmitCondCodes = GL_TRUE;
-   ctx->ShaderCompilerOptions[MESA_SHADER_FRAGMENT].EmitNoIfs = GL_TRUE;
-   ctx->ShaderCompilerOptions[MESA_SHADER_FRAGMENT].EmitNoNoise = GL_TRUE;
-   ctx->ShaderCompilerOptions[MESA_SHADER_FRAGMENT].EmitNoPow = GL_TRUE;
+
+   struct gl_shader_compiler_options *const fs_options =
+      & ctx->ShaderCompilerOptions[MESA_SHADER_FRAGMENT];
+   fs_options->EmitNoIfs = GL_TRUE;
+   fs_options->EmitNoNoise = GL_TRUE;
+   fs_options->EmitNoPow = GL_TRUE;
+   fs_options->EmitNoMainReturn = GL_TRUE;
+   fs_options->EmitNoIndirectInput = GL_TRUE;
+   fs_options->EmitNoIndirectOutput = GL_TRUE;
+   fs_options->EmitNoIndirectUniform = GL_TRUE;
+   fs_options->EmitNoIndirectTemp = GL_TRUE;
 
    ctx->Const.MaxDrawBuffers = 1;