diff options
author | marha <marha@users.sourceforge.net> | 2012-04-10 10:49:59 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-04-10 10:49:59 +0200 |
commit | c6f80401dc533b04341afe8d596960d1bc25efce (patch) | |
tree | 2826007946218a8370d2eebc6aa32083618e2bfe /mesalib/src/glsl/ir_clone.cpp | |
parent | 31706e67674f308e3e7f2a8aaf02f1e0a00fbade (diff) | |
download | vcxsrv-c6f80401dc533b04341afe8d596960d1bc25efce.tar.gz vcxsrv-c6f80401dc533b04341afe8d596960d1bc25efce.tar.bz2 vcxsrv-c6f80401dc533b04341afe8d596960d1bc25efce.zip |
fontconfig mesa xkeyboard-config xserver pixman git update 10 Apr 2012
Diffstat (limited to 'mesalib/src/glsl/ir_clone.cpp')
-rw-r--r-- | mesalib/src/glsl/ir_clone.cpp | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/mesalib/src/glsl/ir_clone.cpp b/mesalib/src/glsl/ir_clone.cpp index c63615c7e..26b0d8f5f 100644 --- a/mesalib/src/glsl/ir_clone.cpp +++ b/mesalib/src/glsl/ir_clone.cpp @@ -27,6 +27,13 @@ #include "glsl_types.h" #include "program/hash_table.h" +ir_rvalue * +ir_rvalue::clone(void *mem_ctx, struct hash_table *ht) const +{ + /* The only possible instantiation is the generic error value. */ + return error_value(mem_ctx); +} + /** * Duplicate an IR variable * @@ -160,8 +167,9 @@ ir_loop::clone(void *mem_ctx, struct hash_table *ht) const ir_call * ir_call::clone(void *mem_ctx, struct hash_table *ht) const { - if (this->type == glsl_type::error_type) - return ir_call::get_error_instruction(mem_ctx); + ir_dereference_variable *new_return_ref = NULL; + if (this->return_deref != NULL) + new_return_ref = this->return_deref->clone(mem_ctx, ht); exec_list new_parameters; @@ -170,7 +178,7 @@ ir_call::clone(void *mem_ctx, struct hash_table *ht) const new_parameters.push_tail(ir->clone(mem_ctx, ht)); } - return new(mem_ctx) ir_call(this->callee, &new_parameters); + return new(mem_ctx) ir_call(this->callee, new_return_ref, &new_parameters); } ir_expression * @@ -390,9 +398,9 @@ public: * table. If it is found, replace it with the value from the table. */ ir_function_signature *sig = - (ir_function_signature *) hash_table_find(this->ht, ir->get_callee()); + (ir_function_signature *) hash_table_find(this->ht, ir->callee); if (sig != NULL) - ir->set_callee(sig); + ir->callee = sig; /* Since this may be used before function call parameters are flattened, * the children also need to be processed. |