test_printf_t test_printf_func;
boolean success = TRUE;
- gallivm = gallivm_create();
+ gallivm = gallivm_create("test_module", LLVMGetGlobalContext());
test = add_printf_test(gallivm);
test_printf_func = (test_printf_t) gallivm_jit_function(gallivm, test);
- test_printf_func(0);
+ gallivm_free_ir(gallivm);
- gallivm_free_function(gallivm, test, test_printf_func);
+ test_printf_func(0);
gallivm_destroy(gallivm);