LogCabin
Classes | Namespaces | Functions
Examples/Benchmark.cc File Reference

This is a basic latency/bandwidth benchmark of LogCabin. More...

#include <atomic>
#include <cassert>
#include <ctime>
#include <getopt.h>
#include <iostream>
#include <thread>
#include <unistd.h>
#include <LogCabin/Client.h>
#include <LogCabin/Debug.h>
#include <LogCabin/Util.h>

Go to the source code of this file.

Classes

class  anonymous_namespace{Benchmark.cc}::OptionParser
 Parses argv for the main function. More...

Namespaces

namespace  anonymous_namespace{Benchmark.cc}

Functions

void anonymous_namespace{Benchmark.cc}::writeThreadMain (uint64_t id, const OptionParser &options, Tree tree, const std::string &key, const std::string &value, std::atomic< bool > &exit, uint64_t &writesDone)
 The main function for a single client thread.
uint64_t anonymous_namespace{Benchmark.cc}::timeNanos ()
 Return the time since the Unix epoch in nanoseconds.
void anonymous_namespace{Benchmark.cc}::timerThreadMain (uint64_t timeout, std::atomic< bool > &exit)
 Main function for the timer thread, whose job is to wait until a particular timeout elapses and then set 'exit' to true.
int main (int argc, char **argv)

Detailed Description

This is a basic latency/bandwidth benchmark of LogCabin.

Definition in file Benchmark.cc.


Function Documentation

int main ( int  argc,
char **  argv 
)

Definition at line 269 of file Benchmark.cc.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines