13#ifndef LLVM_DEBUGINFO_SYMBOLIZE_SYMBOLIZE_H
14#define LLVM_DEBUGINFO_SYMBOLIZE_SYMBOLIZE_H
33class ELFObjectFileBase;
36struct SectionedAddress;
41class SymbolizableModule;
43using namespace object;
69 :
static_cast<size_t>(4ULL * 1024 * 1024 * 1024) ;
128 BIDFetcher = std::move(Fetcher);
141 using ObjectPair = std::pair<const ObjectFile *, const ObjectFile *>;
143 template <
typename T>
145 symbolizeCodeCommon(
const T &ModuleSpecifier,
147 template <
typename T>
149 symbolizeInlinedCodeCommon(
const T &ModuleSpecifier,
151 template <
typename T>
154 template <
typename T>
156 symbolizeFrameCommon(
const T &ModuleSpecifier,
158 template <
typename T>
171 createModuleInfo(
const ObjectFile *Obj, std::unique_ptr<DIContext> Context,
174 ObjectFile *lookUpDsymFile(
const std::string &Path,
176 const std::string &ArchName);
177 ObjectFile *lookUpDebuglinkObject(
const std::string &Path,
179 const std::string &ArchName);
180 ObjectFile *lookUpBuildIDObject(
const std::string &Path,
182 const std::string &ArchName);
184 bool findDebugBinary(
const std::string &OrigPath,
185 const std::string &DebuglinkName,
uint32_t CRCHash,
186 std::string &Result);
189 std::string &Result);
193 const std::string &ArchName);
199 const std::string &ArchName);
204 std::map<std::string, std::unique_ptr<SymbolizableModule>, std::less<>>
209 std::map<std::pair<std::string, std::string>, ObjectPair>
210 ObjectPairForPathArch;
213 std::map<std::string, CachedBinary> BinaryForPath;
218 size_t CacheSize = 0;
222 std::map<std::pair<std::string, std::string>, std::unique_ptr<ObjectFile>>
223 ObjectForUBPathAndArch;
227 std::unique_ptr<BuildIDFetcher> BIDFetcher;
252 size_t size() {
return Bin.getBinary()->getData().size(); }
256 std::function<void()> Evictor;
This file defines the StringMap class.
This file declares a library for handling Build IDs and using them to find debug info.
DILineInfoSpecifier::FunctionNameKind FunctionNameKind
const char LLVMTargetMachineRef LLVMPassBuilderOptionsRef Options
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Tagged union holding either a T or a Error.
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
StringMap - This is an unconventional map that is specialized for handling keys that are "strings",...
StringRef - Represent a constant reference to a string, i.e.
This class is the base class for all object file types.
A simple intrusive list implementation.
CachedBinary(OwningBinary< Binary > Bin)
OwningBinary< Binary > * operator->()
void pushEvictor(std::function< void()> Evictor)
OwningBinary< Binary > & operator*()
Expected< std::vector< DILineInfo > > findSymbol(const ObjectFile &Obj, StringRef Symbol, uint64_t Offset)
Expected< DIInliningInfo > symbolizeInlinedCode(const ObjectFile &Obj, object::SectionedAddress ModuleOffset)
Expected< SymbolizableModule * > getOrCreateModuleInfo(const std::string &ModuleName)
Returns a SymbolizableModule or an error if loading debug info failed.
Expected< DILineInfo > symbolizeCode(const ObjectFile &Obj, object::SectionedAddress ModuleOffset)
static std::string DemangleName(const std::string &Name, const SymbolizableModule *DbiModuleDescriptor)
Expected< DIGlobal > symbolizeData(const ObjectFile &Obj, object::SectionedAddress ModuleOffset)
Expected< std::vector< DILocal > > symbolizeFrame(const ObjectFile &Obj, object::SectionedAddress ModuleOffset)
void setBuildIDFetcher(std::unique_ptr< BuildIDFetcher > Fetcher)
This file defines the ilist_node class template, which is a convenient base class for creating classe...
This is an optimization pass for GlobalISel generic memory operations.
DINameKind
A DINameKind is passed to name search methods to specify a preference regarding the type of name reso...
OutputIt move(R &&Range, OutputIt Out)
Provide wrappers to std::move which take ranges instead of having to pass begin/end explicitly.
Implement std::hash so that hash_code can be used in STL containers.
DINameKind FunctionNameKind
std::vector< std::string > DebugFileDirectory
std::vector< std::string > DsymHints
std::string FallbackDebugPath
FunctionNameKind PrintFunctions
FileLineInfoKind PathStyle