aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/run-legup.sh
diff options
context:
space:
mode:
authorYann Herklotz <git@yannherklotz.com>2021-09-18 14:40:45 +0100
committerYann Herklotz <git@yannherklotz.com>2021-09-18 14:40:45 +0100
commitb666f88219893c82361606f8652297ecc7fb7a9f (patch)
tree946c2ddb5ce21b7af24ce6945fe5f83cbb274061 /scripts/run-legup.sh
parentc4d44af5f3135aba4d4878f8f41c80d1f0b9e9a2 (diff)
parentc4436c02648502c4cb327d2018229e62a2c0d1c0 (diff)
downloadvericert-b666f88219893c82361606f8652297ecc7fb7a9f.tar.gz
vericert-b666f88219893c82361606f8652297ecc7fb7a9f.zip
Merge branch 'master' into develop
Diffstat (limited to 'scripts/run-legup.sh')
-rw-r--r--scripts/run-legup.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/scripts/run-legup.sh b/scripts/run-legup.sh
new file mode 100644
index 0000000..3b6f60f
--- /dev/null
+++ b/scripts/run-legup.sh
@@ -0,0 +1,17 @@
+#!/usr/bin/env bash
+
+top=$(pwd)
+vericert=/vericert
+rm $top/exec_legup.csv
+legup_dir=/data/legup-polybench-$1/legup/legup_$2
+
+echo benchmark,cycles >$top/exec_legup.csv
+
+while read benchmark ; do
+ echo -n "compiling $(basename "$benchmark"): "
+ cd $legup_dir/$benchmark
+ iverilog -o run -s main_tb $vericert/ip/* legup.v
+ cycles=$(./run | sed -n 3p | sed -E -e 's/[^0-9]+([0-9]+)/\1/')
+ echo "$(basename "$benchmark"),$cycles" >>$top/exec_legup.csv
+ echo $cycles cycles
+done < benchmark-list-master