Visible to Intel only — GUID: iqg1680271029224
Ixiasoft
Visible to Intel only — GUID: iqg1680271029224
Ixiasoft
8.1.2. Command Return Values
The return value of a command is printed on the console unless it is used as an argument to some other command. Parenthesis () are used to group a command with arguments together, allowing the return value to be used as an argument. The return value can also be used as a namespace in another command. Variables can be used in the same way.
The following capture shows some examples of using the value returned by a command in another command:
#Intel Simics simulator CLI simics> $address = 0xffe00000 simics> set $address 20 simics> echo "The value at address " + $address + " is " + (get $address) The value at address 4292870144 is 20 simics> $id = 0 simics> system.board.fpga.soc_inst.hps_subsys.agilex_hps.core[$id].print-time -------------------------------------------------------- Processor Steps Cycles Time (s) -------------------------------------------------------- system....core[0] 187271821179 1475824027943 18446.556 -------------------------------------------------------- simics> $cpu = system.board.fpga.soc_inst.hps_subsys.agilex_hps.core[$id] simics> $cpu.print-time -------------------------------------------------------- Processor Steps Cycles Time (s) -------------------------------------------------------- agilex.hps.core[0] 187271821179 1475824027943 18446.556 --------------------------------------------------------
Parenthesis can also be used to break a command with its arguments across multiple lines, making it easier to read scripts with expressions and nested command invocations.