mirror of
https://github.com/openhwgroup/cve2.git
synced 2025-04-22 04:57:25 -04:00
Doc support for overriding enum/string parameters at the top level
Signed-off-by: Pirmin Vogel <vogelpi@lowrisc.org>
This commit is contained in:
parent
2ef5e5e3f2
commit
4c3f1e8a3b
3 changed files with 18 additions and 2 deletions
|
@ -125,6 +125,16 @@ Parameters
|
|||
|
||||
Any parameter marked *EXPERIMENTAL* when enabled is not verified to the same standard as the rest of the Ibex core.
|
||||
|
||||
Note that Ibex uses SystemVerilog enum parameters e.g. for ``RV32M`` and ``RV32B``.
|
||||
This is well supported by most tools but some care is needed when overriding these parameters at the top level:
|
||||
|
||||
* Synopsys VCS does not support overriding enum and string parameters at the top level via command line.
|
||||
As a workaround, SystemVerilog defines are used in Ibex top level files simulated with VCS.
|
||||
These defines can be set via command line.
|
||||
|
||||
* Yosys does not support overriding enum parameters at the top level by setting enum names.
|
||||
Instead, the enum values need to be used.
|
||||
|
||||
Interfaces
|
||||
----------
|
||||
|
||||
|
|
|
@ -29,8 +29,10 @@ module core_ibex_tb_top;
|
|||
// CSR access interface
|
||||
core_ibex_csr_if csr_if(.clk(clk));
|
||||
|
||||
// You cannot override string parameters in VCS via the command line so a `define is used instead
|
||||
// that can be set from the command line. If no value has been specified this gives a default.
|
||||
// VCS does not support overriding enum and string parameters via command line. Instead, a
|
||||
// `define is used that can be set from the command line. If no value has been specified, this
|
||||
// gives a default. Other simulators don't take the detour via `define and can override the
|
||||
// corresponding parameters directly.
|
||||
`ifndef IBEX_CFG_RV32M
|
||||
`define IBEX_CFG_RV32M ibex_pkg::RV32MFast
|
||||
`endif
|
||||
|
|
|
@ -2,6 +2,10 @@
|
|||
// Licensed under the Apache License, Version 2.0, see LICENSE for details.
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
// VCS does not support overriding enum and string parameters via command line. Instead, a `define
|
||||
// is used that can be set from the command line. If no value has been specified, this gives a
|
||||
// default. Other simulators don't take the detour via `define and can override the corresponding
|
||||
// parameters directly.
|
||||
`ifndef RV32M
|
||||
`define RV32M ibex_pkg::RV32MFast
|
||||
`endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue