2020-05-05 00:42:15 +02:00
|
|
|
#!/usr/bin/env perl
|
2013-04-27 03:02:32 +02:00
|
|
|
if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); die; }
|
|
|
|
|
# DESCRIPTION: Verilator: Verilog Test driver/expect definition
|
|
|
|
|
#
|
2020-03-21 16:24:24 +01:00
|
|
|
# Copyright 2003 by Wilson Snyder. This program is free software; you
|
|
|
|
|
# can redistribute it and/or modify it under the terms of either the GNU
|
2013-04-27 03:02:32 +02:00
|
|
|
# Lesser General Public License Version 3 or the Perl Artistic License
|
|
|
|
|
# Version 2.0.
|
2020-03-21 16:24:24 +01:00
|
|
|
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
2013-04-27 03:02:32 +02:00
|
|
|
|
2024-01-06 00:25:39 +01:00
|
|
|
scenarios(vlt => 1);
|
2013-04-27 03:02:32 +02:00
|
|
|
|
|
|
|
|
top_filename("t/t_var_pinsizes.v");
|
|
|
|
|
|
2018-05-07 04:39:18 +02:00
|
|
|
compile(
|
|
|
|
|
verilator_flags2 => ["-sc --pins-sc-uint --trace --exe $Self->{t_dir}/t_var_pinsizes.cpp"],
|
|
|
|
|
make_main => 0,
|
|
|
|
|
);
|
2013-04-27 03:02:32 +02:00
|
|
|
|
2018-05-09 01:39:32 +02:00
|
|
|
{
|
2024-08-26 14:14:39 +02:00
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<bool>\s+&i1;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_uint<8>\s>\s+&i8;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_uint<16>\s>\s+&i16;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_uint<32>\s>\s+&i32;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_uint<64>\s>\s+&i64;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_bv<65>\s>\s+&i65;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_bv<128>\s>\s+&i128;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_bv<513>\s>\s+&i513;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_bv<1>\s>\s+&ibv1;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_in<sc_dt::sc_bv<16>\s>\s+&ibv16;/);
|
2013-04-27 03:02:32 +02:00
|
|
|
|
2024-08-26 14:14:39 +02:00
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<bool>\s+&o1;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_uint<8>\s>\s+&o8;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_uint<16>\s>\s+&o16;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_uint<32>\s>\s+&o32;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_uint<64>\s>\s+&o64;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_bv<65>\s>\s+&o65;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_bv<128>\s>\s+&o128;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_bv<513>\s>\s+&o513;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_bv<1>\s>\s+&obv1;/);
|
|
|
|
|
file_grep("$Self->{obj_dir}/$Self->{vm_prefix}.h", qr/sc_core::sc_out<sc_dt::sc_bv<16>\s>\s+&obv16;/);
|
2013-04-27 03:02:32 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
execute();
|
|
|
|
|
|
|
|
|
|
ok(1);
|
|
|
|
|
1;
|