Commit graph

460 commits

Author SHA1 Message Date
Greg Chadwick
416ecb10df [dv] Add co-simulation environment support to UVM testbench 2021-10-15 11:30:35 +01:00
Greg Chadwick
f4e3eefcfb [rtl,dv,doc] Flip priority of fast interrupts
This matches the priority used in Spike.

This also fixes an issue in the DV where the priority of
external/software/timer interrupts wasn't calculated correctly.
2021-10-15 11:30:35 +01:00
Udi
ff6797b26f [ibex/ml] add CSR/mem_error tests to ml_testlist
Signed-off-by: Udi <udij@google.com>
2021-10-07 16:54:46 -07:00
Greg Chadwick
6cbd7d21c5 [dv] Fix transaction ordering in ibex_mem_intf_monitor
Previously the monitor would emit write transactions the cycle the
request is seen and emit read transactions the cycle the response is
seen. This allowed later write transactions to be emitted before earlier
reads (where a new write transaction is started the cycle a read
response returns).

Now both read and write transactions are emitted when their response is
seen.

In addition the error field from the response is copied into the
transaction.
2021-09-01 09:43:37 +01:00
Greg Chadwick
6815e7b714 [rtl] Implement mvendorid/marchid/mimpid CSRs 2021-08-31 17:39:01 +01:00
Philipp Wagner
be27bc8bcf [style] Fix whitespace issues around operators
Our style guide typically require a single whitespace around operators.
2021-08-31 15:30:28 +02:00
Philipp Wagner
b5011ecec6 [style] Format module instantiations in tabular format
The style guide mandates tabular format in port expressions in module
instantiations
(https://github.com/lowRISC/style-guides/blob/master/VerilogCodingStyle.md#module-instantiation).

The style guide also mandates a two-space indentation for ports and
parameters in module instantiations.

Apply the formatting produced by verible-format to match our style
guide.
2021-08-31 15:30:28 +02:00
Tom Roberts
48f11c6733 [rtl] Add bus integrity checking
Extra bits are added alongside read/write data for the instruction and
data buses to facilitate data integrity checking.

Ibex testbench extended to generate the expected bits.

All other top-levels modified to add the new signals (which are mostly
ignored).

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-08-26 16:55:26 +01:00
Tom Roberts
7c0b1ff160 [rtl] Add register slice on output of shadow core
This decouples the shadow core from any timing paths and so should ease
implementation.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-08-03 13:47:00 +01:00
Tom Roberts
a1902004f9 [rtl] Add ResetAll parameter
This parameter forces a reset of all registers inside the core. This is
required to guarantee a common starting point for lockstep and thus
prevent spurious lockstep failure alerts.

Another minor change in this commit rearranges the writeback stage
multiplexing to gate incoming lsu write data when not valid. This stops
any X values from the data bus propagating to the register file
signalling (and thus to the lockstep comparison) which would cause the
lockstep alert to be X. It has the side effect of possibly reducing
power consumption in the register file.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-07-22 16:53:27 +01:00
Rupert Swarbrick
90ff7ca6c3 [dv,core_ibex] Only write sim.log once
We're already redirecting stdout to sim.log in run_rtl.py. Specifying
'-l' as well meant that VCS opened sim.log in a separate FD.
Suprisingly enough, this mostly worked, but not always! Just write
once :-)
2021-06-29 14:55:22 +01:00
Greg Chadwick
8ec65d02f8 [dv] Newline tweaks for regression logging 2021-06-29 14:08:01 +01:00
Greg Chadwick
ef545a8bd8 [dv] Improve results reporting
This commits adds a yaml based intermediate format for test results.
compare.py serialises a TestRunResult (a named tuple type) into this
format for each test run it checks. collect_results.py reads them all
back in to produce reports.

Three reports are output:
- regr.log - plain text report much like the one previously produced
- regr_junit.xml, regr_junit_merged.xml - JUnit report format, the
  _merged version batches together multiple tests to appear to be a
  single test case under a test suite. This gives better results with
  Azure's JUnit reporting.
2021-06-25 18:31:21 +01:00
Tom Roberts
6daae3509a [rtl] Modify fetch_en_i behavior
This signal used to be a one shot enable out of reset. We need an option
to pause execution for OpenTitan, so fetch_enable is extended to cover
that.

