From 6a5c643aaff9e8fe776ae71dda72c4611cb52c61 Mon Sep 17 00:00:00 2001 From: Jiawei_Tang Date: Mon, 11 Dec 2023 16:08:51 +0800 Subject: [PATCH] [Wisp] only test c1 assertion failure in slowdebug mode Summary: Determine the java mode before run normal logics. If java is release or fastdebug, just go to the ending early. Testing: hotspot/test/runtime/coroutine/c1AssertFailTest.sh Reviwers: lingjun-cg, yulei Issue: https://github.com/dragonwell-project/dragonwell8/issues/605 --- .../test/runtime/coroutine/c1AssertFailTest.sh | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/hotspot/test/runtime/coroutine/c1AssertFailTest.sh b/hotspot/test/runtime/coroutine/c1AssertFailTest.sh index 316c797745d..9a9ace87427 100644 --- a/hotspot/test/runtime/coroutine/c1AssertFailTest.sh +++ b/hotspot/test/runtime/coroutine/c1AssertFailTest.sh @@ -27,8 +27,22 @@ ## @requires os.family == "linux" ## @run shell c1AssertFailTest.sh - -${TESTJAVA}/bin/java -Xcomp -XX:-UseBiasedLocking -XX:+UnlockExperimentalVMOptions -XX:+EnableCoroutine -XX:+UseWispMonitor -Dcom.alibaba.transparentAsync=true & +set -x +version=`${TESTJAVA}/bin/java -version 2>&1` +fastdebug=`echo ${version} | grep "fastdebug"` +# fastdebug mode +if [ "$fastdebug" != "" ];then + echo "fastdebug mode" + exit 0 +fi +debug=`echo ${version} | grep "debug"` +# release mode +if [ "$debug" = "" ];then + echo "release mode" + exit 0 +fi +# slowdebug mode +time ${TESTJAVA}/bin/java -Xcomp -XX:TieredStopAtLevel=1 -XX:-UseBiasedLocking -XX:+UnlockExperimentalVMOptions -XX:+EnableCoroutine -XX:+UseWispMonitor -Dcom.alibaba.transparentAsync=true & PID=$!