From c5f28f50a0b8f796f7f1775342c5922851168459 Mon Sep 17 00:00:00 2001 From: Ondrej Ille Date: Sun, 21 Mar 2021 11:12:42 +0100 Subject: src: Move --psl-report-uncovered to run options, not analysis options. --- src/grt/grt-lib.adb | 6 ++++-- src/grt/grt-options.adb | 4 ++++ src/grt/grt-options.ads | 3 +++ 3 files changed, 11 insertions(+), 2 deletions(-) (limited to 'src/grt') diff --git a/src/grt/grt-lib.adb b/src/grt/grt-lib.adb index af3b52567..13a0f1da4 100644 --- a/src/grt/grt-lib.adb +++ b/src/grt/grt-lib.adb @@ -139,8 +139,10 @@ package body Grt.Lib is procedure Ghdl_Psl_Cover_Failed (Str : Std_String_Ptr; Severity : Integer; Loc : Ghdl_Location_Ptr) is begin - Do_Report ("psl cover failure", - Str, "sequence not covered", Severity, Loc); + if Flag_Psl_Report_Uncovered then + Do_Report ("psl cover failure", + Str, "sequence not covered", Severity, Loc); + end if; end Ghdl_Psl_Cover_Failed; procedure Ghdl_Report (Str : Std_String_Ptr; diff --git a/src/grt/grt-options.adb b/src/grt/grt-options.adb index 45336a268..bf29c1a5e 100644 --- a/src/grt/grt-options.adb +++ b/src/grt/grt-options.adb @@ -83,6 +83,8 @@ package body Grt.Options is P (" files opened in write or append mode (TEXTIO)."); P (" --read-wave-opt=FILENAME read a wave option file."); P (" --write-wave-opt=FILENAME write a wave option file."); + P (" --psl-report-uncovered Reports all uncovered PSL cover points as"); + P (" warning at the end of simulation"); -- P (" --threads=N use N threads for simulation"); P ("Additional features:"); P (" --has-feature=X test presence of feature X"); @@ -432,6 +434,8 @@ package body Grt.Options is then Wave_Opt.File.Start (Option (18 .. Option'Last), To_Be_Created => True); + elsif Option = "--psl-report-uncovered" then + Flag_Psl_Report_Uncovered := True; elsif not Grt.Hooks.Call_Option_Hooks (Option) then Error_S ("unknown run option '"); Diag_C (Option); diff --git a/src/grt/grt-options.ads b/src/grt/grt-options.ads index 03f83f485..8da4ace94 100644 --- a/src/grt/grt-options.ads +++ b/src/grt/grt-options.ads @@ -165,6 +165,9 @@ package Grt.Options is -- Set maximum dynamic stack allocation. Max_Stack_Allocation : Ghdl_Index_Type := 128 * 1024; + -- Report all uncovered cover points at the end of simulation + Flag_Psl_Report_Uncovered : Boolean := False; + -- Helper: extract time from STR (a number followed by a unit, without -- spaces; the number is optionnal). In case of error, display an error -- message and returns -1. -- cgit v1.2.3