1 <?xml version=
"1.0" encoding=
"UTF-8"?>
4 file_name: example5.vut
5 Author: Rodrigo Peixoto
8 ======================================================================
10 This program is free software: you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation, either version 3 of the License, or
13 (at your option) any later version.
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program. If not, see http://www.gnu.org/licenses/.
23 =======================================================================
26 <vut module_name=
"fulladder">
27 <time_scale t_div=
"10" unit=
"ns"/>
29 =========================================================
30 a[
7:
0] i@|
00|
00|ff|ff|random_alloc([R1,R2,R3],
1000000)|
31 --------------------------------------------
32 b[
7:
0] i@|
00|ff|
00|ff|random_alloc([R4,R5,R6],
1000000)|
33 =========================================================
34 result[
7:
0]o@|
00|ff|ff|fe|ref_function(a,b)|
35 --------------------------------------------
36 overflow o@|
0 |
0 |
0 |
1 |ref_function(a,b)|
37 ============================================
46 <python_code output=
"result">lambda a,b: a + b
</python_code>
47 <python_code output=
"overflow">include_python_file(
"overflow.py")
</python_code>