@@ -77,39 +77,38 @@ class LLVMSymbolizer {
77
77
// Overloads accepting ObjectFile does not support COFF currently
78
78
Expected<DILineInfo> symbolizeCode (const ObjectFile &Obj,
79
79
object::SectionedAddress ModuleOffset);
80
- Expected<DILineInfo> symbolizeCode (const std::string & ModuleName,
80
+ Expected<DILineInfo> symbolizeCode (StringRef ModuleName,
81
81
object::SectionedAddress ModuleOffset);
82
82
Expected<DILineInfo> symbolizeCode (ArrayRef<uint8_t > BuildID,
83
83
object::SectionedAddress ModuleOffset);
84
84
Expected<DIInliningInfo>
85
85
symbolizeInlinedCode (const ObjectFile &Obj,
86
86
object::SectionedAddress ModuleOffset);
87
87
Expected<DIInliningInfo>
88
- symbolizeInlinedCode (const std::string & ModuleName,
88
+ symbolizeInlinedCode (StringRef ModuleName,
89
89
object::SectionedAddress ModuleOffset);
90
90
Expected<DIInliningInfo>
91
91
symbolizeInlinedCode (ArrayRef<uint8_t > BuildID,
92
92
object::SectionedAddress ModuleOffset);
93
93
94
94
Expected<DIGlobal> symbolizeData (const ObjectFile &Obj,
95
95
object::SectionedAddress ModuleOffset);
96
- Expected<DIGlobal> symbolizeData (const std::string & ModuleName,
96
+ Expected<DIGlobal> symbolizeData (StringRef ModuleName,
97
97
object::SectionedAddress ModuleOffset);
98
98
Expected<DIGlobal> symbolizeData (ArrayRef<uint8_t > BuildID,
99
99
object::SectionedAddress ModuleOffset);
100
100
Expected<std::vector<DILocal>>
101
101
symbolizeFrame (const ObjectFile &Obj, object::SectionedAddress ModuleOffset);
102
102
Expected<std::vector<DILocal>>
103
- symbolizeFrame (const std::string &ModuleName,
104
- object::SectionedAddress ModuleOffset);
103
+ symbolizeFrame (StringRef ModuleName, object::SectionedAddress ModuleOffset);
105
104
Expected<std::vector<DILocal>>
106
105
symbolizeFrame (ArrayRef<uint8_t > BuildID,
107
106
object::SectionedAddress ModuleOffset);
108
107
109
108
Expected<std::vector<DILineInfo>>
110
109
findSymbol (const ObjectFile &Obj, StringRef Symbol, uint64_t Offset);
111
110
Expected<std::vector<DILineInfo>>
112
- findSymbol (const std::string & ModuleName, StringRef Symbol, uint64_t Offset);
111
+ findSymbol (StringRef ModuleName, StringRef Symbol, uint64_t Offset);
113
112
Expected<std::vector<DILineInfo>>
114
113
findSymbol (ArrayRef<uint8_t > BuildID, StringRef Symbol, uint64_t Offset);
115
114
@@ -132,8 +131,7 @@ class LLVMSymbolizer {
132
131
// / Only one attempt is made to load a module, and errors during loading are
133
132
// / only reported once. Subsequent calls to get module info for a module that
134
133
// / failed to load will return nullptr.
135
- Expected<SymbolizableModule *>
136
- getOrCreateModuleInfo (const std::string &ModuleName);
134
+ Expected<SymbolizableModule *> getOrCreateModuleInfo (StringRef ModuleName);
137
135
138
136
private:
139
137
// Bundles together object file with code/data and object file with
@@ -210,7 +208,7 @@ class LLVMSymbolizer {
210
208
ObjectPairForPathArch;
211
209
212
210
// / Contains parsed binary for each path, or parsing error.
213
- std::map<std::string, CachedBinary> BinaryForPath;
211
+ std::map<std::string, CachedBinary, std::less<> > BinaryForPath;
214
212
215
213
// / A list of cached binaries in LRU order.
216
214
simple_ilist<CachedBinary> LRUBinaries;
0 commit comments