[all-commits] [llvm/llvm-project] 6e56d0: Start support for HLSL `RWBuffer`
Chris B via All-commits
all-commits at lists.llvm.org
Thu Jul 28 06:57:52 PDT 2022
Author: Chris Bieneman <chris.bieneman at me.com>
Date: 2022-07-28 (Thu, 28 Jul 2022)
Start support for HLSL `RWBuffer`
Most of the change here is fleshing out the HLSLExternalSemaSource with
builder implementations to build the builtin types. Eventually, I may
move some of this code into tablegen or a more managable declarative
file but I want to get the AST generation logic ready first.
This code adds two new types into the HLSL AST, `hlsl::Resource` and
`hlsl::RWBuffer`. The `Resource` type is just a wrapper around a handle
identifier, and is largely unused in source. It will morph a bit over
time as I work on getting the source compatability correct, but for now
it is a reasonable stand-in. The `RWBuffer` type is not ready for use.
I'm posting this change for review because it adds a lot of
infrastructure code and is testable.
There is one change to clang code outside the HLSL-specific logic here,
which addresses a behavior change introduced a long time ago in
967d438439ac. That change resulted in unintentionally breaking
situations where an incomplete template declaration was provided from
an AST source, and needed to be completed later by the external AST.
That situation doesn't happen in the normal AST importer flow, but can
happen when an AST source provides incomplete declarations of
templates. The solution is to annotate template specializations of
incomplete types with the HasExternalLexicalSource bit from the base
Depends on D128012.
Differential Revision: https://reviews.llvm.org/D128569
More information about the All-commits