Add DEPRECATED warning on `--xml-only` and `--xml-output`.
This commit is contained in:
parent
29b439b93f
commit
48effad448
1
Changes
1
Changes
|
@ -24,6 +24,7 @@ Verilator 5.035 devel
|
|||
* Add used language to `--preproc-resolve` output (#5795). [Kamil Rakoczy, Antmicro Ltd.]
|
||||
* Add `--make json` to enable integration with non-make/cmake build systems (#5799). [Andrew Voznytsa]
|
||||
* Add empty veriuser.h for legacy compatibility.
|
||||
* Add DEPRECATED warning on `--xml-only` and `--xml-output`.
|
||||
* Remove unused gtkwave/wavealloca.h. [Geza Lore]
|
||||
* Optimize automatic splitting of some packed variables (#5843). [Geza Lore]
|
||||
* Optimize trigger vector in whole words (#5857). [Geza Lore]
|
||||
|
|
|
@ -1815,8 +1815,14 @@ void V3Options::parseOptsList(FileLine* fl, const string& optdir, int argc,
|
|||
}
|
||||
});
|
||||
DECL_OPTION("-x-initial-edge", OnOff, &m_xInitialEdge);
|
||||
DECL_OPTION("-xml-only", OnOff, &m_xmlOnly);
|
||||
DECL_OPTION("-xml-output", CbVal, [this](const char* valp) {
|
||||
DECL_OPTION("-xml-only", CbOnOff, [this, fl](bool flag) {
|
||||
if (!m_xmlOnly && flag)
|
||||
fl->v3warn(DEPRECATED, "Option --xml-only is deprecated, move to --json-only");
|
||||
m_xmlOnly = flag;
|
||||
});
|
||||
DECL_OPTION("-xml-output", CbVal, [this, fl](const char* valp) {
|
||||
if (!m_xmlOnly)
|
||||
fl->v3warn(DEPRECATED, "Option --xml-only is deprecated, move to --json-only");
|
||||
m_xmlOutput = valp;
|
||||
m_xmlOnly = true;
|
||||
});
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only', '-Wno-CONSTRAINTIGN'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only', '-Wno-CONSTRAINTIGN'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -12,7 +12,9 @@ import vltest_bootstrap
|
|||
test.scenarios('vlt')
|
||||
test.top_filename = "t/t_flag_main.v"
|
||||
|
||||
test.lint(verilator_flags2=["--binary -E --dpi-hdr-only --lint-only --xml-only --json-only -Wall"],
|
||||
test.lint(verilator_flags2=[
|
||||
"-Wno-DEPRECATED --binary -E --dpi-hdr-only --lint-only --xml-only --json-only -Wall"
|
||||
],
|
||||
fails=True,
|
||||
expect_filename=test.golden_filename)
|
||||
|
||||
|
|
|
@ -12,9 +12,10 @@ import vltest_bootstrap
|
|||
test.scenarios('vlt')
|
||||
test.top_filename = "t/t_flag_main.v"
|
||||
|
||||
test.lint(
|
||||
verilator_flags2=["--build -E -Wno-fatal --dpi-hdr-only --lint-only --xml-only --json-only"],
|
||||
fails=True,
|
||||
expect_filename=test.golden_filename)
|
||||
test.lint(verilator_flags2=[
|
||||
"-Wno-DEPRECATED --build -E -Wno-fatal --dpi-hdr-only --lint-only --xml-only --json-only"
|
||||
],
|
||||
fails=True,
|
||||
expect_filename=test.golden_filename)
|
||||
|
||||
test.passes()
|
||||
|
|
|
@ -12,7 +12,9 @@ import vltest_bootstrap
|
|||
test.scenarios('vlt')
|
||||
test.top_filename = "t/t_flag_main.v"
|
||||
|
||||
test.lint(verilator_flags2=["-Wall --lint-only -Wno-fatal --dpi-hdr-only --xml-only --json-only"],
|
||||
test.lint(verilator_flags2=[
|
||||
"-Wall -Wno-DEPRECATED --lint-only -Wno-fatal --dpi-hdr-only --xml-only --json-only"
|
||||
],
|
||||
fails=True,
|
||||
expect_filename=test.golden_filename)
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
%Warning-DEPRECATED: Option --xml-only is deprecated, move to --json-only
|
||||
... For warning description see https://verilator.org/warn/DEPRECATED?v=latest
|
||||
... Use "/* verilator lint_off DEPRECATED */" and lint_on around source to disable this message.
|
||||
%Error: Exiting due to
|
|
@ -0,0 +1,19 @@
|
|||
#!/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_EXAMPLE.v'
|
||||
|
||||
test.lint(verilator_flags2=["--xml-only --xml-output /dev/null"],
|
||||
fails=True,
|
||||
expect_filename=test.golden_filename)
|
||||
|
||||
test.passes()
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -14,7 +14,7 @@ test.top_filename = "t/t_xml_first.v"
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only', '--flatten'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only', '--flatten'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only', '--flatten'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only', '--flatten'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only', '--flatten'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only', '--flatten'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only', '--flatten'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only', '--flatten'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
|
@ -13,10 +13,11 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/renamed-" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=["--no-std", "--xml-only --xml-output", out_filename],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
test.compile(
|
||||
verilator_flags2=["--no-std", "-Wno-DEPRECATED --xml-only --xml-output", out_filename],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
||||
test.files_identical(out_filename, test.golden_filename)
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ test.scenarios('vlt')
|
|||
|
||||
out_filename = test.obj_dir + "/V" + test.name + ".xml"
|
||||
|
||||
test.compile(verilator_flags2=['--no-std', '--xml-only'],
|
||||
test.compile(verilator_flags2=['--no-std', '-Wno-DEPRECATED --xml-only'],
|
||||
verilator_make_gmake=False,
|
||||
make_top_shell=False,
|
||||
make_main=False)
|
||||
|
|
Loading…
Reference in New Issue