diff options
| author | Kenneth Graunke <kenneth@whitecape.org> | 2010-07-22 18:29:29 -0700 | 
|---|---|---|
| committer | Kenneth Graunke <kenneth@whitecape.org> | 2010-07-28 15:46:26 -0700 | 
| commit | 46d91615a2f6e1beaee98f40af957ba1a1a6b349 (patch) | |
| tree | bdb2b040f46eb571f769c4d61275971d58bde1bc /src | |
| parent | bafd89fa0f026cef12024382b154a41d90d00373 (diff) | |
ast_function: Set constant_value on return value temporaries in 1.20+.
Diffstat (limited to 'src')
| -rw-r--r-- | src/glsl/ast_function.cpp | 2 | 
1 files changed, 2 insertions, 0 deletions
| diff --git a/src/glsl/ast_function.cpp b/src/glsl/ast_function.cpp index 855f27f175..bb45e2530d 100644 --- a/src/glsl/ast_function.cpp +++ b/src/glsl/ast_function.cpp @@ -122,6 +122,8 @@ process_call(exec_list *instructions, ir_function *f,  	 deref = new(ctx) ir_dereference_variable(var);  	 ir_assignment *assign = new(ctx) ir_assignment(deref, call, NULL);  	 instructions->push_tail(assign); +	 if (state->language_version >= 120) +	    var->constant_value = call->constant_expression_value();  	 deref = new(ctx) ir_dereference_variable(var);  	 return deref; | 
