- In one optimization pass, register files may have been messed therefore
merging instructions which use the same index in two different register files
- The fix consists in only processing temporary registers as it must be
---
src/mesa/program/prog_optimize.c |6 +-
1 files changed, 5
- Thanks to Eric Anholt for his comments and his patch. The code is now much
simpler (and (more) correct). Also thanks to Jakob Bornecrantz for his
explanation of the difference between glsl and mesa IR
- Improved optimization of GPU programs. Now, swizzling is taken into account
and swizzle
- Added two more tests to stress the new optimizations in prog_optimize.c in the
mesa code base
---
tests/all.tests |2 +
tests/shaders/glsl-vs-masked-cos.shader_test | 33 ++
tests/shaders/glsl-vs-masked-dot.shader_test | 32 +
- Several routines directly analyze the grf-to-mrf moves from the Gen binary
code. When it is possible, the mov is removed and the message register is
directly written in the arithmetic instruction
- Also redundant mrf-to-grf moves are removed (frequently for example, when
sampling many text
- Improved optimization of GPU programs. Now, swizzling is taken into account
and swizzles are properly transformed while removing mov instructions.
Removals of mov instructions are now much more effective
- Analysis of control flows is still very primitive and far more too
conservative. Sha