#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <vector>
#include <chrono>
#include <iostream>
#include <fstream>
#include <stdarg.h>
#include "libs/json.hpp"
Go to the source code of this file.
|
void | printf_debug (const char *fmt,...) |
|
void | cpu_test (json &results, int repetition=REP) |
|
template<int N, int M> |
void | cpu_test_r (json &results, int(&arr)[M], int(&sizes)[N], int repetition=REP) |
|
template<int N, int M> |
void | cpu_test_w (json &results, int(&arr)[M], int(&sizes)[N], int repetition=REP) |
|
template<int N, int M> |
void | cpu_test_rw (json &results, int(&arr)[M], int(&sizes)[N], int repetition=REP) |
|
template<int N> |
void | io_test_rw (json &results, int(&sizes)[N], int file_size, const int buffer_size=1 *MB) |
|
void | io_test_many (json &results, int no_files=KILO) |
|
int | main (int argc, char *argv[]) |
|
◆ ARR_SIZE
#define ARR_SIZE (MB * 100) |
◆ CHAR_SIZE
#define CHAR_SIZE sizeof(char) |
◆ GIGA
◆ INT_SIZE
#define INT_SIZE sizeof(int) |
◆ KB
◆ KILO
◆ MB
◆ MEGA
◆ MICRO
◆ MILI
◆ NANO
◆ OFFSET
◆ REP
◆ SHOW_DETAILS
#define SHOW_DETAILS true |
◆ SHOW_DURATION
#define SHOW_DURATION true |
◆ json
◆ cpu_test()
void cpu_test |
( |
json & |
results, |
|
|
int |
repetition = REP |
|
) |
| |
◆ cpu_test_r()
template<int N, int M>
void cpu_test_r |
( |
json & |
results, |
|
|
int(&) |
arr[M], |
|
|
int(&) |
sizes[N], |
|
|
int |
repetition = REP |
|
) |
| |
◆ cpu_test_rw()
template<int N, int M>
void cpu_test_rw |
( |
json & |
results, |
|
|
int(&) |
arr[M], |
|
|
int(&) |
sizes[N], |
|
|
int |
repetition = REP |
|
) |
| |
◆ cpu_test_w()
template<int N, int M>
void cpu_test_w |
( |
json & |
results, |
|
|
int(&) |
arr[M], |
|
|
int(&) |
sizes[N], |
|
|
int |
repetition = REP |
|
) |
| |
◆ io_test_many()
void io_test_many |
( |
json & |
results, |
|
|
int |
no_files = KILO |
|
) |
| |
◆ io_test_rw()
template<int N>
void io_test_rw |
( |
json & |
results, |
|
|
int(&) |
sizes[N], |
|
|
int |
file_size, |
|
|
const int |
buffer_size = 1 * MB |
|
) |
| |
◆ main()
int main |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
Start benchmark, usage: optional <output> file: will create json file output with results optional <scale> float: scales repetition count for benchmark default is 1, for example value 2 will run tests twice as many times, value 0.5 will experiments half as many times
Definition at line 335 of file memory.cc.
◆ printf_debug()
void printf_debug |
( |
const char * |
fmt, |
|
|
|
... |
|
) |
| |