diff options
author | Luca Barbieri <[email protected]> | 2010-09-05 22:29:58 +0200 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2010-09-08 20:36:37 -0700 |
commit | e591c4625cae63660c5000fbab366e40fe154ab0 (patch) | |
tree | 06b65ce727933c9bc7be208085c7400ed5b37f6f /src/mesa/main/shaderapi.c | |
parent | 6d3a2c97f4a78e85545286e0e126cd3a27bd1cbd (diff) |
glsl: add several EmitNo* options, and MaxUnrollIterations
This increases the chance that GLSL programs will actually work.
Note that continues and returns are not yet lowered, so linking
will just fail if not supported.
Signed-off-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/mesa/main/shaderapi.c')
-rw-r--r-- | src/mesa/main/shaderapi.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c index 2977a29ab74..c32c09f8d4b 100644 --- a/src/mesa/main/shaderapi.c +++ b/src/mesa/main/shaderapi.c @@ -97,10 +97,14 @@ _mesa_init_shader_state(GLcontext *ctx) struct gl_shader_compiler_options options; GLuint i; options.EmitHighLevelInstructions = GL_TRUE; - options.EmitContReturn = GL_TRUE; options.EmitCondCodes = GL_FALSE; options.EmitComments = GL_FALSE; options.EmitNoIfs = GL_FALSE; + options.EmitNoLoops = GL_FALSE; + options.EmitNoFunctions = GL_FALSE; + options.EmitNoCont = GL_FALSE; + options.EmitNoMainReturn = GL_FALSE; + options.MaxUnrollIterations = 32; /* Default pragma settings */ options.DefaultPragmas.IgnoreOptimize = GL_FALSE; |