summaryrefslogtreecommitdiffstats
path: root/searchlib/src/apps/docstore
diff options
context:
space:
mode:
authorArne Juul <arnej@verizonmedia.com>2021-02-15 13:54:49 +0000
committerArne Juul <arnej@verizonmedia.com>2021-02-15 14:16:21 +0000
commit805a313df05d2f347af321511527e06ea3cae92c (patch)
tree7e06fbd1c2d5ababf3d219ddb6c4b0cf9525aea9 /searchlib/src/apps/docstore
parentc0b8734987176a93588909739af143c6b0a1a6ff (diff)
use size literals in searchlib
Diffstat (limited to 'searchlib/src/apps/docstore')
-rw-r--r--searchlib/src/apps/docstore/benchmarkdatastore.cpp9
-rw-r--r--searchlib/src/apps/docstore/documentstoreinspect.cpp3
-rw-r--r--searchlib/src/apps/docstore/verifylogdatastore.cpp3
3 files changed, 9 insertions, 6 deletions
diff --git a/searchlib/src/apps/docstore/benchmarkdatastore.cpp b/searchlib/src/apps/docstore/benchmarkdatastore.cpp
index 4c0ac937bfd..20f06a087f5 100644
--- a/searchlib/src/apps/docstore/benchmarkdatastore.cpp
+++ b/searchlib/src/apps/docstore/benchmarkdatastore.cpp
@@ -2,10 +2,11 @@
#include <vespa/searchlib/docstore/logdatastore.h>
#include <vespa/searchlib/index/dummyfileheadercontext.h>
-#include <vespa/vespalib/util/lambdatask.h>
#include <vespa/searchlib/transactionlog/nosyncproxy.h>
-#include <vespa/vespalib/util/threadstackexecutor.h>
#include <vespa/vespalib/data/databuffer.h>
+#include <vespa/vespalib/util/lambdatask.h>
+#include <vespa/vespalib/util/size_literals.h>
+#include <vespa/vespalib/util/threadstackexecutor.h>
#include <vespa/fastos/app.h>
#include <unistd.h>
#include <random>
@@ -95,12 +96,12 @@ BenchmarkDataStoreApp::benchmark(const vespalib::string & dir, size_t numReads,
tuning._randRead.setWantMemoryMap();
}
search::index::DummyFileHeaderContext fileHeaderContext;
- vespalib::ThreadStackExecutor executor(1, 128*1024);
+ vespalib::ThreadStackExecutor executor(1, 128_Ki);
transactionlog::NoSyncProxy noTlSyncer;
LogDataStore store(executor, dir, config, growStrategy, tuning,
fileHeaderContext,
noTlSyncer, NULL, true);
- vespalib::ThreadStackExecutor bmPool(numThreads, 128*1024);
+ vespalib::ThreadStackExecutor bmPool(numThreads, 128_Ki);
LOG(info, "Start read benchmark with %lu threads doing %lu reads in chunks of %lu reads. Totally %lu objects", numThreads, numReads, perChunk, numThreads * numReads * perChunk);
for (size_t i(0); i < numThreads; i++) {
bmPool.execute(vespalib::makeLambdaTask([&]() { read(numReads, perChunk, static_cast<const IDataStore *>(&store)); }));
diff --git a/searchlib/src/apps/docstore/documentstoreinspect.cpp b/searchlib/src/apps/docstore/documentstoreinspect.cpp
index 8a3bb6b247b..8acc2312d46 100644
--- a/searchlib/src/apps/docstore/documentstoreinspect.cpp
+++ b/searchlib/src/apps/docstore/documentstoreinspect.cpp
@@ -5,6 +5,7 @@
#include <vespa/searchlib/transactionlog/nosyncproxy.h>
#include <vespa/fastos/app.h>
#include <vespa/vespalib/objects/nbostream.h>
+#include <vespa/vespalib/util/size_literals.h>
#include <vespa/vespalib/util/threadstackexecutor.h>
#include <cinttypes>
@@ -106,7 +107,7 @@ DocumentStoreInspectApp::verify(const vespalib::string & dir)
GrowStrategy growStrategy;
TuneFileSummary tuning;
search::index::DummyFileHeaderContext fileHeaderContext;
- vespalib::ThreadStackExecutor executor(1, 128*1024);
+ vespalib::ThreadStackExecutor executor(1, 128_Ki);
transactionlog::NoSyncProxy noTlSyncer;
LogDataStore store(executor, dir, config, growStrategy, tuning,
diff --git a/searchlib/src/apps/docstore/verifylogdatastore.cpp b/searchlib/src/apps/docstore/verifylogdatastore.cpp
index 498516882c1..c148f12f9ee 100644
--- a/searchlib/src/apps/docstore/verifylogdatastore.cpp
+++ b/searchlib/src/apps/docstore/verifylogdatastore.cpp
@@ -6,6 +6,7 @@
#include <vespa/searchlib/transactionlog/nosyncproxy.h>
#include <vespa/fastos/app.h>
#include <vespa/vespalib/util/exception.h>
+#include <vespa/vespalib/util/size_literals.h>
#include <vespa/vespalib/util/threadstackexecutor.h>
using namespace search;
@@ -49,7 +50,7 @@ VerifyLogDataStoreApp::verify(const vespalib::string & dir)
GrowStrategy growStrategy;
TuneFileSummary tuning;
search::index::DummyFileHeaderContext fileHeaderContext;
- vespalib::ThreadStackExecutor executor(1, 128*1024);
+ vespalib::ThreadStackExecutor executor(1, 128_Ki);
transactionlog::NoSyncProxy noTlSyncer;
try {