[all-commits] [llvm/llvm-project] a4e932: [HLSL] Implement RWBuffer::operator[] via __builti...
Justin Bogner via All-commits
all-commits at lists.llvm.org
Wed Nov 20 09:56:04 PST 2024
Branch: refs/heads/users/bogner/117017
Home: https://github.com/llvm/llvm-project
Commit: a4e932c29bddb78bd287cabca2e9ea0da6c96337
https://github.com/llvm/llvm-project/commit/a4e932c29bddb78bd287cabca2e9ea0da6c96337
Author: Justin Bogner <mail at justinbogner.com>
Date: 2024-11-20 (Wed, 20 Nov 2024)
Changed paths:
M clang/include/clang/Basic/Builtins.td
M clang/include/clang/Basic/DiagnosticSemaKinds.td
M clang/lib/AST/Type.cpp
M clang/lib/CodeGen/CGBuiltin.cpp
M clang/lib/Sema/HLSLExternalSemaSource.cpp
M clang/lib/Sema/SemaExpr.cpp
M clang/lib/Sema/SemaHLSL.cpp
M clang/test/AST/HLSL/RWBuffer-AST.hlsl
M clang/test/AST/HLSL/RWStructuredBuffer-AST.hlsl
M clang/test/AST/HLSL/RasterizerOrderedStructuredBuffer-AST.hlsl
M clang/test/AST/HLSL/StructuredBuffer-AST.hlsl
M clang/test/CodeGenHLSL/builtins/RWBuffer-constructor.hlsl
M clang/test/CodeGenHLSL/builtins/RWBuffer-elementtype.hlsl
M clang/test/CodeGenHLSL/builtins/RWBuffer-subscript.hlsl
M clang/test/CodeGenHLSL/builtins/RWStructuredBuffer-elementtype.hlsl
M clang/test/CodeGenHLSL/builtins/RasterizerOrderedStructuredBuffer-elementtype.hlsl
M clang/test/CodeGenHLSL/builtins/StructuredBuffer-elementtype.hlsl
M clang/test/CodeGenHLSL/builtins/StructuredBuffers-constructors.hlsl
M clang/test/CodeGenHLSL/builtins/StructuredBuffers-subscripts.hlsl
M clang/test/CodeGenHLSL/builtins/hlsl_resource_t.hlsl
M clang/test/CodeGenHLSL/implicit-norecurse-attrib.hlsl
Log Message:
-----------
[HLSL] Implement RWBuffer::operator[] via __builtin_hlsl_resource_getpointer
This introduces `__builtin_hlsl_resource_getpointer`, which lowers to
`llvm.dx.resource.getpointer` and is used to implement indexing into resources.
This will only work through the backend for typed buffers at this point, but
the changes to structured buffers should be correct as far as the frontend is
concerned.
Note: We probably want this to return a reference in the HLSL device address
space, but for now we're just using address space 0. Creating a device address
space and updating this code can be done later as necessary.
Fixes #95956
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list