The signal is already driven low by the testbench at the end of test.
This is moved after the performance counter reads to ensure they can
complete.

Fixes #1105

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-06-23 09:16:27 +01:00
Tom Roberts
8a4c1b9e6d [dv/uvm/core] Fix a minor reset issue
Fix the reset polarity in the irq driver (clears irq signals to zero
on reset rather than them being x) plus remove an unused signal.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-06-23 09:16:27 +01:00
Tom Roberts
62aa2bcab8 [dv/uvm/core_ibex] Fix timeout issue in wfi tests
The test loops around waiting for the core to sleep then sending
interrupts to wake it. In some cases, the sequence sends an interrupt
that isn't enabled. It never gets back to try again with a new interrupt
since the test is waiting to see wfi first. This change removes that
requirement since it is redundant anyway (have to see wfi to sleep).

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-06-18 17:36:38 +01:00
Rupert Swarbrick
8dd21e491f Append logs for tests to regr.log
Commit 700f29b changed things so that details of the various tests
that ran ended up in separate files. This is nice (and important for
running things in parallel), but isn't massively helpful if you use
regr.log to understand what happened from a CI run!

This patch adds the logs again, splitting them up so that failing
tests come before passing ones (since you usually just care about the
failures).
2021-06-18 15:08:04 +01:00
Tom Roberts
fd4fdc4519 [dv/uvm/core_ibex] Pass ISA from Makefile
This allows run.py to pass ISA options through to Spike. This relates to
the failure in #1369 (test inserts a bitmanip instruction which Spike
interprets as valid but the core treats as invalid depending on config).

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-06-18 11:09:39 +01:00
Tom Roberts
1a46c4ede6 [dv/uvm/core_ibex] Update CSR description file
The CSR tests don't currently support multiple configurations
(see #1333). Since the OpenTitan configuration is the only one currently
being run, update this file to pass with that for now.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-06-18 11:09:39 +01:00
Rupert Swarbrick
2ce6653c65 [core_ibex,dv] Allow running RTL simulations in parallel 2021-06-16 14:37:10 +01:00
Rupert Swarbrick
6a07438cc5 [uvm,core_ibex] Add missing dependency in Makefile
We can't run coverage until the simulation is complete.
2021-06-15 16:48:51 +01:00
Rupert Swarbrick
700f29b7b3 [uvm,core_ibex] Run comparisons in parallel
This patch teaches Make which tests we're actually running (via the
list_tests.py script), which means that we can compare the ISS and RTL
results in parallel rather than serially.

There's a bit of duplicated code (both list_tests.py and sim.py
currently contain the code to get a list of tests and then filter by
Ibex configuration), but this should go away with a later patch that
runs the RTL simulations in parallel in a similar way.

Note: This might seem a little silly: trace comparison takes way less
time than the RTL simulation! The point is that it's probably easier
to work "from the bottom" than to start by parallelising the
simulations themselves.
2021-06-15 16:48:51 +01:00
Rupert Swarbrick
b40f5b8f55 [core_ibex,dv] Name RTL runs by seed, not iteration index
This makes path calculations a bit easier when it comes to loading
stuff up for comparison (allowing us to move more into the Makefile).
Long-term, it might also allow us to change how we track things
entirely, getting rid of the start-seed part of the output directory
structure.
2021-06-15 16:48:51 +01:00
Rupert Swarbrick
d611de9a60 [uvm] Remove --seed argument from sim.py
This isn't used any more: we use --start_seed instead. Remove support
for it, which simplifies the code quite a bit.
2021-06-15 16:48:51 +01:00
Dawid Zimonczyk
e716b5add8 Add the Width parameter to prim_buf module
The prim_buf.sv file in Ibex is a manual copy of a file which is
typically auto-generated by FuseSoC/primgen. However, Ibex DV doesn't
yet run FuseSoC, and we provide a pregenerated copy instead. The
auto-generated file and its copy got out of sync. Fix that by adding the
new Width parameter.
2021-06-10 10:00:15 +01:00
Dawid Zimonczyk
047e1d6d22 [core_ibex] Update command to work with newer versions of Riviera
These changes match newer versions of Riviera. They work for all
versions >= 2020.04. Ibex itself only compiles successfully with
version 2021.04, so there's no need to maintain command-line
compatibility with older versions.
2021-06-07 10:50:46 +01:00
Rupert Swarbrick
514c096892 [core_ibex,dv] Don't compile coverage model if COV=0 2021-06-03 10:05:11 +01:00
Tom Roberts
93a76b3900 [config] Add an Opentitan configuration
This adds the configuration instantiated in Opentitan and adds
missing prim support to allow the TB to run that configuration.

