ruby-vpi 8.1.0 → 8.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/HISTORY +17 -0
- data/bin/generate_test_tpl/bench.v +1 -1
- data/bin/generate_test_tpl/runner.rake +3 -1
- data/doc/background.organization.html +1 -1
- data/doc/index.html +2 -2
- data/doc/manual.txt +2 -2
- data/doc/src/manual.xml +2 -2
- data/doc/usage.tutorial.html +1 -1
- data/history.html +27 -0
- data/history.part.html +27 -0
- data/lib/ruby-vpi/runner.rb +29 -12
- data/ref/c/annotated.html +1 -6
- data/ref/c/common_8h.html +1 -1
- data/ref/c/files.html +1 -3
- data/ref/c/functions.html +24 -44
- data/ref/c/functions_vars.html +24 -44
- data/ref/c/globals.html +5 -211
- data/ref/c/globals_0x63.html +32 -49
- data/ref/c/globals_0x65.html +3 -10
- data/ref/c/globals_0x66.html +3 -20
- data/ref/c/globals_0x70.html +19 -26
- data/ref/c/globals_0x72.html +4 -15
- data/ref/c/globals_0x73.html +13 -199
- data/ref/c/globals_0x74.html +2 -9
- data/ref/c/globals_0x76.html +415 -426
- data/ref/c/globals_0x78.html +3 -10
- data/ref/c/globals_defs.html +30 -35
- data/ref/c/globals_defs_0x65.html +2 -7
- data/ref/c/globals_defs_0x70.html +3 -8
- data/ref/c/globals_defs_0x76.html +413 -420
- data/ref/c/globals_defs_0x78.html +2 -7
- data/ref/c/globals_enum.html +1 -1
- data/ref/c/globals_eval.html +1 -1
- data/ref/c/globals_func.html +14 -173
- data/ref/c/globals_type.html +26 -29
- data/ref/c/globals_vars.html +4 -88
- data/ref/c/index.html +1 -1
- data/ref/c/relay_8cin.html +1 -1
- data/ref/c/relay_8hin.html +1 -1
- data/ref/c/ruby-vpi_8c.html +1 -1
- data/ref/c/structrelay____RubyOptions____def.html +1 -1
- data/ref/c/structt__cb__data.html +6 -23
- data/ref/c/structt__vpi__delay.html +3 -20
- data/ref/c/structt__vpi__error__info.html +3 -71
- data/ref/c/structt__vpi__strengthval.html +3 -3
- data/ref/c/structt__vpi__systf__data.html +12 -46
- data/ref/c/structt__vpi__time.html +3 -3
- data/ref/c/structt__vpi__value.html +3 -113
- data/ref/c/structt__vpi__vecval.html +3 -3
- data/ref/c/structt__vpi__vlog__info.html +3 -54
- data/ref/c/swig_8cin.html +2 -2
- data/ref/c/swig_8hin.html +1 -1
- data/ref/c/verilog_8h.html +1 -1
- data/ref/c/vlog_8cin.html +1 -1
- data/ref/c/vlog_8hin.html +1 -1
- data/ref/c/vpi__user_8h.html +16 -16
- data/ref/ruby/classes/ERB.html +5 -5
- data/ref/ruby/classes/ERB.src/{M000032.html → M000033.html} +0 -0
- data/ref/ruby/classes/FileUtils.html +10 -10
- data/ref/ruby/classes/FileUtils.src/M000088.html +5 -5
- data/ref/ruby/classes/FileUtils.src/M000089.html +18 -0
- data/ref/ruby/classes/Integer.html +68 -68
- data/ref/ruby/classes/Integer.src/M000011.html +12 -5
- data/ref/ruby/classes/Integer.src/M000012.html +5 -5
- data/ref/ruby/classes/Integer.src/M000013.html +5 -5
- data/ref/ruby/classes/Integer.src/M000014.html +5 -5
- data/ref/ruby/classes/Integer.src/M000015.html +5 -5
- data/ref/ruby/classes/Integer.src/M000016.html +18 -0
- data/ref/ruby/classes/Integer.src/M000019.html +9 -9
- data/ref/ruby/classes/Integer.src/M000020.html +9 -12
- data/ref/ruby/classes/Integer.src/M000021.html +12 -18
- data/ref/ruby/classes/Integer.src/M000022.html +18 -12
- data/ref/ruby/classes/Integer.src/M000023.html +12 -17
- data/ref/ruby/classes/Integer.src/M000024.html +30 -0
- data/ref/ruby/classes/OutputInfo.html +5 -5
- data/ref/ruby/classes/OutputInfo.src/{M000028.html → M000029.html} +0 -0
- data/ref/ruby/classes/RDoc.html +5 -5
- data/ref/ruby/classes/RDoc.src/{M000091.html → M000092.html} +0 -0
- data/ref/ruby/classes/RubyVpi.html +10 -10
- data/ref/ruby/classes/RubyVpi.src/M000090.html +37 -7
- data/ref/ruby/classes/RubyVpi.src/M000091.html +20 -0
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.html +45 -45
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000080.html +5 -5
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000081.html +5 -9
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000082.html +9 -31
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000083.html +31 -69
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000084.html +69 -114
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000085.html +114 -13
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000086.html +13 -5
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000087.html +18 -0
- data/ref/ruby/classes/String.html +10 -10
- data/ref/ruby/classes/String.src/M000031.html +28 -5
- data/ref/ruby/classes/String.src/M000032.html +18 -0
- data/ref/ruby/classes/Table.html +20 -20
- data/ref/ruby/classes/Table.src/M000025.html +25 -5
- data/ref/ruby/classes/Table.src/M000026.html +5 -5
- data/ref/ruby/classes/Table.src/M000027.html +5 -5
- data/ref/ruby/classes/Table.src/M000028.html +18 -0
- data/ref/ruby/classes/Template.html +5 -5
- data/ref/ruby/classes/Template.src/{M000029.html → M000030.html} +0 -0
- data/ref/ruby/classes/VerilogParser/Module/Parameter.html +5 -5
- data/ref/ruby/classes/VerilogParser/Module/Parameter.src/{M000009.html → M000010.html} +0 -0
- data/ref/ruby/classes/VerilogParser/Module/Port.html +20 -20
- data/ref/ruby/classes/VerilogParser/Module/Port.src/M000006.html +8 -5
- data/ref/ruby/classes/VerilogParser/Module/Port.src/M000007.html +5 -5
- data/ref/ruby/classes/VerilogParser/Module/Port.src/M000008.html +5 -5
- data/ref/ruby/classes/VerilogParser/Module/Port.src/M000009.html +18 -0
- data/ref/ruby/classes/VerilogParser/Module.html +5 -5
- data/ref/ruby/classes/VerilogParser/Module.src/{M000004.html → M000005.html} +0 -0
- data/ref/ruby/classes/VerilogParser.html +5 -5
- data/ref/ruby/classes/VerilogParser.src/{M000003.html → M000004.html} +0 -0
- data/ref/ruby/classes/XX/Document.html +45 -45
- data/ref/ruby/classes/XX/Document.src/M000071.html +9 -7
- data/ref/ruby/classes/XX/Document.src/M000072.html +7 -7
- data/ref/ruby/classes/XX/Document.src/M000073.html +7 -7
- data/ref/ruby/classes/XX/Document.src/M000074.html +7 -9
- data/ref/ruby/classes/XX/Document.src/M000075.html +9 -8
- data/ref/ruby/classes/XX/Document.src/M000076.html +8 -8
- data/ref/ruby/classes/XX/Document.src/M000077.html +8 -21
- data/ref/ruby/classes/XX/Document.src/M000078.html +21 -85
- data/ref/ruby/classes/XX/Document.src/M000079.html +98 -0
- data/ref/ruby/classes/XX/HTML4/Strict.html +5 -5
- data/ref/ruby/classes/XX/HTML4/Strict.src/{M000036.html → M000037.html} +0 -0
- data/ref/ruby/classes/XX/HTML4/Transitional.html +5 -5
- data/ref/ruby/classes/XX/HTML4/Transitional.src/{M000035.html → M000036.html} +0 -0
- data/ref/ruby/classes/XX/HTML4.html +5 -5
- data/ref/ruby/classes/XX/HTML4.src/{M000034.html → M000035.html} +0 -0
- data/ref/ruby/classes/XX/Markup/ClassMethods.html +40 -40
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000043.html +9 -7
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000044.html +7 -12
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000045.html +12 -7
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000046.html +7 -14
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000047.html +14 -7
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000048.html +7 -14
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000049.html +14 -9
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000050.html +22 -0
- data/ref/ruby/classes/XX/Markup/InstanceMethods.html +100 -100
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000051.html +43 -20
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000052.html +20 -18
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000053.html +18 -35
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000054.html +35 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000055.html +7 -18
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000056.html +18 -19
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000057.html +19 -19
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000058.html +19 -15
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000059.html +15 -10
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000060.html +10 -13
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000061.html +13 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000062.html +7 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000063.html +7 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000064.html +7 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000065.html +7 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000066.html +7 -8
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000067.html +8 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000068.html +7 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000069.html +7 -7
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000070.html +20 -0
- data/ref/ruby/classes/XX/Markup.html +5 -5
- data/ref/ruby/classes/XX/Markup.src/{M000041.html → M000042.html} +0 -0
- data/ref/ruby/classes/XX/XHTML/Strict.html +5 -5
- data/ref/ruby/classes/XX/XHTML/Strict.src/{M000039.html → M000040.html} +0 -0
- data/ref/ruby/classes/XX/XHTML/Transitional.html +5 -5
- data/ref/ruby/classes/XX/XHTML/Transitional.src/{M000038.html → M000039.html} +0 -0
- data/ref/ruby/classes/XX/XHTML.html +5 -5
- data/ref/ruby/classes/XX/XHTML.src/{M000037.html → M000038.html} +0 -0
- data/ref/ruby/classes/XX/XML.html +5 -5
- data/ref/ruby/classes/XX/XML.src/{M000033.html → M000034.html} +0 -0
- data/ref/ruby/classes/XX/XMLish.html +5 -5
- data/ref/ruby/classes/XX/XMLish.src/{M000040.html → M000041.html} +0 -0
- data/ref/ruby/created.rid +1 -1
- data/ref/ruby/files/lib/ruby-vpi/runner_rb.html +29 -1
- data/ref/ruby/files/lib/ruby-vpi/runner_rb.src/M000002.html +6 -6
- data/ref/ruby/files/lib/ruby-vpi/runner_rb.src/M000003.html +26 -0
- data/ref/ruby/fr_method_index.html +90 -89
- data/samp/counter/counter_rspecTest_bench.v +3 -1
- data/samp/counter/counter_rspecTest_runner.rake +3 -1
- data/samp/counter/counter_unitTest_bench.v +2 -2
- data/samp/counter/counter_unitTest_runner.rake +3 -1
- data/samp/pipelined_alu/InputGenerator.rb +15 -40
- data/samp/pipelined_alu/hw5_unit_test_bench.v +2 -7
- data/samp/pipelined_alu/hw5_unit_test_proto.rb +8 -3
- data/samp/pipelined_alu/hw5_unit_test_runner.rake +3 -1
- data/samp/pipelined_alu/hw5_unit_test_spec.rb +4 -4
- metadata +30 -55
- data/ref/c/globals_0x62.html +0 -62
- data/ref/c/globals_0x67.html +0 -64
- data/ref/c/globals_0x69.html +0 -62
- data/ref/c/globals_0x6c.html +0 -64
- data/ref/c/globals_0x6d.html +0 -62
- data/ref/c/globals_0x6e.html +0 -63
- data/ref/c/globals_0x75.html +0 -63
- data/ref/c/globals_defs_0x6c.html +0 -57
- data/ref/c/globals_defs_0x6e.html +0 -56
- data/ref/c/globals_defs_0x72.html +0 -57
- data/ref/c/globals_defs_0x73.html +0 -164
- data/ref/c/globals_defs_0x75.html +0 -56
- data/ref/c/globals_func_0x66.html +0 -62
- data/ref/c/globals_func_0x67.html +0 -55
- data/ref/c/globals_func_0x69.html +0 -53
- data/ref/c/globals_func_0x70.html +0 -53
- data/ref/c/globals_func_0x72.html +0 -57
- data/ref/c/globals_func_0x73.html +0 -114
- data/ref/c/globals_func_0x76.html +0 -57
- data/ref/c/structswig__cast__info.html +0 -98
- data/ref/c/structswig__class.html +0 -115
- data/ref/c/structswig__module__info.html +0 -132
- data/ref/c/structswig__type__info.html +0 -132
- data/ref/c/swig__vpi_8h.html +0 -8739
- data/ref/c/swig__wrap_8cin.html +0 -11556
- data/ref/c/unions__vpi__value__value.html +0 -166
- data/ref/ruby/classes/FileUtils.src/M000087.html +0 -18
- data/ref/ruby/classes/Integer.src/M000010.html +0 -25
- data/ref/ruby/classes/Integer.src/M000018.html +0 -22
- data/ref/ruby/classes/RubyVpi.src/M000089.html +0 -50
- data/ref/ruby/classes/SWIG/TYPE_p_unsigned_int.src/M000079.html +0 -18
- data/ref/ruby/classes/String.src/M000030.html +0 -41
- data/ref/ruby/classes/Table.src/M000024.html +0 -38
- data/ref/ruby/classes/VerilogParser/Module/Port.src/M000005.html +0 -21
- data/ref/ruby/classes/XX/Document.src/M000070.html +0 -22
- data/ref/ruby/classes/XX/Markup/ClassMethods.src/M000042.html +0 -22
- data/ref/ruby/classes/XX/Markup/InstanceMethods.src/M000050.html +0 -56
@@ -20,97 +20,98 @@
|
|
20
20
|
<div id="index">
|
21
21
|
<h1 class="section-bar">Methods</h1>
|
22
22
|
<div id="index-entries">
|
23
|
-
<a href="classes/XX/Document.html#
|
24
|
-
<a href="classes/SWIG/TYPE_p_unsigned_int.html#
|
25
|
-
<a href="classes/FileUtils.html#
|
26
|
-
<a href="classes/XX/Document.html#
|
27
|
-
<a href="classes/Table.html#
|
28
|
-
<a href="classes/SWIG/TYPE_p_unsigned_int.html#
|
29
|
-
<a href="classes/Integer.html#
|
30
|
-
<a href="classes/Integer.html#
|
31
|
-
<a href="
|
32
|
-
<a href="classes/
|
33
|
-
<a href="classes/SWIG/TYPE_p_unsigned_int.html#
|
34
|
-
<a href="classes/
|
35
|
-
<a href="classes/XX/HTML4/
|
36
|
-
<a href="classes/XX/HTML4.html#
|
37
|
-
<a href="classes/XX/
|
38
|
-
<a href="classes/
|
39
|
-
<a href="classes/
|
40
|
-
<a href="classes/
|
41
|
-
<a href="classes/Integer.html#M000012">
|
42
|
-
<a href="classes/Integer.html#
|
43
|
-
<a href="classes/Integer.html#
|
44
|
-
<a href="classes/Integer.html#
|
45
|
-
<a href="classes/
|
46
|
-
<a href="classes/
|
47
|
-
<a href="classes/
|
48
|
-
<a href="classes/ERB.html#
|
49
|
-
<a href="classes/
|
50
|
-
<a href="classes/
|
51
|
-
<a href="classes/VerilogParser/Module.html#
|
52
|
-
<a href="classes/
|
53
|
-
<a href="classes/VerilogParser
|
54
|
-
<a href="classes/
|
23
|
+
<a href="classes/XX/Document.html#M000079"><< (XX::Document)</a><br />
|
24
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000086">[] (SWIG::TYPE_p_unsigned_int)</a><br />
|
25
|
+
<a href="classes/FileUtils.html#M000089">collect_args (FileUtils)</a><br />
|
26
|
+
<a href="classes/XX/Document.html#M000078">create (XX::Document)</a><br />
|
27
|
+
<a href="classes/Table.html#M000025">doc (Table)</a><br />
|
28
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000087">each (SWIG::TYPE_p_unsigned_int)</a><br />
|
29
|
+
<a href="classes/Integer.html#M000020">ensure_max (Integer)</a><br />
|
30
|
+
<a href="classes/Integer.html#M000019">ensure_min (Integer)</a><br />
|
31
|
+
<a href="files/lib/ruby-vpi/runner_rb.html#M000003">expand_include_dir_options (lib/ruby-vpi/runner.rb)</a><br />
|
32
|
+
<a href="classes/Integer.html#M000023">extend_sign (Integer)</a><br />
|
33
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000083">get_value (SWIG::TYPE_p_unsigned_int)</a><br />
|
34
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000082">get_value_wrapper (SWIG::TYPE_p_unsigned_int)</a><br />
|
35
|
+
<a href="classes/XX/HTML4/Strict.html#M000037">html4_ (XX::HTML4::Strict)</a><br />
|
36
|
+
<a href="classes/XX/HTML4/Transitional.html#M000036">html4_ (XX::HTML4::Transitional)</a><br />
|
37
|
+
<a href="classes/XX/HTML4.html#M000035">html4_ (XX::HTML4)</a><br />
|
38
|
+
<a href="classes/XX/Markup.html#M000042">included (XX::Markup)</a><br />
|
39
|
+
<a href="classes/RubyVpi.html#M000090">init_bench (RubyVpi)</a><br />
|
40
|
+
<a href="classes/VerilogParser/Module/Port.html#M000007">input? (VerilogParser::Module::Port)</a><br />
|
41
|
+
<a href="classes/Integer.html#M000012">length (Integer)</a><br />
|
42
|
+
<a href="classes/Integer.html#M000013">limit (Integer)</a><br />
|
43
|
+
<a href="classes/Integer.html#M000011">log2 (Integer)</a><br />
|
44
|
+
<a href="classes/Integer.html#M000015">mask (Integer)</a><br />
|
45
|
+
<a href="classes/Integer.html#M000017">max (Integer)</a><br />
|
46
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000085">method_missing (SWIG::TYPE_p_unsigned_int)</a><br />
|
47
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000051">method_missing (XX::Markup::InstanceMethods)</a><br />
|
48
|
+
<a href="classes/ERB.html#M000033">new (ERB)</a><br />
|
49
|
+
<a href="classes/VerilogParser/Module/Parameter.html#M000010">new (VerilogParser::Module::Parameter)</a><br />
|
50
|
+
<a href="classes/XX/Document.html#M000071">new (XX::Document)</a><br />
|
51
|
+
<a href="classes/VerilogParser/Module.html#M000005">new (VerilogParser::Module)</a><br />
|
52
|
+
<a href="classes/Template.html#M000030">new (Template)</a><br />
|
53
|
+
<a href="classes/VerilogParser.html#M000004">new (VerilogParser)</a><br />
|
54
|
+
<a href="classes/VerilogParser/Module/Port.html#M000006">new (VerilogParser::Module::Port)</a><br />
|
55
|
+
<a href="classes/OutputInfo.html#M000029">new (OutputInfo)</a><br />
|
55
56
|
<a href="files/lib/ruby-vpi/runner_rb.html#M000002">object_file_path (lib/ruby-vpi/runner.rb)</a><br />
|
56
|
-
<a href="classes/VerilogParser/Module/Port.html#
|
57
|
-
<a href="classes/Integer.html#
|
58
|
-
<a href="classes/XX/Document.html#
|
59
|
-
<a href="classes/XX/Document.html#
|
60
|
-
<a href="classes/XX/Document.html#
|
61
|
-
<a href="classes/SWIG/TYPE_p_unsigned_int.html#
|
62
|
-
<a href="classes/VerilogParser/Module/Port.html#
|
63
|
-
<a href="classes/FileUtils.html#
|
64
|
-
<a href="classes/Integer.html#
|
65
|
-
<a href="classes/Table.html#
|
66
|
-
<a href="classes/Integer.html#
|
67
|
-
<a href="classes/Integer.html#
|
68
|
-
<a href="classes/Integer.html#
|
69
|
-
<a href="classes/String.html#
|
70
|
-
<a href="classes/XX/Document.html#
|
71
|
-
<a href="classes/Table.html#
|
72
|
-
<a href="classes/Table.html#
|
73
|
-
<a href="classes/XX/Document.html#
|
74
|
-
<a href="classes/XX/Document.html#
|
75
|
-
<a href="classes/Integer.html#
|
76
|
-
<a href="classes/RDoc.html#
|
77
|
-
<a href="classes/String.html#
|
78
|
-
<a href="classes/RubyVpi.html#
|
57
|
+
<a href="classes/VerilogParser/Module/Port.html#M000008">output? (VerilogParser::Module::Port)</a><br />
|
58
|
+
<a href="classes/Integer.html#M000021">pack (Integer)</a><br />
|
59
|
+
<a href="classes/XX/Document.html#M000074">pop (XX::Document)</a><br />
|
60
|
+
<a href="classes/XX/Document.html#M000077">pretty (XX::Document)</a><br />
|
61
|
+
<a href="classes/XX/Document.html#M000073">push (XX::Document)</a><br />
|
62
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000084">put_value (SWIG::TYPE_p_unsigned_int)</a><br />
|
63
|
+
<a href="classes/VerilogParser/Module/Port.html#M000009">reg? (VerilogParser::Module::Port)</a><br />
|
64
|
+
<a href="classes/FileUtils.html#M000088">sh (FileUtils)</a><br />
|
65
|
+
<a href="classes/Integer.html#M000024">split (Integer)</a><br />
|
66
|
+
<a href="classes/Table.html#M000027">to_html4 (Table)</a><br />
|
67
|
+
<a href="classes/Integer.html#M000014">to_limit (Integer)</a><br />
|
68
|
+
<a href="classes/Integer.html#M000016">to_mask (Integer)</a><br />
|
69
|
+
<a href="classes/Integer.html#M000018">to_max (Integer)</a><br />
|
70
|
+
<a href="classes/String.html#M000032">to_ruby_const_name (String)</a><br />
|
71
|
+
<a href="classes/XX/Document.html#M000076">to_str (XX::Document)</a><br />
|
72
|
+
<a href="classes/Table.html#M000026">to_xhtml (Table)</a><br />
|
73
|
+
<a href="classes/Table.html#M000028">to_xml (Table)</a><br />
|
74
|
+
<a href="classes/XX/Document.html#M000072">top (XX::Document)</a><br />
|
75
|
+
<a href="classes/XX/Document.html#M000075">tracking_additions (XX::Document)</a><br />
|
76
|
+
<a href="classes/Integer.html#M000022">unpack (Integer)</a><br />
|
77
|
+
<a href="classes/RDoc.html#M000092">usage_from_file (RDoc)</a><br />
|
78
|
+
<a href="classes/String.html#M000031">verilog_to_ruby (String)</a><br />
|
79
|
+
<a href="classes/RubyVpi.html#M000091">with_coverage_analysis (RubyVpi)</a><br />
|
79
80
|
<a href="files/bin/generate_test_rb.html#M000001">write_file (bin/generate_test.rb)</a><br />
|
80
|
-
<a href="classes/SWIG/TYPE_p_unsigned_int.html#
|
81
|
-
<a href="classes/XX/XHTML/Strict.html#
|
82
|
-
<a href="classes/XX/XHTML.html#
|
83
|
-
<a href="classes/XX/XHTML/Transitional.html#
|
84
|
-
<a href="classes/XX/XML.html#
|
85
|
-
<a href="classes/XX/XMLish.html#
|
86
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
87
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
88
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
89
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
90
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
91
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
92
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
93
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
94
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
95
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
96
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
97
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
98
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
99
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
100
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
101
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
102
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
103
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
104
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
105
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
106
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
107
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
108
|
-
<a href="classes/XX/Markup/ClassMethods.html#
|
109
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
110
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
111
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
112
|
-
<a href="classes/XX/Markup/InstanceMethods.html#
|
113
|
-
<a href="classes/SWIG/TYPE_p_unsigned_int.html#
|
81
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000080">x? (SWIG::TYPE_p_unsigned_int)</a><br />
|
82
|
+
<a href="classes/XX/XHTML/Strict.html#M000040">xhtml_ (XX::XHTML::Strict)</a><br />
|
83
|
+
<a href="classes/XX/XHTML.html#M000038">xhtml_ (XX::XHTML)</a><br />
|
84
|
+
<a href="classes/XX/XHTML/Transitional.html#M000039">xhtml_ (XX::XHTML::Transitional)</a><br />
|
85
|
+
<a href="classes/XX/XML.html#M000034">xml_ (XX::XML)</a><br />
|
86
|
+
<a href="classes/XX/XMLish.html#M000041">xmlish_ (XX::XMLish)</a><br />
|
87
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000047">xx_ancestors (XX::Markup::ClassMethods)</a><br />
|
88
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000067">xx_ancestors (XX::Markup::InstanceMethods)</a><br />
|
89
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000058">xx_any_ (XX::Markup::InstanceMethods)</a><br />
|
90
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000059">xx_cdata_ (XX::Markup::InstanceMethods)</a><br />
|
91
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000062">xx_class (XX::Markup::InstanceMethods)</a><br />
|
92
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000048">xx_config (XX::Markup::ClassMethods)</a><br />
|
93
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000068">xx_config (XX::Markup::InstanceMethods)</a><br />
|
94
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000049">xx_config_for (XX::Markup::ClassMethods)</a><br />
|
95
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000069">xx_config_for (XX::Markup::InstanceMethods)</a><br />
|
96
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000050">xx_configure (XX::Markup::ClassMethods)</a><br />
|
97
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000070">xx_configure (XX::Markup::InstanceMethods)</a><br />
|
98
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000045">xx_define_tag_method (XX::Markup::ClassMethods)</a><br />
|
99
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000065">xx_define_tag_method (XX::Markup::InstanceMethods)</a><br />
|
100
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000044">xx_define_tmp_method (XX::Markup::ClassMethods)</a><br />
|
101
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000064">xx_define_tmp_method (XX::Markup::InstanceMethods)</a><br />
|
102
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000055">xx_doc (XX::Markup::InstanceMethods)</a><br />
|
103
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000057">xx_markup_ (XX::Markup::InstanceMethods)</a><br />
|
104
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000060">xx_parse_attributes (XX::Markup::InstanceMethods)</a><br />
|
105
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000061">xx_parse_yaml_attributes (XX::Markup::InstanceMethods)</a><br />
|
106
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000046">xx_remove_tag_method (XX::Markup::ClassMethods)</a><br />
|
107
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000066">xx_remove_tag_method (XX::Markup::InstanceMethods)</a><br />
|
108
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000052">xx_tag_ (XX::Markup::InstanceMethods)</a><br />
|
109
|
+
<a href="classes/XX/Markup/ClassMethods.html#M000043">xx_tag_method_name (XX::Markup::ClassMethods)</a><br />
|
110
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000063">xx_tag_method_name (XX::Markup::InstanceMethods)</a><br />
|
111
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000056">xx_text_ (XX::Markup::InstanceMethods)</a><br />
|
112
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000053">xx_which (XX::Markup::InstanceMethods)</a><br />
|
113
|
+
<a href="classes/XX/Markup/InstanceMethods.html#M000054">xx_with_doc_in_effect (XX::Markup::InstanceMethods)</a><br />
|
114
|
+
<a href="classes/SWIG/TYPE_p_unsigned_int.html#M000081">z? (SWIG::TYPE_p_unsigned_int)</a><br />
|
114
115
|
</div>
|
115
116
|
</div>
|
116
117
|
</body>
|
@@ -1,5 +1,7 @@
|
|
1
1
|
/* This is the Verilog side of the bench. */
|
2
2
|
|
3
|
+
`include "counter.v"
|
4
|
+
|
3
5
|
module counter_rspecTest_bench;
|
4
6
|
|
5
7
|
// instantiate the design under test
|
@@ -8,7 +10,7 @@ module counter_rspecTest_bench;
|
|
8
10
|
reg reset;
|
9
11
|
wire [Size - 1 : 0] count;
|
10
12
|
|
11
|
-
counter #(.Size(Size))counter_rspecTest_bench_design(.clock(clock), .reset(reset), .count(count));
|
13
|
+
counter #(.Size(Size)) counter_rspecTest_bench_design(.clock(clock), .reset(reset), .count(count));
|
12
14
|
|
13
15
|
// connect to the Ruby side of this bench
|
14
16
|
initial begin
|
@@ -3,9 +3,11 @@
|
|
3
3
|
# These are source files that are to be simulated.
|
4
4
|
SIMULATOR_SOURCES = [
|
5
5
|
'counter_rspecTest_bench.v',
|
6
|
-
'counter.v',
|
7
6
|
]
|
8
7
|
|
8
|
+
# These are paths to directories which contain dependencies for the sources listed above.
|
9
|
+
SIMULATOR_INCLUDES = []
|
10
|
+
|
9
11
|
# This specifies the "top module" that is to be simulated.
|
10
12
|
SIMULATOR_TARGET = 'counter_rspecTest_bench'
|
11
13
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
/* This is the Verilog side of the bench. */
|
2
2
|
|
3
|
-
|
3
|
+
`include "counter.v"
|
4
4
|
|
5
5
|
module counter_unitTest_bench;
|
6
6
|
|
@@ -10,7 +10,7 @@ module counter_unitTest_bench;
|
|
10
10
|
reg reset;
|
11
11
|
wire [Size - 1 : 0] count;
|
12
12
|
|
13
|
-
counter #(.Size(Size))counter_unitTest_bench_design(.clock(clock), .reset(reset), .count(count));
|
13
|
+
counter #(.Size(Size)) counter_unitTest_bench_design(.clock(clock), .reset(reset), .count(count));
|
14
14
|
|
15
15
|
// connect to the Ruby side of this bench
|
16
16
|
initial begin
|
@@ -3,9 +3,11 @@
|
|
3
3
|
# These are source files that are to be simulated.
|
4
4
|
SIMULATOR_SOURCES = [
|
5
5
|
'counter_unitTest_bench.v',
|
6
|
-
'counter.v',
|
7
6
|
]
|
8
7
|
|
8
|
+
# These are paths to directories which contain dependencies for the sources listed above.
|
9
|
+
SIMULATOR_INCLUDES = []
|
10
|
+
|
9
11
|
# This specifies the "top module" that is to be simulated.
|
10
12
|
SIMULATOR_TARGET = 'counter_unitTest_bench'
|
11
13
|
|
@@ -20,75 +20,50 @@
|
|
20
20
|
|
21
21
|
# Generates random input sequences of configurable length.
|
22
22
|
class InputGenerator
|
23
|
-
|
24
23
|
# the first 1000 prime numbers, gotten from <http://en.wikipedia.org/wiki/List_of_prime_numbers#The_first_1000_prime_numbers>
|
25
24
|
PrimeNums = [
|
26
25
|
2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, 509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, 613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701, 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811, 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, 919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997, 1009, 1013, 1019, 1021, 1031, 1033, 1039, 1049, 1051, 1061, 1063, 1069, 1087, 1091, 1093, 1097, 1103, 1109, 1117, 1123, 1129, 1151, 1153, 1163, 1171, 1181, 1187, 1193, 1201, 1213, 1217, 1223, 1229, 1231, 1237, 1249, 1259, 1277, 1279, 1283, 1289, 1291, 1297, 1301, 1303, 1307, 1319, 1321, 1327, 1361, 1367, 1373, 1381, 1399, 1409, 1423, 1427, 1429, 1433, 1439, 1447, 1451, 1453, 1459, 1471, 1481, 1483, 1487, 1489, 1493, 1499, 1511, 1523, 1531, 1543, 1549, 1553, 1559, 1567, 1571, 1579, 1583, 1597, 1601, 1607, 1609, 1613, 1619, 1621, 1627, 1637, 1657, 1663, 1667, 1669, 1693, 1697, 1699, 1709, 1721, 1723, 1733, 1741, 1747, 1753, 1759, 1777, 1783, 1787, 1789, 1801, 1811, 1823, 1831, 1847, 1861, 1867, 1871, 1873, 1877, 1879, 1889, 1901, 1907, 1913, 1931, 1933, 1949, 1951, 1973, 1979, 1987, 1993, 1997, 1999, 2003, 2011, 2017, 2027, 2029, 2039, 2053, 2063, 2069, 2081, 2083, 2087, 2089, 2099, 2111, 2113, 2129, 2131, 2137, 2141, 2143, 2153, 2161, 2179, 2203, 2207, 2213, 2221, 2237, 2239, 2243, 2251, 2267, 2269, 2273, 2281, 2287, 2293, 2297, 2309, 2311, 2333, 2339, 2341, 2347, 2351, 2357, 2371, 2377, 2381, 2383, 2389, 2393, 2399, 2411, 2417, 2423, 2437, 2441, 2447, 2459, 2467, 2473, 2477, 2503, 2521, 2531, 2539, 2543, 2549, 2551, 2557, 2579, 2591, 2593, 2609, 2617, 2621, 2633, 2647, 2657, 2659, 2663, 2671, 2677, 2683, 2687, 2689, 2693, 2699, 2707, 2711, 2713, 2719, 2729, 2731, 2741, 2749, 2753, 2767, 2777, 2789, 2791, 2797, 2801, 2803, 2819, 2833, 2837, 2843, 2851, 2857, 2861, 2879, 2887, 2897, 2903, 2909, 2917, 2927, 2939, 2953, 2957, 2963, 2969, 2971, 2999, 3001, 3011, 3019, 3023, 3037, 3041, 3049, 3061, 3067, 3079, 3083, 3089, 3109, 3119, 3121, 3137, 3163, 3167, 3169, 3181, 3187, 3191, 3203, 3209, 3217, 3221, 3229, 3251, 3253, 3257, 3259, 3271, 3299, 3301, 3307, 3313, 3319, 3323, 3329, 3331, 3343, 3347, 3359, 3361, 3371, 3373, 3389, 3391, 3407, 3413, 3433, 3449, 3457, 3461, 3463, 3467, 3469, 3491, 3499, 3511, 3517, 3527, 3529, 3533, 3539, 3541, 3547, 3557, 3559, 3571, 3581, 3583, 3593, 3607, 3613, 3617, 3623, 3631, 3637, 3643, 3659, 3671, 3673, 3677, 3691, 3697, 3701, 3709, 3719, 3727, 3733, 3739, 3761, 3767, 3769, 3779, 3793, 3797, 3803, 3821, 3823, 3833, 3847, 3851, 3853, 3863, 3877, 3881, 3889, 3907, 3911, 3917, 3919, 3923, 3929, 3931, 3943, 3947, 3967, 3989, 4001, 4003, 4007, 4013, 4019, 4021, 4027, 4049, 4051, 4057, 4073, 4079, 4091, 4093, 4099, 4111, 4127, 4129, 4133, 4139, 4153, 4157, 4159, 4177, 4201, 4211, 4217, 4219, 4229, 4231, 4241, 4243, 4253, 4259, 4261, 4271, 4273, 4283, 4289, 4297, 4327, 4337, 4339, 4349, 4357, 4363, 4373, 4391, 4397, 4409, 4421, 4423, 4441, 4447, 4451, 4457, 4463, 4481, 4483, 4493, 4507, 4513, 4517, 4519, 4523, 4547, 4549, 4561, 4567, 4583, 4591, 4597, 4603, 4621, 4637, 4639, 4643, 4649, 4651, 4657, 4663, 4673, 4679, 4691, 4703, 4721, 4723, 4729, 4733, 4751, 4759, 4783, 4787, 4789, 4793, 4799, 4801, 4813, 4817, 4831, 4861, 4871, 4877, 4889, 4903, 4909, 4919, 4931, 4933, 4937, 4943, 4951, 4957, 4967, 4969, 4973, 4987, 4993, 4999, 5003, 5009, 5011, 5021, 5023, 5039, 5051, 5059, 5077, 5081, 5087, 5099, 5101, 5107, 5113, 5119, 5147, 5153, 5167, 5171, 5179, 5189, 5197, 5209, 5227, 5231, 5233, 5237, 5261, 5273, 5279, 5281, 5297, 5303, 5309, 5323, 5333, 5347, 5351, 5381, 5387, 5393, 5399, 5407, 5413, 5417, 5419, 5431, 5437, 5441, 5443, 5449, 5471, 5477, 5479, 5483, 5501, 5503, 5507, 5519, 5521, 5527, 5531, 5557, 5563, 5569, 5573, 5581, 5591, 5623, 5639, 5641, 5647, 5651, 5653, 5657, 5659, 5669, 5683, 5689, 5693, 5701, 5711, 5717, 5737, 5741, 5743, 5749, 5779, 5783, 5791, 5801, 5807, 5813, 5821, 5827, 5839, 5843, 5849, 5851, 5857, 5861, 5867, 5869, 5879, 5881, 5897, 5903, 5923, 5927, 5939, 5953, 5981, 5987, 6007, 6011, 6029, 6037, 6043, 6047, 6053, 6067, 6073, 6079, 6089, 6091, 6101, 6113, 6121, 6131, 6133, 6143, 6151, 6163, 6173, 6197, 6199, 6203, 6211, 6217, 6221, 6229, 6247, 6257, 6263, 6269, 6271, 6277, 6287, 6299, 6301, 6311, 6317, 6323, 6329, 6337, 6343, 6353, 6359, 6361, 6367, 6373, 6379, 6389, 6397, 6421, 6427, 6449, 6451, 6469, 6473, 6481, 6491, 6521, 6529, 6547, 6551, 6553, 6563, 6569, 6571, 6577, 6581, 6599, 6607, 6619, 6637, 6653, 6659, 6661, 6673, 6679, 6689, 6691, 6701, 6703, 6709, 6719, 6733, 6737, 6761, 6763, 6779, 6781, 6791, 6793, 6803, 6823, 6827, 6829, 6833, 6841, 6857, 6863, 6869, 6871, 6883, 6899, 6907, 6911, 6917, 6947, 6949, 6959, 6961, 6967, 6971, 6977, 6983, 6991, 6997, 7001, 7013, 7019, 7027, 7039, 7043, 7057, 7069, 7079, 7103, 7109, 7121, 7127, 7129, 7151, 7159, 7177, 7187, 7193, 7207, 7211, 7213, 7219, 7229, 7237, 7243, 7247, 7253, 7283, 7297, 7307, 7309, 7321, 7331, 7333, 7349, 7351, 7369, 7393, 7411, 7417, 7433, 7451, 7457, 7459, 7477, 7481, 7487, 7489, 7499, 7507, 7517, 7523, 7529, 7537, 7541, 7547, 7549, 7559, 7561, 7573, 7577, 7583, 7589, 7591, 7603, 7607, 7621, 7639, 7643, 7649, 7669, 7673, 7681, 7687, 7691, 7699, 7703, 7717, 7723, 7727, 7741, 7753, 7757, 7759, 7789, 7793, 7817, 7823, 7829, 7841, 7853, 7867, 7873, 7877, 7879, 7883, 7901, 7907, 7919
|
27
26
|
]
|
28
27
|
|
29
|
-
|
30
|
-
|
31
|
-
# @param bits Number of bits that can be used to represent a generated input sequence
|
28
|
+
# Constructs a new input sequence generator.
|
29
|
+
# bits:: Number of bits that can be used to represent a generated input sequence
|
32
30
|
def initialize(bits)
|
33
31
|
self.bits = bits
|
34
32
|
end
|
35
33
|
|
36
|
-
|
37
|
-
|
38
|
-
# gets the number of bits that can be used to represent a generated input sequence
|
34
|
+
# returns the number of bits that can be used to represent a generated input sequence
|
39
35
|
def bits
|
40
36
|
@inputBits
|
41
37
|
end
|
42
38
|
|
43
|
-
|
44
|
-
|
45
39
|
# sets the number of bits that can be used to represent a generated input sequence
|
46
40
|
def bits=(num)
|
47
41
|
@inputBits = num
|
48
42
|
@inputLimit = 2 ** @inputBits
|
49
43
|
end
|
50
44
|
|
51
|
-
|
52
|
-
|
53
45
|
# generates a random input sequence
|
54
46
|
def gen
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
when 2 # zero
|
65
|
-
0
|
66
|
-
|
67
|
-
when 3 # one
|
68
|
-
1
|
69
|
-
|
70
|
-
when 4 # prime numbers
|
71
|
-
genPrime
|
72
|
-
|
73
|
-
when 5 # power-of-two numbers
|
74
|
-
genPowerOfTwo
|
75
|
-
end
|
47
|
+
choices = [
|
48
|
+
0,
|
49
|
+
1,
|
50
|
+
gen_prime,
|
51
|
+
gen_power_of_two,
|
52
|
+
rand(@inputLimit),
|
53
|
+
]
|
54
|
+
|
55
|
+
choices[rand(choices.length)]
|
76
56
|
end
|
77
57
|
|
78
|
-
|
79
|
-
|
80
58
|
# generates a random prime number
|
81
|
-
def
|
82
|
-
prime = PrimeNums[rand(PrimeNums.
|
59
|
+
def gen_prime
|
60
|
+
prime = PrimeNums[rand(PrimeNums.length)]
|
83
61
|
prime < @inputLimit ? prime : 2
|
84
62
|
end
|
85
63
|
|
86
|
-
|
87
|
-
|
88
64
|
# generates a random power-of-two number
|
89
|
-
def
|
65
|
+
def gen_power_of_two
|
90
66
|
power = rand(@inputBits) + 1
|
91
67
|
(2 ** power) - 1
|
92
68
|
end
|
93
|
-
|
94
69
|
end
|
@@ -1,11 +1,6 @@
|
|
1
1
|
/* This is the Verilog side of the bench. */
|
2
2
|
|
3
|
-
`
|
4
|
-
`define DATABITS 7
|
5
|
-
`define OP_NOP 0
|
6
|
-
`define OP_ADD 1
|
7
|
-
`define OP_SUB 2
|
8
|
-
`define OP_MULT 3
|
3
|
+
`include "hw5_unit.v"
|
9
4
|
|
10
5
|
module hw5_unit_test_bench;
|
11
6
|
|
@@ -20,7 +15,7 @@ module hw5_unit_test_bench;
|
|
20
15
|
wire [`DATABITS-1:0] out_databits;
|
21
16
|
wire [1:0] out_op;
|
22
17
|
|
23
|
-
hw5_unit
|
18
|
+
hw5_unit hw5_unit_test_bench_design(.clk(clk), .reset(reset), .in_databits(in_databits), .a(a), .b(b), .in_op(in_op), .res(res), .out_databits(out_databits), .out_op(out_op));
|
24
19
|
|
25
20
|
// connect to the Ruby side of this bench
|
26
21
|
initial begin
|
@@ -1,8 +1,13 @@
|
|
1
1
|
# A prototype of the design under test.
|
2
2
|
class Hw5_unitPrototype < Hw5_unit
|
3
3
|
def simulate!
|
4
|
-
#
|
5
|
-
|
6
|
-
|
4
|
+
# discard old outputs
|
5
|
+
@res.hexStrVal = 'x'
|
6
|
+
@out_databits.hexStrVal = 'x'
|
7
|
+
@out_op.hexStrVal = 'x'
|
8
|
+
|
9
|
+
# process new inputs
|
10
|
+
|
11
|
+
# produce new outputs
|
7
12
|
end
|
8
13
|
end
|
@@ -3,9 +3,11 @@
|
|
3
3
|
# These are source files that are to be simulated.
|
4
4
|
SIMULATOR_SOURCES = [
|
5
5
|
'hw5_unit_test_bench.v',
|
6
|
-
'hw5_unit.v',
|
7
6
|
]
|
8
7
|
|
8
|
+
# These are paths to directories which contain dependencies for the sources listed above.
|
9
|
+
SIMULATOR_INCLUDES = []
|
10
|
+
|
9
11
|
# This specifies the "top module" that is to be simulated.
|
10
12
|
SIMULATOR_TARGET = 'hw5_unit_test_bench'
|
11
13
|
|
@@ -34,10 +34,10 @@ class Hw5_unit_test_spec < Test::Unit::TestCase
|
|
34
34
|
OPERATION_TAG_LIMIT = 2 ** Hw5_unit::DATABITS
|
35
35
|
|
36
36
|
def setup
|
37
|
-
@ig = InputGenerator.new(Hw5_unit::WIDTH)
|
38
|
-
|
39
37
|
@design = Hw5_unit.new
|
40
38
|
@design.reset!
|
39
|
+
|
40
|
+
@inputGen = InputGenerator.new(Hw5_unit::WIDTH)
|
41
41
|
end
|
42
42
|
|
43
43
|
def test_pipeline
|
@@ -50,8 +50,8 @@ class Hw5_unit_test_spec < Test::Unit::TestCase
|
|
50
50
|
op = Hw5_unit::Operation.new(
|
51
51
|
Hw5_unit::OPERATIONS[rand(Hw5_unit::OPERATIONS.size)],
|
52
52
|
numIssued % OPERATION_TAG_LIMIT,
|
53
|
-
@
|
54
|
-
@
|
53
|
+
@inputGen.gen,
|
54
|
+
@inputGen.gen
|
55
55
|
)
|
56
56
|
|
57
57
|
@design.a.intVal = op.arg1
|