Skip to content

The [unroll(count)] attribute has a different meaning than in D3DCompiler (HLSL) #1534

Description

@tex3d

In HLSL, the unroll count is the upper limit of number of loops, not the number of unrolled iterations per loop in output IR, as it means in LLVM. The HLSL definition means that using the [unroll(count)] can cut off loop iterations before the loop condition would have stopped iteration, and the loop is guaranteed to be completely unrolled. We don't respect this definition in DxCompiler.

Activity

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

Metadata

Metadata

Labels

bugBug, regression, crash

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions