A CHARM++ program accepts the following command line options:
+pN
Run the program with N processors. The default is 1.
+ss
Print summary statistics about chare creation. This option
prints the total number of chare creation requests, and the total number of
chare creation requests processed across all processors.
+cs
Print statistics about the number of create chare messages
requested and processed, the number of messages for chares requested and
processed, and the number of messages for branch office chares requested and
processed, on a per processor basis. Note that the number of messages
created and processed for a particular type of message on a given node
may not be the same, since a message may be processed by a different
processor from the one originating the request.
user_options
Options that are be interpreted by the user
program may be included mixed with the system options.
However, user_options cannot start with +.
The user_options will be passed as arguments to the user program
via the usual argc/argv construct to the main
entry point of the main chare.
CHARM++ system options will not appear in argc/argv.
4.1.1 Additional Network Options
Programs built using the network version of CHARM++ can be
run alone, without charmrun. This restricts you to using the
processors on the local
machine, but it is convenient and often useful for debugging.
For example, a CHARM++ program can be run on one processor
in the debugger using:
gdb pgm
The following ++ command line options are available in
the network version:
++local
Run charm program only on local machines. No
remote shell invocation is needed in this case. It starts node programs
right on your local machine. This could be useful if you just want to
run small program on only one machine, for example, your laptop.
++debug
Run each node under gdb in an xterm window, prompting
the user to begin execution.
++debug-no-pause
Run each node under gdb in an xterm window
immediately (i.e. without prompting the user to begin execution).
++maxrsh
Maximum number of rsh's to run at a
time.
++nodelist
File containing list of nodes.
++ppn
number of pes per node
++help
print help messages
++runscript
script to run node-program with
++xterm
which xterm to use
++in-xterm
Run each node in an xterm window
++display
X Display for xterm
++debugger
which debugger to use
++remote-shell
which remote shell to use
++useip
Use IP address provided for charmrun IP
++usehostname
Send nodes our symbolic hostname instead of IP address
++server-auth
CCS Authentication file
++server-port
Port to listen for CCS requests
++server
Enable client-server (CCS) mode
++nodegroup
which group of nodes to use
++verbose
Print diagnostic messages
++timeout
seconds to wait per host connection
++p
number of processes to create
If using the ++debug option, the user must ensure the
following:
The DISPLAY environment variable points to your terminal.
SSH's X11 forwarding does not work properly with CHARM++.
The nodes must be authorized to create windows on the host machine (see
man pages for xhost and xauth).
xterm, xdpyinfo, and gdb must be in
the user's path.
The path must be set in the .cshrc file, not the .login
file, because rsh does not run the .login file.
On multicore platforms, operating systems (by default) are free to move
processes and threads among cores to balance load. This however sometimes can
degrade the performance of Charm++ applications due to the extra overhead of
moving processes and threads, especailly when Charm++ applications has already
implemented its own dynamic load balancing.
Charm++ provides the following runtime options to set the processor affinity
automatically so that processes or threads no longer move. When cpu affinity
is supported by an operating system (tested at Charm++ configuration time),
same runtime options can be used for all flavors of Charm++ versions including
network and MPI versions, smp and non-smp versions.
+setcpuaffinity
set cpu affinity automatically for processes (when Charm++ is based on non-smp versions) or threads (when smp)
+excludecore <core #>
does not set cpu affinity for the given core number. One can use this option multiple times to provide a list of core numbers to avoid.