llvmpipe/ms: fix sign extension bug in rasterizer.
authorDave Airlie <airlied@redhat.com>
Tue, 21 Jul 2020 06:32:08 +0000 (16:32 +1000)
committerMarge Bot <eric+marge@anholt.net>
Thu, 23 Jul 2020 01:50:28 +0000 (01:50 +0000)
commitbe6c53bb9d3dd0c48bf956d566006e3372fbfdc4
treedf12fe754856e48d831eebca150e16d62ebb3016
parent4d73988f6fef39e9263ec0bb49cd5efff68393bc
llvmpipe/ms: fix sign extension bug in rasterizer.

/glcts --deqp-surface-width=1024 --deqp-surface-height=64  --deqp-case=KHR-GL45.texture_view.view_sampling  --deqp-surface-type=fbo
was failing but only for width 1024.

The test was filling a 4x4 ms texture, but leaving the viewport set to 1024x64.

This was resulting in this code incorrectly sign extending a value, and passing
it into the mask generator and getting the wrong values. Explicit cast
avoids the sign extension and fixes the above test.

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6006>
.gitlab-ci/deqp-virgl-gl-fails.txt
.gitlab-ci/piglit/quick_gl.txt
src/gallium/drivers/llvmpipe/lp_rast_tri_tmp.h