Don't do updatePrecision on float16_t operations

float16_t does not take GLSL precisions and SPIR-V does not
support RelaxedPrecision on float16_t.

Fixes #2894
This commit is contained in:
Greg Fischer
2022-02-24 13:50:41 -07:00
parent ac7f6a293e
commit 79a35ace7c
4 changed files with 93 additions and 4 deletions

View File

@@ -0,0 +1,16 @@
#version 450
#extension GL_KHR_shader_subgroup_vote: enable
#extension GL_EXT_shader_subgroup_extended_types_float16 : enable
layout(set = 0, binding = 0, std430) buffer Buffer1
{
uint result[];
};
void main (void)
{
uint tempRes;
float16_t valueNoEqual = float16_t(gl_SubgroupInvocationID);
tempRes = subgroupAllEqual(valueNoEqual) ? 0x0 : 0x10;
result[gl_VertexIndex] = tempRes;
}