[Mesa-dev] [PATCH v2] i965/vec4: pass the correct src_sz to emit_send at emit_untyped_atomic
Francisco Jerez
currojerez at riseup.net
Tue Mar 8 00:08:06 UTC 2016
Alejandro PiƱeiro <apinheiro at igalia.com> writes:
> If the src is invalid, so src size is zero, the src_sz passed to emit
> send should be zero too, instead of a default 1 if we are in a simd4x2
> case. This can happens if using emit_untyped_atomic for an atomic
> dec/inc.
>
> v2: use the proper src_sz when calling emit_send, instead of just
> avoid loading src at emit_send if BAD_FILE (Francisco Jerez)
Thanks!
Reviewed-by: Francisco Jerez <currojerez at riseup.net>
> ---
> src/mesa/drivers/dri/i965/brw_vec4_surface_builder.cpp | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/mesa/drivers/dri/i965/brw_vec4_surface_builder.cpp b/src/mesa/drivers/dri/i965/brw_vec4_surface_builder.cpp
> index 28002c5..1db349a 100644
> --- a/src/mesa/drivers/dri/i965/brw_vec4_surface_builder.cpp
> +++ b/src/mesa/drivers/dri/i965/brw_vec4_surface_builder.cpp
> @@ -221,7 +221,7 @@ namespace brw {
> emit_insert(bld, addr, dims, has_simd4x2),
> has_simd4x2 ? 1 : dims,
> emit_insert(bld, src_reg(srcs), size, has_simd4x2),
> - has_simd4x2 ? 1 : size,
> + has_simd4x2 && size ? 1 : size,
> surface, op, rsize, pred);
> }
>
> --
> 2.5.0
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 212 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160307/bfa1677e/attachment.sig>
More information about the mesa-dev
mailing list