mirror of https://github.com/YosysHQ/yosys.git
Add "setundef -undef"
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
parent
efaef82f75
commit
83ffb23739
|
@ -40,6 +40,9 @@ struct SetundefWorker
|
|||
if (next_bit_mode == 1)
|
||||
return RTLIL::State::S1;
|
||||
|
||||
if (next_bit_mode == 4)
|
||||
return RTLIL::State::Sx;
|
||||
|
||||
// xorshift32
|
||||
next_bit_state ^= next_bit_state << 13;
|
||||
next_bit_state ^= next_bit_state >> 17;
|
||||
|
@ -81,6 +84,9 @@ struct SetundefPass : public Pass {
|
|||
log(" -one\n");
|
||||
log(" replace with bits set (1)\n");
|
||||
log("\n");
|
||||
log(" -undef\n");
|
||||
log(" replace with undef (x) bits, may be used with -undriven\n");
|
||||
log("\n");
|
||||
log(" -anyseq\n");
|
||||
log(" replace with $anyseq drivers (for formal)\n");
|
||||
log("\n");
|
||||
|
@ -123,6 +129,11 @@ struct SetundefPass : public Pass {
|
|||
worker.next_bit_mode = 2;
|
||||
continue;
|
||||
}
|
||||
if (args[argidx] == "-undef") {
|
||||
got_value = true;
|
||||
worker.next_bit_mode = 4;
|
||||
continue;
|
||||
}
|
||||
if (args[argidx] == "-init") {
|
||||
init_mode = true;
|
||||
continue;
|
||||
|
|
Loading…
Reference in New Issue