From 107c470356e76dff780c5cf197a376d5667097b8 Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Wed, 15 May 2019 15:31:20 +0200 Subject: CSV file generation for benches (only binary_search for now) --- test/monniaux/build_benches.sh | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 test/monniaux/build_benches.sh (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh new file mode 100755 index 00000000..02123665 --- /dev/null +++ b/test/monniaux/build_benches.sh @@ -0,0 +1,9 @@ + +source benches.sh + +rm -f commands.txt +for bench in $benches; do + echo "(cd $bench && make -j5 $1)" >> commands.txt +done + +cat commands.txt | xargs -n1 -I{} -P4 bash -c '{}' -- cgit From ebf6efcadc130ada9b449fad04b19e4a3455a99d Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Wed, 29 May 2019 17:58:13 +0200 Subject: make -j20 instead of xargs -P4 + make -j5 --- test/monniaux/build_benches.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh index 02123665..5c431f74 100755 --- a/test/monniaux/build_benches.sh +++ b/test/monniaux/build_benches.sh @@ -3,7 +3,8 @@ source benches.sh rm -f commands.txt for bench in $benches; do - echo "(cd $bench && make -j5 $1)" >> commands.txt + #echo "(cd $bench && make -j5 $1)" >> commands.txt + (cd $bench && make -j20 $1) done -cat commands.txt | xargs -n1 -I{} -P4 bash -c '{}' +#cat commands.txt | xargs -n1 -I{} -P4 bash -c '{}' -- cgit From 7e65d55ddfb6b4d44efbd131b989866a3fbe21d9 Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Fri, 14 Jun 2019 11:32:24 +0200 Subject: build_benches printing compile time in compile_times.txt --- test/monniaux/build_benches.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh index 5c431f74..123f4c82 100755 --- a/test/monniaux/build_benches.sh +++ b/test/monniaux/build_benches.sh @@ -1,10 +1,13 @@ +TMPFILE=/tmp/1513times.txt source benches.sh rm -f commands.txt +rm -f $TMPFILE for bench in $benches; do #echo "(cd $bench && make -j5 $1)" >> commands.txt - (cd $bench && make -j20 $1) + (cd $bench && make -j20 $1) | grep -P "\d+: \d+\.\d+" >> $TMPFILE done +cat $TMPFILE | sort -n -k 1 > compile_times.txt #cat commands.txt | xargs -n1 -I{} -P4 bash -c '{}' -- cgit From e4e4bb635650055a94112250b71c111096f1263e Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Wed, 19 Jun 2019 11:50:31 +0200 Subject: Makefile in test/monniaux that generates the compilation time graphs --- test/monniaux/build_benches.sh | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh index 123f4c82..a8f1b1a5 100755 --- a/test/monniaux/build_benches.sh +++ b/test/monniaux/build_benches.sh @@ -1,3 +1,5 @@ +#!/usr/bin/bash + TMPFILE=/tmp/1513times.txt source benches.sh @@ -5,9 +7,14 @@ source benches.sh rm -f commands.txt rm -f $TMPFILE for bench in $benches; do - #echo "(cd $bench && make -j5 $1)" >> commands.txt - (cd $bench && make -j20 $1) | grep -P "\d+: \d+\.\d+" >> $TMPFILE + if [ "$1" == "" ]; then + (cd $bench && make -j20) + else + (cd $bench && make -j20) | grep -P "\d+: \d+\.\d+" >> $TMPFILE + fi done -cat $TMPFILE | sort -n -k 1 > compile_times.txt -#cat commands.txt | xargs -n1 -I{} -P4 bash -c '{}' +if [ "$1" != "" ]; then + cat $TMPFILE | sort -n -k 1 > $1 +fi + -- cgit From 2e5a2138b9853717f467e4cce5ab397d380bb368 Mon Sep 17 00:00:00 2001 From: David Monniaux Date: Wed, 19 Jun 2019 17:48:03 +0200 Subject: avoid problems on carlit: don't hardcode the path to bash --- test/monniaux/build_benches.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh index a8f1b1a5..931cebac 100755 --- a/test/monniaux/build_benches.sh +++ b/test/monniaux/build_benches.sh @@ -1,4 +1,4 @@ -#!/usr/bin/bash +#!/usr/bin/env bash TMPFILE=/tmp/1513times.txt -- cgit From 962c8f9935b257c1df6bddfc88ec41d4822f65c3 Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Wed, 13 Nov 2019 11:55:18 +0100 Subject: Removing clutter from building + running benches --- test/monniaux/build_benches.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh index 931cebac..a749779d 100755 --- a/test/monniaux/build_benches.sh +++ b/test/monniaux/build_benches.sh @@ -4,11 +4,16 @@ TMPFILE=/tmp/1513times.txt source benches.sh +default="\e[39m" +magenta="\e[35m" +red="\e[31m" + rm -f commands.txt rm -f $TMPFILE for bench in $benches; do + echo -e "${magenta}Building $bench..${default}" if [ "$1" == "" ]; then - (cd $bench && make -j20) + (cd $bench && make -s -j20 > /dev/null &> /dev/null) || { echo -e "${red}Build failed" && break; } else (cd $bench && make -j20) | grep -P "\d+: \d+\.\d+" >> $TMPFILE fi -- cgit From 6a3a2c90c52c60f2f9cc64dddb7b953a6b804f76 Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Tue, 26 Nov 2019 17:11:17 +0100 Subject: build_benches.sh adapting to number of cores --- test/monniaux/build_benches.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'test/monniaux/build_benches.sh') diff --git a/test/monniaux/build_benches.sh b/test/monniaux/build_benches.sh index a749779d..01abf55d 100755 --- a/test/monniaux/build_benches.sh +++ b/test/monniaux/build_benches.sh @@ -2,6 +2,7 @@ TMPFILE=/tmp/1513times.txt +cores=$(grep -c ^processor /proc/cpuinfo) source benches.sh default="\e[39m" @@ -13,9 +14,9 @@ rm -f $TMPFILE for bench in $benches; do echo -e "${magenta}Building $bench..${default}" if [ "$1" == "" ]; then - (cd $bench && make -s -j20 > /dev/null &> /dev/null) || { echo -e "${red}Build failed" && break; } + (cd $bench && make -s -j$cores > /dev/null &> /dev/null) || { echo -e "${red}Build failed" && break; } else - (cd $bench && make -j20) | grep -P "\d+: \d+\.\d+" >> $TMPFILE + (cd $bench && make -j$cores) | grep -P "\d+: \d+\.\d+" >> $TMPFILE fi done -- cgit