19 std::shared_ptr<ondisk::UnifiedOnDiskCache> UniDB;
24 return std::make_pair(std::move(CAS), std::move(AC));
29 bool ForceValidation) {
30#if LLVM_ENABLE_ONDISK_CAS
42#if LLVM_ENABLE_ONDISK_CAS
This file contains the declaration of the ActionCache class, which is the base class for ActionCache ...
Lightweight error class with error context and mandatory checking.
Tagged union holding either a T or a Error.
Represent a constant reference to a string, i.e.
static StringRef getHashName()
Get the name of the hash for any table identifiers.
static LLVM_ABI Expected< ValidationResult > recover(StringRef Path)
Recover from invalid data in Path after a failed validateIfNeeded, by marking all the data for garbag...
static LLVM_ABI Expected< ValidationResult > validateIfNeeded(StringRef Path, StringRef HashName, unsigned HashByteSize, bool CheckHash, OnDiskGraphDB::HashingFuncT HashFn, bool ForceValidation)
Validate the data in Path in-process, if it has not been validated since the last system boot.
std::unique_ptr< ObjectStore > createObjectStoreFromUnifiedOnDiskCache(std::shared_ptr< ondisk::UnifiedOnDiskCache > UniDB)
void hashingFunc(ArrayRef< ArrayRef< uint8_t > > Refs, ArrayRef< char > Data, SmallVectorImpl< uint8_t > &Result)
Convenience wrapper for BuiltinObjectHasher.
decltype(HasherT::hash(std::declval< ArrayRef< uint8_t > & >())) HashType
std::unique_ptr< ActionCache > createActionCacheFromUnifiedOnDiskCache(std::shared_ptr< ondisk::UnifiedOnDiskCache > UniDB)
Expected< std::unique_ptr< ondisk::UnifiedOnDiskCache > > createBuiltinUnifiedOnDiskCache(StringRef Path)
Create a UnifiedOnDiskCache instance that uses BLAKE3 hashing.
LLVM_ABI Expected< std::pair< std::unique_ptr< ObjectStore >, std::unique_ptr< ActionCache > > > createOnDiskUnifiedCASDatabases(StringRef Path)
Create on-disk ObjectStore and ActionCache instances based on ondisk::UnifiedOnDiskCache,...
LLVM_ABI Expected< ValidationResult > recoverOnDiskUnifiedCASDatabases(StringRef Path)
Recover the builtin on-disk CAS in Path after a failed validation.
LLVM_ABI Expected< ValidationResult > validateOnDiskUnifiedCASDatabasesIfNeeded(StringRef Path, bool CheckHash, bool ForceValidation)
Validate the builtin on-disk CAS in Path in-process, if needed.
This is an optimization pass for GlobalISel generic memory operations.
LLVM_ABI std::error_code inconvertibleErrorCode()
The value returned by this function can be returned from convertToErrorCode for Error values where no...
Error createStringError(std::error_code EC, char const *Fmt, const Ts &... Vals)
Create formatted StringError object.