In the context of a force/assign you cannot reuse a saved signal value.

This patch removes the overly optimistic lookaside save for a signal
that has been set (%set/v). This is incorrect because if a force or
assign are active the value will not be set as expected.
This commit is contained in:
Cary R 2008-04-09 18:45:44 -07:00 committed by Stephen Williams
parent e2dfeac86c
commit 8cece424d1
1 changed files with 3 additions and 1 deletions

View File

@ -174,9 +174,11 @@ static void set_to_lvariable(ivl_lval_t lval,
} else {
save_signal_lookaside(bit, sig, use_word, wid);
fprintf(vvp_out, " %%set/v v%p_%lu, %u, %u;\n",
sig, use_word, bit, wid);
/* save_signal width of 0 CLEARS the signal from the
lookaside. */
save_signal_lookaside(bit, sig, use_word, 0);
}
}