2

我们知道,对于单个实体 E,我们可以关联多个架构 A(i)。

测试平台也是如此,它们是简单的实体架构。但是,使用 GHDL,我不知道如何运行这样一个特定的测试平台,比如架构 A(arch)。

回想一下,这是一个简单的脚本,用于为名为“dut”的设计运行测试平台“tb”:

ghdl -a dut.vhd
ghdl -a tb.vhd
ghdl -e tb
ghdl -r tb

这里没有给出 tb 的架构名称。我怎样才能准确地说我想运行架构说“arch42”?

4

1 回答 1

2

info ghdl:

3.1.3 Run command

Run (or simulate) a design.

 $ ghdl -r [OPTIONS] PRIMARY_UNIT [SECONDARY_UNIT] [SIMULATION_OPTIONS]  

The options and arguments are the same as for the elaboration
command, *note Elaboration command::

The secondary unit would be arch42 from what you relate, the primary is tb. You'd need to elaborate the identical primary and secondary. If you're using a gcc based ghdl there will be an executable with a name comprised of both tb-arch42.

ghdl -e tb arch42
ghdl -r tb arch42

The current version of ghdl is ghdl-0.31 and as far as I know all platform distributions distribute ghdl.info, which the man page references as a source of in depth information.

于 2014-03-26T09:22:44.880 回答