diff --git a/src/intel/compiler/brw_opt.cpp b/src/intel/compiler/brw_opt.cpp index dca507cdc89..5dd4d833cd2 100644 --- a/src/intel/compiler/brw_opt.cpp +++ b/src/intel/compiler/brw_opt.cpp @@ -19,13 +19,6 @@ brw_optimize(brw_shader &s) /* Start by validating the shader we currently have. */ brw_validate(s); - /* Track how much non-SSA at this point. */ - { - const brw_def_analysis &defs = s.def_analysis.require(); - s.shader_stats.non_ssa_registers_after_nir = - defs.count() - defs.ssa_count(); - } - bool progress = false; int iteration = 0; int pass_num = 0; @@ -60,6 +53,13 @@ brw_optimize(brw_shader &s) OPT(brw_opt_eliminate_find_live_channel); + /* Track how much non-SSA at this point. */ + { + const brw_def_analysis &defs = s.def_analysis.require(); + s.shader_stats.non_ssa_registers_after_nir = + defs.count() - defs.ssa_count(); + } + do { progress = false; pass_num = 0;