mirror of
https://github.com/verilator/verilator.git
synced 2025-01-09 08:07:46 +00:00
729f8b9334
This makes the implementation of the detection and propagation of the suspendable property simpler and easier to read. More importantly, there are no more jumps around the AST with the `visit` functions, which in some cases could result in incorrect visitor context while in the `visit` function. See the added test, which would cause Verilator to segfault before this patch. In testing, verilation performance was not shown to be affected by this change. Though there is a slight performance improvement from this patch, due to adding one more check before refreshing class member cache. Signed-off-by: Krzysztof Bieganski <kbieganski@antmicro.com>
24 lines
456 B
Systemverilog
24 lines
456 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 (/*AUTOARG*/
|
|
// Inputs
|
|
clk
|
|
);
|
|
input clk;
|
|
semaphore s = new;
|
|
|
|
initial begin
|
|
s.put();
|
|
end
|
|
|
|
always @(posedge clk) begin
|
|
s.get();
|
|
$write("*-* All Finished *-*\n");
|
|
$finish;
|
|
end
|
|
endmodule
|