Skip to content

[SPIR-V] Error in OPConstant half literal number #145073

Open
@spall

Description

@spall

Saw the following validation error when compiling this code:

vkCreateShaderModule(): pCreateInfo->pCode (spirv-val produced an error):
# | The high-order bits of a literal number in instruction <id> 26 must be 0 for a floating-point type, or 0 for an integer type with Signedness of 0, or sign extended when Signedness is 1
# |   %half_0x1_26cpn7 = OpConstant %half 0x1.26cp-7

For instruction <id> 26 I've also seen 23, and 17.

https://godbolt.org/z/1sjb35aqd

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions