[all-commits] [llvm/llvm-project] ebe9c7: [HLSL] CodeGen hlsl cbuffer/tbuffer.
Xiang Li via All-commits
all-commits at lists.llvm.org
Wed Oct 12 21:17:55 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: ebe9c7f3e2da779b984b336dadf37cc4ec2ae260
https://github.com/llvm/llvm-project/commit/ebe9c7f3e2da779b984b336dadf37cc4ec2ae260
Author: Xiang Li <python3kgae at outlook.com>
Date: 2022-10-12 (Wed, 12 Oct 2022)
Changed paths:
M clang/lib/CodeGen/CGDecl.cpp
M clang/lib/CodeGen/CGHLSLRuntime.cpp
M clang/lib/CodeGen/CGHLSLRuntime.h
M clang/lib/CodeGen/CodeGenModule.cpp
A clang/test/CodeGenHLSL/cbuf.hlsl
A clang/test/CodeGenHLSL/cbuf_in_namespace.hlsl
A clang/test/CodeGenHLSL/static_global_and_function_in_cb.hlsl
Log Message:
-----------
[HLSL] CodeGen hlsl cbuffer/tbuffer.
cbuffer A {
float a;
float b;
}
will be translated to a global variable.
Something like
struct CB_Ty {
float a;
float b;
};
CB_Ty A;
And all use of a and b will be replaced with A.a and A.b.
Only support none-legacy cbuffer layout now.
CodeGen for Resource binding will be in separate patch.
In the separate patch, resource binding will map the resource information to the global variable.
Reviewed By: efriedma
Differential Revision: https://reviews.llvm.org/D130131
More information about the All-commits
mailing list