-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathMakefile
35 lines (25 loc) · 931 Bytes
/
Makefile
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
# Copyright (C) 2021 Intel Corporation
#
# SPDX-License-Identifier: Apache-2.0
.NOTPARALLEL:
export SHELL=bash
.PHONY: all
all: release test bench_fib
release:
cmake -B build -S . -DCMAKE_BUILD_TYPE=RelWithDebInfo && make -C build -j$(shell nproc)
debug:
cmake -B build_debug -S . -DCMAKE_BUILD_TYPE=Debug && make -C build_debug -j$(shell nproc)
clean:
rm -rf build build_debug
test:
cd build/; ctest
install:
make -C build install
bench_loops:
@echo ----------------------------------------------------------------------------
@echo -e "Loop_mode\tBench\tSize \tIters\tTime\tCPU\tUnit"
@echo ----------------------------------------------------------------------------
@for x in $(shell ls -1 build/benchmarks/bench_loops_*) ; do numactl -N 0 $$x --benchmark_format=csv 2>/dev/null | grep /real_time | tr /, '\t'; done
bench_fib:
numactl -N 0 build/benchmarks/bench_fib
bench: bench_fib bench_loops