LLDB mainline
|
#include "lldb/Symbol/LocateSymbolFile.h"
#include <dirent.h>
#include <dlfcn.h>
#include <pwd.h>
#include <CoreFoundation/CoreFoundation.h>
#include "Host/macosx/cfcpp/CFCBundle.h"
#include "Host/macosx/cfcpp/CFCData.h"
#include "Host/macosx/cfcpp/CFCReleaser.h"
#include "Host/macosx/cfcpp/CFCString.h"
#include "lldb/Core/Module.h"
#include "lldb/Core/ModuleList.h"
#include "lldb/Core/ModuleSpec.h"
#include "lldb/Host/Host.h"
#include "lldb/Host/HostInfo.h"
#include "lldb/Symbol/ObjectFile.h"
#include "lldb/Utility/ArchSpec.h"
#include "lldb/Utility/DataBuffer.h"
#include "lldb/Utility/DataExtractor.h"
#include "lldb/Utility/Endian.h"
#include "lldb/Utility/LLDBLog.h"
#include "lldb/Utility/Log.h"
#include "lldb/Utility/StreamString.h"
#include "lldb/Utility/Timer.h"
#include "lldb/Utility/UUID.h"
#include "mach/machine.h"
#include "llvm/ADT/ScopeExit.h"
#include "llvm/Support/FileSystem.h"
Go to the source code of this file.
Functions | |
int | LocateMacOSXFilesUsingDebugSymbols (const ModuleSpec &module_spec, ModuleSpec &return_module_spec) |
static bool | GetModuleSpecInfoFromUUIDDictionary (CFDictionaryRef uuid_dict, ModuleSpec &module_spec, Status &error, const std::string &command) |
static llvm::StringRef | GetDbgShellCommand () |
It's expensive to check for the DBGShellCommands defaults setting. | |
static FileSpec | GetDsymForUUIDExecutable () |
Get the dsymForUUID executable and cache the result so we don't end up stat'ing the binary over and over. | |
Variables | |
static CFURLRef(* | g_dlsym_DBGCopyFullDSYMURLForUUID )(CFUUIDRef uuid, CFURLRef exec_url) = nullptr |
static CFDictionaryRef(* | g_dlsym_DBGCopyDSYMPropertyLists )(CFURLRef dsym_url) |
|
static |
It's expensive to check for the DBGShellCommands defaults setting.
Only do it once per lldb run and cache the result.
Definition at line 500 of file LocateSymbolFileMacOSX.cpp.
References PATH_MAX.
Referenced by GetDsymForUUIDExecutable().
|
static |
Get the dsymForUUID executable and cache the result so we don't end up stat'ing the binary over and over.
Definition at line 523 of file LocateSymbolFileMacOSX.cpp.
References GetDbgShellCommand(), lldb_private::FileSystem::Instance(), and lldb_private::FileSystem::Resolve().
|
static |
Definition at line 331 of file LocateSymbolFileMacOSX.cpp.
References lldb_private::PathMappingList::Append(), error(), CFCString::FileSystemRepresentation(), lldb_private::ModuleSpec::GetFileSpec(), lldb_private::GetLog(), lldb_private::FileSpec::GetPath(), lldb_private::ModuleSpec::GetSourceMappingList(), lldb_private::ModuleSpec::GetSymbolFileSpec(), lldb_private::Host, lldb_private::FileSystem::Instance(), LLDB_LOGF, lldb_private::FileSpec::RemoveLastPathComponent(), lldb_private::FileSystem::Resolve(), and lldb_private::FileSpec::SetFile().
int LocateMacOSXFilesUsingDebugSymbols | ( | const ModuleSpec & | module_spec, |
ModuleSpec & | return_module_spec | ||
) |
Definition at line 49 of file LocateSymbolFileMacOSX.cpp.
References lldb_private::FileSpec::Clear(), CFCBundle::CopyExecutableURL(), lldb_private::FileSystem::Exists(), lldb_private::ModuleSpecList::FindMatchingModuleSpec(), lldb_private::Symbols::FindSymbolFileInBundle(), g_dlsym_DBGCopyDSYMPropertyLists, g_dlsym_DBGCopyFullDSYMURLForUUID, CFCReleaser< T >::get(), lldb_private::ModuleSpec::GetArchitecturePtr(), lldb_private::UUID::GetAsString(), lldb_private::UUID::GetBytes(), lldb_private::ModuleSpec::GetFileSpec(), lldb_private::ModuleSpec::GetFileSpecPtr(), lldb_private::ModuleList::GetGlobalModuleListProperties(), lldb_private::GetLog(), lldb_private::ObjectFile::GetModuleSpecifications(), lldb_private::FileSpec::GetPath(), lldb_private::ModuleSpec::GetSymbolFileSpec(), lldb_private::ModuleSpec::GetUUID(), lldb_private::ModuleSpec::GetUUIDPtr(), lldb_private::FileSystem::Instance(), lldb_private::UUID::IsValid(), LLDB_LOGF, PATH_MAX, CFCReleaser< T >::reset(), lldb_private::FileSystem::Resolve(), and lldb_private::SharedCacheImageInfo::uuid.
|
static |
Definition at line 46 of file LocateSymbolFileMacOSX.cpp.
Referenced by LocateMacOSXFilesUsingDebugSymbols().
|
static |
Definition at line 44 of file LocateSymbolFileMacOSX.cpp.
Referenced by LocateMacOSXFilesUsingDebugSymbols().