[HLSL] CodeGen HLSL Resource annotations
authorChris Bieneman <chris.bieneman@me.com>
Mon, 18 Jul 2022 15:08:08 +0000 (10:08 -0500)
committerChris Bieneman <chris.bieneman@me.com>
Mon, 1 Aug 2022 16:19:43 +0000 (11:19 -0500)
commit5dbb92d8cdf751d5960225e874c27d19597fa65e
tree4065df50dc0e066c56dbd0efc608e2dafdb2e001
parentf29a19b0b8d279616df795db52a3b6fafef6e1de
[HLSL] CodeGen HLSL Resource annotations

HLSL Resource types need special annotations that the backend will use
to build out metadata and resource annotations that are required by
DirectX and Vulkan drivers in order to provide correct data bindings
for shader exeuction.

This patch adds some of the required data for unordered-access-views
(UAV) resource binding into the module flags. This data will evolve
over time to cover all the required use cases, but this should get
things started.

Depends on D130018.

Differential Revision: https://reviews.llvm.org/D130019
clang/lib/CodeGen/CGDeclCXX.cpp
clang/lib/CodeGen/CGHLSLRuntime.cpp
clang/lib/CodeGen/CGHLSLRuntime.h
clang/test/CodeGenHLSL/builtins/RWBuffer-annotations.hlsl [new file with mode: 0644]