From: Clifford Wolf Date: Sat, 18 Jan 2014 01:56:36 +0000 (+0100) Subject: Improved setundef random number generator X-Git-Tag: yosys-0.2.0~163 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=839af272adeb6e15c0b1fd1c35249db4a9da9f4d;p=yosys.git Improved setundef random number generator --- diff --git a/passes/cmds/setundef.cc b/passes/cmds/setundef.cc index 394834a36..9d59834c2 100644 --- a/passes/cmds/setundef.cc +++ b/passes/cmds/setundef.cc @@ -40,7 +40,7 @@ static RTLIL::State next_bit() next_bit_state ^= next_bit_state << 5; log_assert(next_bit_state != 0); - return ((next_bit_state >> (next_bit_state & 15)) & 1) ? RTLIL::State::S0 : RTLIL::State::S1; + return ((next_bit_state >> (next_bit_state & 15)) & 16) ? RTLIL::State::S0 : RTLIL::State::S1; } struct SetundefWorker