avl-core 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- avl_core-0.1.0/LICENSE +21 -0
- avl_core-0.1.0/PKG-INFO +164 -0
- avl_core-0.1.0/README.md +114 -0
- avl_core-0.1.0/avl/__init__.py +141 -0
- avl_core-0.1.0/avl/_core/__init__.py +93 -0
- avl_core-0.1.0/avl/_core/agent.py +20 -0
- avl_core-0.1.0/avl/_core/bool.py +46 -0
- avl_core-0.1.0/avl/_core/component.py +169 -0
- avl_core-0.1.0/avl/_core/coverage.py +74 -0
- avl_core-0.1.0/avl/_core/coverbin.py +177 -0
- avl_core-0.1.0/avl/_core/covercross.py +67 -0
- avl_core-0.1.0/avl/_core/covergroup.py +143 -0
- avl_core-0.1.0/avl/_core/coverpoint.py +207 -0
- avl_core-0.1.0/avl/_core/driver.py +25 -0
- avl_core-0.1.0/avl/_core/enum.py +126 -0
- avl_core-0.1.0/avl/_core/env.py +108 -0
- avl_core-0.1.0/avl/_core/factory.py +130 -0
- avl_core-0.1.0/avl/_core/fifo.py +91 -0
- avl_core-0.1.0/avl/_core/float.py +191 -0
- avl_core-0.1.0/avl/_core/int.py +176 -0
- avl_core-0.1.0/avl/_core/list.py +109 -0
- avl_core-0.1.0/avl/_core/log.py +301 -0
- avl_core-0.1.0/avl/_core/logic.py +95 -0
- avl_core-0.1.0/avl/_core/model.py +25 -0
- avl_core-0.1.0/avl/_core/monitor.py +24 -0
- avl_core-0.1.0/avl/_core/object.py +586 -0
- avl_core-0.1.0/avl/_core/phase.py +87 -0
- avl_core-0.1.0/avl/_core/phase_manager.py +109 -0
- avl_core-0.1.0/avl/_core/port.py +49 -0
- avl_core-0.1.0/avl/_core/scoreboard.py +80 -0
- avl_core-0.1.0/avl/_core/scoreboard_indexed.py +87 -0
- avl_core-0.1.0/avl/_core/sequence.py +157 -0
- avl_core-0.1.0/avl/_core/sequence_item.py +90 -0
- avl_core-0.1.0/avl/_core/sequencer.py +149 -0
- avl_core-0.1.0/avl/_core/transaction.py +108 -0
- avl_core-0.1.0/avl/_core/uint.py +169 -0
- avl_core-0.1.0/avl/_core/var.py +399 -0
- avl_core-0.1.0/avl/_core/visualization.py +113 -0
- avl_core-0.1.0/avl/templates/__init__.py +14 -0
- avl_core-0.1.0/avl/templates/_vanilla.py +188 -0
- avl_core-0.1.0/pyproject.toml +57 -0
avl_core-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) [2025] [avl@projectapheleia.net]
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
avl_core-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
|
+
Name: avl-core
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Apheleia Verification Library. A set of Python base classes for efficient HDL verification.
|
|
5
|
+
License: MIT License
|
|
6
|
+
|
|
7
|
+
Copyright (c) [2025] [avl@projectapheleia.net]
|
|
8
|
+
|
|
9
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
10
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
11
|
+
in the Software without restriction, including without limitation the rights
|
|
12
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
13
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
14
|
+
furnished to do so, subject to the following conditions:
|
|
15
|
+
|
|
16
|
+
The above copyright notice and this permission notice shall be included in all
|
|
17
|
+
copies or substantial portions of the Software.
|
|
18
|
+
|
|
19
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
20
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
21
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
22
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
23
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
24
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
25
|
+
SOFTWARE.
|
|
26
|
+
Author: avl
|
|
27
|
+
Author-email: avl@projectapheleia.net
|
|
28
|
+
Maintainer: avl
|
|
29
|
+
Maintainer-email: avl@projectapheleia.net
|
|
30
|
+
Requires-Python: >=3.10
|
|
31
|
+
Classifier: Development Status :: 4 - Beta
|
|
32
|
+
Classifier: Programming Language :: Python
|
|
33
|
+
Provides-Extra: dev
|
|
34
|
+
Requires-Dist: anytree (>=2.13.0)
|
|
35
|
+
Requires-Dist: black (>=22.3.0) ; extra == "dev"
|
|
36
|
+
Requires-Dist: cocotb (>=1.9.1)
|
|
37
|
+
Requires-Dist: graphviz (>=0.20.3)
|
|
38
|
+
Requires-Dist: matplotlib (>=3.10.0) ; extra == "dev"
|
|
39
|
+
Requires-Dist: mypy (>=0.910) ; extra == "dev"
|
|
40
|
+
Requires-Dist: pandas (>=2.2.3)
|
|
41
|
+
Requires-Dist: pytest (>=7.0) ; extra == "dev"
|
|
42
|
+
Requires-Dist: pyyml (>=0.0.2)
|
|
43
|
+
Requires-Dist: ruff (>=0.11.0) ; extra == "dev"
|
|
44
|
+
Requires-Dist: sphinx (>=8.1.3) ; extra == "dev"
|
|
45
|
+
Requires-Dist: sphinx_rtd_theme (>=3.0.2) ; extra == "dev"
|
|
46
|
+
Requires-Dist: tabulate (>=0.9.0)
|
|
47
|
+
Requires-Dist: z3-solver (>=4.15.0.0)
|
|
48
|
+
Description-Content-Type: text/markdown
|
|
49
|
+
|
|
50
|
+
# AVL - Apheleia Verification Library
|
|
51
|
+
|
|
52
|
+
[](LICENSE)
|
|
53
|
+
[](https://www.python.org/)
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
AVL has been developed by experienced, industry professional verification engineers to provide a methodology \
|
|
57
|
+
and library of base classes for developing functional verification environments in [Python](https://www.python.org/).
|
|
58
|
+
|
|
59
|
+
AVL is built on the [CocoTB](https://docs.cocotb.org/en/stable/) framework, but aims to combine the best elements of \
|
|
60
|
+
[UVM](https://accellera.org/community/uvm) in a more engineer friendly and efficient way.
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## 📦 Installation
|
|
66
|
+
|
|
67
|
+
### Using `pip`
|
|
68
|
+
```sh
|
|
69
|
+
# Standard build
|
|
70
|
+
pip install avl-core
|
|
71
|
+
|
|
72
|
+
# Development build
|
|
73
|
+
pip install avl-core[dev]
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
### Install from Source
|
|
77
|
+
```sh
|
|
78
|
+
git clone https://github.com/projectapheleia/avl.git
|
|
79
|
+
cd avl
|
|
80
|
+
|
|
81
|
+
# Standard build
|
|
82
|
+
pip install .
|
|
83
|
+
|
|
84
|
+
# Development build
|
|
85
|
+
pip install .[dev]
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Alternatively if you want to create a [virtual environment](https://docs.python.org/3/library/venv.html) rather than install globally a script is provided. This will install, with edit privileges to local virtual environment.
|
|
89
|
+
|
|
90
|
+
This script assumes you have [Verilator](https://www.veripool.org/verilator/), [GTKWave](https://gtkwave.sourceforge.net/) and [Graphviz](https://graphviz.org/download/) installed, so all examples and documentation will build out of the box.
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
```sh
|
|
94
|
+
git clone https://github.com/projectapheleia/avl.git
|
|
95
|
+
cd avl
|
|
96
|
+
source avl.sh
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
## 📖 Documentation
|
|
100
|
+
|
|
101
|
+
In order to build the documentation you must have installed the development build.
|
|
102
|
+
|
|
103
|
+
### Build from Source
|
|
104
|
+
```sh
|
|
105
|
+
cd docs
|
|
106
|
+
make html
|
|
107
|
+
<browser> build/html/index.html
|
|
108
|
+
```
|
|
109
|
+
## 🏃 Examples
|
|
110
|
+
|
|
111
|
+
In order to run all the examples you must have installed the development build.
|
|
112
|
+
|
|
113
|
+
To run all examples:
|
|
114
|
+
|
|
115
|
+
```sh
|
|
116
|
+
cd examples
|
|
117
|
+
|
|
118
|
+
# To run
|
|
119
|
+
make -j 8 sim
|
|
120
|
+
|
|
121
|
+
# To clean
|
|
122
|
+
make -j 8 clean
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
To run an individual example:
|
|
126
|
+
|
|
127
|
+
```sh
|
|
128
|
+
cd examples/THE EXAMPLE YOU WANT
|
|
129
|
+
|
|
130
|
+
# To run
|
|
131
|
+
make sim
|
|
132
|
+
|
|
133
|
+
# To clean
|
|
134
|
+
make clean
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
The examples use the [CocoTB Makefile](https://docs.cocotb.org/en/stable/building.html) and default to [Verilator](https://www.veripool.org/verilator/) with all waveforms generated. This can be modified using the standard CocoTB build system.
|
|
138
|
+
|
|
139
|
+
---
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
## 🧹 Code Style & Linting
|
|
143
|
+
|
|
144
|
+
This project uses [**Ruff**](https://docs.astral.sh/ruff/) for linting and formatting.
|
|
145
|
+
|
|
146
|
+
Check code for issues:
|
|
147
|
+
|
|
148
|
+
```sh
|
|
149
|
+
ruff check .
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
Automatically fix common issues:
|
|
153
|
+
|
|
154
|
+
```sh
|
|
155
|
+
ruff check . --fix
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
## 📧 Contact
|
|
161
|
+
|
|
162
|
+
- Email: avl@projectapheleia.net
|
|
163
|
+
- GitHub: [projectapheleia](https://github.com/projectapheleia)
|
|
164
|
+
|
avl_core-0.1.0/README.md
ADDED
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# AVL - Apheleia Verification Library
|
|
2
|
+
|
|
3
|
+
[](LICENSE)
|
|
4
|
+
[](https://www.python.org/)
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
AVL has been developed by experienced, industry professional verification engineers to provide a methodology \
|
|
8
|
+
and library of base classes for developing functional verification environments in [Python](https://www.python.org/).
|
|
9
|
+
|
|
10
|
+
AVL is built on the [CocoTB](https://docs.cocotb.org/en/stable/) framework, but aims to combine the best elements of \
|
|
11
|
+
[UVM](https://accellera.org/community/uvm) in a more engineer friendly and efficient way.
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
## 📦 Installation
|
|
17
|
+
|
|
18
|
+
### Using `pip`
|
|
19
|
+
```sh
|
|
20
|
+
# Standard build
|
|
21
|
+
pip install avl-core
|
|
22
|
+
|
|
23
|
+
# Development build
|
|
24
|
+
pip install avl-core[dev]
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### Install from Source
|
|
28
|
+
```sh
|
|
29
|
+
git clone https://github.com/projectapheleia/avl.git
|
|
30
|
+
cd avl
|
|
31
|
+
|
|
32
|
+
# Standard build
|
|
33
|
+
pip install .
|
|
34
|
+
|
|
35
|
+
# Development build
|
|
36
|
+
pip install .[dev]
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Alternatively if you want to create a [virtual environment](https://docs.python.org/3/library/venv.html) rather than install globally a script is provided. This will install, with edit privileges to local virtual environment.
|
|
40
|
+
|
|
41
|
+
This script assumes you have [Verilator](https://www.veripool.org/verilator/), [GTKWave](https://gtkwave.sourceforge.net/) and [Graphviz](https://graphviz.org/download/) installed, so all examples and documentation will build out of the box.
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
```sh
|
|
45
|
+
git clone https://github.com/projectapheleia/avl.git
|
|
46
|
+
cd avl
|
|
47
|
+
source avl.sh
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## 📖 Documentation
|
|
51
|
+
|
|
52
|
+
In order to build the documentation you must have installed the development build.
|
|
53
|
+
|
|
54
|
+
### Build from Source
|
|
55
|
+
```sh
|
|
56
|
+
cd docs
|
|
57
|
+
make html
|
|
58
|
+
<browser> build/html/index.html
|
|
59
|
+
```
|
|
60
|
+
## 🏃 Examples
|
|
61
|
+
|
|
62
|
+
In order to run all the examples you must have installed the development build.
|
|
63
|
+
|
|
64
|
+
To run all examples:
|
|
65
|
+
|
|
66
|
+
```sh
|
|
67
|
+
cd examples
|
|
68
|
+
|
|
69
|
+
# To run
|
|
70
|
+
make -j 8 sim
|
|
71
|
+
|
|
72
|
+
# To clean
|
|
73
|
+
make -j 8 clean
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
To run an individual example:
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
cd examples/THE EXAMPLE YOU WANT
|
|
80
|
+
|
|
81
|
+
# To run
|
|
82
|
+
make sim
|
|
83
|
+
|
|
84
|
+
# To clean
|
|
85
|
+
make clean
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
The examples use the [CocoTB Makefile](https://docs.cocotb.org/en/stable/building.html) and default to [Verilator](https://www.veripool.org/verilator/) with all waveforms generated. This can be modified using the standard CocoTB build system.
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
## 🧹 Code Style & Linting
|
|
94
|
+
|
|
95
|
+
This project uses [**Ruff**](https://docs.astral.sh/ruff/) for linting and formatting.
|
|
96
|
+
|
|
97
|
+
Check code for issues:
|
|
98
|
+
|
|
99
|
+
```sh
|
|
100
|
+
ruff check .
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
Automatically fix common issues:
|
|
104
|
+
|
|
105
|
+
```sh
|
|
106
|
+
ruff check . --fix
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
## 📧 Contact
|
|
112
|
+
|
|
113
|
+
- Email: avl@projectapheleia.net
|
|
114
|
+
- GitHub: [projectapheleia](https://github.com/projectapheleia)
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
from ._core import (
|
|
2
|
+
Agent as Agent,
|
|
3
|
+
)
|
|
4
|
+
from ._core import (
|
|
5
|
+
Bool as Bool,
|
|
6
|
+
)
|
|
7
|
+
from ._core import (
|
|
8
|
+
Byte as Byte,
|
|
9
|
+
)
|
|
10
|
+
from ._core import (
|
|
11
|
+
Component as Component,
|
|
12
|
+
)
|
|
13
|
+
from ._core import (
|
|
14
|
+
Coverage as Coverage,
|
|
15
|
+
)
|
|
16
|
+
from ._core import (
|
|
17
|
+
Coverbin as Coverbin,
|
|
18
|
+
)
|
|
19
|
+
from ._core import (
|
|
20
|
+
Covercross as Covercross,
|
|
21
|
+
)
|
|
22
|
+
from ._core import (
|
|
23
|
+
Covergroup as Covergroup,
|
|
24
|
+
)
|
|
25
|
+
from ._core import (
|
|
26
|
+
Coverpoint as Coverpoint,
|
|
27
|
+
)
|
|
28
|
+
from ._core import (
|
|
29
|
+
Double as Double,
|
|
30
|
+
)
|
|
31
|
+
from ._core import (
|
|
32
|
+
Driver as Driver,
|
|
33
|
+
)
|
|
34
|
+
from ._core import (
|
|
35
|
+
Enum as Enum,
|
|
36
|
+
)
|
|
37
|
+
from ._core import (
|
|
38
|
+
Env as Env,
|
|
39
|
+
)
|
|
40
|
+
from ._core import (
|
|
41
|
+
Factory as Factory,
|
|
42
|
+
)
|
|
43
|
+
from ._core import (
|
|
44
|
+
Fifo as Fifo,
|
|
45
|
+
)
|
|
46
|
+
from ._core import (
|
|
47
|
+
Float as Float,
|
|
48
|
+
)
|
|
49
|
+
from ._core import (
|
|
50
|
+
Fp16 as Fp16,
|
|
51
|
+
)
|
|
52
|
+
from ._core import (
|
|
53
|
+
Fp32 as Fp32,
|
|
54
|
+
)
|
|
55
|
+
from ._core import (
|
|
56
|
+
Fp64 as Fp64,
|
|
57
|
+
)
|
|
58
|
+
from ._core import (
|
|
59
|
+
Half as Half,
|
|
60
|
+
)
|
|
61
|
+
from ._core import (
|
|
62
|
+
IndexedScoreboard as IndexedScoreboard,
|
|
63
|
+
)
|
|
64
|
+
from ._core import (
|
|
65
|
+
Int as Int,
|
|
66
|
+
)
|
|
67
|
+
from ._core import (
|
|
68
|
+
Int8 as Int8,
|
|
69
|
+
)
|
|
70
|
+
from ._core import (
|
|
71
|
+
Int16 as Int16,
|
|
72
|
+
)
|
|
73
|
+
from ._core import (
|
|
74
|
+
Int32 as Int32,
|
|
75
|
+
)
|
|
76
|
+
from ._core import (
|
|
77
|
+
Int64 as Int64,
|
|
78
|
+
)
|
|
79
|
+
from ._core import (
|
|
80
|
+
List as List,
|
|
81
|
+
)
|
|
82
|
+
from ._core import (
|
|
83
|
+
Log as Log,
|
|
84
|
+
)
|
|
85
|
+
from ._core import (
|
|
86
|
+
Logic as Logic,
|
|
87
|
+
)
|
|
88
|
+
from ._core import (
|
|
89
|
+
Model as Model,
|
|
90
|
+
)
|
|
91
|
+
from ._core import (
|
|
92
|
+
Monitor as Monitor,
|
|
93
|
+
)
|
|
94
|
+
from ._core import (
|
|
95
|
+
Object as Object,
|
|
96
|
+
)
|
|
97
|
+
from ._core import (
|
|
98
|
+
Phase as Phase,
|
|
99
|
+
)
|
|
100
|
+
from ._core import (
|
|
101
|
+
PhaseManager as PhaseManager,
|
|
102
|
+
)
|
|
103
|
+
from ._core import (
|
|
104
|
+
Port as Port,
|
|
105
|
+
)
|
|
106
|
+
from ._core import (
|
|
107
|
+
Queue as Queue,
|
|
108
|
+
)
|
|
109
|
+
from ._core import (
|
|
110
|
+
Scoreboard as Scoreboard,
|
|
111
|
+
)
|
|
112
|
+
from ._core import (
|
|
113
|
+
Sequence as Sequence,
|
|
114
|
+
)
|
|
115
|
+
from ._core import (
|
|
116
|
+
SequenceItem as SequenceItem,
|
|
117
|
+
)
|
|
118
|
+
from ._core import (
|
|
119
|
+
Sequencer as Sequencer,
|
|
120
|
+
)
|
|
121
|
+
from ._core import (
|
|
122
|
+
Transaction as Transaction,
|
|
123
|
+
)
|
|
124
|
+
from ._core import (
|
|
125
|
+
Uint as Uint,
|
|
126
|
+
)
|
|
127
|
+
from ._core import (
|
|
128
|
+
Uint8 as Uint8,
|
|
129
|
+
)
|
|
130
|
+
from ._core import (
|
|
131
|
+
Uint16 as Uint16,
|
|
132
|
+
)
|
|
133
|
+
from ._core import (
|
|
134
|
+
Uint32 as Uint32,
|
|
135
|
+
)
|
|
136
|
+
from ._core import (
|
|
137
|
+
Uint64 as Uint64,
|
|
138
|
+
)
|
|
139
|
+
from ._core import (
|
|
140
|
+
Visualization as Visualization,
|
|
141
|
+
)
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
from .agent import Agent
|
|
2
|
+
from .bool import Bool
|
|
3
|
+
from .component import Component
|
|
4
|
+
from .coverage import Coverage
|
|
5
|
+
from .coverbin import Coverbin
|
|
6
|
+
from .covercross import Covercross
|
|
7
|
+
from .covergroup import Covergroup
|
|
8
|
+
from .coverpoint import Coverpoint
|
|
9
|
+
from .driver import Driver
|
|
10
|
+
from .enum import Enum
|
|
11
|
+
from .env import Env
|
|
12
|
+
from .factory import Factory
|
|
13
|
+
from .fifo import Fifo
|
|
14
|
+
from .float import Double, Float, Fp16, Fp32, Fp64, Half
|
|
15
|
+
from .int import Byte, Int, Int8, Int16, Int32, Int64
|
|
16
|
+
from .list import List, Queue
|
|
17
|
+
from .log import Log
|
|
18
|
+
from .logic import Logic
|
|
19
|
+
from .model import Model
|
|
20
|
+
from .monitor import Monitor
|
|
21
|
+
from .object import Object
|
|
22
|
+
from .phase import Phase
|
|
23
|
+
from .phase_manager import PhaseManager
|
|
24
|
+
from .port import Port
|
|
25
|
+
from .scoreboard import Scoreboard
|
|
26
|
+
from .scoreboard_indexed import IndexedScoreboard
|
|
27
|
+
from .sequence import Sequence
|
|
28
|
+
from .sequence_item import SequenceItem
|
|
29
|
+
from .sequencer import Sequencer
|
|
30
|
+
from .transaction import Transaction
|
|
31
|
+
from .uint import Uint, Uint8, Uint16, Uint32, Uint64
|
|
32
|
+
from .visualization import Visualization
|
|
33
|
+
|
|
34
|
+
# Enable logging
|
|
35
|
+
Log._override_cocotb_logging()
|
|
36
|
+
|
|
37
|
+
# Add default phases
|
|
38
|
+
PhaseManager.add_phase("RUN", None, top_down=False)
|
|
39
|
+
PhaseManager.add_phase("REPORT", PhaseManager.get_phase("RUN"), top_down=False)
|
|
40
|
+
|
|
41
|
+
# Add version
|
|
42
|
+
__version__: str = "0.1.0"
|
|
43
|
+
|
|
44
|
+
__all__ = [
|
|
45
|
+
"__version__",
|
|
46
|
+
"Log",
|
|
47
|
+
"List",
|
|
48
|
+
"Queue",
|
|
49
|
+
"Fifo",
|
|
50
|
+
"Port",
|
|
51
|
+
"Phase",
|
|
52
|
+
"Phase_Manager",
|
|
53
|
+
"Object",
|
|
54
|
+
"Transaction",
|
|
55
|
+
"Component",
|
|
56
|
+
"Driver",
|
|
57
|
+
"Sequencer",
|
|
58
|
+
"Monitor",
|
|
59
|
+
"Model",
|
|
60
|
+
"Scoreboard",
|
|
61
|
+
"IndexedScoreboard",
|
|
62
|
+
"Agent",
|
|
63
|
+
"Env",
|
|
64
|
+
"SequenceItem",
|
|
65
|
+
"Sequence",
|
|
66
|
+
"Logic",
|
|
67
|
+
"Bool",
|
|
68
|
+
"Int",
|
|
69
|
+
"Int8",
|
|
70
|
+
"Byte",
|
|
71
|
+
"Int16",
|
|
72
|
+
"Int32",
|
|
73
|
+
"Int64",
|
|
74
|
+
"Uint",
|
|
75
|
+
"Uint8",
|
|
76
|
+
"Uint16",
|
|
77
|
+
"Uint32",
|
|
78
|
+
"Uint64",
|
|
79
|
+
"Fp16",
|
|
80
|
+
"Half",
|
|
81
|
+
"Fp32",
|
|
82
|
+
"Float",
|
|
83
|
+
"Fp64",
|
|
84
|
+
"Double",
|
|
85
|
+
"Enum",
|
|
86
|
+
"Coverbin",
|
|
87
|
+
"Coverpoint",
|
|
88
|
+
"Covercross",
|
|
89
|
+
"Covergroup",
|
|
90
|
+
"Coverage",
|
|
91
|
+
"Visualization",
|
|
92
|
+
"Factory",
|
|
93
|
+
]
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Copyright 2024 Apheleia
|
|
2
|
+
#
|
|
3
|
+
# Description:
|
|
4
|
+
# Apheleia Verification Library Agent
|
|
5
|
+
|
|
6
|
+
from .component import Component
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class Agent(Component):
|
|
10
|
+
def __init__(self, name: str, parent: Component) -> None:
|
|
11
|
+
"""
|
|
12
|
+
Initialize the avl_agent instance.
|
|
13
|
+
:param name: Name of the agent instance
|
|
14
|
+
:type name: str
|
|
15
|
+
:param parent: Parent component
|
|
16
|
+
:type parent: Component
|
|
17
|
+
"""
|
|
18
|
+
super().__init__(name, parent)
|
|
19
|
+
|
|
20
|
+
__all__ = ["Agent"]
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# Copyright 2024 Apheleia
|
|
2
|
+
#
|
|
3
|
+
# Description:
|
|
4
|
+
# Apheleia Verification Library Variable Class
|
|
5
|
+
|
|
6
|
+
from collections.abc import Callable
|
|
7
|
+
from typing import Any
|
|
8
|
+
|
|
9
|
+
from .logic import Logic
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class Bool(Logic):
|
|
13
|
+
def __init__(self, name: str, value: bool, auto_random: bool = True, fmt : Callable[..., int] = str) -> None:
|
|
14
|
+
"""
|
|
15
|
+
Initialize an instance of the Bool class.
|
|
16
|
+
|
|
17
|
+
:param name: The name of the instance.
|
|
18
|
+
:type name: str
|
|
19
|
+
:param value: The initial value of the instance.
|
|
20
|
+
:type value: bool
|
|
21
|
+
:param auto_random: Flag indicating whether the instance should be automatically randomized, defaults to True.
|
|
22
|
+
:type auto_random: bool, optional
|
|
23
|
+
"""
|
|
24
|
+
super().__init__(name, value, auto_random=auto_random, fmt=fmt, width=1)
|
|
25
|
+
|
|
26
|
+
def _cast_(self, other: Any) -> int:
|
|
27
|
+
"""
|
|
28
|
+
Cast the value to the appropriate type based on the width of the variable.
|
|
29
|
+
:param other: The value to be cast.
|
|
30
|
+
:type other: Any
|
|
31
|
+
:return: The casted value.
|
|
32
|
+
:rtype: bool
|
|
33
|
+
"""
|
|
34
|
+
return bool(super()._cast_(other))
|
|
35
|
+
|
|
36
|
+
def _wrap_(self, result : Any) -> Logic:
|
|
37
|
+
"""
|
|
38
|
+
Wrap the result in an Logic instance.
|
|
39
|
+
:param result: The result to be wrapped.
|
|
40
|
+
:type result: Any
|
|
41
|
+
:return: An instance of Logic with the result.
|
|
42
|
+
:rtype: Logic
|
|
43
|
+
"""
|
|
44
|
+
return type(self)(self.name, result, auto_random=self._auto_random_, fmt=self._fmt_)
|
|
45
|
+
|
|
46
|
+
__all__ = ["Bool"]
|