mirror of https://github.com/YosysHQ/yosys.git
Merge remote-tracking branch 'origin/eddie/fix1115' into xc7mux
This commit is contained in:
commit
cdbcd2efbd
|
@ -3438,7 +3438,7 @@ void RTLIL::SigSpec::extend_u0(int width, bool is_signed)
|
||||||
|
|
||||||
if (width_ < width) {
|
if (width_ < width) {
|
||||||
RTLIL::SigBit padding = width_ > 0 ? (*this)[width_ - 1] : RTLIL::State::Sx;
|
RTLIL::SigBit padding = width_ > 0 ? (*this)[width_ - 1] : RTLIL::State::Sx;
|
||||||
if (!is_signed)
|
if (padding != RTLIL::State::Sx && !is_signed)
|
||||||
padding = RTLIL::State::S0;
|
padding = RTLIL::State::S0;
|
||||||
while (width_ < width)
|
while (width_ < width)
|
||||||
append(padding);
|
append(padding);
|
||||||
|
|
|
@ -0,0 +1,21 @@
|
||||||
|
|
||||||
|
read_verilog -formal <<EOT
|
||||||
|
module gate(input clk, output [1:0] o);
|
||||||
|
assign o = 1'bx;
|
||||||
|
endmodule
|
||||||
|
EOT
|
||||||
|
|
||||||
|
proc
|
||||||
|
|
||||||
|
## Equivalence checking
|
||||||
|
|
||||||
|
read_verilog -formal <<EOT
|
||||||
|
module gold(input clk, output [1:0] o);
|
||||||
|
assign o = 2'bxx;
|
||||||
|
endmodule
|
||||||
|
EOT
|
||||||
|
|
||||||
|
proc
|
||||||
|
|
||||||
|
miter -equiv -flatten -make_assert -make_outputs gold gate miter
|
||||||
|
sat -verify -prove-asserts -show-ports -enable_undef miter
|
Loading…
Reference in New Issue