OSDN Git Service

vc4: Pair up QPU instructions when scheduling.
authorEric Anholt <eric@anholt.net>
Mon, 1 Dec 2014 19:48:20 +0000 (11:48 -0800)
committerEric Anholt <eric@anholt.net>
Tue, 2 Dec 2014 06:29:42 +0000 (22:29 -0800)
commit29c7cf2b2ba850cf467167548d53383e1338fd5c
treeff978d0d716844b991b5e235483efbc53f2c9e73
parent7b0067d23a6f64cf83c42e7f11b2cd4100c569fe
vc4: Pair up QPU instructions when scheduling.

We've got two mostly-independent operations in each QPU instruction, so
try to pack two operations together.  This is fairly naive (doesn't track
read and write separately in instructions, doesn't convert ADD-based MOVs
into MUL-based movs, doesn't reorder across uniform loads), but does show
a decent improvement on shader-db-2.

total instructions in shared programs: 59583 -> 57651 (-3.24%)
instructions in affected programs:     47361 -> 45429 (-4.08%)
src/gallium/drivers/vc4/vc4_qpu.c
src/gallium/drivers/vc4/vc4_qpu.h
src/gallium/drivers/vc4/vc4_qpu_schedule.c