24.03.2013 Views

ModelSim SE User's Manual - Electrical and Computer Engineering

ModelSim SE User's Manual - Electrical and Computer Engineering

ModelSim SE User's Manual - Electrical and Computer Engineering

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

UM-362 14 - PSL Assertions<br />

Using assertions in <strong>ModelSim</strong><br />

Assertion flow<br />

Limitations<br />

<strong>ModelSim</strong> <strong>SE</strong> User’s <strong>Manual</strong><br />

The following diagram gives a visual depiction of using assertions in <strong>ModelSim</strong>.<br />

HDL with<br />

embedded assertions<br />

Wave<br />

window<br />

or HDL assertions file<br />

vlog/vcom<br />

vsim<br />

Assertions<br />

pane<br />

vlog/vcom -pslfile<br />

<strong>ModelSim</strong> lets you embed assertions within your Verilog or VHDL code or supply them in<br />

a separate file. If the assertions are embedded, vlog/vcom will compile them automatically.<br />

If the assertions are in a separate file, you add the -pslfile argument to vlog/vcom. Once<br />

compilation is complete, you invoke the simulator vsim on the design. The simulator<br />

automatically h<strong>and</strong>les any assertions that are present in the design. From there you run the<br />

simulation <strong>and</strong> debug any assertion failures.<br />

The current release has some limitations. Most of these features will be added in future<br />

releases.<br />

Only the simple subset of PSL is supported.<br />

Vunits cannot be bound to a design unit instance. They can be bound only to a module,<br />

entity, <strong>and</strong> architecture.<br />

There is no support for verification unit inheritance–vunits cannot be derived from other<br />

vunits.<br />

There is no support for unclocked assertions. Level-sensitive clock expressions are not<br />

allowed.<br />

There is no support for %for <strong>and</strong> %if preprocessor comm<strong>and</strong>s.<br />

There is no support for integer, structures, <strong>and</strong> union in the modeling layer. The only PSL<br />

built-in functions currently supported are rose(), fell(), <strong>and</strong> prev().

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!