mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-17 07:00:20 +01:00
intel/fs: Take into account amount of data read in spilling cost heuristic.
Until now the spilling cost calculation was neglecting the amount of data read from the register during the spilling cost calculation. This caused it to make suboptimal decisions in some cases leading to higher memory bandwidth usage than necessary. Improves Unigine Heaven performance by ~4% on BDW, reversing an unintended FPS regression from my previous commit147e71242cwith n=12 and statistical significance 5%. In addition SynMark2 OglCSDof performance is improved by an additional ~5% on SKL, and a Kerbal Space Program apitrace around the Moho planet I can provide on request improves by ~20%. Cc: <mesa-stable@lists.freedesktop.org> Reviewed-by: Plamena Manolova <plamena.manolova@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> (cherry picked from commit58324389be) [Andres Gomez: resolve trivial conflicts] Signed-off-by: Andres Gomez <agomez@igalia.com> Conflicts: src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp
This commit is contained in:
parent
a7c86ab750
commit
4c2356f13c
1 changed files with 1 additions and 1 deletions
|
|
@ -822,7 +822,7 @@ fs_visitor::choose_spill_reg(struct ra_graph *g)
|
|||
foreach_block_and_inst(block, fs_inst, inst, cfg) {
|
||||
for (unsigned int i = 0; i < inst->sources; i++) {
|
||||
if (inst->src[i].file == VGRF)
|
||||
spill_costs[inst->src[i].nr] += loop_scale;
|
||||
spill_costs[inst->src[i].nr] += regs_read(inst, i) * loop_scale;
|
||||
}
|
||||
|
||||
if (inst->dst.file == VGRF)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue