Intel® Simics® Simulator for Intel® FPGAs: User Guide

ID 784383
Date 12/04/2023

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

5.3.2. Simulation Run Control from CLI

The prompt in the Intel® Simics® simulator CLI indicates the current state of the simulation. When this shows the simics> prompt, it indicates that the simulation is not running at that time (this has not started yet or is paused). When the CLI shows the running> prompt, it means that the simulation is running at that time. In any of these 2 cases, the Intel® Simics® simulator prompt is ready to receive any Intel® Simics® simulator command.

It is possible to switch to running state using the run or continue commands. Both commands are equivalent (just an alias of each other) and they allow to start or continue the simulation if this was paused.

If the simulation is running, it is also possible to pause the simulation using the stop command as follows:
# Intel Simics simulator CLI 

simics> run
running> stop
simics> continue
running> stop
simics> run 1s         -- transits to running state for 1 sec and the stops
simics> r 1 s          -- transits to running state for 1 sec and the stops
simics> c 1000 steps   -- transits to running state for 1000 CPU steps 
                            and the stops
In the previous capture, you can notice that the run and continue commands can also be simplified using just the r or c commands. Also, it is possible to control for how long you want to advance in the simulation providing this as a argument for these commands. The syntax for them is as follows:
run <count> <unit>
continue <count> <unit>

Where [unit] can be one of the following units: steps, cycles, h, m, s, ms, us, ns, or ps.

Additionally, to the run and continue commands that allow to run certain number of steps, the stepi or si command can also be used to do the same, but the difference with this command is that it shows in the CLI the assembler instructions that were executed. The format is as follows:
stepi <steps_count>
si <steps_count>
For example:
# Intel Simics simulator CLI 

 simics> stepi 3
[agilex.hps.core[1]] v:0x0000ffff88805664 p:0x8000001084355664  hint #0x1d
[agilex.hps.core[1]] v:0x0000ffff88805668 p:0x8000001084355668  ret
[agilex.hps.core[1]] v:0x0000ffff88803a10 p:0x8000001084353a10  add x0, sp, #0x40
simics> si 2
[agilex.hps.core[1]] v:0x0000ffff88803858 p:0x8000001084353858  ldr x0, [sp, #24]
[agilex.hps.core[1]] v:0x0000ffff8880385c p:0x800000108435385c  bl 0xffff88801720