Add error on --savable --timing (#5690).

This commit is contained in:
Wilson Snyder 2024-12-19 17:30:40 -05:00
parent 62945bb3bc
commit bb45fd6c6c
4 changed files with 26 additions and 0 deletions

View File

@ -31,6 +31,7 @@ Verilator 5.031 devel
* Add error on `wait` with missing `.triggered` (#4457).
* Add error when improperly storing to parameter (#5147). [Gökçe Aydos]
* Add error on illegal `--prefix` etc. values (#5507). [Fabian Keßler]
* Add error on `--savable --timing` (#5690). [Narcis Rodas]
* Add coverage point hierarchy to coverage reports (#5575) (#5576). [Andrew Nolte]
* Add warning on global constraints (#5625). [Ryszard Rozak, Antmicro Ltd.]
* Add default CMAKE_BUILD_TYPE (#5691) (#5692). [Anthony Moore]

View File

@ -949,6 +949,9 @@ void V3Options::notify() VL_MT_DISABLED {
if (coverage() && savable()) {
cmdfl->v3error("Unsupported: --coverage and --savable not supported together");
}
if (v3Global.opt.timing().isSetTrue() && savable()) {
cmdfl->v3error("Unsupported: --timing and --savable not supported together");
}
// Mark options as available
m_available = true;

View File

@ -0,0 +1,2 @@
%Error: Unsupported: --timing and --savable not supported together
%Error: Exiting due to

View File

@ -0,0 +1,20 @@
#!/usr/bin/env python3
# DESCRIPTION: Verilator: Verilog Test driver/expect definition
#
# Copyright 2024 by Wilson Snyder. This program is free software; you
# can redistribute it and/or modify it under the terms of either the GNU
# Lesser General Public License Version 3 or the Perl Artistic License
# Version 2.0.
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
import vltest_bootstrap
test.scenarios('vlt')
test.top_filename = "t/t_savable_coverage_bad.v"
test.compile(v_flags2=["--savable --timing"],
save_time=500,
fails=True,
expect_filename=test.golden_filename)
test.passes()