From 1093b07670f32a7bc0f119b4d2df1e6793695887 Mon Sep 17 00:00:00 2001 From: Noah Boorstin Date: Thu, 11 Mar 2021 06:45:45 +0000 Subject: [PATCH] this is just a test for now, try to reimplement regression-wally in bash --- wally-pipelined/regression/regression-wally.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 wally-pipelined/regression/regression-wally.sh diff --git a/wally-pipelined/regression/regression-wally.sh b/wally-pipelined/regression/regression-wally.sh new file mode 100755 index 00000000..12d39418 --- /dev/null +++ b/wally-pipelined/regression/regression-wally.sh @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +check_test () { + output=$(./$1) + found=$(echo $output | grep -c "$2") + echo "$found" +} +echo "starting Imperas rv64ic" +coproc rv64 {(check_test "sim-wally-batch" "All tests ran without failures.")} +echo "starting busybear" +coproc busybear {(check_test "sim-busybear-batch" "loaded 100000 instructions")} +IFS= read -r -d '' -u "${rv64[0]}" rv64_out +[[ $rv64_out -eq 1 ]] && echo "rv64ic passed" || echo "rv64ic failed" +IFS= read -r -d '' -u "${busybear[0]}" busybear_out +[[ $busybear_out -eq 1 ]] && echo "busybear passed" || echo "busybear failed" + +#wait $(jobs -p) +[[ $rv64_out -eq 1 && $busybear_out -eq 1 ]] && echo "all passed" || echo "not all passed"