diff --git a/imported/llvm-dialects b/imported/llvm-dialects index 8c54ca076f..16a0e93317 160000 --- a/imported/llvm-dialects +++ b/imported/llvm-dialects @@ -1 +1 @@ -Subproject commit 8c54ca076fbf841dc5d22da8b6a1d434a01b153c +Subproject commit 16a0e93317979f0b281458a5f3b830e0426983b1 diff --git a/llpc/translator/lib/SPIRV/SPIRVToLLVMDbgTran.cpp b/llpc/translator/lib/SPIRV/SPIRVToLLVMDbgTran.cpp index e6d4713528..39b1f7e8cd 100644 --- a/llpc/translator/lib/SPIRV/SPIRVToLLVMDbgTran.cpp +++ b/llpc/translator/lib/SPIRV/SPIRVToLLVMDbgTran.cpp @@ -371,7 +371,15 @@ DINode *SPIRVToLLVMDbgTran::transTypeMember(const SPIRVExtInst *DebugInst) { SPIRVValue *ConstVal = BM->get(Ops[ValueIdx]); assert(isConstantOpCode(ConstVal->getOpCode()) && "Static member must be a constant"); llvm::Value *Val = SPIRVReader->transValue(ConstVal, nullptr, nullptr); - return Builder.createStaticMemberType(Scope, Name, File, LineNo, BaseType, Flags, cast(Val)); + return Builder.createStaticMemberType( + Scope, Name, File, LineNo, BaseType, Flags, + cast(Val) +#if !defined(LLVM_MAIN_REVISION) || LLVM_MAIN_REVISION >= 480812 + // New version of the code (also handles unknown version, which we treat as latest) + , + llvm::dwarf::DW_TAG_member +#endif + ); } uint64_t Size = getConstant(Ops[SizeIdx]); uint64_t Alignment = 0;