@@ -1172,15 +1172,16 @@ class DICompositeType : public DIType {
1172
1172
friend class MDNode ;
1173
1173
1174
1174
unsigned RuntimeLang;
1175
+ llvm::APInt SpareBitsMask;
1175
1176
1176
1177
DICompositeType (LLVMContext &C, StorageType Storage, unsigned Tag,
1177
1178
unsigned Line, unsigned RuntimeLang, uint64_t SizeInBits,
1178
1179
uint32_t AlignInBits, uint64_t OffsetInBits,
1179
- uint32_t NumExtraInhabitants, DIFlags Flags ,
1180
- ArrayRef<Metadata *> Ops)
1180
+ uint32_t NumExtraInhabitants, APInt SpareBitsMask ,
1181
+ DIFlags Flags, ArrayRef<Metadata *> Ops)
1181
1182
: DIType(C, DICompositeTypeKind, Storage, Tag, Line, SizeInBits,
1182
1183
AlignInBits, OffsetInBits, NumExtraInhabitants, Flags, Ops),
1183
- RuntimeLang (RuntimeLang) {}
1184
+ RuntimeLang (RuntimeLang), SpareBitsMask(SpareBitsMask) {}
1184
1185
~DICompositeType () = default ;
1185
1186
1186
1187
// / Change fields in place.
@@ -1198,20 +1199,20 @@ class DICompositeType : public DIType {
1198
1199
getImpl (LLVMContext &Context, unsigned Tag, StringRef Name, Metadata *File,
1199
1200
unsigned Line, DIScope *Scope, DIType *BaseType, uint64_t SizeInBits,
1200
1201
uint32_t AlignInBits, uint64_t OffsetInBits, DIType *SpecificationOf,
1201
- uint32_t NumExtraInhabitants, DIFlags Flags, DINodeArray Elements ,
1202
- unsigned RuntimeLang, DIType *VTableHolder,
1202
+ uint32_t NumExtraInhabitants, APInt SpareBitsMask, DIFlags Flags ,
1203
+ DINodeArray Elements, unsigned RuntimeLang, DIType *VTableHolder,
1203
1204
DITemplateParameterArray TemplateParams, StringRef Identifier,
1204
1205
DIDerivedType *Discriminator, Metadata *DataLocation,
1205
1206
Metadata *Associated, Metadata *Allocated, Metadata *Rank,
1206
1207
DINodeArray Annotations, StorageType Storage,
1207
1208
bool ShouldCreate = true ) {
1208
- return getImpl (Context, Tag, getCanonicalMDString (Context, Name), File,
1209
- Line, Scope, BaseType, SizeInBits, AlignInBits, OffsetInBits ,
1210
- Flags, Elements.get (), RuntimeLang, VTableHolder ,
1211
- TemplateParams.get (),
1212
- getCanonicalMDString (Context, Identifier), Discriminator,
1213
- DataLocation, Associated, Allocated, Rank, Annotations.get (),
1214
- SpecificationOf, NumExtraInhabitants , Storage, ShouldCreate);
1209
+ return getImpl (
1210
+ Context, Tag, getCanonicalMDString (Context, Name), File, Line, Scope ,
1211
+ BaseType, SizeInBits, AlignInBits, OffsetInBits, Flags, Elements.get (),
1212
+ RuntimeLang, VTableHolder, TemplateParams.get (),
1213
+ getCanonicalMDString (Context, Identifier), Discriminator, DataLocation ,
1214
+ Associated, Allocated, Rank, Annotations.get (), SpecificationOf ,
1215
+ NumExtraInhabitants, SpareBitsMask , Storage, ShouldCreate);
1215
1216
}
1216
1217
static DICompositeType *
1217
1218
getImpl (LLVMContext &Context, unsigned Tag, MDString *Name, Metadata *File,
@@ -1222,8 +1223,8 @@ class DICompositeType : public DIType {
1222
1223
MDString *Identifier, Metadata *Discriminator, Metadata *DataLocation,
1223
1224
Metadata *Associated, Metadata *Allocated, Metadata *Rank,
1224
1225
Metadata *Annotations, Metadata *SpecificationOf,
1225
- uint32_t NumExtraInhabitants, StorageType Storage ,
1226
- bool ShouldCreate = true );
1226
+ uint32_t NumExtraInhabitants, APInt SpareBitsMask ,
1227
+ StorageType Storage, bool ShouldCreate = true );
1227
1228
1228
1229
TempDICompositeType cloneImpl () const {
1229
1230
return getTemporary (
@@ -1233,7 +1234,7 @@ class DICompositeType : public DIType {
1233
1234
getTemplateParams (), getIdentifier (), getDiscriminator (),
1234
1235
getRawDataLocation (), getRawAssociated (), getRawAllocated (),
1235
1236
getRawRank (), getAnnotations (), getSpecificationOf (),
1236
- getNumExtraInhabitants ());
1237
+ getNumExtraInhabitants (), getSpareBitsMask () );
1237
1238
}
1238
1239
1239
1240
public:
@@ -1248,11 +1249,11 @@ class DICompositeType : public DIType {
1248
1249
Metadata *DataLocation = nullptr , Metadata *Associated = nullptr ,
1249
1250
Metadata *Allocated = nullptr , Metadata *Rank = nullptr ,
1250
1251
DINodeArray Annotations = nullptr , DIType *SpecificationOf = nullptr ,
1251
- uint32_t NumExtraInhabitants = 0 ),
1252
+ uint32_t NumExtraInhabitants = 0 , APInt SpareBitsMask = APInt() ),
1252
1253
(Tag, Name, File, Line, Scope, BaseType, SizeInBits, AlignInBits,
1253
- OffsetInBits, SpecificationOf, NumExtraInhabitants, Flags, Elements ,
1254
- RuntimeLang, VTableHolder, TemplateParams, Identifier, Discriminator ,
1255
- DataLocation, Associated, Allocated, Rank, Annotations))
1254
+ OffsetInBits, SpecificationOf, NumExtraInhabitants, SpareBitsMask, Flags ,
1255
+ Elements, RuntimeLang, VTableHolder, TemplateParams, Identifier,
1256
+ Discriminator, DataLocation, Associated, Allocated, Rank, Annotations))
1256
1257
DEFINE_MDNODE_GET(
1257
1258
DICompositeType,
1258
1259
(unsigned Tag, MDString *Name, Metadata *File, unsigned Line,
@@ -1263,11 +1264,12 @@ class DICompositeType : public DIType {
1263
1264
Metadata *Discriminator = nullptr , Metadata *DataLocation = nullptr ,
1264
1265
Metadata *Associated = nullptr , Metadata *Allocated = nullptr ,
1265
1266
Metadata *Rank = nullptr , Metadata *Annotations = nullptr ,
1266
- Metadata *SpecificationOf = nullptr , uint32_t NumExtraInhabitants = 0 ),
1267
+ Metadata *SpecificationOf = nullptr , uint32_t NumExtraInhabitants = 0 ,
1268
+ APInt SpareBitsMask = APInt()),
1267
1269
(Tag, Name, File, Line, Scope, BaseType, SizeInBits, AlignInBits,
1268
1270
OffsetInBits, Flags, Elements, RuntimeLang, VTableHolder, TemplateParams,
1269
1271
Identifier, Discriminator, DataLocation, Associated, Allocated, Rank,
1270
- Annotations, SpecificationOf, NumExtraInhabitants))
1272
+ Annotations, SpecificationOf, NumExtraInhabitants, SpareBitsMask ))
1271
1273
1272
1274
TempDICompositeType clone() const { return cloneImpl (); }
1273
1275
@@ -1283,7 +1285,7 @@ class DICompositeType : public DIType {
1283
1285
MDString *Name, Metadata *File, unsigned Line, Metadata *Scope,
1284
1286
Metadata *BaseType, uint64_t SizeInBits, uint32_t AlignInBits,
1285
1287
uint64_t OffsetInBits, Metadata *SpecificationOf,
1286
- uint32_t NumExtraInhabitants, DIFlags Flags,
1288
+ uint32_t NumExtraInhabitants, APInt SpareBitsMask, DIFlags Flags,
1287
1289
Metadata *Elements, unsigned RuntimeLang, Metadata *VTableHolder,
1288
1290
Metadata *TemplateParams, Metadata *Discriminator,
1289
1291
Metadata *DataLocation, Metadata *Associated, Metadata *Allocated,
@@ -1305,8 +1307,8 @@ class DICompositeType : public DIType {
1305
1307
MDString *Name, Metadata *File, unsigned Line, Metadata *Scope,
1306
1308
Metadata *BaseType, uint64_t SizeInBits, uint32_t AlignInBits,
1307
1309
uint64_t OffsetInBits, Metadata *SpecificationOf,
1308
- uint32_t NumExtraInhabitants, DIFlags Flags, Metadata *Elements ,
1309
- unsigned RuntimeLang, Metadata *VTableHolder,
1310
+ uint32_t NumExtraInhabitants, APInt SpareBitsMask, DIFlags Flags ,
1311
+ Metadata *Elements, unsigned RuntimeLang, Metadata *VTableHolder,
1310
1312
Metadata *TemplateParams, Metadata *Discriminator,
1311
1313
Metadata *DataLocation, Metadata *Associated,
1312
1314
Metadata *Allocated, Metadata *Rank, Metadata *Annotations);
@@ -1323,6 +1325,7 @@ class DICompositeType : public DIType {
1323
1325
}
1324
1326
StringRef getIdentifier () const { return getStringOperand (7 ); }
1325
1327
unsigned getRuntimeLang () const { return RuntimeLang; }
1328
+ const APInt &getSpareBitsMask () const { return SpareBitsMask; }
1326
1329
1327
1330
Metadata *getRawBaseType () const { return getOperand (3 ); }
1328
1331
Metadata *getRawElements () const { return getOperand (4 ); }
0 commit comments