[llvm] [SPIR-V] Add the Flat Decorator for Double and Int Storage Element Types (PR #194302)

Steven Perron via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 29 06:53:38 PDT 2026


https://github.com/s-perron requested changes to this pull request.

I'm not sure I like this change without further discussion of the design. This needs to interact with multiple features:

1. Variable marked with `nointerpolation` in HLSL need to be decoarated with flat.
2. Not all integers/double arrays get the flat decorations. We need to consider some might be the PerVertex values. (I forget the HLSL term for it off the top of my head).

We need to design how all of these will work together. Are there HLSL rules on which variables should be flat or interpolated? We could implement this in clang where HLSL add the decoration to the input and output variables that require it based on HLSL rules.

https://github.com/llvm/llvm-project/pull/194302


More information about the llvm-commits mailing list