Resolves #1362

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-05-26 16:23:33 +01:00
Rupert Swarbrick
e0b477069e Update lowrisc_ip to lowRISC/opentitan@7117c349d
Update code from upstream repository
https://github.com/lowRISC/opentitan to revision
7117c349d5465b5152d3bb774079013924a3e9ba

* [dv/common] Improve coverage exclusion method (Cindy Chen)
* [prim] Waive unused parameter warnings for an FPGA-specific param
  (Rupert Swarbrick)
* [dpi] Fix indexing bug in ecc32_mem_area (Rupert Swarbrick)
* [dv, xcelium] Dump covergroup report (Srikrishna Iyer)
* [dvsim] Testplanner refactor & covergroup support (Srikrishna Iyer)
* [otp_ctrl] Workaround for generated prim depending on generated prim
  (Michael Schaffner)
* [dpi_memutil] Fix bug in RegisterMemoryArea (Rupert Swarbrick)
* [rom_ctrl/dv] Add skeleton testbench (Tom Roberts)
* [dvsim/verilator] Remove FUSESOC_IGNORE (Michael Schaffner)
* [checklists] Update all checklists for consistency (Srikrishna Iyer)
* [dv] Add integrity generation to backdoor memory loading (Greg
  Chadwick)
* [prim_secded] Add C reference models for Hsiao encode (Greg
  Chadwick)
* [rtl/prim_async_fifo] Fix async fifo typo when depth <= 2 (Cindy
  Chen)
* [dv/unr] Fix unr clk rst ports (Cindy Chen)
* [pads] - added AnalogIn1 pads for OTP supply (Arnon Sharlin)
* [dv/common] add ECC support to mem_bkdr_if (Udi Jonnalagadda)

Signed-off-by: Rupert Swarbrick <rswarbrick@lowrisc.org>
2021-05-25 15:14:52 +01:00
Philipp Wagner
c7cb958f0d Update lowrisc_ip to lowRISC/opentitan@ca950b43a
Update code from upstream repository
https://github.com/lowRISC/opentitan to revision
ca950b43a0e9ef5013b8e2e5de765bc34fb59b74

Two updates to the Ibex code were required:
* Adjust the prim_secded port names to match the changes in
  OpenTitan.
* Replace `has_ral` in `ibex_icache_env_cfg.sv` and
  `ibex_icache_base_test.sv` with its newer equivalent, matching
  https://github.com/lowRISC/opentitan/pull/5932 and the additional
  updates in https://github.com/lowRISC/opentitan/pull/5951.

Upstream changes include:
* [prim_secded] Use _i/_o suffix for port names (Philipp Wagner)
* [tl,dv] Allow bits to be set in responses regardless of mask (Rupert
  Swarbrick)
* [push_pull agent] Driver code refactor (Srikrishna Iyer)
* [dv/dvsim] Group failures per test in buckets (Guillermo Maturana)
* [dv/uvmdvgen] Flag error for paths in block name (Guillermo
  Maturana)
* [prim_fifo_async] Style fixes (Philipp Wagner)
* Remove non-ASCII characters from SV code and meson.build (Rupert
  Swarbrick)
* [dv/spi_device] Fix spi_device_csr_wr_with_rand_reset timeout issue
  (Cindy Chen)
* [otp] Update to match latest foundry wrapper (Timothy Chen)
* [flash] update to match latest foundry wrapper (Timothy Chen)
* [top] Latest ast integration (Timothy Chen)
* [lint] Strengthen Verible lint check to 100-character lines (Rupert
  Swarbrick)
* [ prim ] Suppress unneeded assertion when clearing prim_packer_fifo
  (Martin Lueker-Boden)
