mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 02:58:05 +02:00
i965: Add support for math on constants in gen6 brw_wm_glsl.c path.
Fixes 10 piglit cases that were assertion failing.
This commit is contained in:
parent
ad8cb131d8
commit
f289dcd849
1 changed files with 5 additions and 4 deletions
|
|
@ -896,11 +896,12 @@ void emit_math1(struct brw_wm_compile *c,
|
|||
BRW_MATH_SATURATE_NONE);
|
||||
struct brw_reg src;
|
||||
|
||||
if (intel->gen >= 6 && arg0[0].hstride == BRW_HORIZONTAL_STRIDE_0) {
|
||||
/* Gen6 math requires that source and dst horizontal stride be 1.
|
||||
*
|
||||
if (intel->gen >= 6 && (arg0[0].hstride == BRW_HORIZONTAL_STRIDE_0 ||
|
||||
arg0[0].file != BRW_GENERAL_REGISTER_FILE)) {
|
||||
/* Gen6 math requires that source and dst horizontal stride be 1,
|
||||
* and that the argument be in the GRF.
|
||||
*/
|
||||
src = *dst;
|
||||
src = dst[dst_chan];
|
||||
brw_MOV(p, src, arg0[0]);
|
||||
} else {
|
||||
src = arg0[0];
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue