tranif control ports handle nil inputs

In certain special cases, it is possible for the tranif control input
to be nil. (probably only during startup.) Treat that case as HiZ.
This commit is contained in:
Stephen Williams 2009-10-07 12:58:19 -07:00
parent 537ba93fe4
commit 2229ad896b
1 changed files with 5 additions and 1 deletions

View File

@ -114,7 +114,11 @@ bool vvp_island_branch_tran::run_test_enabled()
}
enabled_flag = false;
vvp_bit4_t enable_val = ep->invalue.value(0).value();
vvp_bit4_t enable_val;
if (ep->invalue.size() == 0)
enable_val = BIT4_Z;
else
enable_val = ep->invalue.value(0).value();
if (active_high==true && enable_val != BIT4_1)
return false;