diff --git a/.pick_status.json b/.pick_status.json index 9211c3e430e..9f5737aec87 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -4504,7 +4504,7 @@ "description": "elk: Call nir_opt_algebraic_late in elk_postprocess_nir", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "442daeb54a2e43bd450ebbb37fc05001f4acd08f", "notes": null diff --git a/src/intel/compiler/elk/elk_nir.c b/src/intel/compiler/elk/elk_nir.c index 7b4d8661205..6a8712a352c 100644 --- a/src/intel/compiler/elk/elk_nir.c +++ b/src/intel/compiler/elk/elk_nir.c @@ -1601,8 +1601,12 @@ elk_postprocess_nir(nir_shader *nir, const struct elk_compiler *compiler, }; OPT(nir_lower_subgroups, &subgroups_options); - if (OPT(nir_lower_int64)) + if (OPT(nir_lower_int64)) { elk_nir_optimize(nir, is_scalar, devinfo); + + /* elk_nir_optimize undoes late lowerings. */ + OPT(nir_opt_algebraic_late); + } } /* Do this only after the last opt_gcm. GCM will undo this lowering. */