diff options
author | Caio Marcelo de Oliveira Filho <[email protected]> | 2019-01-11 11:50:53 -0800 |
---|---|---|
committer | Caio Marcelo de Oliveira Filho <[email protected]> | 2019-01-14 10:49:28 -0800 |
commit | 9fdded0cc34b4bdb87923707c05b8ceffb2f174c (patch) | |
tree | b742e0cd4e33cd4766ed9f0b03c5c3eda2470556 /src/compiler/glsl/linker.cpp | |
parent | ee23e8b17c77fa94320168427fb8a10a84b50e94 (diff) |
src/compiler: use new hash table and set creation helpers
Replace calls to create hash tables and sets that use
_mesa_hash_pointer/_mesa_key_pointer_equal with the helpers
_mesa_pointer_hash_table_create() and _mesa_pointer_set_create().
Reviewed-by: Jason Ekstrand <[email protected]>
Acked-by: Eric Engestrom <[email protected]>
Diffstat (limited to 'src/compiler/glsl/linker.cpp')
-rw-r--r-- | src/compiler/glsl/linker.cpp | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/compiler/glsl/linker.cpp b/src/compiler/glsl/linker.cpp index d9b9f60067f..2d76e852f47 100644 --- a/src/compiler/glsl/linker.cpp +++ b/src/compiler/glsl/linker.cpp @@ -1460,8 +1460,7 @@ move_non_declarations(exec_list *instructions, exec_node *last, hash_table *temps = NULL; if (make_copies) - temps = _mesa_hash_table_create(NULL, _mesa_hash_pointer, - _mesa_key_pointer_equal); + temps = _mesa_pointer_hash_table_create(NULL); foreach_in_list_safe(ir_instruction, inst, instructions) { if (inst->as_function()) @@ -1507,8 +1506,7 @@ class array_sizing_visitor : public deref_type_updater { public: array_sizing_visitor() : mem_ctx(ralloc_context(NULL)), - unnamed_interfaces(_mesa_hash_table_create(NULL, _mesa_hash_pointer, - _mesa_key_pointer_equal)) + unnamed_interfaces(_mesa_pointer_hash_table_create(NULL)) { } @@ -4412,9 +4410,7 @@ build_program_resource_list(struct gl_context *ctx, if (input_stage == MESA_SHADER_STAGES && output_stage == 0) return; - struct set *resource_set = _mesa_set_create(NULL, - _mesa_hash_pointer, - _mesa_key_pointer_equal); + struct set *resource_set = _mesa_pointer_set_create(NULL); /* Program interface needs to expose varyings in case of SSO. */ if (shProg->SeparateShader) { |