* src/cover: Show LHS/RHS arrows in the HTML report.
* src/cover: Add function name for expression coverage. Split loc and tree for emitted cover tags to distinguish branch type and branch condition location. Add titles and print also multi-line code samples for coverage tags.
---------
Co-authored-by: Ondrej Ille <ondrej.ille@tropicsqaure.com>
Sean Anderson [Thu, 22 Jun 2023 01:10:26 +0000 (21:10 -0400)]
vhpi: Add support for getting record types by name
When cocotb tries to access an object with a name like `VHPI5.O.F`, it
doesn't know whether O is a signal or a record. This ambiguity could be
resolved by trying to look up the name like `:VHPI5:O.F` or
`:VHPI5:O:F`, but cocotb can't determine which to use ahead of time.
This is a limitation of cocotb, but probably not one which will ever get
resolved.
Add support for looking up record types by name, primarily to allow
cocotb to access them.
Sean Anderson [Thu, 22 Jun 2023 01:00:43 +0000 (21:00 -0400)]
vhpi: Add get/set support for selected names
Inhomogenous types are create scopes instead of signals. Additionally,
inhomogenous arrays have nested scopes for their elements. Add the
necessary machinery to determine the scope for a name/objDecl, and look
up the signal at the final level.
In the style of vhpi7, assign a value to each element of the test
records, and try to change them. To avoid needing to repeat the same
code while recursing through records, we just print out the values and
check them against the golden output. We cheat a bit for
multidimensional arrays because array properties are checked properly in
vhpi7.
Sean Anderson [Thu, 22 Jun 2023 00:42:18 +0000 (20:42 -0400)]
vhpi: Add support for selected names
The other major type of prefixed names is selected names. Add support
for them. In many ways they are simpler than indexed names, since we
don't have to keep track of multiple indices. Getting/setting is not
supported, but it will be addressed in the next commit.
Sean Anderson [Wed, 21 Jun 2023 23:32:14 +0000 (19:32 -0400)]
vhpi: Support record elements
Add support for record elements. Convert the vhpi5 test to gold to make
it easier to check recursive structures, and change the record
definition to something a little more interesting.
Sean Anderson [Sun, 18 Jun 2023 21:29:01 +0000 (17:29 -0400)]
vhpi: Pre-calculate names' offsets
We have all the information necessary to determine the offset of indexed
names when creating them. To simplify the process of determining the
offset by pre-calculating them.
Sean Anderson [Sun, 11 Jun 2023 19:01:05 +0000 (15:01 -0400)]
vhpi: Support EnumLiterals
Add support for the various *Literals properties of enums. Although
`EnumLiteral`s are generalizations of both `expr`s and `decl`s, we only
really support single-inheritance at the moment. Make c_enumLiteral a
subtype of c_abstractDecl, since there are more properties in `decl`s
than in `expr`s. This should be the only exception in this area we need
to make, since other literals aren't generalizations of decl.
Sean Anderson [Sun, 11 Jun 2023 15:02:42 +0000 (11:02 -0400)]
vhpi: Support char and string values
The native format for character types is vhpiCharVal. Similarly, the
native format for 1-d character arrays is vhpiStrVal. Use these formats
instead of the short enum formats. Note that vhpiStrVals are
nul-terminated, and the terminator is not included in the numElems (but
it is included in bufSize).
Nick Gasson [Sat, 17 Jun 2023 15:19:07 +0000 (16:19 +0100)]
Rework determination of most recently analysed architecture
Avoid using timestamps as well as loading every architecture and instead
establish a total order over all architectures in a library with a new
_sequence file.