KhronosGroup / KhronosGroup/glslang

No Float16 emitted with use of input 16-bit float

Open
#2,402 1 comment 0 reactions 0 assignees View on GitHub
bug SPIR-V
Dominant language
C++
Stars
3.6k
Forks
989
Avg merge
1d 2h
Merged PRs (30d)
31

Description

to sum up the issue, I think `Float16` is missing with use of `GL_EXT_shader_explicit_arithmetic_types_float16 `. The following example shows `Int16` is set, but not `Float16`

---

So I have 2 shaders

```glsl
#version 450
#extension GL_EXT_shader_explicit_arithmetic_types_float16 : enable
layout(location = 0) in f16vec2 inPosition;
```

and

```glsl
#version 450
#extension GL_EXT_shader_explicit_arithmetic_types_int16 : enable
layout(location = 0) in i16vec2 inPosition;
```

The first produces

```
Capability Shader
Capability StorageInputOutput16
Extension "SPV_KHR_16bit_storage"
```

While the second produces

```
Capability Shader
Capability Int16
Capability StorageInputOutput16
Extension "SPV_KHR_16bit_storage"
```

Contributor guide

Open the contributing guide

Research direction

Start with glslangvalidator and compile the two minimal GLSL examples from the issue, comparing their generated SPIR-V capabilities and extensions. Trace the compiler path handling GL_EXT_shader_explicit_arithmetic_types_float16 and verify completion when the float16 shader emits the expected Float16 capability alongside its existing output.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.