[clang] [llvm] [HLSL] Implement Texture2DArray for HLSL (PR #203951)
Helena Kotas via cfe-commits
cfe-commits at lists.llvm.org
Fri Jun 19 11:24:15 PDT 2026
hekota wrote:
> Perhaps it would be a lot more manageable if we remove the name of the texture type from the tests and exercise all the different texture types under the same file. For example, `clang/test/SemaHLSL/Resources/Texture2DArray-SampleBias.hlsl` and `clang/test/SemaHLSL/Resources/Texture2D-SampleBias.hlsl` can be consolidated into a single `clang/test/SemaHLSL/Resources/Texture-SampleBias.hlsl` test file.
>
> Furthermore, since Texture2DArray shares much of the same functionality as Texture2D, a random sampling of existing tests on Texture2D methods can be replaced with Texture2DArray. Or just pick a random subset of the methods they have in common and append tests for those methods to the consolidated test files.
Agreed, we should merge similar tests into one file. But maybe instead of picking a random subset of methods we could run the test pretty much for each class using runtime parameters, the same way we do in https://github.com/llvm/llvm-project/blob/main/clang/test/AST/HLSL/StructuredBuffers-AST.hlsl.
I'm ok with merging the tests this PR as they are now and following-up with a test-consolidating change.
https://github.com/llvm/llvm-project/pull/203951
More information about the cfe-commits
mailing list