diff options
author | Eric Anholt <[email protected]> | 2013-10-09 17:17:59 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2013-10-10 15:54:16 -0700 |
commit | 36fbe66d3a71df76fcb6f915846da4471b3a8442 (patch) | |
tree | 636b90e73c5b7f977811014791dcb1c90ab45eac /src/mesa/drivers/dri/r200/radeon_common.c | |
parent | ee21c8b1e6d3a506fa04d8f86e99b2afe9fca841 (diff) |
i965/fs: Convert gen7 to using GRFs for texture messages.
Looking at Lightsmark's shaders, the way we used MRFs (or in gen7's
case, GRFs) was bad in a couple of ways. One was that it prevented
compute-to-MRF for the common case of a texcoord that gets used
exactly once, but where the texcoord setup all gets emitted before the
texture calls (such as when it's a bare fragment shader input, which
gets interpolated before processing main()). Another was that it
introduced a bunch of dependencies that constrained scheduling, and
forced waits for texture operations to be done before they are
required. For example, we can now move the compute-to-MRF
interpolation for the second texture send down after the first send.
The downside is that this generally prevents
remove_duplicate_mrf_writes() from doing anything, whereas previously
it avoided work for the case of sampling from the same texcoord twice.
However, I suspect that most of the win that originally justified that
code was in avoiding the WAR stall on the first send, which this patch
also avoids, rather than the small cost of the extra instruction. We
see instruction count regressions in shaders in unigine, yofrankie,
savage2, hon, and gstreamer.
Improves GLB2.7 performance by 0.633628% +/- 0.491809% (n=121/125, avg of
~66fps, outliers below 61 dropped).
Improves openarena performance by 1.01092% +/- 0.66897% (n=425).
No significant difference on Lightsmark (n=44).
v2: Squash in the fix for register unspilling for send-from-GRF, fixing a
segfault in lightsmark.
Reviewed-by: Kenneth Graunke <[email protected]>
Acked-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/r200/radeon_common.c')
0 files changed, 0 insertions, 0 deletions