* [dv/otp_ctrl] Add coverage exclusions (Cindy Chen)
* [dv/dvsim] Add "^Error:" as a run fail pattern. (Guillermo Maturana)
* [dvsim] Fix column bug in DV summary report (Srikrishna Iyer)
* [dvsim] Fix testplan test counts (Srikrishna Iyer)
* [dvsim] Fix lowRISC/opentitan#6061 (Srikrishna Iyer)
* [prim_clock_div] Update waiver (Michael Schaffner)
* [fpv] dvsim script error (Cindy Chen)
* [prim_otp] Update interface (Michael Schaffner)
* [dvsim] update edacloudlauncher imports (Udi Jonnalagadda)
* [dv/doc] Minor fix on dv_doc (Cindy Chen)
* [dvsim] Scheduler updates - max_parallel, max_poll (Srikrishna Iyer)
* [dvsim] Set `Deploy.job_name` more robustly (Srikrishna Iyer)
* [prim] Make SECDED prim generation deterministic (Rupert Swarbrick)
* [tool, xcel] Support dumpping the array of struct in shm/vcd (Tung
  Hoang)
* [dv/otp_ctrl] OTP_CTRL DV doc (Cindy Chen)
* [dv/dv_macros] Fix DV_PRINT_ARR_CONTENTS (Guillermo Maturana)
* [prim_pad_attr/prim_flop_en] Add waiver files (Michael Schaffner)
* [prim_usb_diff] Minor lint fix (Michael Schaffner)
* [prim_clock_div] Update waiver file (Michael Schaffner)
* [top] change prim_generic usage into prim (Timothy Chen)
* [formal/conn] Support dvsim to publish regression result summary
  (Cindy Chen)
* Add formatting changes from allow list (Rafal Kapuscik)
* [prim] Add generic and Xilinx-specific xor2 primitives (Pirmin
  Vogel)
* [prim] Add Width parameter to buffer primitives (Pirmin Vogel)
* [prim] Add generic and Xilinx-specific enable-FF primitives (Pirmin
  Vogel)
* [prim] Remove temporary workaround in parameter list related to
  primgen (Pirmin Vogel)
* [dv/dvsim] Provides more context on some failures. (Guillermo
  Maturana)
* [dvsim] Fix local run error. (Eunchan Kim)
* [dv] Support multi-ral (part 4) (Weicai Yang)
* [dv/dvsim] Adds failure bucketizer for triage. (Guillermo Maturana)
* [lint/docs] Update ascentlint dvsim command in readme (Michael
  Schaffner)
* [top] Various top level lint fixes (Timothy Chen)
* [pinmux/padring] Wire up the pad attribute WARL behavior modules
  (Michael Schaffner)
* [dv] Fix tl_error failure (Weicai Yang)
* [pinout] Update flash test mode and voltage signals/pads (Michael
  Schaffner)
* [pad_wrapper] Extend the generic and Xilinx pad wrapper models
  (Michael Schaffner)
* [dv] Update scb for all blocks (Weicai Yang)
* [dv] Support multi-ral (part 3) (Weicai Yang)
* [prim_arbiter,lint] Tell Verilator to split variables for scheduling
  (Rupert Swarbrick)
* [prim] Fix lint warnings, replace inline AscentLint waivers (Pirmin
  Vogel)
* [dvsim] Scratch root default to $REPO_TOP/scratch (Srikrishna Iyer)
* [dv] Update `process_tl_access` args for all blocks (Weicai Yang)
* [dv] Support multi-ral (part 2) (Weicai Yang)
* [formal] Clean up some formal warnings (Cindy Chen)
* [topgen] Rework pinmux datastructure and templatize tops (Michael
  Schaffner)
* [otp_ctrl] Several small lint fixes (Michael Schaffner)
* [prim_fifo_async] Make async FIFO output zero when empty (Noah
  Moroze)
* [flash] Improve flash ECC handling based on transasction attribute
  (Timothy Chen)
* [dv] Remove toggle coverage excl for a_user/d_user (Weicai Yang)
* [dvsim] Fix remaining comments  from lowRISC/opentitan#5876
  (Srikrishna Iyer)
* [dv] Support multi-ral (part 1) (Weicai Yang)

