verilator/test_regress/t/t_assigndly_task.v
Krzysztof Bieganski 016e630ecf
Refine dynamic NBA condition (#4773)
Signed-off-by: Krzysztof Bieganski <kbieganski@antmicro.com>
2023-12-20 18:12:17 +01:00

23 lines
464 B
Systemverilog

// DESCRIPTION: Verilator: Verilog Test module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2023 by Antmicro Ltd.
// SPDX-License-Identifier: CC0-1.0
module t (
input clk,
input [7:0] d,
input [2:0] a,
output [7:0] q
);
always_ff @(posedge clk) tick(a);
logic [7:0] d_ = d;
logic [7:0] q_;
assign q = q_;
task automatic tick(logic [2:0] a);
q_[a] <= d_[a];
endtask
endmodule