mirror of
https://github.com/zama-ai/concrete.git
synced 2026-04-17 03:00:54 -04:00
feat(compiler): Output client parameters when compile to a library
close #198
This commit is contained in:
36
compiler/include/concretelang/ClientLib/KeySetCache.h
Normal file
36
compiler/include/concretelang/ClientLib/KeySetCache.h
Normal file
@@ -0,0 +1,36 @@
|
||||
// Part of the Concrete Compiler Project, under the BSD3 License with Zama
|
||||
// Exceptions. See
|
||||
// https://github.com/zama-ai/homomorphizer/blob/master/LICENSE.txt for license
|
||||
// information.
|
||||
|
||||
#ifndef CONCRETELANG_SUPPORT_KEYSETCACHE_H_
|
||||
#define CONCRETELANG_SUPPORT_KEYSETCACHE_H_
|
||||
|
||||
#include "concretelang/ClientLib/KeySet.h"
|
||||
|
||||
namespace mlir {
|
||||
namespace concretelang {
|
||||
|
||||
class KeySet;
|
||||
|
||||
class KeySetCache {
|
||||
std::string backingDirectoryPath;
|
||||
|
||||
public:
|
||||
KeySetCache(std::string backingDirectoryPath)
|
||||
: backingDirectoryPath(backingDirectoryPath) {}
|
||||
|
||||
llvm::Expected<std::unique_ptr<KeySet>>
|
||||
tryLoadOrGenerateSave(ClientParameters ¶ms, uint64_t seed_msb,
|
||||
uint64_t seed_lsb);
|
||||
|
||||
private:
|
||||
static llvm::Expected<std::unique_ptr<KeySet>>
|
||||
tryLoadKeys(ClientParameters ¶ms, uint64_t seed_msb, uint64_t seed_lsb,
|
||||
llvm::SmallString<0> &folderPath);
|
||||
};
|
||||
|
||||
} // namespace concretelang
|
||||
} // namespace mlir
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user