Skip to content

nir/opt_algebraic: Improve lowering of idiv by pot.

Georg Lehmann requested to merge DadSchoorse/mesa:nir-pot-idiv into main

Use ishr after some code to ensure that it rounds towards zero.

Foz-DB Navi21:

Totals from 1954 (1.45% of 134913) affected shaders:
CodeSize: 10216088 -> 10157104 (-0.58%); split: -0.58%, +0.00%
Instrs: 1916028 -> 1910276 (-0.30%); split: -0.30%, +0.00%
Latency: 23682255 -> 23632905 (-0.21%); split: -0.21%, +0.00%
InvThroughput: 4476220 -> 4452651 (-0.53%); split: -0.53%, +0.00%
VClause: 38244 -> 38232 (-0.03%); split: -0.04%, +0.01%
SClause: 79304 -> 79309 (+0.01%); split: -0.03%, +0.04%
Copies: 140581 -> 140592 (+0.01%); split: -0.01%, +0.02%
PreVGPRs: 80197 -> 80194 (-0.00%)

Merge request reports