2013-08-15 03:37:13 +02:00
|
|
|
// DESCRIPTION: Verilator: Verilog Test module
|
|
|
|
|
//
|
2026-01-27 02:24:34 +01:00
|
|
|
// This program is free software; you can redistribute it and/or modify it
|
|
|
|
|
// under the terms of either the GNU Lesser General Public License Version 3
|
|
|
|
|
// or the Perl Artistic License Version 2.0.
|
|
|
|
|
// SPDX-FileCopyrightText: 2009 Wilson Snyder
|
2020-03-21 16:24:24 +01:00
|
|
|
// SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
2013-08-15 03:37:13 +02:00
|
|
|
|
2026-03-03 13:21:24 +01:00
|
|
|
module t;
|
2013-08-15 03:37:13 +02:00
|
|
|
|
2026-03-08 23:26:40 +01:00
|
|
|
import "DPI-C" function int dpii_string(input string DSM_NAME);
|
2013-08-15 03:37:13 +02:00
|
|
|
|
2026-03-08 23:26:40 +01:00
|
|
|
generate
|
|
|
|
|
begin : DSM
|
|
|
|
|
string SOME_STRING;
|
|
|
|
|
end
|
|
|
|
|
endgenerate
|
2013-08-15 03:37:13 +02:00
|
|
|
|
2026-03-08 23:26:40 +01:00
|
|
|
initial begin
|
|
|
|
|
$sformat(DSM.SOME_STRING, "%m");
|
|
|
|
|
if (dpii_string(DSM.SOME_STRING) != 5) $stop;
|
2013-08-15 03:37:13 +02:00
|
|
|
|
2026-03-08 23:26:40 +01:00
|
|
|
$write("*-* All Finished *-*\n");
|
|
|
|
|
$finish;
|
|
|
|
|
end
|
2013-08-15 03:37:13 +02:00
|
|
|
|
|
|
|
|
endmodule
|