2024-02-28 00:08:27 +01:00
|
|
|
// DESCRIPTION: Verilator: Verilog Test module
|
|
|
|
|
//
|
2026-01-27 02:24:34 +01:00
|
|
|
// This file ONLY is placed under the Creative Commons Public Domain.
|
|
|
|
|
// SPDX-FileCopyrightText: 2024 Antmicro Ltd
|
2024-02-28 00:08:27 +01:00
|
|
|
// SPDX-License-Identifier: CC0-1.0
|
|
|
|
|
|
2026-03-10 02:38:29 +01:00
|
|
|
typedef struct {bit x;} u_struct_t;
|
2024-02-28 00:08:27 +01:00
|
|
|
|
2026-03-10 02:38:29 +01:00
|
|
|
module u_mh (
|
|
|
|
|
inout u_struct_t u_i,
|
|
|
|
|
inout u_struct_t u_o
|
|
|
|
|
);
|
|
|
|
|
assign u_o.x = u_i.x;
|
2024-02-28 00:08:27 +01:00
|
|
|
endmodule
|
|
|
|
|
|
|
|
|
|
module t;
|
2026-03-10 02:38:29 +01:00
|
|
|
u_struct_t u_i, u_o;
|
2024-02-28 00:08:27 +01:00
|
|
|
|
2026-03-10 02:38:29 +01:00
|
|
|
u_mh u_mh (
|
|
|
|
|
u_i,
|
|
|
|
|
u_o
|
|
|
|
|
);
|
2024-02-28 00:08:27 +01:00
|
|
|
|
2026-03-10 02:38:29 +01:00
|
|
|
initial begin
|
|
|
|
|
u_i.x = 1;
|
|
|
|
|
#1;
|
|
|
|
|
if (u_o.x != 1'b1) $stop;
|
|
|
|
|
$write("*-* All Finished *-*\n");
|
|
|
|
|
$finish;
|
|
|
|
|
end
|
2024-02-28 00:08:27 +01:00
|
|
|
endmodule
|