mirror of
https://github.com/verilator/verilator.git
synced 2025-01-19 12:54:02 +00:00
30 lines
690 B
Systemverilog
30 lines
690 B
Systemverilog
// DESCRIPTION: Verilator: Verilog Test module
|
|
//
|
|
// This file ONLY is placed under the Creative Commons Public Domain, for
|
|
// any use, without warranty, 2024 by Wilson Snyder.
|
|
// SPDX-License-Identifier: CC0-1.0
|
|
|
|
module t(/*AUTOARG*/);
|
|
function int fun(int val);
|
|
fork
|
|
$display("abc");
|
|
$display("def");
|
|
join_none // Although join is illegal, join_none legal (IEEE 1800-2023 13.4)
|
|
return val + 2;
|
|
endfunction
|
|
|
|
task tsk();
|
|
fork
|
|
$display("ghi");
|
|
$display("jkl");
|
|
join_none
|
|
endtask
|
|
|
|
initial begin
|
|
$display("$d", fun(2));
|
|
tsk();
|
|
$write("*-* All Finished *-*\n");
|
|
$finish;
|
|
end
|
|
endmodule
|