gallivm: Separate freeing LLVM intermediate data from freeing final code.
authorFrank Henigman <fjhenigman@google.com>
Tue, 1 Oct 2013 19:15:42 +0000 (15:15 -0400)
committerJosé Fonseca <jfonseca@vmware.com>
Wed, 14 May 2014 10:05:00 +0000 (11:05 +0100)
commit865d0312c0dd7411ce813206cef3c399d6641241
tree47ed3c8a2a4c2662f8d38d6bbc5baa80bed4407b
parent2c73102dc33bb2ac2475cecd0614a5889db36630
gallivm: Separate freeing LLVM intermediate data from freeing final code.

Split free_gallivm_state() into two steps.  First step is
gallivm_free_ir() which cleans up the LLVM scaffolding used to generate
code while preserving the code itself.  Second step is
gallivm_free_code() to free the memory occupied by the code.

v2: s/gallivm_teardown/gallivm_free_ir/ (Jose)

Signed-off-by: José Fonseca <jfonseca@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
src/gallium/auxiliary/gallivm/lp_bld_init.c
src/gallium/auxiliary/gallivm/lp_bld_init.h