@@ -1172,16 +1172,16 @@ class DICompileUnit : public DIScope {
1172
1172
DIGlobalVariableExpressionArray GlobalVariables,
1173
1173
DIImportedEntityArray ImportedEntities, DIMacroNodeArray Macros,
1174
1174
uint64_t DWOId, bool SplitDebugInlining, bool DebugInfoForProfiling,
1175
- unsigned NameTableKind, bool RangesBaseAddress, StorageType Storage ,
1176
- bool ShouldCreate = true ) {
1177
- return getImpl (Context, SourceLanguage, File,
1178
- getCanonicalMDString (Context, Producer), IsOptimized ,
1179
- getCanonicalMDString (Context, Flags), RuntimeVersion,
1180
- getCanonicalMDString (Context, SplitDebugFilename),
1181
- EmissionKind, EnumTypes.get (), RetainedTypes.get (),
1182
- GlobalVariables. get (), ImportedEntities.get (), Macros.get (),
1183
- DWOId, SplitDebugInlining, DebugInfoForProfiling ,
1184
- NameTableKind, RangesBaseAddress , Storage, ShouldCreate);
1175
+ unsigned NameTableKind, bool RangesBaseAddress, StringRef SysRoot ,
1176
+ StorageType Storage, bool ShouldCreate = true ) {
1177
+ return getImpl (
1178
+ Context, SourceLanguage, File, getCanonicalMDString (Context, Producer),
1179
+ IsOptimized, getCanonicalMDString (Context, Flags), RuntimeVersion,
1180
+ getCanonicalMDString (Context, SplitDebugFilename), EmissionKind ,
1181
+ EnumTypes.get (), RetainedTypes. get (), GlobalVariables .get (),
1182
+ ImportedEntities.get (), Macros.get (), DWOId, SplitDebugInlining ,
1183
+ DebugInfoForProfiling, NameTableKind, RangesBaseAddress ,
1184
+ getCanonicalMDString (Context, SysRoot) , Storage, ShouldCreate);
1185
1185
}
1186
1186
static DICompileUnit *
1187
1187
getImpl (LLVMContext &Context, unsigned SourceLanguage, Metadata *File,
@@ -1191,7 +1191,8 @@ class DICompileUnit : public DIScope {
1191
1191
Metadata *GlobalVariables, Metadata *ImportedEntities,
1192
1192
Metadata *Macros, uint64_t DWOId, bool SplitDebugInlining,
1193
1193
bool DebugInfoForProfiling, unsigned NameTableKind,
1194
- bool RangesBaseAddress, StorageType Storage, bool ShouldCreate = true );
1194
+ bool RangesBaseAddress, MDString *SysRoot, StorageType Storage,
1195
+ bool ShouldCreate = true );
1195
1196
1196
1197
TempDICompileUnit cloneImpl () const {
1197
1198
return getTemporary (
@@ -1200,7 +1201,7 @@ class DICompileUnit : public DIScope {
1200
1201
getEmissionKind (), getEnumTypes (), getRetainedTypes (),
1201
1202
getGlobalVariables (), getImportedEntities (), getMacros (), DWOId,
1202
1203
getSplitDebugInlining (), getDebugInfoForProfiling (), getNameTableKind (),
1203
- getRangesBaseAddress ());
1204
+ getRangesBaseAddress (), getSysRoot () );
1204
1205
}
1205
1206
1206
1207
public:
@@ -1216,11 +1217,13 @@ class DICompileUnit : public DIScope {
1216
1217
DIGlobalVariableExpressionArray GlobalVariables,
1217
1218
DIImportedEntityArray ImportedEntities, DIMacroNodeArray Macros,
1218
1219
uint64_t DWOId, bool SplitDebugInlining, bool DebugInfoForProfiling,
1219
- DebugNameTableKind NameTableKind, bool RangesBaseAddress),
1220
+ DebugNameTableKind NameTableKind, bool RangesBaseAddress,
1221
+ StringRef SysRoot),
1220
1222
(SourceLanguage, File, Producer, IsOptimized, Flags, RuntimeVersion,
1221
1223
SplitDebugFilename, EmissionKind, EnumTypes, RetainedTypes,
1222
1224
GlobalVariables, ImportedEntities, Macros, DWOId, SplitDebugInlining,
1223
- DebugInfoForProfiling, (unsigned )NameTableKind, RangesBaseAddress))
1225
+ DebugInfoForProfiling, (unsigned )NameTableKind, RangesBaseAddress,
1226
+ SysRoot))
1224
1227
DEFINE_MDNODE_GET_DISTINCT_TEMPORARY(
1225
1228
DICompileUnit,
1226
1229
(unsigned SourceLanguage, Metadata *File, MDString *Producer,
@@ -1229,11 +1232,11 @@ class DICompileUnit : public DIScope {
1229
1232
Metadata *RetainedTypes, Metadata *GlobalVariables,
1230
1233
Metadata *ImportedEntities, Metadata *Macros, uint64_t DWOId,
1231
1234
bool SplitDebugInlining, bool DebugInfoForProfiling,
1232
- unsigned NameTableKind, bool RangesBaseAddress),
1235
+ unsigned NameTableKind, bool RangesBaseAddress, MDString *SysRoot ),
1233
1236
(SourceLanguage, File, Producer, IsOptimized, Flags, RuntimeVersion,
1234
1237
SplitDebugFilename, EmissionKind, EnumTypes, RetainedTypes,
1235
1238
GlobalVariables, ImportedEntities, Macros, DWOId, SplitDebugInlining,
1236
- DebugInfoForProfiling, NameTableKind, RangesBaseAddress))
1239
+ DebugInfoForProfiling, NameTableKind, RangesBaseAddress, SysRoot ))
1237
1240
1238
1241
TempDICompileUnit clone() const { return cloneImpl (); }
1239
1242
@@ -1250,14 +1253,10 @@ class DICompileUnit : public DIScope {
1250
1253
DebugNameTableKind getNameTableKind () const {
1251
1254
return (DebugNameTableKind)NameTableKind;
1252
1255
}
1253
- bool getRangesBaseAddress () const {
1254
- return RangesBaseAddress; }
1255
- StringRef getProducer () const {
1256
- return getStringOperand (1 ); }
1257
- StringRef getFlags () const {
1258
- return getStringOperand (2 ); }
1259
- StringRef getSplitDebugFilename () const {
1260
- return getStringOperand (3 ); }
1256
+ bool getRangesBaseAddress () const { return RangesBaseAddress; }
1257
+ StringRef getProducer () const { return getStringOperand (1 ); }
1258
+ StringRef getFlags () const { return getStringOperand (2 ); }
1259
+ StringRef getSplitDebugFilename () const { return getStringOperand (3 ); }
1261
1260
DICompositeTypeArray getEnumTypes () const {
1262
1261
return cast_or_null<MDTuple>(getRawEnumTypes ());
1263
1262
}
@@ -1279,6 +1278,7 @@ class DICompileUnit : public DIScope {
1279
1278
void setSplitDebugInlining (bool SplitDebugInlining) {
1280
1279
this ->SplitDebugInlining = SplitDebugInlining;
1281
1280
}
1281
+ StringRef getSysRoot () const { return getStringOperand (9 ); }
1282
1282
1283
1283
MDString *getRawProducer () const { return getOperandAs<MDString>(1 ); }
1284
1284
MDString *getRawFlags () const { return getOperandAs<MDString>(2 ); }
@@ -1290,6 +1290,7 @@ class DICompileUnit : public DIScope {
1290
1290
Metadata *getRawGlobalVariables () const { return getOperand (6 ); }
1291
1291
Metadata *getRawImportedEntities () const { return getOperand (7 ); }
1292
1292
Metadata *getRawMacros () const { return getOperand (8 ); }
1293
+ MDString *getRawSysRoot () const { return getOperandAs<MDString>(9 ); }
1293
1294
1294
1295
// / Replace arrays.
1295
1296
// /
@@ -2082,50 +2083,45 @@ class DIModule : public DIScope {
2082
2083
: DIScope(Context, DIModuleKind, Storage, dwarf::DW_TAG_module, Ops) {}
2083
2084
~DIModule () = default ;
2084
2085
2085
- static DIModule *getImpl (LLVMContext &Context, DIScope *Scope,
2086
- StringRef Name, StringRef ConfigurationMacros,
2087
- StringRef IncludePath, StringRef SysRoot,
2086
+ static DIModule *getImpl (LLVMContext &Context, DIScope *Scope, StringRef Name,
2087
+ StringRef ConfigurationMacros, StringRef IncludePath,
2088
2088
StorageType Storage, bool ShouldCreate = true ) {
2089
2089
return getImpl (Context, Scope, getCanonicalMDString (Context, Name),
2090
2090
getCanonicalMDString (Context, ConfigurationMacros),
2091
2091
getCanonicalMDString (Context, IncludePath),
2092
- getCanonicalMDString (Context, SysRoot),
2093
2092
Storage, ShouldCreate);
2094
2093
}
2095
2094
static DIModule *getImpl (LLVMContext &Context, Metadata *Scope,
2096
2095
MDString *Name, MDString *ConfigurationMacros,
2097
- MDString *IncludePath, MDString *SysRoot ,
2098
- StorageType Storage, bool ShouldCreate = true );
2096
+ MDString *IncludePath, StorageType Storage ,
2097
+ bool ShouldCreate = true );
2099
2098
2100
2099
TempDIModule cloneImpl () const {
2101
2100
return getTemporary (getContext (), getScope (), getName (),
2102
- getConfigurationMacros (), getIncludePath (),
2103
- getSysRoot ());
2101
+ getConfigurationMacros (), getIncludePath ());
2104
2102
}
2105
2103
2106
2104
public:
2107
- DEFINE_MDNODE_GET (DIModule, (DIScope *Scope, StringRef Name,
2108
- StringRef ConfigurationMacros , StringRef IncludePath ,
2109
- StringRef SysRoot ),
2110
- (Scope, Name, ConfigurationMacros, IncludePath, SysRoot ))
2105
+ DEFINE_MDNODE_GET (DIModule,
2106
+ (DIScope * Scope , StringRef Name ,
2107
+ StringRef ConfigurationMacros, StringRef IncludePath ),
2108
+ (Scope, Name, ConfigurationMacros, IncludePath))
2111
2109
DEFINE_MDNODE_GET (DIModule,
2112
2110
(Metadata *Scope, MDString *Name, MDString *ConfigurationMacros,
2113
- MDString *IncludePath, MDString *SysRoot ),
2114
- (Scope, Name, ConfigurationMacros, IncludePath, SysRoot ))
2111
+ MDString *IncludePath),
2112
+ (Scope, Name, ConfigurationMacros, IncludePath))
2115
2113
2116
2114
TempDIModule clone () const { return cloneImpl (); }
2117
2115
2118
2116
DIScope *getScope () const { return cast_or_null<DIScope>(getRawScope ()); }
2119
2117
StringRef getName () const { return getStringOperand (1 ); }
2120
2118
StringRef getConfigurationMacros () const { return getStringOperand (2 ); }
2121
2119
StringRef getIncludePath () const { return getStringOperand (3 ); }
2122
- StringRef getSysRoot () const { return getStringOperand (4 ); }
2123
2120
2124
2121
Metadata *getRawScope () const { return getOperand (0 ); }
2125
2122
MDString *getRawName () const { return getOperandAs<MDString>(1 ); }
2126
2123
MDString *getRawConfigurationMacros () const { return getOperandAs<MDString>(2 ); }
2127
2124
MDString *getRawIncludePath () const { return getOperandAs<MDString>(3 ); }
2128
- MDString *getRawSysRoot () const { return getOperandAs<MDString>(4 ); }
2129
2125
2130
2126
static bool classof (const Metadata *MD) {
2131
2127
return MD->getMetadataID () == DIModuleKind;
0 commit comments