nir/conditional_if: Properly use the builder
authorJason Ekstrand <jason.ekstrand@intel.com>
Sat, 24 Dec 2016 18:39:19 +0000 (10:39 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Fri, 30 Dec 2016 20:38:04 +0000 (12:38 -0800)
commitcd6f736c0702da3e620d9c97a1a01d911d72381f
tree69ad629242f52e85a9e2a4b1e55b1457b7965b3d
parent47b54a6f747cf3025696a6c29b75940d78e05ecb
nir/conditional_if: Properly use the builder

We were passing around a void *mem_ctx and using that to initialize the
builder which was wrong since that pointed to ralloc_parent(impl) which
is the shader but the builder is supposed to be initialized with the
nir_function_impl.

Reviewed-by: Eduardo Lima Mitev <elima@igalia.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
src/compiler/nir/nir_opt_conditional_discard.c