Signed-off-by: Philipp Wagner <phw@lowrisc.org>
2021-05-11 18:28:56 +01:00
Tom Roberts
7ac218f3ae [rtl] Wire scan_rst_ni through ibex_top_tracing
Better to have the tracing top consistent with the non-tracing top.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-04-21 12:41:24 +01:00
Dawid Zimonczyk
d8bf475da7 add cast to enum
Signed-off-by: Dawid Zimonczyk <dawidz@aldec.com.pl>
2021-04-19 11:32:37 +01:00
Greg Chadwick
1b59c67b50 [dv] Remove MISA from csr_description.yaml
The value of `misa` will change depending on whether M or B are enabled.
The presence and read values of other CSRs may also depend upon the Ibex
configuration. A fix is required to allow riscv_csr_test to deal with
different CSR descriptions for different Ibex configurations. For now
just comment out `misa` from the descriptions file to enable
riscv_csr_test to run on a wider range of configurations.
2021-04-14 12:13:12 +01:00
Greg Chadwick
69e715b287 [dv] Improvements to functional coverage
This adds more instruction categories and corrects various issues in the
categorization code. Further cross coverage has been added including
illegal bins to remove bins that cannot occur.

The concept of using SVAs with cross coverage has been dropped. The
systemverilog scheduling model makes the concept unworkable.
2021-04-14 08:55:16 +01:00
Greg Chadwick
5504876110 [dv] Add known failure detection to riscv_debug_ebreakmu_test 2021-04-09 18:42:12 +01:00
Greg Chadwick
25cd6600c6 [dv] Don't kill regression on sim error
When the simulator terminates with an error code that is reported as a
test failure and the regression continues. A new check for a plain
'Error' message is required to catch simulator reported errors that
don't become a UVM_FATAL or UVM_ERROR message (e.g. hitting an illegal
coverage bin). Previously any such simulation error would kill the whole
regression.
2021-04-08 09:59:17 +01:00
Tom Roberts
a88f5eb912 [rtl] Add dual core lockstep option
Note that the alert output is tied off for now until an option is added
to reset all registers (otherwise there will be X propagation).

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-04-07 12:07:38 +01:00
Tom Roberts
6a3200929b [rtl] Add a new top level plus wiring
This commit creates a new top level wrapping the core, register file and
icache RAMs. The tracing top level is also renamed to ibex_top_tracing
to match. This new top level is intended to enable a dual core lockstep
implementation of Ibex.

There are no functional changes in this commit, only wiring.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-04-07 12:07:38 +01:00
Tom Roberts
b106001d82 [rtl/icache] Move various parameters into the pkg
No functional change. These parameters are effectively fixed. Moving
them to the pkg eases top-level wiring of RAM signals.

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-04-07 12:07:38 +01:00
Rupert Swarbrick
c7f44557d2 Fix initialisation in ibex_icache_env_cfg.sv 2021-04-06 12:50:03 +01:00
Rupert Swarbrick
7d61def943 Update lowrisc_ip to lowRISC/opentitan@f29a0f7a7
Update code from upstream repository
https://github.com/lowRISC/opentitan to revision
f29a0f7a7115e03fba734b1c00691c253aceb07e. The list of OpenTitan
changes that are merged in appears at the bottom of the commit.

There are some manual changes needed to adapt the code to work with
these changes.

 - The ICache monitors need some extra types to adapt to the (rather
   odd) data model that the OpenTitan dv_lib code now uses, where a
   monitor needs to know an agent's associated sequence type.

 - Verilator simulations now use MemArea slightly differently

OpenTitan changes:

* [dv] Allow monitor items to have different types from sequence items
  (Rupert Swarbrick)
* [dvsim] Fix primary_cfg handling (Srikrishna Iyer)
* [dvsim] Deal with non unicode chars in log files (Srikrishna Iyer)
* [dvsim] Added common build fail patterns (Srikrishna Iyer)
* [dvsim] Minot cleanup to the lint flow (Srikrishna Iyer)
* [dvsim] Minor cleanups to to formal flow (Srikrishna Iyer)
* [dvsim] Fixes to UNR and cov analysis flows (Srikrishna Iyer)
* [dvsim] Very minor cleanup of Deploy class (Srikrishna Iyer)
* [dvsim] LsfLauncher report early errors as F (Srikrishna Iyer)
* [dvsim] Minor fix in clean_odirs function (Srikrishna Iyer)
* [chip dv] Set +sw_images as comma-separated list (Srikrishna Iyer)
* [flash_ctrl] Split tl intefaces for flash_ctrl and prim_flash_cfg
  (Timothy Chen)
* [keymgr] Fix input value checks (Timothy Chen)
* [formal/script] Update generic formal flow naming from `fpv` to
  `formal` (Cindy Chen)
