Fix UNDRIVEN warning seg fault (#3989)

This commit is contained in:
Felix Neumärker 2023-03-03 18:54:38 -05:00 committed by Wilson Snyder
parent 3fc684359a
commit 12728bc478
3 changed files with 25 additions and 1 deletions

View File

@ -61,6 +61,7 @@ Verilator 5.007 devel
* Fix subsequent parameter declarations (#3969). [Ryszard Rozak, Antmicro Ltd]
* Fix timing delays to not truncate below 64 bits (#3973) (#3982). [Felix Neumärker]
* Fix cmake on macOS to mark weak symbols with -U linker flag (#3978) (#3979). [Peter Debacker]
* Fix UNDRIVEN warning seg fault (#3989). [Felix Neumärker]
* Fix packed array structure replication.
* Fix enum.next(0) and enum.prev(0).

View File

@ -408,7 +408,8 @@ private:
}
if (entryp->isDrivenWhole() && !m_inBBox && !VN_IS(nodep, VarXRef)
&& !VN_IS(nodep->dtypep()->skipRefp(), UnpackArrayDType)
&& nodep->fileline() != entryp->getNodeFileLinep() && !entryp->isUnderGen()) {
&& nodep->fileline() != entryp->getNodeFileLinep() && !entryp->isUnderGen()
&& entryp->getNodep()) {
if (m_alwaysCombp
&& (!entryp->isDrivenAlwaysCombWhole()
|| (entryp->isDrivenAlwaysCombWhole()

View File

@ -0,0 +1,22 @@
#!/usr/bin/env perl
if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); die; }
# DESCRIPTION: Verilator: Verilog Test driver/expect definition
#
# Copyright 2023 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
scenarios(vlt => 1);
top_filename("t/t_lint_always_comb_multidriven.v");
lint(
verilator_flags2 => ['--public-flat-rw --lint-only'],
fails => 1,
expect_filename => "t/t_lint_always_comb_multidriven.out",
);
ok(1);
1;