// No need to fill in the Name, Line, Size, Alignment, Offset in case of
// CVR derived types.
llvm::DIType DbgTy =
- DebugFactory.CreateDerivedType(Tag, Unit, "", llvm::DIFile(),
+ DebugFactory.CreateDerivedType(Tag, Unit, "", Unit,
0, 0, 0, 0, 0, FromTy);
return DbgTy;
}
uint64_t Align = CGM.getContext().getTypeAlign(Ty);
return
- DebugFactory.CreateDerivedType(Tag, Unit, "", llvm::DIFile(),
+ DebugFactory.CreateDerivedType(Tag, Unit, "", Unit,
0, Size, Align, 0, 0, EltTy);
}
if (BlockLiteralGenericSet)
return BlockLiteralGeneric;
- llvm::DIFile DefUnit;
unsigned Tag = llvm::dwarf::DW_TAG_structure_type;
llvm::SmallVector<llvm::DIDescriptor, 5> EltTys;
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "reserved", DefUnit,
+ "reserved", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "Size", DefUnit,
+ "Size", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
unsigned Flags = llvm::DIType::FlagAppleBlock;
EltTy = DebugFactory.CreateCompositeType(Tag, Unit, "__block_descriptor",
- DefUnit, 0, FieldOffset, 0, 0, Flags,
+ Unit, 0, FieldOffset, 0, 0, Flags,
llvm::DIType(), Elements);
// Bit size, align and offset of the type.
uint64_t Align = CGM.getContext().getTypeAlign(Ty);
DescTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_pointer_type,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, Size, Align, 0, 0, EltTy);
FieldOffset = 0;
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__isa", DefUnit,
+ "__isa", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__flags", DefUnit,
+ "__flags", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__reserved", DefUnit,
+ "__reserved", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__FuncPtr", DefUnit,
+ "__FuncPtr", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(Ty);
FieldAlign = CGM.getContext().getTypeAlign(Ty);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__descriptor", DefUnit,
+ "__descriptor", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
Elements = DebugFactory.GetOrCreateArray(EltTys.data(), EltTys.size());
EltTy = DebugFactory.CreateCompositeType(Tag, Unit, "__block_literal_generic",
- DefUnit, 0, FieldOffset, 0, 0, Flags,
+ Unit, 0, FieldOffset, 0, 0, Flags,
llvm::DIType(), Elements);
BlockLiteralGenericSet = true;
BlockLiteralGeneric
= DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_pointer_type, Unit,
- "", llvm::DIFile(),
+ "", Unit,
0, Size, Align, 0, 0, EltTy);
return BlockLiteralGeneric;
}
llvm::DIType DbgTy =
DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_subroutine_type,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, 0, 0, 0, 0,
llvm::DIType(), EltTypeArray);
return DbgTy;
return
DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_subroutine_type,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, 0, 0, 0, 0,
llvm::DIType(), EltTypeArray);
}
llvm::DIType DTy =
DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_inheritance,
RecordTy, llvm::StringRef(),
- llvm::DIFile(), 0, 0, 0,
+ Unit, 0, 0, 0,
BaseOffset, BFlags,
getOrCreateType(BI->getType(),
Unit));
DebugFactory.GetOrCreateArray(STys.data(), STys.size());
llvm::DIType SubTy =
DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_subroutine_type,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, 0, 0, 0, 0, llvm::DIType(), SElements);
unsigned Size = Context.getTypeSize(Context.VoidPtrTy);
llvm::DIType vtbl_ptr_type
= DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_pointer_type,
- Unit, "__vtbl_ptr_type", llvm::DIFile(),
+ Unit, "__vtbl_ptr_type", Unit,
0, Size, 0, 0, 0, SubTy);
- VTablePtrType = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_pointer_type,
- Unit, "", llvm::DIFile(),
- 0, Size, 0, 0, 0, vtbl_ptr_type);
+ VTablePtrType =
+ DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_pointer_type,
+ Unit, "", Unit,
+ 0, Size, 0, 0, 0, vtbl_ptr_type);
return VTablePtrType;
}
unsigned Size = CGM.getContext().getTypeSize(CGM.getContext().VoidPtrTy);
llvm::DIType VPTR
= DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- getVtableName(RD), llvm::DIFile(),
+ getVtableName(RD), Unit,
0, Size, 0, 0, 0,
getOrCreateVTablePtrType(Unit));
EltTys.push_back(VPTR);
getOrCreateType(CGM.getContext().getObjCInterfaceType(SClass), Unit);
llvm::DIType InhTag =
DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_inheritance,
- Unit, "", llvm::DIFile(), 0, 0, 0,
+ Unit, "", Unit, 0, 0, 0,
0 /* offset */, 0, SClassTy);
EltTys.push_back(InhTag);
}
return
DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_vector_type,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, Size, Align, 0, 0,
ElementTy, SubscriptArray);
}
llvm::DIType DbgTy =
DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_array_type,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, Size, Align, 0, 0,
getOrCreateType(EltTy, Unit),
SubscriptArray);
// FIXME: This should probably be a function type instead.
ElementTypes[0] =
DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, U,
- "ptr", llvm::DIFile(), 0,
+ "ptr", U, 0,
Info.first, Info.second, FieldOffset, 0,
PointerDiffDITy);
FieldOffset += Info.first;
ElementTypes[1] =
DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, U,
- "ptr", llvm::DIFile(), 0,
+ "ptr", U, 0,
Info.first, Info.second, FieldOffset, 0,
PointerDiffDITy);
return DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_structure_type,
U, llvm::StringRef("test"),
- llvm::DIFile(), 0, FieldOffset,
+ U, 0, FieldOffset,
0, 0, 0, llvm::DIType(), Elements);
}
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__isa", llvm::DIFile(),
+ "__isa", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__forwarding", llvm::DIFile(),
+ "__forwarding", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__flags", llvm::DIFile(),
+ "__flags", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__size", llvm::DIFile(),
+ "__size", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__copy_helper",
- llvm::DIFile(),
+ "__copy_helper", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- "__destroy_helper",
- llvm::DIFile(),
+ "__destroy_helper", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
FieldSize = CGM.getContext().getTypeSize(FType);
FieldAlign = CGM.getContext().getTypeAlign(FType);
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member,
- Unit, "", llvm::DIFile(),
+ Unit, "", Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
*XOffset = FieldOffset;
FieldTy = DebugFactory.CreateDerivedType(llvm::dwarf::DW_TAG_member, Unit,
- VD->getName(), llvm::DIFile(),
+ VD->getName(), Unit,
0, FieldSize, FieldAlign,
FieldOffset, 0, FieldTy);
EltTys.push_back(FieldTy);
unsigned Flags = llvm::DIType::FlagBlockByrefStruct;
return DebugFactory.CreateCompositeType(llvm::dwarf::DW_TAG_structure_type,
- Unit, "",
- llvm::DIFile(),
+ Unit, "", Unit,
0, FieldOffset, 0, 0, Flags,
llvm::DIType(), Elements);