Remove deprecated options (#4663)

This commit is contained in:
Geza Lore 2023-11-04 17:28:36 +00:00 committed by GitHub
parent 88fcbf5f1d
commit dc346b7ffa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 16 additions and 80 deletions

View File

@ -21,19 +21,3 @@ C++11 compiler support
Verilator currently regresses both 64-bit and 32-bit pointer modes (GCC's
`-m64` and `-m32`). Support for 32-bit `-m32` mode will be deprecated no
sooner than January 2024.
Option `-O<letter>`
The debug `-O<letter>` options have been replaced with
`-fno-<optimization>` debug options to match GCC. The old options are
planned for removal no sooner than June 2023.
Option `--prof-threads`
The `--prof-threads` option has been superseded by the `--prof-exec` and
`--prof-pgo` options and is planned for removal no sooner than April 2023.
Verilated model options `+verilator+prof+threads+*`
The `+verilator+prof+threads+start`, `+verilator+prof+threads+window` and
`+verilator+prof+threads+file` options have been superseded by the
`+verilator+prof+exec+start`, `+verilator+prof+exec+window` and
`+verilator+prof+exec+file` options respectively and are planned for removal
no sooner than April 2023.

View File

@ -64,15 +64,18 @@ Summary:
.. option:: +verilator+prof+threads+file+<filename>
Deprecated. Alias for :vlopt:`+verilator+prof+exec+file+\<filename\>`
Removed in 5.020. Was an alias for
:vlopt:`+verilator+prof+exec+file+\<filename\>`
.. option:: +verilator+prof+threads+start+<value>
Deprecated. Alias for :vlopt:`+verilator+prof+exec+start+\<value\>`
Removed in 5.020. Was an alias for
:vlopt:`+verilator+prof+exec+start+\<value\>`
.. option:: +verilator+prof+threads+window+<value>
Deprecated. Alias for :vlopt:`+verilator+prof+exec+window+\<value\>`
Removed in 5.020. Was an alias for
:vlopt:`+verilator+prof+exec+window+\<value\>`
.. option:: +verilator+prof+vlt+file+<filename>

View File

@ -1036,7 +1036,7 @@ Summary:
.. option:: --prof-threads
Deprecated. Same as --prof-exec and --prof-pgo together.
Removed in 5.020. Was an alias for --prof-exec and --prof-pgo together.
.. option:: --protect-ids

View File

@ -2710,14 +2710,11 @@ void VerilatedContextImp::commandArgVl(const std::string& arg) {
"Exiting due to command line argument (not an error)");
} else if (arg == "+verilator+noassert") {
assertOn(false);
} else if (commandArgVlUint64(arg, "+verilator+prof+exec+start+", u64)
|| commandArgVlUint64(arg, "+verilator+prof+threads+start+", u64)) {
} else if (commandArgVlUint64(arg, "+verilator+prof+exec+start+", u64)) {
profExecStart(u64);
} else if (commandArgVlUint64(arg, "+verilator+prof+exec+window+", u64, 1)
|| commandArgVlUint64(arg, "+verilator+prof+threads+window+", u64, 1)) {
} else if (commandArgVlUint64(arg, "+verilator+prof+exec+window+", u64, 1)) {
profExecWindow(u64);
} else if (commandArgVlString(arg, "+verilator+prof+exec+file+", str)
|| commandArgVlString(arg, "+verilator+prof+threads+file+", str)) {
} else if (commandArgVlString(arg, "+verilator+prof+exec+file+", str)) {
profExecFilename(str);
} else if (commandArgVlString(arg, "+verilator+prof+vlt+file+", str)) {
profVltFilename(str);

View File

@ -1330,47 +1330,6 @@ void V3Options::parseOptsList(FileLine* fl, const string& optdir, int argc,
DECL_OPTION("-O2", CbCall, [this]() { optimize(2); });
DECL_OPTION("-O3", CbCall, [this]() { optimize(3); });
DECL_OPTION("-O", CbPartialMatch, [this, fl](const char* optp) {
// Optimization, e.g. -O1rX
// LCOV_EXCL_START
fl->v3warn(DEPRECATED, "Option -O<letter> is deprecated. "
"Use -f<optimization> or -fno-<optimization> instead.");
for (const char* cp = optp; *cp; ++cp) {
const bool flag = std::isupper(*cp);
switch (std::tolower(*cp)) {
case '0': optimize(0); break;
case '1': optimize(1); break;
case '2': optimize(2); break;
case '3': optimize(3); break;
case 'a': m_fTable = flag; break; // == -fno-table
case 'b': m_fCombine = flag; break; // == -fno-combine
case 'c': m_fConst = flag; break; // == -fno-const
case 'd': m_fDedupe = flag; break; // == -fno-dedup
case 'e': m_fCase = flag; break; // == -fno-case
case 'g': m_fGate = flag; break; // == -fno-gate
case 'i': m_fInline = flag; break; // == -fno-inline
case 'k': m_fSubstConst = flag; break; // == -fno-subst-const
case 'l': m_fLife = flag; break; // == -fno-life
case 'm': m_fAssemble = flag; break; // == -fno-assemble
case 'o': m_fConstBitOpTree = flag; break; // == -fno-const-bit-op-tree
case 'p':
m_public = !flag;
break; // With -Op so flag=0, we want public on so few optimizations done
case 'r': m_fReorder = flag; break; // == -fno-reorder
case 's': m_fSplit = flag; break; // == -fno-split
case 't': m_fLifePost = flag; break; // == -fno-life-post
case 'u': m_fSubst = flag; break; // == -fno-subst
case 'v': m_fReloop = flag; break; // == -fno-reloop
case 'w': m_fMergeCond = flag; break; // == -fno-merge-cond
case 'x': m_fExpand = flag; break; // == -fno-expand
case 'y': m_fAcycSimp = flag; break; // == -fno-acyc-simp
case 'z': m_fLocalize = flag; break; // == -fno-localize
default:
break; // No error, just ignore
// LCOV_EXCL_STOP
}
}
});
DECL_OPTION("-o", Set, &m_exeName);
DECL_OPTION("-order-clock-delay", CbOnOff, [fl](bool /*flag*/) {
fl->v3warn(DEPRECATED, "Option order-clock-delay is deprecated and has no effect.");
@ -1417,11 +1376,6 @@ void V3Options::parseOptsList(FileLine* fl, const string& optdir, int argc,
[this]() { m_profC = m_profCFuncs = true; }); // Renamed
DECL_OPTION("-prof-exec", OnOff, &m_profExec);
DECL_OPTION("-prof-pgo", OnOff, &m_profPgo);
DECL_OPTION("-prof-threads", CbOnOff, [this, fl](bool flag) {
fl->v3warn(DEPRECATED, "Option --prof-threads is deprecated. "
"Use --prof-exec and --prof-pgo instead.");
m_profExec = m_profPgo = flag;
});
DECL_OPTION("-protect-ids", OnOff, &m_protectIds);
DECL_OPTION("-protect-key", Set, &m_protectKey);
DECL_OPTION("-protect-lib", CbVal, [this](const char* valp) {

View File

@ -1,7 +1,5 @@
%Warning-DEPRECATED: Option -O<letter> is deprecated. Use -f<optimization> or -fno-<optimization> instead.
%Warning-DEPRECATED: Option --trace-fst-thread is deprecated. Use --trace-fst with --trace-threads > 0.
... 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.
%Warning-DEPRECATED: Option --prof-threads is deprecated. Use --prof-exec and --prof-pgo instead.
%Warning-DEPRECATED: Option --trace-fst-thread is deprecated. Use --trace-fst with --trace-threads > 0.
%Warning-DEPRECATED: Option order-clock-delay is deprecated and has no effect.
%Error: Exiting due to

View File

@ -11,7 +11,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
lint(
verilator_flags2 => ["-Ox --prof-threads --trace-fst-thread --order-clock-delay"],
verilator_flags2 => ["--trace-fst-thread --order-clock-delay"],
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -32,13 +32,13 @@ execute(
);
execute(
all_run_flags => ["+verilator+prof+threads+window+0"],
all_run_flags => ["+verilator+prof+exec+window+0"],
fails => 1,
expect_filename => "t/" . $Self->{name} . "_d.out",
);
execute(
all_run_flags => ["+verilator+prof+threads+window+1000000000000000000000000"],
all_run_flags => ["+verilator+prof+exec+window+1000000000000000000000000"],
fails => 1,
expect_filename => "t/" . $Self->{name} . "_e.out",
);

View File

@ -1,2 +1,2 @@
%Error: COMMAND_LINE:0: Argument '+verilator+prof+threads+window+' must be an unsigned integer, greater than 0
%Error: COMMAND_LINE:0: Argument '+verilator+prof+exec+window+' must be an unsigned integer, greater than 0
Aborting...

View File

@ -1,2 +1,2 @@
%Error: COMMAND_LINE:0: Argument '+verilator+prof+threads+window+' must be an unsigned integer, greater than 0. Value out of range of uint64_t
%Error: COMMAND_LINE:0: Argument '+verilator+prof+exec+window+' must be an unsigned integer, greater than 0. Value out of range of uint64_t
Aborting...