Skip to content

Commit 3f8d7ed

Browse files
committed
llvm-spirv: Support DWARF5 static member as DW_TAG_variable
1 parent 3a62e3e commit 3f8d7ed

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

llvm-spirv/lib/SPIRV/LLVMToSPIRVDbgTran.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,9 @@ SPIRVEntry *LLVMToSPIRVDbgTran::transDbgEntryImpl(const MDNode *MDN) {
359359
return transDbgLocalVariable(LV);
360360
if (const DIGlobalVariable *GV = dyn_cast<DIGlobalVariable>(DIEntry))
361361
return transDbgGlobalVariable(GV);
362+
if (const DIDerivedType *MT = dyn_cast<DIDerivedType>(DIEntry))
363+
if (MT->isStaticMember())
364+
return transDbgMemberType(MT);
362365
llvm_unreachable("Unxpected debug info type for variable");
363366
case dwarf::DW_TAG_formal_parameter:
364367
return transDbgLocalVariable(cast<DILocalVariable>(DIEntry));

0 commit comments

Comments
 (0)