tu/blit: Don't set CLAMPENABLE in sampler for 3d path
authorConnor Abbott <cwabbott0@gmail.com>
Wed, 19 Jan 2022 10:24:13 +0000 (11:24 +0100)
committerMarge Bot <emma+marge@anholt.net>
Fri, 21 Jan 2022 20:55:46 +0000 (20:55 +0000)
commitab5176ec403afa27a7247189f773bed347e1fc4f
treee9f7781cbced4e76d4b049bbe3d85983dc0dbb8d
parentbb41d47f2e7273d460e4822eda0170f7d3bd6423
tu/blit: Don't set CLAMPENABLE in sampler for 3d path

This was copied from the blob before we understood what it did, and it
has questionable utility: there's nothing in the GL, Vulkan, or D3D11
specs that require the result be clamped to the underlying range to
account for imprecision. And it doesn't make sense at all for cubic
filtering, because the result can legitimately be outside the range in
some scenarios. Just remove it.

This fixes a bunch of tests added in vulkan CTS 1.2.8 to test blitting
from compressed textures, which use random inputs and therefore are more
likely to hit the out-of-range condition. For example,
dEQP-VK.api.copy_and_blit.core.blit_image.all_formats.color.2d.etc2_r8g8b8a8_unorm_block.r8g8b8a8_snorm.general_general_cubic.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14613>
src/freedreno/vulkan/tu_clear_blit.c