* [top, prim] Address wmask and data width mismatch issue (Timothy
  Chen)
* [dvsim] Add GUI mode for running simulations (Srikrishna Iyer)
* [dv] Fix reg backdoor (Weicai Yang)
* [dpi] Make an "ECC32" flavour of MemArea (Rupert Swarbrick)
* [uvmdvgen] Fix has_interrupts in env_cfg (Cindy Chen)
* [dvsim] Keep dependencies list (Srikrishna Iyer)
* [prim_prince] Reverse the k0||k1 mapping to match with the paper
  (Michael Schaffner)
* [dvsim] Fix printing of last 10 lines (Srikrishna Iyer)
* [primgen] Minor fix to enable types with underscores (Michael
  Schaffner)
* [dvsim] Prevent command echo suppression (Srikrishna Iyer)
* [dvsim] Spot fixes for LSF and internal launcher (Srikrishna Iyer)
* [sva] csr assertion dependency update (Cindy Chen)
* [memutil] Change DpiMemUtil so that it no longer owns MemAreas
  (Rupert Swarbrick)
* [memutil] Factor out MemArea as a class (Rupert Swarbrick)
* [prim] Split out PRESENT and PRINCE support from prim:all (Rupert
  Swarbrick)
* [fpv/otp_ctrl] Disable assertions due to lc_esc_en (Cindy Chen)
* [prim_prince] Annotate some arrays to avoid UNOPTFLAT warnings
  (Rupert Swarbrick)
* [top] Hook up latest ast ports and complete a few other integration
  (Timothy Chen)
* Eliminate `#pragma once` in favor of include guards (Chris Frantz)
* [sw,dv] Update headers to pass fix_include_guards.py (Alex Bradbury)
* [xbar/dv] Fix assertion error due to short reset (Weicai Yang)
* [sram] Add memory initialization (Timothy Chen)
* [uvmdvgen] Update links in checklist template (Philipp Wagner)
* [dv/uvmdvgen] Add comment for testplan (Cindy Chen)
* [dv/top_earlgrey] chip csr_aliasing timeout (Cindy Chen)
* [dvsim] Cosmetic updates to launcher methods (Srikrishna Iyer)
* [dv] Update csr_wr to support field write (Weicai Yang)
* [dv/common] Fix regression warnings (Cindy Chen)
* [dv] Get blocks with multiple device interfaces working with chip DV
  (Rupert Swarbrick)
* [doc] Use relative links in Hjson-related shortcodes (Philipp
  Wagner)
* [dvsim] minor enhancement to clean_odir (Srikrishna Iyer)
* [dvsim] Statically display jobs' status (Srikrishna Iyer)
* [dvsim] Do weighted scheduling of jobs (Srikrishna Iyer)
* [dvsim] Schedule jobs by dependency (Srikrishna Iyer)
* [dv] Xcelium UNR typo (Srikrishna Iyer)
* [dvsim] Implement LsfLauncher (Srikrishna Iyer)
* [dv/chip] solve same_csr_outstanding_timeout (Cindy Chen)
* [dv] make dv_base_agent work for high-level agent (Weicai Yang)
* [tools/dv] added UNR flow for xcelium (Rasmus Madsen)
* [prim] Split prim:subreg out of prim:all (Rupert Swarbrick)
* [prim] Split prim_alert_* out of prim:all (Rupert Swarbrick)
* [prim] Split out fifos into a prim_fifo core (Rupert Swarbrick)
* [prim] Split out arbiters into a prim_arbiter core (Rupert
  Swarbrick)
* [prim] Make prim:flop_2sync depend on prim:flop (Rupert Swarbrick)

