summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2020-06-19 17:01:26 +1000
committerDave Airlie <airlied@redhat.com>2020-07-27 13:48:11 +1000
commita0c584db0803ea83358bf40f347d372c3551fe08 (patch)
treeb2803c892b3566ab964d5444f41711230bc1f849
parenta81af51a37cda11a9947576a84c0e08715f694e7 (diff)
gallivm/nir: add some vulkan needed lowering passes
-rw-r--r--src/gallium/auxiliary/gallivm/lp_bld_nir.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_nir.c b/src/gallium/auxiliary/gallivm/lp_bld_nir.c
index ff351c3ee46..954b720cd34 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_nir.c
+++ b/src/gallium/auxiliary/gallivm/lp_bld_nir.c
@@ -2045,6 +2045,12 @@ bool lp_build_nir_llvm(
void lp_build_opt_nir(struct nir_shader *nir)
{
bool progress;
+
+ static const struct nir_lower_tex_options lower_tex_options = {
+ .lower_tg4_offsets = true,
+ };
+ NIR_PASS_V(nir, nir_lower_tex, &lower_tex_options);
+ NIR_PASS_V(nir, nir_lower_frexp);
do {
progress = false;
NIR_PASS_V(nir, nir_opt_constant_folding);