tkPvm version 1.0b1
The latest version of this file can be found at
http://www.nici.kun.nl/tkpvm/welcome.html
What is tkPvm
tkPvm is the result of a wedding. The husband is pvm3.3.x (preferably 3.3.7) and the
wife is Tk4.0 or Tk3.6 (preferably 4.0). Probably it will work unchanged for pvm3.4.0,
but that is not released yet so I cannot try it out. As usual with a marriage, both
sides profit from the combination:
- PVM-users
- The tcl-language is an interpreted scripting language. With TkPvm you
can now write pvm processes in the Tcl language, as opposed to C or
Fortran. No compilations are necessary any more, once you created pvmsh
and pvmwish. The shell program pvmsh can be seen as an enhanced version
of the pvm console. It can control the virtual machine in the same way
as the pvm console does, but it is a full shell with history substitution
('!!') and variables.
The pvmwish interpreter has the same function as pvmsh, but in addition it
has a lot of commands to build your own grapical user interface. There are
buttons, entry widgets, menu's and so on. Now each process can have input
and output through it's own X11-window.
- Tcl/Tk-users
- PVM is a library for controlling a virtual parallel machine which consists
of any number of hosts. Processes can spawn and kill each other and
communicate through a pvm-channel. It can be compared with the Tk 'send'
command, only it works with sockets. Therefore it runs without Tk (X11),
and the processes can use different displays and run on different hosts.
In addition, pvmsh has access to the same event loop as Tk 4.0. This means
that you now can use the 'after' and 'fileevent' commands without tk and X11.
- The pvm-related commands that can be used in Tcl now are:
-
- send, recv
- Send and recieve anything from or to any other process.
- spawn, kill
- Spawn and kill other processes.
- tasks
- Request information about running tasks.
- bind
- Bind pvm-related events in the Tcl/Tk event loop. This is a very powerful
command which makes programming an event-driven application much easier.
To do the same in C or Fortran is much more difficult. PVM has no
equivalent function for this. Tk has, but originall it is only used for
X-events. Now the same can be done with PVM-events.
And many more.....
How to install tkPvm
First, install Tcl7.4 and pvm3.3.7. If you want graphical capabilities you need Tk4.0 (or Tk3.6)
too. These can be downloaded from:
For pvm3.3.7, don't forget that the environment variables PVM_ROOT and PVM_ARCH need to be
set at all times. Best is to define these in your '.cshrc'. Also, it is useful to add
several paths that are used for pvm to the 'path' variable (for the executables) and
the 'LD_LIBRARY_PATH' environment variable (the pvm libraries). All information about
this is available inside the pvm distribution.
It is advised that you use shared libraries as much as possible. The NICI ftp-server has
patches available for Tcl7.4 and Tk4.0 to archive that. Copy the patch files
to the main directories of Tcl7.4 and Tk4.0, and run the GNU 'patch' utility.
Gunzip (to uncompress .gz-files), patch and the patches for Tcl7.4 and Tk4.0 can be downloaded from:
More Information about Tcl/Tk and PVM
There is a Tcl/Tk home page
and a PVM home page on the WWW. And there are
newsgroups comp.lang.tcl and
comp.parallel.pvm where you can get more help.
There also is more information available in the tkPvm index
written by J.
Nijtmans for the
project