LLVM 22.0.0git
llvm::orc::LibraryScanHelper Class Reference

Scans and tracks libraries for symbol resolution. More...

#include "llvm/ExecutionEngine/Orc/TargetProcess/LibraryScanner.h"

Public Member Functions

 LibraryScanHelper (const std::vector< std::string > &SPaths, std::shared_ptr< LibraryPathCache > LibPathCache, std::shared_ptr< PathResolver > LibPathResolver)
void addBasePath (const std::string &P, PathType Kind=PathType::Unknown)
std::vector< std::shared_ptr< LibrarySearchPath > > getNextBatch (PathType Kind, size_t batchSize)
bool leftToScan (PathType K) const
void resetToScan ()
bool isTrackedBasePath (StringRef P) const
std::vector< std::shared_ptr< LibrarySearchPath > > getAllUnits () const
SmallVector< StringRefgetSearchPaths () const
PathResolvergetPathResolver () const
LibraryPathCachegetCache () const
bool hasSeenOrMark (StringRef P) const
std::optional< std::string > resolve (StringRef P, std::error_code &ec) const

Detailed Description

Scans and tracks libraries for symbol resolution.

Maintains a list of library paths to scan, caches scanned units, and resolves paths canonically for consistent tracking.

Definition at line 325 of file LibraryScanner.h.

Constructor & Destructor Documentation

◆ LibraryScanHelper()

llvm::orc::LibraryScanHelper::LibraryScanHelper ( const std::vector< std::string > & SPaths,
std::shared_ptr< LibraryPathCache > LibPathCache,
std::shared_ptr< PathResolver > LibPathResolver )
inlineexplicit

Definition at line 327 of file LibraryScanner.h.

References addBasePath(), llvm::dbgs(), DEBUG_WITH_TYPE, and llvm::move().

Member Function Documentation

◆ addBasePath()

void llvm::orc::LibraryScanHelper::addBasePath ( const std::string & P,
PathType Kind = PathType::Unknown )

Definition at line 662 of file LibraryScanner.cpp.

References llvm::dbgs(), and LLVM_DEBUG.

Referenced by LibraryScanHelper().

◆ getAllUnits()

std::vector< std::shared_ptr< LibrarySearchPath > > llvm::orc::LibraryScanHelper::getAllUnits ( ) const

Definition at line 752 of file LibraryScanner.cpp.

References _, and llvm::orc::Result.

◆ getCache()

LibraryPathCache & llvm::orc::LibraryScanHelper::getCache ( ) const
inline

Definition at line 361 of file LibraryScanner.h.

◆ getNextBatch()

std::vector< std::shared_ptr< LibrarySearchPath > > llvm::orc::LibraryScanHelper::getNextBatch ( PathType Kind,
size_t batchSize )

◆ getPathResolver()

PathResolver & llvm::orc::LibraryScanHelper::getPathResolver ( ) const
inline

Definition at line 359 of file LibraryScanner.h.

◆ getSearchPaths()

SmallVector< StringRef > llvm::orc::LibraryScanHelper::getSearchPaths ( ) const
inline

Definition at line 352 of file LibraryScanner.h.

References _, and llvm::SmallVectorTemplateBase< T, bool >::push_back().

◆ hasSeenOrMark()

bool llvm::orc::LibraryScanHelper::hasSeenOrMark ( StringRef P) const
inline

Definition at line 363 of file LibraryScanner.h.

References P.

◆ isTrackedBasePath()

bool llvm::orc::LibraryScanHelper::isTrackedBasePath ( StringRef P) const

Definition at line 716 of file LibraryScanner.cpp.

◆ leftToScan()

bool llvm::orc::LibraryScanHelper::leftToScan ( PathType K) const

Definition at line 726 of file LibraryScanner.cpp.

References llvm::orc::NotScanned.

◆ resetToScan()

void llvm::orc::LibraryScanHelper::resetToScan ( )

◆ resolve()

std::optional< std::string > llvm::orc::LibraryScanHelper::resolve ( StringRef P,
std::error_code & ec ) const
inline

Definition at line 367 of file LibraryScanner.h.

References P.


The documentation for this class was generated from the following files: