From 6bcbd09a6b96dc330820866d06cbd0ef8732e5cb Mon Sep 17 00:00:00 2001 From: Wade Fife Date: Mon, 3 Mar 2025 11:10:06 -0600 Subject: [PATCH] fpga: tools: Change -onfinish to final This changes the -onfinish setting from "stop" to "final" for Questa and ModelSim. The "final" setting is required so that SystemVerilog final blocks run. This also has the same effect as "stop" in that it won't ask you in the GUI if you want to exit the simulator when $finish() is called. Original-commit: 7ab4e9a4e2c0408ca595ad168199a54bf416c894 --- tools/scripts/launch_modelsim.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/scripts/launch_modelsim.sh b/tools/scripts/launch_modelsim.sh index a240d13..28180b6 100755 --- a/tools/scripts/launch_modelsim.sh +++ b/tools/scripts/launch_modelsim.sh @@ -45,10 +45,10 @@ function print_color { SCRIPT_DIR=$(dirname "$(realpath "$0")") -# Setting -onfinish to "stop" prevents the simulator from immediately trying to -# exit when finish() is called. This is annoying in the GUI and important for -# error detection in batch mode. -MSIM_DEFAULT="-quiet -L unisims_ver -onfinish stop" +# Setting -onfinish to "final" ensures final blocks run and prevents the +# simulator from trying to exit immediately when $finish() is called, which is +# not desirable in the GUI. +MSIM_DEFAULT="-quiet -L unisims_ver -onfinish final" # Use specified modelsim.ini, if set if [[ -z $MSIM_MODELSIM_INI ]]; then