Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions tools/clang/lib/SPIRV/AstTypeProbe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1021,8 +1021,9 @@ bool isResourceDescriptorHeap(const Decl *D) {
}

bool isResourceDescriptorHeap(QualType T) {
const RecordType *RT = T->getAs<RecordType>();
return RT && RT->getDecl()->getName() == ".Resource";
const HLSLDynamicResourceAttr *Attr =
getAttr<HLSLDynamicResourceAttr>(T);
return Attr && !Attr->getIsSampler();
}

bool isSamplerDescriptorHeap(const Decl *D) {
Expand All @@ -1031,8 +1032,9 @@ bool isSamplerDescriptorHeap(const Decl *D) {
}

bool isSamplerDescriptorHeap(QualType T) {
const RecordType *RT = T->getAs<RecordType>();
return RT && RT->getDecl()->getName() == ".Sampler";
const HLSLDynamicResourceAttr *Attr =
getAttr<HLSLDynamicResourceAttr>(T);
return Attr && Attr->getIsSampler();
}

bool isAKindOfStructuredOrByteBuffer(QualType type) {
Expand Down
Loading