Signed-off-by: Rupert Swarbrick <rswarbrick@lowrisc.org>
2021-04-06 12:49:51 +01:00
Rupert Swarbrick
b04c1850b6 Avoid encumbered name in ibex_icache_testplan.hjson
With this change, we no longer use "sanity" in non-vendored code.
2021-04-05 15:38:56 +01:00
Philipp Wagner
69ae65c713 [dv] Remove semicolon
It's Python.
2021-03-22 18:28:18 +00:00
Philipp Wagner
907a3f6ec7 [dv] Fix name of ELF file in report
The name of the ELF file was wrong in the regr.log file, it should be
e.g. `riscv_debug_ebreakmu_test_9.o`, not
`riscv_debug_ebreakmu_test.9.o`.
2021-03-22 18:28:18 +00:00
Greg Chadwick
c1e287e13b [dv] Fix riscv_nested_interrupt_test
This broke due to changes in IRQ sequences. It relies on the inner
interrupt being an NMI. This alters the test to use the specific NMI
sequence.
2021-03-22 17:35:35 +00:00
Greg Chadwick
2c3c474cc0 [dv] Fix riscv_irq_in_debug_mode_test
Test wasn't handling a case where the IRQ remains raised after DRET so
IRQ should be handled.
2021-03-22 17:35:35 +00:00
Greg Chadwick
f0a4042d6a [dv] Allow full IRQ randomisation
`no_nmi` in irq_raise_seq and irq_raise_single_seq would always cause an
NMI to be raised if it was set. This alters it to have the same
behaviour as `no_fast`. Setting `no_nmi` prevents an NMI from being
produced by the sequences, leaving it clears allows an NMI to be
produced but doesn't force it. This allows tests which can deal with NMI
along with other IRQs to fully randomise IRQs.

A new `irq_raise_nmi_seq` is provided for tests that specifically want
an NMI.
2021-03-22 17:35:35 +00:00
Greg Chadwick
5711d4fc15 [dv] Small core_ibex_test_lib refactor
Splits out checking for IRQ handling and waiting for specific xRET to
seperate tasks to allow more flexible checking.
2021-03-22 17:35:35 +00:00
Udi Jonnalagadda
6576247a1e [ci/ibex] temporarily remove pmp_full_random_test
this test is arbitrarily failing in regressions on a Spike timeout,
temporarily remove this to avoid blocking.

@udinator to fix this in the near future.

Signed-off-by: Udi Jonnalagadda <udij@google.com>
2021-03-14 20:11:34 +00:00
Tom Roberts
2c75c2b2ec Update lowrisc_ip to lowRISC/opentitan@1ae03937f
Update code from upstream repository
https://github.com/lowRISC/opentitan to revision
1ae03937f0bb4b146bb6e736bccb4821bfda556b

* [prim/fifo_async] Add assertions on pointers (Tom Roberts)
* [prim/fifo_async] Add support for Depth <= 2 (Tom Roberts)
* [prim/fifo_async] Code tidy-up (Tom Roberts)
* [top / ast] Continued ast integration (Timothy Chen)
* [dvsim] Use bash when running make underneath (Srikrishna Iyer)
* [prim] Increase maximum width for prim_util_memload to 312 (Greg
  Chadwick)
* [sram_ctrl] Fix potential back-to-back partial write bug (Michael
  Schaffner)
* [dvsim] Fix for lowRISC/opentitan#5527 (Srikrishna Iyer)
* [lint] Waive Verilator UNUSED warnings for packages (Rupert
  Swarbrick)
* [uvmdvgen] Update DV doc path and terminology (Srikrishna Iyer)
* [clkmgr] Fix dft issues (Timothy Chen)
* [util] add `dec` types to prim_secded_pkg (Udi Jonnalagadda)
* [util] minor updates to secded_gen (Udi Jonnalagadda)
* [lint] Fix a bunch of lint warnings related to long lines (>100
  chars) (Michael Schaffner)
* [dv] Update common intr_test seq (Weicai Yang)
* [util] Slight refactor of secded_gen.py (Timothy Chen)
* [tlul] Add memory transmission integrity checks (Timothy Chen)
* [dvsim] Move clean_odirs to `util.py` (Srikrishna Iyer)
* [dvsim] Split Deploy into Deploy and Launcher (Srikrishna Iyer)
* [dvsim] Add utils.TS_FORMAT* vars (Srikrishna Iyer)
* [dv/lock_reg] Update IPs to adopt the lock_reg changes (Cindy Chen)
* [dv/enable_regs] Support enable registers have more than one field
  (Cindy Chen)
* [dv/base_reg] use m_field instead of accessing field (Cindy Chen)
* [dv/sram] add SRAM scrambling model for DV (Udi Jonnalagadda)
* [dv/tools] Updated Coverage flow for xcelium (Rasmus Madsen)

Signed-off-by: Tom Roberts <tomroberts@lowrisc.org>
2021-03-12 16:15:22 +00:00