Skip to content

Incorrect emitted code when doing bitfield operation #52

Description

@yxsamurai

hi, I found a glsl/spirv shader code issue when doing bitfield packing in Unity, the same code works well in dx11(hlsl/dxbc), but things went wrong after converted to glsl/spirv by hlslcc.
Shader code below is tested in Shader-Playground
hlsl
glsl
'u_xlatu0.x' should not be overwritten in the first 'bitfieldExtract' and used as input for the second 'bitfieldExtract'

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions