Float controls: compute: fix for strict 16bit storage validation
authorDavid Neto <dneto@google.com>
Thu, 11 Jul 2019 19:12:37 +0000 (15:12 -0400)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Wed, 14 Aug 2019 11:36:49 +0000 (07:36 -0400)
commit941bda5649c10e108013d434cd0594fbd738c5f8
tree9f2d7eeae7dd807c39d603ff596b97eadb975523
parent61eb59ae0d06c80cf82f6a7fc3b5962a8d75d3c9
Float controls: compute: fix for strict 16bit storage validation

Emit definitions of float constants only if those constants
are used in the rest of the shader.  In the case of 16bit
float this saves us from having to also declare a Float16 capability.

Non-storage-related use of fp16 requires Float16 capability,
and shaderFloat16 Vulkan feature from VK_KHR_shader_float16_int8.
Such uses include declaring constants, using fp16 arithmetic, etc.

Components: Vulkan

Affects:
dEQP-VK.spirv_assembly.instruction.compute.float_controls.*

VK-GL-CTS issue: 1874

Change-Id: Ia403aac8ae32646329f67bf48d6231af233e9c20
external/vulkancts/modules/vulkan/spirv_assembly/vktSpvAsmFloatControlsTests.cpp