|
LLVM 22.0.0git
|
File system that tracks the number of calls to the underlying file system. More...
#include "llvm/Support/VirtualFileSystem.h"
Public Member Functions | |
| TracingFileSystem (llvm::IntrusiveRefCntPtr< llvm::vfs::FileSystem > FS) | |
| ErrorOr< Status > | status (const Twine &Path) override |
| ErrorOr< std::unique_ptr< File > > | openFileForRead (const Twine &Path) override |
| directory_iterator | dir_begin (const Twine &Dir, std::error_code &EC) override |
| std::error_code | getRealPath (const Twine &Path, SmallVectorImpl< char > &Output) override |
| bool | exists (const Twine &Path) override |
| std::error_code | isLocal (const Twine &Path, bool &Result) override |
| Public Member Functions inherited from llvm::RTTIExtends< TracingFileSystem, ProxyFileSystem > | |
| const void * | dynamicClassID () const override |
| bool | isA () const |
| Check whether this instance is a subclass of QueryT. | |
Public Attributes | |
| std::size_t | NumStatusCalls = 0 |
| std::size_t | NumOpenFileForReadCalls = 0 |
| std::size_t | NumDirBeginCalls = 0 |
| std::size_t | NumGetRealPathCalls = 0 |
| std::size_t | NumExistsCalls = 0 |
| std::size_t | NumIsLocalCalls = 0 |
Static Public Attributes | |
| static const char | ID = 0 |
Protected Member Functions | |
| void | printImpl (raw_ostream &OS, PrintType Type, unsigned IndentLevel) const override |
Additional Inherited Members | |
| Static Public Member Functions inherited from llvm::RTTIExtends< TracingFileSystem, ProxyFileSystem > | |
| static const void * | classID () |
| static bool | classof (const T *R) |
File system that tracks the number of calls to the underlying file system.
This is particularly useful when wrapped around RealFileSystem to add lightweight tracking of expensive syscalls.
Definition at line 1159 of file VirtualFileSystem.h.
|
inline |
Definition at line 1171 of file VirtualFileSystem.h.
References llvm::move().
|
inlineoverride |
Definition at line 1184 of file VirtualFileSystem.h.
References llvm::vfs::ProxyFileSystem::dir_begin(), and NumDirBeginCalls.
Definition at line 1195 of file VirtualFileSystem.h.
References llvm::vfs::ProxyFileSystem::exists(), and NumExistsCalls.
|
inlineoverride |
Definition at line 1189 of file VirtualFileSystem.h.
References llvm::vfs::ProxyFileSystem::getRealPath(), and NumGetRealPathCalls.
|
inlineoverride |
Definition at line 1200 of file VirtualFileSystem.h.
References llvm::vfs::ProxyFileSystem::isLocal(), and NumIsLocalCalls.
|
inlineoverride |
Definition at line 1179 of file VirtualFileSystem.h.
References NumOpenFileForReadCalls, and llvm::vfs::ProxyFileSystem::openFileForRead().
|
overrideprotected |
Definition at line 2991 of file VirtualFileSystem.cpp.
References NumDirBeginCalls, NumExistsCalls, NumGetRealPathCalls, NumIsLocalCalls, NumOpenFileForReadCalls, NumStatusCalls, and llvm::Type::print().
Definition at line 1174 of file VirtualFileSystem.h.
References NumStatusCalls, and llvm::vfs::ProxyFileSystem::status().
Definition at line 1162 of file VirtualFileSystem.h.
| std::size_t llvm::vfs::TracingFileSystem::NumDirBeginCalls = 0 |
Definition at line 1166 of file VirtualFileSystem.h.
Referenced by dir_begin(), and printImpl().
| std::size_t llvm::vfs::TracingFileSystem::NumExistsCalls = 0 |
Definition at line 1168 of file VirtualFileSystem.h.
Referenced by exists(), and printImpl().
| std::size_t llvm::vfs::TracingFileSystem::NumGetRealPathCalls = 0 |
Definition at line 1167 of file VirtualFileSystem.h.
Referenced by getRealPath(), and printImpl().
| std::size_t llvm::vfs::TracingFileSystem::NumIsLocalCalls = 0 |
Definition at line 1169 of file VirtualFileSystem.h.
Referenced by isLocal(), and printImpl().
| std::size_t llvm::vfs::TracingFileSystem::NumOpenFileForReadCalls = 0 |
Definition at line 1165 of file VirtualFileSystem.h.
Referenced by openFileForRead(), and printImpl().
| std::size_t llvm::vfs::TracingFileSystem::NumStatusCalls = 0 |
Definition at line 1164 of file VirtualFileSystem.h.
Referenced by printImpl(), and status().