mirror of
https://github.com/verilator/verilator.git
synced 2026-09-05 08:42:46 +02:00
Fix V3Table trying to generate 'x' bits in the lookup table. (#5491)
Due to out of range selects, V3Table attempted to create a table in the constant pool with an 'x' value in it, which caused an internal error. Ensure V3Table behaves the same for out of range selects as the original logic would. There is a related bug #5490, about leaving partially out of range selects in the logic after inserting bounds checks in V3Unknown.
This commit is contained in:
@@ -315,6 +315,7 @@ private:
|
||||
for (TableOutputVar& tov : m_outVarps) {
|
||||
if (V3Number* const outnump = simvis.fetchOutNumberNull(tov.varScopep())) {
|
||||
UINFO(8, " Output " << tov.name() << " = " << *outnump << endl);
|
||||
UASSERT_OBJ(!outnump->isAnyXZ(), outnump, "Table should not contain X/Z");
|
||||
outputAssignedMask.setBit(tov.ord(), 1); // Mark output as assigned
|
||||
tov.addValue(inValue, *outnump);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user