From: Roland Scheidegger Date: Wed, 2 Sep 2020 02:04:50 +0000 (+0200) Subject: gallivm: add InstSimplify pass X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1d018bc7fde744b5fc71108887a51e5bfaff8776;p=mesa.git gallivm: add InstSimplify pass This is the recommended replacement for the removed ConstantPropagation pass, and llvm now added c binding for it. Part-of: --- diff --git a/src/gallium/auxiliary/gallivm/lp_bld_init.c b/src/gallium/auxiliary/gallivm/lp_bld_init.c index 1eb4892a4a6..fe3ef4a48df 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_init.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_init.c @@ -171,6 +171,8 @@ create_pass_manager(struct gallivm_state *gallivm) LLVMAddPromoteMemoryToRegisterPass(gallivm->passmgr); #if LLVM_VERSION_MAJOR <= 11 LLVMAddConstantPropagationPass(gallivm->passmgr); +#else + LLVMAddInstructionSimplifyPass(gallivm->passmgr); #endif LLVMAddInstructionCombiningPass(gallivm->passmgr); LLVMAddGVNPass(gallivm->passmgr);