From 82324fcff55f2c333dede0212ed18ad90a191def Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Storsj=C3=B6?= Date: Mon, 29 Apr 2019 13:04:10 +0300 Subject: [PATCH] run-tests: Build optimized versions of the exception handling tests Exception handling codegen can be greatly affected by optimization. --- run-tests.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/run-tests.sh b/run-tests.sh index 133cbb8..9ad6833 100755 --- a/run-tests.sh +++ b/run-tests.sh @@ -94,8 +94,13 @@ for arch in $ARCHS; do for test in $TESTS_CPP $TESTS_CPP_EXCEPTIONS; do $arch-w64-$target_os-clang++ $test.cpp -o $TEST_DIR/$test.exe done + for test in $TESTS_CPP_EXCEPTIONS; do + $arch-w64-$target_os-clang++ $test.cpp -O2 -o $TEST_DIR/$test-opt.exe + done if [ "$arch" != "aarch64" ] || [ -n "$NATIVE_AARCH64" ]; then - TESTS_EXTRA="$TESTS_EXTRA $TESTS_CPP_EXCEPTIONS" + for test in $TESTS_CPP_EXCEPTIONS; do + TESTS_EXTRA="$TESTS_EXTRA $test $test-opt" + done fi for test in $TESTS_CPP_LOAD_DLL; do case $target_os in