summaryrefslogtreecommitdiff
path: root/tools/llvm-lto/llvm-lto.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2017-12-24 01:00:08 +0000
committerDimitry Andric <dim@FreeBSD.org>2017-12-24 01:00:08 +0000
commitc7dac04c3480f3c20487f912f77343139fce2d99 (patch)
tree21a09bce0171e27bd1e92649db9df797fa097cea /tools/llvm-lto/llvm-lto.cpp
parent044eb2f6afba375a914ac9d8024f8f5142bb912e (diff)
Diffstat (limited to 'tools/llvm-lto/llvm-lto.cpp')
-rw-r--r--tools/llvm-lto/llvm-lto.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/llvm-lto/llvm-lto.cpp b/tools/llvm-lto/llvm-lto.cpp
index 20c6813968be2..7d71a3e8dfe3b 100644
--- a/tools/llvm-lto/llvm-lto.cpp
+++ b/tools/llvm-lto/llvm-lto.cpp
@@ -156,6 +156,9 @@ static cl::opt<std::string> ThinLTOModuleId(
static cl::opt<std::string>
ThinLTOCacheDir("thinlto-cache-dir", cl::desc("Enable ThinLTO caching."));
+static cl::opt<int>
+ ThinLTOCachePruningInterval("thinlto-cache-pruning-interval", cl::desc("Set ThinLTO cache pruning interval."));
+
static cl::opt<std::string> ThinLTOSaveTempsPrefix(
"thinlto-save-temps",
cl::desc("Save ThinLTO temp files using filenames created by adding "
@@ -470,6 +473,7 @@ public:
ThinGenerator.setCodePICModel(getRelocModel());
ThinGenerator.setTargetOptions(Options);
ThinGenerator.setCacheDir(ThinLTOCacheDir);
+ ThinGenerator.setCachePruningInterval(ThinLTOCachePruningInterval);
ThinGenerator.setFreestanding(EnableFreestanding);
// Add all the exported symbols to the table of symbols to preserve.