OSDN Git Service

i965: Fix message and response length calculations for INT DIV.
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 29 Sep 2011 00:37:52 +0000 (17:37 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Mon, 3 Oct 2011 00:01:04 +0000 (17:01 -0700)
commit6b10aab2bbe0e69e2e8efca5e754870c8a543064
tree0de89b53f1615e6918b3a226e5d00dd03c0d1896
parentee2bf3a4b6b37287e6d150d3dd6742b7fa4f8215
i965: Fix message and response length calculations for INT DIV.

Both POW and INT DIV need a message length of 2; previously, we only
checked for POW.

Also, BRW_MATH_FUNCTION_INT_DIV_QUOTIENT_AND_REMAINDER has a response
length of 2; previously, we only checked for SINCOS.  We don't use this
message, but in case we ever decide to, we may as well fix it now.

While we're at it, just move these computations into
brw_set_math_message, since they're entirely based on the function.
This fixes it for both brw_math and the old backend's brw_math_16.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Tested-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
src/mesa/drivers/dri/i965/brw_eu_emit.c