2015-09-21 21:48:40 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
|
|
|
rootdir=$(readlink -f $(dirname $0))
|
|
|
|
source "$rootdir/scripts/autotest_common.sh"
|
|
|
|
|
|
|
|
set -xe
|
|
|
|
|
|
|
|
if [ $EUID -ne 0 ]; then
|
|
|
|
echo "$0 must be run as root"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2015-10-03 00:11:56 +00:00
|
|
|
trap "process_core; $rootdir/scripts/cleanup.sh; exit 1" SIGINT SIGTERM EXIT
|
2015-09-25 16:48:11 +00:00
|
|
|
|
2015-09-21 21:48:40 +00:00
|
|
|
timing_enter autotest
|
|
|
|
|
|
|
|
src=$(readlink -f $(dirname $0))
|
|
|
|
out=$PWD
|
|
|
|
cd $src
|
|
|
|
|
|
|
|
# set up huge pages
|
|
|
|
timing_enter afterboot
|
|
|
|
./scripts/configure_hugepages.sh 3072
|
|
|
|
timing_exit afterboot
|
|
|
|
|
2015-10-08 18:05:17 +00:00
|
|
|
./scripts/unbind_nvme.sh
|
2015-09-21 21:48:40 +00:00
|
|
|
|
|
|
|
#####################
|
|
|
|
# Unit Tests
|
|
|
|
#####################
|
|
|
|
|
|
|
|
timing_enter lib
|
|
|
|
|
|
|
|
time test/lib/nvme/nvme.sh
|
|
|
|
time test/lib/memory/memory.sh
|
|
|
|
|
|
|
|
timing_exit lib
|
|
|
|
|
2015-10-03 00:11:56 +00:00
|
|
|
./scripts/cleanup.sh
|
2015-09-21 21:48:40 +00:00
|
|
|
|
|
|
|
timing_exit autotest
|
|
|
|
chmod a+r $output_dir/timing.txt
|
|
|
|
|
2015-09-25 16:48:11 +00:00
|
|
|
trap - SIGINT SIGTERM EXIT
|
|
|
|
|
2015-09-21 21:48:40 +00:00
|
|
|
# catch any stray core files
|
|
|
|
process_core
|