i965/fs: Enumerate logical fb writes arguments
authorBen Widawsky <benjamin.widawsky@intel.com>
Tue, 20 Oct 2015 21:29:37 +0000 (14:29 -0700)
committerBen Widawsky <benjamin.widawsky@intel.com>
Thu, 22 Oct 2015 04:14:44 +0000 (21:14 -0700)
commit5fa7114652068735347c8715d1fc1d2cef72c433
treeca35015ec10d0295d049ef00c8ccda5c2d4c803d
parent18a631eb9056857a9ced477e7e3d1a435a906be2
i965/fs: Enumerate logical fb writes arguments

Gen9 adds the ability to write out a stencil value, so we need to expand the
virtual payload by one. Abstracting this now makes that change easier to read.

I was admittedly confused early on about some of the hardcoding. If people
believe the resulting code is inferior, I am not super attached to the patch.

v2:
Remove explicit numbering from the enumeration (Matt).
Use a real naming scheme, and reference it in the opcode definition (Curro)
Add a missed hardcoded logical position in get_lowered_simd_width (Ben)
Add an assertion to make sure the component numbering is correct (Ben)

Cc: Matt Turner <mattst88@gmail.com>
Cc: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_defines.h
src/mesa/drivers/dri/i965/brw_fs.cpp
src/mesa/drivers/dri/i965/brw_fs_visitor.cpp