The Tcl Console that runs under the Vivado
Integrated Design Environment (IDE) or Tcl mode (vivado -mode
tcl
or vivado -mode gui
) is slightly
different from the one that runs under the batch mode (vivado
-mode batch
).
This behavior is inherent to Tcl and is not related to the Vivado tool. Literature can be found on the web that explains the underlying reasons.
But the consequence is that during an interactive session (Tcl or GUI modes), Vivado runs under tclsh
mode. However, in batch mode,
Vivado runs in Tcl script mode.
Although in all three modes (Tcl, GUI, and batch) the Tcl Console behaves mostly
the same, the Tcl environment is slightly different. One difference is that in batch
mode, the unknown commands are not sent to the OS for execution. To make sure that a
script works under all the three Vivado modes, it is
recommended to explicitly use the exec
command to
execute external programs.