Otherwise the ctx.ac.postponed_kill will not be allocated.
Fixes: ce87da71e93 ("nir: add pass to lower discard() to demote()")
Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/2662
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4301>
switch (intrin->intrinsic) {
case nir_intrinsic_discard:
intrin->intrinsic = nir_intrinsic_demote;
+ shader->info.fs.uses_demote = true;
break;
case nir_intrinsic_discard_if:
intrin->intrinsic = nir_intrinsic_demote_if;
+ shader->info.fs.uses_demote = true;
break;
case nir_intrinsic_load_helper_invocation:
intrin->intrinsic = nir_intrinsic_is_helper_invocation;