@@ -700,7 +700,6 @@ class DIType : public DIScope {
700
700
DIFlags Flags;
701
701
uint64_t SizeInBits;
702
702
uint64_t OffsetInBits;
703
- uint32_t AlignInBits;
704
703
705
704
protected:
706
705
DIType (LLVMContext &C, unsigned ID, StorageType Storage, unsigned Tag,
@@ -716,7 +715,7 @@ class DIType : public DIScope {
716
715
this ->Line = Line;
717
716
this ->Flags = Flags;
718
717
this ->SizeInBits = SizeInBits;
719
- this ->AlignInBits = AlignInBits;
718
+ this ->SubclassData32 = AlignInBits;
720
719
this ->OffsetInBits = OffsetInBits;
721
720
}
722
721
@@ -735,7 +734,7 @@ class DIType : public DIScope {
735
734
736
735
unsigned getLine () const { return Line; }
737
736
uint64_t getSizeInBits () const { return SizeInBits; }
738
- uint32_t getAlignInBits () const { return AlignInBits ; }
737
+ uint32_t getAlignInBits () const { return SubclassData32 ; }
739
738
uint32_t getAlignInBytes () const { return getAlignInBits () / CHAR_BIT; }
740
739
uint64_t getOffsetInBits () const { return OffsetInBits; }
741
740
DIFlags getFlags () const { return Flags; }
@@ -1389,13 +1388,13 @@ class DICompileUnit : public DIScope {
1389
1388
1390
1389
private:
1391
1390
unsigned SourceLanguage;
1392
- bool IsOptimized;
1393
1391
unsigned RuntimeVersion;
1394
- unsigned EmissionKind;
1395
1392
uint64_t DWOId;
1393
+ unsigned EmissionKind;
1394
+ unsigned NameTableKind;
1395
+ bool IsOptimized;
1396
1396
bool SplitDebugInlining;
1397
1397
bool DebugInfoForProfiling;
1398
- unsigned NameTableKind;
1399
1398
bool RangesBaseAddress;
1400
1399
1401
1400
DICompileUnit (LLVMContext &C, StorageType Storage, unsigned SourceLanguage,
@@ -2165,13 +2164,13 @@ class DILexicalBlock : public DILexicalBlockBase {
2165
2164
friend class LLVMContextImpl ;
2166
2165
friend class MDNode ;
2167
2166
2168
- unsigned Line;
2169
2167
uint16_t Column;
2170
2168
2171
2169
DILexicalBlock (LLVMContext &C, StorageType Storage, unsigned Line,
2172
2170
unsigned Column, ArrayRef<Metadata *> Ops)
2173
- : DILexicalBlockBase(C, DILexicalBlockKind, Storage, Ops), Line(Line),
2171
+ : DILexicalBlockBase(C, DILexicalBlockKind, Storage, Ops),
2174
2172
Column (Column) {
2173
+ SubclassData32 = Line;
2175
2174
assert (Column < (1u << 16 ) && " Expected 16-bit column" );
2176
2175
}
2177
2176
~DILexicalBlock () = default ;
@@ -2206,7 +2205,7 @@ class DILexicalBlock : public DILexicalBlockBase {
2206
2205
2207
2206
TempDILexicalBlock clone() const { return cloneImpl (); }
2208
2207
2209
- unsigned getLine () const { return Line ; }
2208
+ unsigned getLine () const { return SubclassData32 ; }
2210
2209
unsigned getColumn () const { return Column; }
2211
2210
2212
2211
static bool classof (const Metadata *MD) {
@@ -2218,12 +2217,11 @@ class DILexicalBlockFile : public DILexicalBlockBase {
2218
2217
friend class LLVMContextImpl ;
2219
2218
friend class MDNode ;
2220
2219
2221
- unsigned Discriminator;
2222
-
2223
2220
DILexicalBlockFile (LLVMContext &C, StorageType Storage,
2224
2221
unsigned Discriminator, ArrayRef<Metadata *> Ops)
2225
- : DILexicalBlockBase(C, DILexicalBlockFileKind, Storage, Ops),
2226
- Discriminator (Discriminator) {}
2222
+ : DILexicalBlockBase(C, DILexicalBlockFileKind, Storage, Ops) {
2223
+ SubclassData32 = Discriminator;
2224
+ }
2227
2225
~DILexicalBlockFile () = default ;
2228
2226
2229
2227
static DILexicalBlockFile *getImpl (LLVMContext &Context, DILocalScope *Scope,
@@ -2255,7 +2253,7 @@ class DILexicalBlockFile : public DILexicalBlockBase {
2255
2253
(Scope, File, Discriminator))
2256
2254
2257
2255
TempDILexicalBlockFile clone () const { return cloneImpl (); }
2258
- unsigned getDiscriminator () const { return Discriminator ; }
2256
+ unsigned getDiscriminator () const { return SubclassData32 ; }
2259
2257
2260
2258
static bool classof (const Metadata *MD) {
2261
2259
return MD->getMetadataID () == DILexicalBlockFileKind;
@@ -2342,8 +2340,6 @@ class DINamespace : public DIScope {
2342
2340
friend class LLVMContextImpl ;
2343
2341
friend class MDNode ;
2344
2342
2345
- unsigned ExportSymbols : 1 ;
2346
-
2347
2343
DINamespace (LLVMContext &Context, StorageType Storage, bool ExportSymbols,
2348
2344
ArrayRef<Metadata *> Ops);
2349
2345
~DINamespace () = default ;
@@ -2373,7 +2369,7 @@ class DINamespace : public DIScope {
2373
2369
2374
2370
TempDINamespace clone () const { return cloneImpl (); }
2375
2371
2376
- bool getExportSymbols () const { return ExportSymbols ; }
2372
+ bool getExportSymbols () const { return SubclassData1 ; }
2377
2373
DIScope *getScope () const { return cast_or_null<DIScope>(getRawScope ()); }
2378
2374
StringRef getName () const { return getStringOperand (2 ); }
2379
2375
@@ -2390,8 +2386,6 @@ class DINamespace : public DIScope {
2390
2386
class DIModule : public DIScope {
2391
2387
friend class LLVMContextImpl ;
2392
2388
friend class MDNode ;
2393
- unsigned LineNo;
2394
- bool IsDecl;
2395
2389
2396
2390
DIModule (LLVMContext &Context, StorageType Storage, unsigned LineNo,
2397
2391
bool IsDecl, ArrayRef<Metadata *> Ops);
@@ -2443,8 +2437,8 @@ class DIModule : public DIScope {
2443
2437
StringRef getConfigurationMacros () const { return getStringOperand (3 ); }
2444
2438
StringRef getIncludePath () const { return getStringOperand (4 ); }
2445
2439
StringRef getAPINotesFile () const { return getStringOperand (5 ); }
2446
- unsigned getLineNo () const { return LineNo ; }
2447
- bool getIsDecl () const { return IsDecl ; }
2440
+ unsigned getLineNo () const { return SubclassData32 ; }
2441
+ bool getIsDecl () const { return SubclassData1 ; }
2448
2442
2449
2443
Metadata *getRawScope () const { return getOperand (1 ); }
2450
2444
MDString *getRawName () const { return getOperandAs<MDString>(2 ); }
@@ -2462,11 +2456,11 @@ class DIModule : public DIScope {
2462
2456
// / Base class for template parameters.
2463
2457
class DITemplateParameter : public DINode {
2464
2458
protected:
2465
- bool IsDefault;
2466
-
2467
2459
DITemplateParameter (LLVMContext &Context, unsigned ID, StorageType Storage,
2468
2460
unsigned Tag, bool IsDefault, ArrayRef<Metadata *> Ops)
2469
- : DINode(Context, ID, Storage, Tag, Ops), IsDefault(IsDefault) {}
2461
+ : DINode(Context, ID, Storage, Tag, Ops) {
2462
+ SubclassData1 = IsDefault;
2463
+ }
2470
2464
~DITemplateParameter () = default ;
2471
2465
2472
2466
public:
@@ -2475,7 +2469,7 @@ class DITemplateParameter : public DINode {
2475
2469
2476
2470
MDString *getRawName () const { return getOperandAs<MDString>(0 ); }
2477
2471
Metadata *getRawType () const { return getOperand (1 ); }
2478
- bool isDefault () const { return IsDefault ; }
2472
+ bool isDefault () const { return SubclassData1 ; }
2479
2473
2480
2474
static bool classof (const Metadata *MD) {
2481
2475
return MD->getMetadataID () == DITemplateTypeParameterKind ||
@@ -2574,7 +2568,6 @@ class DITemplateValueParameter : public DITemplateParameter {
2574
2568
// / Base class for variables.
2575
2569
class DIVariable : public DINode {
2576
2570
unsigned Line;
2577
- uint32_t AlignInBits;
2578
2571
2579
2572
protected:
2580
2573
DIVariable (LLVMContext &C, unsigned ID, StorageType Storage, signed Line,
@@ -2587,7 +2580,7 @@ class DIVariable : public DINode {
2587
2580
StringRef getName () const { return getStringOperand (1 ); }
2588
2581
DIFile *getFile () const { return cast_or_null<DIFile>(getRawFile ()); }
2589
2582
DIType *getType () const { return cast_or_null<DIType>(getRawType ()); }
2590
- uint32_t getAlignInBits () const { return AlignInBits ; }
2583
+ uint32_t getAlignInBits () const { return SubclassData32 ; }
2591
2584
uint32_t getAlignInBytes () const { return getAlignInBits () / CHAR_BIT; }
2592
2585
// / Determines the size of the variable's type.
2593
2586
std::optional<uint64_t > getSizeInBits () const ;
@@ -3162,8 +3155,6 @@ class DIGlobalVariable : public DIVariable {
3162
3155
};
3163
3156
3164
3157
class DICommonBlock : public DIScope {
3165
- unsigned LineNo;
3166
-
3167
3158
friend class LLVMContextImpl ;
3168
3159
friend class MDNode ;
3169
3160
@@ -3205,7 +3196,7 @@ class DICommonBlock : public DIScope {
3205
3196
}
3206
3197
StringRef getName () const { return getStringOperand (2 ); }
3207
3198
DIFile *getFile () const { return cast_or_null<DIFile>(getRawFile ()); }
3208
- unsigned getLineNo () const { return LineNo ; }
3199
+ unsigned getLineNo () const { return SubclassData32 ; }
3209
3200
3210
3201
Metadata *getRawScope () const { return getOperand (0 ); }
3211
3202
Metadata *getRawDecl () const { return getOperand (1 ); }
@@ -3314,8 +3305,6 @@ class DILabel : public DINode {
3314
3305
friend class LLVMContextImpl ;
3315
3306
friend class MDNode ;
3316
3307
3317
- unsigned Line;
3318
-
3319
3308
DILabel (LLVMContext &C, StorageType Storage, unsigned Line,
3320
3309
ArrayRef<Metadata *> Ops);
3321
3310
~DILabel () = default ;
@@ -3353,7 +3342,7 @@ class DILabel : public DINode {
3353
3342
DILocalScope *getScope () const {
3354
3343
return cast_or_null<DILocalScope>(getRawScope ());
3355
3344
}
3356
- unsigned getLine () const { return Line ; }
3345
+ unsigned getLine () const { return SubclassData32 ; }
3357
3346
StringRef getName () const { return getStringOperand (1 ); }
3358
3347
DIFile *getFile () const { return cast_or_null<DIFile>(getRawFile ()); }
3359
3348
@@ -3459,11 +3448,11 @@ class DIImportedEntity : public DINode {
3459
3448
friend class LLVMContextImpl ;
3460
3449
friend class MDNode ;
3461
3450
3462
- unsigned Line;
3463
-
3464
3451
DIImportedEntity (LLVMContext &C, StorageType Storage, unsigned Tag,
3465
3452
unsigned Line, ArrayRef<Metadata *> Ops)
3466
- : DINode(C, DIImportedEntityKind, Storage, Tag, Ops), Line(Line) {}
3453
+ : DINode(C, DIImportedEntityKind, Storage, Tag, Ops) {
3454
+ SubclassData32 = Line;
3455
+ }
3467
3456
~DIImportedEntity () = default ;
3468
3457
3469
3458
static DIImportedEntity *getImpl (LLVMContext &Context, unsigned Tag,
@@ -3499,7 +3488,7 @@ class DIImportedEntity : public DINode {
3499
3488
3500
3489
TempDIImportedEntity clone () const { return cloneImpl (); }
3501
3490
3502
- unsigned getLine () const { return Line ; }
3491
+ unsigned getLine () const { return SubclassData32 ; }
3503
3492
DIScope *getScope () const { return cast_or_null<DIScope>(getRawScope ()); }
3504
3493
DINode *getEntity () const { return cast_or_null<DINode>(getRawEntity ()); }
3505
3494
StringRef getName () const { return getStringOperand (2 ); }
@@ -3615,11 +3604,11 @@ class DIMacro : public DIMacroNode {
3615
3604
friend class LLVMContextImpl ;
3616
3605
friend class MDNode ;
3617
3606
3618
- unsigned Line;
3619
-
3620
3607
DIMacro (LLVMContext &C, StorageType Storage, unsigned MIType, unsigned Line,
3621
3608
ArrayRef<Metadata *> Ops)
3622
- : DIMacroNode(C, DIMacroKind, Storage, MIType, Ops), Line(Line) {}
3609
+ : DIMacroNode(C, DIMacroKind, Storage, MIType, Ops) {
3610
+ SubclassData32 = Line;
3611
+ }
3623
3612
~DIMacro () = default ;
3624
3613
3625
3614
static DIMacro *getImpl (LLVMContext &Context, unsigned MIType, unsigned Line,
@@ -3649,7 +3638,7 @@ class DIMacro : public DIMacroNode {
3649
3638
3650
3639
TempDIMacro clone () const { return cloneImpl (); }
3651
3640
3652
- unsigned getLine () const { return Line ; }
3641
+ unsigned getLine () const { return SubclassData32 ; }
3653
3642
3654
3643
StringRef getName () const { return getStringOperand (0 ); }
3655
3644
StringRef getValue () const { return getStringOperand (1 ); }
@@ -3666,11 +3655,11 @@ class DIMacroFile : public DIMacroNode {
3666
3655
friend class LLVMContextImpl ;
3667
3656
friend class MDNode ;
3668
3657
3669
- unsigned Line;
3670
-
3671
3658
DIMacroFile (LLVMContext &C, StorageType Storage, unsigned MIType,
3672
3659
unsigned Line, ArrayRef<Metadata *> Ops)
3673
- : DIMacroNode(C, DIMacroFileKind, Storage, MIType, Ops), Line(Line) {}
3660
+ : DIMacroNode(C, DIMacroFileKind, Storage, MIType, Ops) {
3661
+ SubclassData32 = Line;
3662
+ }
3674
3663
~DIMacroFile () = default ;
3675
3664
3676
3665
static DIMacroFile *getImpl (LLVMContext &Context, unsigned MIType,
@@ -3711,7 +3700,7 @@ class DIMacroFile : public DIMacroNode {
3711
3700
replaceOperandWith (1 , Elements.get ());
3712
3701
}
3713
3702
3714
- unsigned getLine () const { return Line ; }
3703
+ unsigned getLine () const { return SubclassData32 ; }
3715
3704
DIFile *getFile () const { return cast_or_null<DIFile>(getRawFile ()); }
3716
3705
3717
3706
DIMacroNodeArray getElements () const {
0 commit comments