-
-
Notifications
You must be signed in to change notification settings - Fork 114
/
Copy pathsetup.sh
executable file
·44 lines (36 loc) · 1.01 KB
/
setup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/sh
#
# setup.sh
#
if [ -z $DATA_DIR ]; then
echo "Please set DATA_DIR environment variable before running benchmark"
exit 1
fi
OB_DIR=@CMAKE_BINARY_DIR@/benchmarks
OB_BUILD_TYPE=@CMAKE_BUILD_TYPE@
OB_COMPILER=@CMAKE_CXX_COMPILER@
OB_COMPILER_VERSION=`$OB_COMPILER --version | head -1`
OB_CXXFLAGS="@_cxx_flags@"
OB_RUNS=3
OB_SEQ=`seq -s' ' 1 $OB_RUNS`
OB_TIME_CMD=/usr/bin/time
OB_TIME_FORMAT="%M %e %S %U %P %C"
OB_DATA_FILES=`find -L $DATA_DIR -mindepth 1 -maxdepth 1 -type f | sort`
echo "BENCHMARK: $BENCHMARK_NAME"
echo "---------------------"
echo "BUILD:"
echo "build type\t: $OB_BUILD_TYPE"
echo "compiler\t: $OB_COMPILER"
echo "CXX version\t: $OB_COMPILER_VERSION"
echo "CXX flags\t: $OB_CXXFLAGS"
echo "---------------------"
echo "CPU:"
grep '^model name' /proc/cpuinfo | tail -1
grep '^cpu MHz' /proc/cpuinfo | tail -1
grep '^cpu cores' /proc/cpuinfo | tail -1
grep '^siblings' /proc/cpuinfo | tail -1
echo "---------------------"
echo "MEMORY:"
free
echo "---------------------"
echo "RESULTS:"