perf: overflow test

Change-Id: Ic7aa0d99ae9a5b7d3ce4436129a360275e6937ca
refs: #1358
This commit is contained in:
TOIDA,Suguru
2019-12-16 13:35:52 +09:00
parent 305511b48f
commit 1a204b6674
18 changed files with 907 additions and 0 deletions

37
test/perf_overflow/run.sh Normal file
View File

@ -0,0 +1,37 @@
#!/bin/env bash
# run.sh COPYRIGHT FUJITSU LIMITED 2019
test_dir=$(dirname "${BASH_SOURCE[0]}")
result_dir="$test_dir/results"
# read config
. "${test_dir}/../common.sh"
# settings
test_bin="$test_dir/perf_overflow"
test_cases=`cat << __EOF__
000 1
001 2
002 3
003 4
010 5 -c READ,RESET,REFRESH
011 5 -c READ,READ,REFRESH
012 5 -c RESET,RESET,READ
013 5 -c REFRESH,REFRESH,RESET
014 5 -c REFRESH,READ,READ
__EOF__`
mkdir -p "$result_dir"
while read num args
do
"$test_bin" $args > "$result_dir/${num}.host"
"${MCEXEC}" 0 "$test_bin" $args > "$result_dir/${num}.mck"
diff -q "$result_dir/${num}.host" "$result_dir/${num}.mck"
if [ $? -eq 0 ]; then
echo "$num: OK"
else
echo "$num: NG"
fi
done <<EOF
$test_cases
EOF