LLDB mainline
|
The SourceFileCache class separates the source manager from the cache of source files. More...
#include <SourceManager.h>
Public Member Functions | |
SourceFileCache ()=default | |
~SourceFileCache ()=default | |
void | AddSourceFile (const FileSpec &file_spec, FileSP file_sp) |
void | RemoveSourceFile (const FileSP &file_sp) |
FileSP | FindSourceFile (const FileSpec &file_spec) const |
void | Clear () |
void | Dump (Stream &stream) const |
Private Types | |
typedef std::map< FileSpec, FileSP > | FileCache |
Private Member Functions | |
void | AddSourceFileImpl (const FileSpec &file_spec, FileSP file_sp) |
Private Attributes | |
FileCache | m_file_cache |
llvm::sys::RWMutex | m_mutex |
The SourceFileCache class separates the source manager from the cache of source files.
There is one source manager per Target but both the Debugger and the Process have their own source caches.
The SourceFileCache just handles adding, storing, removing and looking up source files. The caching policies are implemented in SourceManager::GetFile.
Definition at line 123 of file SourceManager.h.
|
private |
Definition at line 141 of file SourceManager.h.
|
default |
|
default |
Definition at line 809 of file SourceManager.cpp.
|
private |
Definition at line 837 of file SourceManager.cpp.
|
inline |
Definition at line 134 of file SourceManager.h.
References m_file_cache.
Referenced by CommandObjectSourceCacheClear::DoExecute(), lldb_private::Debugger::SetPropertyValue(), and lldb_private::Debugger::SetUseSourceCache().
void SourceManager::SourceFileCache::Dump | ( | Stream & | stream | ) | const |
Definition at line 858 of file SourceManager.cpp.
References lldb_private::Stream::Format(), and lldb_private::toString().
Referenced by CommandObjectSourceCacheDump::DoExecute().
SourceManager::FileSP SourceManager::SourceFileCache::FindSourceFile | ( | const FileSpec & | file_spec | ) | const |
Definition at line 848 of file SourceManager.cpp.
void SourceManager::SourceFileCache::RemoveSourceFile | ( | const FileSP & | file_sp | ) |
Definition at line 821 of file SourceManager.cpp.
|
private |
Definition at line 142 of file SourceManager.h.
Referenced by Clear().
|
mutableprivate |
Definition at line 144 of file SourceManager.h.