diff options
author | Jason Ekstrand <[email protected]> | 2019-03-03 09:24:12 -0600 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2019-03-06 17:24:57 +0000 |
commit | 9314084237d50e109ab575fca8696da28cf76798 (patch) | |
tree | 4ffb0eba1ec842190acdcb03a38bc73a95c8ffe6 /src/mesa/drivers/dri/i965/brw_program.c | |
parent | ebb3695376499c276d4e1508836ce6b38faf1390 (diff) |
nir: Teach loop unrolling about 64-bit instruction lowering
The lowering we do for 64-bit instructions can cause a single NIR ALU
instruction to blow up into hundreds or thousands of instructions
potentially with control flow. If loop unrolling isn't aware of this,
it can unroll a loop 20 times which contains a nir_op_fsqrt which we
then lower to a full software implementation based on integer math.
Those 20 invocations suddenly get a lot more expensive than NIR loop
unrolling currently expects. By giving it an approximate estimate
function, we can prevent loop unrolling from going to town when it
shouldn't.
Reviewed-by: Matt Turner <[email protected]>
Reviewed-by: Jordan Justen <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_program.c')
0 files changed, 0 insertions, 0 deletions