mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-14 15:46:28 +00:00
Rename StorageClass to AddressSpace.
This CL updates the internals to use AddressSpace instead of the old StorageClass name. Bug: tint:1404 Change-Id: Iecc208e839453437f4d630f65e0152206a52db7e Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/104420 Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: Dan Sinclair <dsinclair@chromium.org> Auto-Submit: Dan Sinclair <dsinclair@chromium.org>
This commit is contained in:
committed by
Dawn LUCI CQ
parent
d5b64ecd78
commit
ff7cf21021
@@ -565,7 +565,7 @@ uint32_t Inspector::GetWorkgroupStorageSize(const std::string& entry_point) {
|
||||
uint32_t total_size = 0;
|
||||
auto* func_sem = program_->Sem().Get(func);
|
||||
for (const sem::Variable* var : func_sem->TransitivelyReferencedGlobals()) {
|
||||
if (var->StorageClass() == ast::StorageClass::kWorkgroup) {
|
||||
if (var->AddressSpace() == ast::AddressSpace::kWorkgroup) {
|
||||
auto* ty = var->Type()->UnwrapRef();
|
||||
uint32_t align = ty->Align();
|
||||
uint32_t size = ty->Size();
|
||||
|
||||
@@ -126,11 +126,11 @@ void InspectorBuilder::AddUniformBuffer(const std::string& name,
|
||||
const ast::Type* type,
|
||||
uint32_t group,
|
||||
uint32_t binding) {
|
||||
GlobalVar(name, type, ast::StorageClass::kUniform, Binding(AInt(binding)), Group(AInt(group)));
|
||||
GlobalVar(name, type, ast::AddressSpace::kUniform, Binding(AInt(binding)), Group(AInt(group)));
|
||||
}
|
||||
|
||||
void InspectorBuilder::AddWorkgroupStorage(const std::string& name, const ast::Type* type) {
|
||||
GlobalVar(name, type, ast::StorageClass::kWorkgroup);
|
||||
GlobalVar(name, type, ast::AddressSpace::kWorkgroup);
|
||||
}
|
||||
|
||||
void InspectorBuilder::AddStorageBuffer(const std::string& name,
|
||||
@@ -138,7 +138,7 @@ void InspectorBuilder::AddStorageBuffer(const std::string& name,
|
||||
ast::Access access,
|
||||
uint32_t group,
|
||||
uint32_t binding) {
|
||||
GlobalVar(name, type, ast::StorageClass::kStorage, access, Binding(AInt(binding)),
|
||||
GlobalVar(name, type, ast::AddressSpace::kStorage, access, Binding(AInt(binding)),
|
||||
Group(AInt(group)));
|
||||
}
|
||||
|
||||
@@ -188,7 +188,7 @@ void InspectorBuilder::AddResource(const std::string& name,
|
||||
}
|
||||
|
||||
void InspectorBuilder::AddGlobalVariable(const std::string& name, const ast::Type* type) {
|
||||
GlobalVar(name, type, ast::StorageClass::kPrivate);
|
||||
GlobalVar(name, type, ast::AddressSpace::kPrivate);
|
||||
}
|
||||
|
||||
const ast::Function* InspectorBuilder::MakeSamplerReferenceBodyFunction(
|
||||
|
||||
Reference in New Issue
Block a user