This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGe3fd0b20731f: [HLSL] Add resource binding attribute for
HLSL. (authored by python3kgae).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST A
python3kgae updated this revision to Diff 461990.
python3kgae added a comment.
Add Issue link for FIXME.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
clang/include/clang/Basic/Attr.td
clang/
python3kgae updated this revision to Diff 461987.
python3kgae added a comment.
Rebase
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
clang/include/clang/Basic/Attr.td
clang/include/clang/Basic
aaron.ballman accepted this revision.
aaron.ballman added a comment.
LGTM!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
___
cfe-commits mailing list
cfe-comm
python3kgae added inline comments.
Comment at: clang/test/SemaHLSL/resource_binding_attr_error.hlsl:15
+// expected-error@+1 {{invalid space specifier 's2' used; expected 'space'
followed by an integer, like space1}}
+cbuffer a : register(b0, s2) {
+
beanz wrote
python3kgae updated this revision to Diff 452739.
python3kgae added a comment.
Fix format in AttrDocs.td and avoid name conflict in test.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
clang/inc
beanz added inline comments.
Comment at: clang/test/SemaHLSL/resource_binding_attr_error.hlsl:15
+// expected-error@+1 {{invalid space specifier 's2' used; expected 'space'
followed by an integer, like space1}}
+cbuffer a : register(b0, s2) {
+
aaron.ballman wro
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM, only nits left that can be fixed when landing (no need for additional
review).
Comment at: clang/include/clang/Basic/AttrDocs.td:6557-6560
+.. code-block
python3kgae added inline comments.
Comment at: clang/lib/Sema/SemaDecl.cpp:2893-2894
+ else if (const auto *RB = dyn_cast(Attr))
+NewAttr =
+S.mergeHLSLResourceBindingAttr(D, *RB, RB->getSlot(), RB->getSpace());
else if (Attr->shouldInheritEvenIfAlreadyPresent() |
python3kgae updated this revision to Diff 452325.
python3kgae marked 2 inline comments as done.
python3kgae added a comment.
Remove mergeHLSLResourceBindingAttr since should not be able to set
ResourceBinding more than once.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
htt
aaron.ballman added inline comments.
Comment at: clang/include/clang/Basic/AttrDocs.td:6557-6558
+Here're resource binding examples with and without space:
+``RWBuffer Uav : register(u3, space1)``
+``Buffer Buf : register(t1)``
+The full documentation is available here:
https://
python3kgae marked an inline comment as done.
python3kgae added inline comments.
Comment at: clang/lib/Parse/ParseHLSL.cpp:112-113
+}
+if (!Tok.is(tok::identifier)) {
+ Diag(Tok.getLocation(), diag::err_expected) << tok::identifier;
+ SkipUntil(tok::r_paren, Sto
python3kgae updated this revision to Diff 452232.
python3kgae marked an inline comment as done.
python3kgae added a comment.
Limit to lower case.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
c
aaron.ballman added inline comments.
Comment at: clang/include/clang/Basic/AttrDocs.td:6557-6558
+Here're resource binding examples with and without space:
+``register(t3, space1)``
+``register(t1)``
+The full documentation is available here:
https://docs.microsoft.com/en-us/win
python3kgae updated this revision to Diff 452037.
python3kgae added a comment.
Add fixit for case like space 1.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
clang/include/clang/Basic/Attr.td
python3kgae added inline comments.
Comment at: clang/include/clang/Basic/Attr.td:4022
+ let LangOpts = [HLSL];
+ let Args = [StringArgument<"Slot", 1>, StringArgument<"Space", 1>];
+ let Documentation = [HLSLResourceBindingDocs];
aaron.ballman wrote:
> Do you
python3kgae updated this revision to Diff 451917.
python3kgae marked 14 inline comments as done.
python3kgae added a comment.
Remove optional flag for Slot.
Update error messages and doc.
Add test for empty resource attribute and space only resource attribute.
Repository:
rG LLVM Github Monore
aaron.ballman added inline comments.
Comment at: clang/include/clang/Basic/Attr.td:150
+[{isa(S)}],
+"global functions">;
This string literal looks suspiciously wrong to me. This is the text that shows
up in a diagnostic
python3kgae updated this revision to Diff 451282.
python3kgae added a comment.
Treat resource binding as "HLSLSemantic".
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
clang/include/clang/Basic/
python3kgae updated this revision to Diff 451262.
python3kgae added a comment.
Move resource binding attribute validation to Sema.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130033/new/
https://reviews.llvm.org/D130033
Files:
clang/include/cl
beanz added a comment.
I have some nitpick comments about the wording of the errors and docs, but the
bigger meta issue is that you've implemented this parsing entirely from
scratch, and I suspect this should be sharing parsing logic with the generic
semantic parser.
I know the parameters them
python3kgae created this revision.
python3kgae added reviewers: svenvh, asavonic, beanz, pow2clk, Anastasia,
aaron.ballman.
Herald added a project: All.
python3kgae requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
The resource binding attri
22 matches
Mail list logo