Pārlūkot izejas kodu

SCRIPTS: Added script for the timing of the benchmarks

Added a first draft of the script that we'll invoke for measuring the
execution time of the benchmarks and storing it in a file passed as
parameter
Andrea Gussoni 8 gadi atpakaļ
vecāks
revīzija
b901644fe6
2 mainītis faili ar 12 papildinājumiem un 1 dzēšanām
  1. 2 1
      utils/deploy.sh
  2. 10 0
      utils/time-and-save.sh

+ 2 - 1
utils/deploy.sh

@@ -30,8 +30,9 @@ fi
 
 # Compile the runtime
 cd $RUNTIME_DIR/build
-make
+make clean
 cmake -DLLC_HOST_CPU=cortex-a15 ../
+make clean
 make -j8
 
 # Add the .icd file that enable the ocl-icd loader to identify the mali platform

+ 10 - 0
utils/time-and-save.sh

@@ -0,0 +1,10 @@
+#!/bin/bash
+
+# Save path the current path that will be used to store the results.
+BASE_PATH=$(pwd)
+
+# Enter in the directory passed as first parameter, then execute run and save the results in the file passed as second parameter
+cd $1
+BENCH_NAME=$1
+BENCH_TIME=`(/usr/bin/time -f "%e" ./run) 2>&1 > /dev/null | tail -1`
+echo "$BENCH_NAME $BENCH_TIME" >> $BASE_PATH/$2