yosys/tests/sim/sim_adlatch.ys

11 lines
326 B
Plaintext
Raw Permalink Normal View History

2022-02-16 06:58:51 -06:00
read_verilog -icells <<EOT
module adlatch(input d, rst, en, output reg q);
$adlatch #(.EN_POLARITY(1'b1), .ARST_POLARITY(1'b1), .ARST_VALUE(1'b0), .WIDTH(1)) uut (.EN(en), .ARST(rst), .D(d), .Q(q));
endmodule
EOT
proc
opt_dff
2022-02-15 02:35:53 -06:00
stat
2022-02-16 06:58:51 -06:00
select -assert-count 1 t:$adlatch
2022-02-15 02:35:53 -06:00
sim -r tb_adlatch.fst -scope tb_adlatch.uut -sim-cmp adlatch