From: Keith Whitwell Date: Thu, 7 Oct 2010 18:49:20 +0000 (+0100) Subject: llvmpipe: store zero into all alloca'd values X-Git-Url: https://git.libre-soc.org/?p=mesa.git;a=commitdiff_plain;h=6da29f36111edc821a4aa10128e9681fc75a43d7 llvmpipe: store zero into all alloca'd values Fixes slowdown in isosurf with earlier versions of llvm. --- diff --git a/src/gallium/auxiliary/gallivm/lp_bld_flow.c b/src/gallium/auxiliary/gallivm/lp_bld_flow.c index 5bc9c741a88..cd5fbc24638 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_flow.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_flow.c @@ -830,6 +830,7 @@ lp_build_alloca(LLVMBuilderRef builder, } res = LLVMBuildAlloca(first_builder, type, name); + LLVMBuildStore(builder, LLVMConstNull(type), res); LLVMDisposeBuilder(first_builder);