aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_vec4.cpp
Commit message (Collapse)AuthorAgeFilesLines
* i965/vs: Move the other two src_reg/dst_reg constructors to brw_vec4.cpp.Eric Anholt2012-07-061-0/+43
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* i965/vs: Move class functions to brw_vec4.cpp.Eric Anholt2012-07-061-0/+113
| | | | | | | This has less impact than for the FS (4k savings), because it was partially done already, but makes things more consistent. Reviewed-by: Kenneth Graunke <[email protected]>
* i965/vs: Add vec4_instruction::is_tex() query.Kenneth Graunke2011-12-181-0/+10
| | | | | | | Copy and pasted from fs_inst::is_tex(), but without TXB. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* i965/vs: Implement integer quotient and remainder math operations.Kenneth Graunke2011-10-021-0/+2
| | | | | | | Signed-off-by: Kenneth Graunke <[email protected]> Tested-by: Ian Romanick <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* i965/vs: Add support for compute-to-MRF.Eric Anholt2011-09-201-0/+177
| | | | | Removes 1.8% of the instructions from 97% of the vertex shaders in shader-db.
* i965/vs: Add a function for how many MRFs get written as part of a SEND.Eric Anholt2011-09-201-0/+37
| | | | | This will be used for compute-to-mrf, which needs to know when MRFs get overwritten.
* i965/vs: Add support for simple algebraic optimizations.Eric Anholt2011-09-201-0/+92
| | | | | | | | | | | | | | We generate silly code for array access, and it's easier to generally support the cleanup than to specifically avoid the bad code in each place we might generate it. Removes 4.6% of instructions from 41.6% of shaders in shader-db, particularly savage2/hon and unigine. v2: Fixes by Ken: Make is_zero/one member functions, and fix a progress flag. Reviewed-by: Kenneth Graunke <[email protected]>
* i965/vs: Add support for copy propagation of the UNIFORM and ATTR files.Eric Anholt2011-09-081-0/+13
| | | | Removes 2.0% of the instructions from 35.7% of vertex shaders in shader-db.
* i965/vs: Add constant propagation to a few opcodes.Eric Anholt2011-09-081-0/+16
| | | | | | | | | | | This differs from the FS in that we track constants in each destination channel, and we we have to look at all the swizzled source channels. Also, the instruction stream walk is done in an O(n) manner instead of O(n^2). Across shader-db, this reduces 8.0% of the instructions from 60.0% of the vertex shaders, leaving us now behind the old backend by 11.1% overall.
* i965/vs: Add support for overflowing the number of available push constants.Eric Anholt2011-09-081-0/+85
| | | | | | | | Fixes glsl-vs-uniform-array-4. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=33742 Reviewed-by: Ian Romanick <[email protected]> Acked-by: Kenneth Graunke <[email protected]>
* i965/vs: Pack live uniform vectors together in the push constant upload.Eric Anholt2011-08-301-0/+89
| | | | | | | | | | At some point we need to also move uniform accesses out to pull constants when there are just too many in use, but we lack tests for that at the moment. Fixes glsl-vs-large-uniform-array. Reviewed-by: Kenneth Graunke <[email protected]>
* i965/vs: Track uniforms as separate vectors once we've done array access.Eric Anholt2011-08-301-0/+30
| | | | | | | This will make it easier to figure out which elements are totally unused and not upload them. Reviewed-by: Kenneth Graunke <[email protected]>
* i965/vs: Add simple dead code elimination.Eric Anholt2011-08-191-0/+31
| | | | | This is copied right from the fragment shader. It is needed for real register allocation to work correctly.
* i965/vs: Copy the live intervals calculation over from the FS.Eric Anholt2011-08-191-0/+130
This is a rather pessimistic calculation, since it doesn't distinguish individual channels of a vec4, or elements of an array, but should be a minimum start for register allocation.