[Mesa-dev] [PATCH] i965/fs: Don't rewrite texture message destinations to avoid MOVs.
eric at anholt.net
Mon Feb 13 17:44:56 PST 2012
On Sun, 12 Feb 2012 23:29:14 -0800, Kenneth Graunke <kenneth at whitecape.org> wrote:
> Commit dc7f449d1ac53a66e6efb56ccf2a5953418a26ca introduced a new method
> for avoiding MOVs: try to rewrite the destination of the instruction
> that produced the RHS so it writes into the LHS.
> Unfortunately, this is not safe for texturing operations, as they
> return a set of four contiguous registers. Consider the following:
> SEND g7 ...
> MOV g15 g7
> ADD g8 1.0
> Upon seeing the MOV, we would rewrite the SEND to write to g15 (and
> implicitly g16, g17, and g18), causing the next instruction that
> references g8 to read garbage.
> The VS does not need texturing workarounds because sampler results fit
> in a single register in SIMD4x2 mode.
I'm not following something. I don't see how last_rhs_inst->is_tex(),
but this code somehow sees a MOV. Could you paste some annotated WM
I am slightly worried that this code could get confused by the MOV
sequence of texture swizzling -- that src.equals(last_rhs_inst->dst),
but the instruction in question isn't filling the entirety of that
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 197 bytes
Desc: not available
More information about the mesa-dev