1
1

This directory has not been used in years; no one has contributed

anything useful to it.  So let's ditch it.  It can always be brought
back if someone wants to put something useful in here.

This commit was SVN r22010.
Этот коммит содержится в:
Jeff Squyres 2009-09-24 14:09:59 +00:00
родитель 56c653ebcd
Коммит 3340f62e5f
30 изменённых файлов: 0 добавлений и 15971 удалений

@ -1,21 +0,0 @@
#
# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
# University Research and Technology
# Corporation. All rights reserved.
# Copyright (c) 2004-2005 The University of Tennessee and The University
# of Tennessee Research Foundation. All rights
# reserved.
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
# University of Stuttgart. All rights reserved.
# Copyright (c) 2004-2005 The Regents of the University of California.
# All rights reserved.
# $COPYRIGHT$
#
# Additional copyrights may follow
#
# $HEADER$
#
SUBDIRS = user install

@ -1,33 +0,0 @@
#
# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
# University Research and Technology
# Corporation. All rights reserved.
# Copyright (c) 2004-2005 The University of Tennessee and The University
# of Tennessee Research Foundation. All rights
# reserved.
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
# University of Stuttgart. All rights reserved.
# Copyright (c) 2004-2005 The Regents of the University of California.
# All rights reserved.
# $COPYRIGHT$
#
# Additional copyrights may follow
#
# $HEADER$
#
# The majority of stuff to build the PS/PDF files are included in a
# separate Makefile so that they can be invoked directly at "make
# dist" time without needing to generate a real "Makefile" from
# Makefile.am.
include Makefile.latex
# Now ensure that all the relevant files get picked up in the tarball.
EXTRA_DIST = $(MAIN_TEX) $(OTHER_SRC_FILES) $(FIG_FILES) $(PNG_FILES) $(BIBTEX_SOURCES) Makefile.latex
dist-hook: pdf
mv user.pdf $(DESTDIR)$(distdir)/../.

@ -1,228 +0,0 @@
# -*-Makefile-*-
#
# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
# University Research and Technology
# Corporation. All rights reserved.
# Copyright (c) 2004-2005 The University of Tennessee and The University
# of Tennessee Research Foundation. All rights
# reserved.
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
# University of Stuttgart. All rights reserved.
# Copyright (c) 2004-2005 The Regents of the University of California.
# All rights reserved.
# $COPYRIGHT$
#
# Additional copyrights may follow
#
# $HEADER$
#
# This first section contains macros whose values that you need to
# fill in.
#
# MAIN_TEX: In order to build your document, fill in the MAIN_TEX
# macro with the name of your main .tex file -- the one that you
# invoke LaTeX on.
MAIN_TEX = user.tex
# OTHER_SRC_FILES: Put in the names of all the other files that your
# thesis depends on (e.g., other .tex files, figures, etc.) in the
# OTHER_SRC_FILES macro. This is ensure that whenever one of the
# "other" files changes, "make" will rebuild your paper.
LISTINGS_FILES = \
listings.cfg \
listings.sty \
lstdoc.sty \
lstlang1.sty \
lstlang2.sty \
lstlang3.sty \
lstmisc.sty \
lstpatch.sty
OTHER_SRC_FILES = \
defs.tex \
version.tex \
titlepage.tex \
audience.tex \
introduction.tex \
release-notes.tex \
getting-started.tex \
mpi-details.tex \
mca.tex \
commands.tex \
mca-orte.tex \
mca-ompi.tex \
debuggers.tex \
troubleshooting.tex \
misc.tex \
bibliography.tex \
$(LISTINGS_FILES)
# Bibtex source files
BIBTEX_SOURCES = refs.bib
# xfig figures. .eps and .pdf files will be automatically generated
# from these.
FIG_FILES =
PNG_FILES = openmpi_logo-only.png
# Required commands
LATEX = latex
PDFLATEX = pdflatex
DVIPS = dvips
MAKEINDEX = makeindex
BIBTEX = bibtex
FIG2DEV = fig2dev
PNGTOPNM = pngtopnm
PNMTOPS = pnmtops
#########################################################################
#
# You should not need to edit below this line
#
#########################################################################
SUFFIXES = .tex .dvi .ps .pdf .fig .eps .png
.SUFFIXES: .tex .dvi .ps .pdf .fig .eps .png
MAIN_DVI = $(MAIN_TEX:.tex=.dvi)
MAIN_PS = $(MAIN_TEX:.tex=.ps)
MAIN_PDF = $(MAIN_TEX:.tex=.pdf)
MAIN_BBL = $(MAIN_TEX:.tex=.bbl)
MAIN_BASENAME = $(MAIN_TEX:.tex=)
EPS_FILES = $(PNG_FILES:.png=.eps)
EPS_FIG_FILES = $(FIG_FILES:.fig=.eps)
PDF_FIG_FILES = $(FIG_FILES:.fig=.pdf)
#
# Some common target names
# Note that the default target is "ps"
#
ps: $(MAIN_PS)
pdf: $(MAIN_PDF)
#
# Make the dependencies so that things build when they need to
#
$(MAIN_PS): $(MAIN_DVI)
$(MAIN_DVI): $(MAIN_TEX) $(CITE_TEX) $(OTHER_SRC_FILES) $(EPS_FIG_FILES) $(EPS_FILES) $(MAIN_BBL)
$(MAIN_PDF): $(MAIN_TEX) $(CITE_TEX) $(OTHER_SRC_FILES) $(PDF_FIG_FILES) $(PNG_FILES) $(MAIN_BBL)
#
# Search Strings
#
REFERENCES = "(There were undefined references|Rerun to get (cross-references|the bars) right)"
NEEDINDEX = "Writing index file"
RERUNBIB = "No file.*\.bbl|Citation.*undefined|LaTeX Warning: Label\(s\) may"
#
# General rules
#
.fig.eps:
$(FIG2DEV) -L eps $< $@
.fig.pdf:
$(FIG2DEV) -L pdf $< $@
.png.eps:
$(PNGTOPNM) $< | $(PNMTOPS) -noturn > $*.eps
# Only run bibtex if latex has already been run (i.e., if there is
# already a .aux file). If .aux file does not exist, then bibtex will
# be run during the .tex.dvi / .tex.pdf rules. We don't run latex
# here to generate the .aux file because a) we don't know whether to
# run latex or pdflatex, and b) the dependencies are wrong for
# pdflatex because we may need to generate some pdf images first.
$(MAIN_BBL): $(BIBTEX_SOURCES)
@if (test -f $(MAIN_BASENAME).aux); then \
echo "### Running BibTex"; \
$(BIBTEX) $(MAIN_BASENAME); \
fi
# Main workhorse for .tex -> .dvi. Run latex, makeindex, and bibtex
# as necessary.
.tex.dvi:
echo "### Running LaTeX (1)"
$(LATEX) $*
@if (egrep $(REFERENCES) $*.log > /dev/null); then \
echo "### Running LaTeX to fix references (2)"; \
($(LATEX) $*); \
fi
@if (egrep $(NEEDINDEX) $*.log >/dev/null); then \
echo "### Running makeindex to generate index"; \
$(MAKEINDEX) $*; \
echo "### Running LaTeX after generating index"; \
$(LATEX) $*; \
fi
@if (egrep $(RERUNBIB) $*.log >/dev/null); then \
echo "### Running BibTex because references changed"; \
$(BIBTEX) $(MAIN_BASENAME); \
echo "### Running LaTeX after generating bibtex"; \
$(LATEX) $*; \
fi
@if (egrep $(REFERENCES) $*.log > /dev/null); then \
echo "### Running LaTeX to fix references (3)"; \
($(LATEX) $*); \
fi
@if (egrep $(REFERENCES) $*.log > /dev/null); then \
echo "### Running LaTeX to fix references (4)"; \
($(LATEX) $*); \
fi
.dvi.ps:
$(DVIPS) -o $*.ps $*
# Main workhorse for .tex -> .pdf. Run latex, makeindex, and bibtex
# as necessary. Essentially the same as .tex.dvi, except
# s/latex/pdflatex/g.
.tex.pdf:
echo "### Running pdfLaTeX (1)"
$(PDFLATEX) $*
@if (egrep $(REFERENCES) $*.log > /dev/null); then \
echo "### Running pdfLaTeX to fix references (2)"; \
($(PDFLATEX) $*); \
fi
@if (egrep $(NEEDINDEX) $*.log >/dev/null); then \
echo "### Running makeindex to generate index"; \
$(MAKEINDEX) $*; \
echo "### Running pdfLaTeX after generating index"; \
$(PDFLATEX) $*; \
fi
@if (egrep $(RERUNBIB) $*.log >/dev/null); then \
echo "### Running BibTex because references changed"; \
$(BIBTEX) $(MAIN_BASENAME); \
echo "### Running pdfLaTeX after generating bibtex"; \
$(PDFLATEX) $*; \
fi
@if (egrep $(REFERENCES) $*.log > /dev/null); then \
echo "### Running pdfLaTeX to fix references (3)"; \
($(PDFLATEX) $*); \
fi
@if (egrep $(REFERENCES) $*.log > /dev/null); then \
echo "### Running pdfLaTeX to fix references (4)"; \
($(PDFLATEX) $*); \
fi
#
# Standard targets
#
clean:
/bin/rm -f *~ *.bak *%
/bin/rm -f *.log *.aux *.dvi *.blg *.toc *.bbl *.lof *.lot \
*.ind *.idx *.ilg *.int *.out \
$(MAIN_PS) $(MAIN_DVI) $(MAIN_PDF) \
$(EPS_FILES) $(EPS_FIG_FILES) $(PDF_FIG_FILES)

@ -1,89 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Don't Panic! (Who Should Read This Document?)}
{\Huge JMS needs overhauling -- no such thing as a previous OMPI user}
This document probably looks huge to new users. But don't panic! It
is divided up into multiple, relatively independent sections that can
be read and digested separately. Although this manual covers a lot of
relevant material for all users, the following guidelines are
suggested for various types of users. If you are:
\begin{itemize}
\item {\bf New to MPI}: First, read Chapter~\ref{sec:introduction} for
an introduction to MPI and Open MPI. A good reference on MPI
programming is also strongly recommended; there are several books
available as well as excellent on-line tutorials
(e.g.,~\cite{gropp98:_mpi2,gropp94:_using_mpi,gropp99:_using_mpi_2,snir96:_mpi_the_compl_refer}).
When you're comfortable with the concepts of MPI, move on to {\bf
New to Open MPI}.
\vspace{-3pt}
\item {\bf New to Open MPI}: If you're familiar with MPI but unfamiliar
with Open MPI, first read Chapter~\ref{sec:getting-started} for a
mini-tutorial on getting started with Open MPI. You'll probably be
familiar with many of the concepts described, and simply learn the
Open MPI terminology and commands. Glance over and use as a reference
Chapter~\ref{sec:commands} for the rest of the Open MPI commands.
Chapter~\ref{sec:troubleshooting} contains some quick tips on common
problems with Open MPI.
Assuming that you've already got MPI codes that you want to run
under LAM/MPI, read Chapter~\ref{sec:mpi-functionality} to see
exactly what MPI-2 features LAM/MPI supports.
When you're comfortable with all this, move on to {\bf Previous Open
MPI user}.
\vspace{-3pt}
\item {\bf Previous Open MPI user}: As a previous Open MPI user,
you're probably already fairly familiar with all the Open MPI
commands -- their basic functionality hasn't changed much. However,
many of them have grown new options and capabilities, particularly
in the area of run-time tunable parameters. So be sure to read
Chapters~\ref{sec:ssi} to learn about Open MPI's Modular Component
Architecture (MCA), Chapters~\ref{sec:mca-orte}
and~\ref{sec:mca-ompi} (run-time environment and MPI MCA modules),
and finally Chapter~\ref{sec:misc} (miscellaneous Open MPI
information, features, etc.).
If you're curious to see a brief listing of new features in this
release, see the release notes in Chapter~\ref{sec:release-notes}.
This isn't really necessary, but when you're kicking the tires of
this version, it's a good way to ensure that you are aware of all
the new features.
Finally, even for the seasoned MPI and Open MPI veteran, be sure to
check out Chapter~\ref{sec:debug} for information about debugging
MPI programs in parallel.
\vspace{-3pt}
\item {\bf System administrator}: Unless you're also a parallel
programmer, you're reading the wrong document. You should be
reading the Open MPI Installation
Guide~\cite{open_mpi_install_guide} for detailed
information on how to configure, compile, and install Open MPI.
\end{itemize}

@ -1,22 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\bibliography{refs}
\bibliographystyle{plain}

Разница между файлами не показана из-за своего большого размера Загрузить разницу

@ -1,497 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Debugging Parallel Programs}
\label{sec:debug}
\label{sec:debugging}
\index{debuggers|(}
{\Huge JMS this section is not bad, but needs a little revising (see
notes below}
Open MPI supports multiple methods of debugging parallel programs.
The following notes and observations generally apply to debugging in
parallel:
\begin{itemize}
\item Note that most debuggers require that MPI applications were
compiled with debugging support enabled. This typically entails
adding \cmdarg{-g} to the compile and link lines when building
your MPI application.
\item Unless you specifically need it, it is not recommended to
compile Open MPI with \cmdarg{-g}. This will allow you to treat MPI
function calls as atomic instructions.
\item Even when debugging in parallel, it is possible that not all MPI
processes will execute exactly the same code. For example, ``if''
statements that are based upon a communicator's rank of the calling
process, or other location-specific information may cause different
execution paths in each MPI process.
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Naming MPI Objects}
Open MPI supports the MPI-2 functions {\sf
MPI\_\-$<$type$>$\_\-SET\_\-NAME} and {\sf
MPI\_\-$<$type$>$\_\-GET\_\-NAME}, where {\sf $<$type$>$} can be:
{\sf COMM}, {\sf WIN}, or {\sf TYPE}. Hence, you can associate
relevant text names with communicators, windows, and datatypes (e.g.,
``6x13x12 molecule datatype'', ``Local group reduction
intracommunicator'', ``Spawned worker intercommunicator''). The use
of these functions is strongly encouraged while debugging MPI
applications. Since they are constant-time, one-time setup functions,
using these functions likely does not impact performance, and may be
safe to use in production environments, too.
The rationale for using these functions is to allow Open MPI (and
supported debuggers, profilers, and other MPI diagnostic tools) to
display accurate information about MPI communicators, windows, and
datatypes. For example, whenever a communicator name is available,
Open MPI will use it in relevant error messages; when names are not
available, communicators (and windows and types) are identified by
index number, which -- depending on the application -- may vary
between successive runs. The TotalView parallel debugger will also
show communicator names (if available) when displaying the message
queues.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{TotalView Parallel Debugger}
\label{sec:debug-totalview}
TotalView is a commercial debugger from Etnus that supports debugging
MPI programs in parallel. That is, with supported MPI
implementations, the TotalView debugger can automatically attach to
one or more MPI processes in a parallel application.
Open MPI now supports basic debugging functionality with the TotalView
debugger. Specifically, Open MPI supports TotalView attaching to one
or more MPI processes, as well as viewing the MPI message queues in
supported RPI modules.
This section provides some general tips and suggested use of TotalView
with Open MPI. It is {\em not} intended to replace the TotalView
documentation in any way. {\bf Be sure to consult the TotalView
documentation for more information and details than are provided
here.}
Note: TotalView is licensed product provided by Etnus. You need to
have TotalView installed properly before you can use it with Open
MPI.\footnote{Refer to \url{http://www.etnus.com/} for more
information about TotalView.}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Attaching TotalView to MPI Processes}
\index{TotalView parallel debugger}
\index{debuggers!TotalView}
Open MPI does not need to be configured or compiled in any special way
to allow TotalView to attach to MPI processes.
You can attach TotalView to MPI processes started by \icmd{mpirun} /
\icmd{mpiexec} in following ways:
\begin{enumerate}
\item Use the \cmdarg{-tv} convenience argument when running
\cmd{mpirun} or \cmd{mpiexec} (this is the preferred method):
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ mpirun -tv [...other mpirun arguments...]
\end{lstlisting}
% Stupid emacs mode: $
For example:
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ mpirun -tv C my_mpi_program arg1 arg2 arg3
\end{lstlisting}
% Stupid emacs mode: $
\item Directly launch \cmd{mpirun} in TotalView (you {\em cannot}
launch \cmd{mpiexec} in TotalView):
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ totalview mpirun -a [...mpirun arguments...]
\end{lstlisting}
% Stupid emacs mode: $
For example:
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ totalview mpirun -a C my_mpi_program arg1 arg2 arg3
\end{lstlisting}
% Stupid emacs mode: $
Note the \cmdarg{-a} argument after \cmd{mpirun}. This is necessary
to tell TotalView that arguments following ``\cmdarg{-a}'' belong to
\cmd{mpirun} and not TotalView.
Also note that the \cmdarg{-tv} convenience argument to \cmd{mpirun}
simply executes ``\cmd{totalview mpirun -a ...}''; so both methods
are essentially identical.
\end{enumerate}
TotalView can either attach to all MPI processes in
\mpiconst{MPI\_\-COMM\_\-WORLD} or a subset of them. The controls for
``partial attach'' are in TotalView, not Open MPI. In TotalView 6.0.0
(analogous methods may work for earlier versions of TotalView -- see
the TotalView documentation for more details), you need to set the
parallel launch preference to ``ask.'' In the root window menu:
\begin{enumerate}
\item Select File $\rightarrow$ Preferences
\item Select the Parallel tab
\item In the ``When a job goes parallel'' box, select ``Ask what to do''
\item Click on OK
\end{enumerate}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Suggested Use}
Since TotalView support is started with the \cmd{mpirun} command,
TotalView will, by default, start by debugging \cmd{mpirun} itself.
While this may seem to be an annoying drawback, there are actually
good reasons for this:
\begin{itemize}
\item While debugging the parallel program, if you need to re-run the
program, you can simply re-run the application from within TotalView
itself. There is no need to exit the debugger to run your parallel
application again.
\item TotalView can be configured to automatically skip displaying the
\cmd{mpirun} code. Specifically, instead of displaying the
\cmd{mpirun} code and enabling it for debugging, TotalView will
recognize the command named \cmd{mpirun} and start executing it
immediately upon load. See below for details.
\end{itemize}
\noindent There are two ways to start debugging the MPI application:
\begin{enumerate}
\item The preferred method is to have a \ifile{\$HOME/.tvdrc} file
that tells TotalView to skip past the \cmd{mpirun} code and
automatically start the parallel program. Create or edit your
\ifile{\$HOME/.tvdrc} file to include the following:
\lstset{style=ompi-shell}
\begin{lstlisting}
# Set a variable to say what the MPI ``starter'' program is
set starter_program mpirun
# Check if the newly loaded image is the starter program
# and start it immediately if it is.
proc auto_run_starter {loaded_id} {
global starter_program
set executable_name [TV::symbol get $loaded_id full_pathname]
set file_component [file tail $executable_name]
if {[string compare $file_component $starter_program] == 0} {
puts ``Automatically starting $file_component''
dgo
}
}
# Append this function to TotalView's image load callbacks so that
# TotalView run this program automatically.
dlappend TV::image_load_callbacks auto_run_starter
\end{lstlisting}
% Stupid emacs mode: $
Note that when using this method, \cmd{mpirun} is actually running in
the debugger while you are debugging your parallel application, even
though it may not be obvious. Hence, when the MPI job completes,
you'll be returned to viewing \cmd{mpirun} in the debugger. {\em This
is normal} -- all MPI processes have exited; the only process that
remains is \cmd{mpirun}. If you click ``Go'' again, \cmd{mpirun} will
launch the MPI job again.
\item Do not create the \file{\$HOME/.tvdrc} file with the ``auto
run'' functionality described in the previous item, but instead
simply click the ``go'' button when TotalView launches. This runs
the \cmd{mpirun} command with the command line arguments, which will
eventually launch the MPI programs and allow attachment to the MPI
processes.
\end{enumerate}
When TotalView initially attaches to an MPI process, you will see the
code for \mpifunc{MPI\_\-INIT} or one of its sub-functions (which will
likely be assembly code, unless Open MPI itself was compiled with debugging
information).
%
You probably want to skip past the rest of \mpifunc{MPI\_\-INIT}. In
the Stack Trace window, click on function which called
\mpifunc{MPI\_\-INIT} (e.g., \func{main}) and set a breakpoint to line
following call to \mpifunc{MPI\_\-INIT}. Then click ``Go''.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Limitations}
The following limitations are currently imposed when debugging Open MPI
jobs in TotalView:
\begin{enumerate}
\item Cannot attach to scripts: You cannot attach TotalView to MPI
processes if they were launched by scripts instead of \cmd{mpirun}.
Specifically, the following won't work:
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ mpirun -tv C script_to_launch_foo
\end{lstlisting}
% Stupid emacs mode: $
But this will:
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ mpirun -tv C foo
\end{lstlisting}
% Stupid emacs mode: $
For that reason, since \cmd{mpiexec} is a script, although the
\cmdarg{-tv} switch works with \cmd{mpiexec} (because it will
eventually invoke \cmd{mpirun}), you cannot launch \cmd{mpiexec}
with TotalView.
\item TotalView needs to launch the TotalView server on all remote
nodes in order to attach to remote processes.
The command that TotalView uses to launch remote executables might
be different than what Open MPI uses. You may have to set this
command explicitly and independently of Open MPI.
%
For example, if your local environment has \cmd{rsh} disabled and
only allows \cmd{ssh}, then you likely need to set the TotalView
remote server launch command to ``\cmd{ssh}''. You can set this
internally in TotalView or with the \ienvvar{TVDSVRLAUNCHCMD}
environment variable (see the TotalView documentation for more
information on this).
\item The TotalView license must be able to be found on all nodes
where you expect to attach the debugger.
Consult with your system administrator to ensure that this is set up
properly. You may need to edit your ``dot'' files (e.g.,
\file{.profile}, \file{.bashrc}, \file{.cshrc}, etc.) to ensure that
relevant environment variable settings exist on all nodes.
\item It is always a good idea to let \cmd{mpirun} finish before you
rerun or exit TotalView.
\item TotalView will not be able to attach to MPI programs when you
execute \cmd{mpirun} with \cmdarg{-s} option.
This is because TotalView will not get the source code of your
program on nodes other than the source node. We advise you to
either use a common filesystem or copy the source code and
executable on all nodes when using TotalView with Open MPI so that you
can avoid the use of \cmd{mpirun}'s \cmdarg{-s} flag.
\end{enumerate}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Message Queue Debugging}
The TotalView debugger can show the sending, receiving, and
unexepected message queues for many parallel applications. Note the
following:
\begin{itemize}
\item The MPI-2 function for naming communicators
(\mpifunc{MPI\_\-COMM\_\-SET\_\-NAME}) is strongly recommended when
using the message queue debugging functionality. For example,
\mpiconst{MPI\_\-COMM\_\-WORLD} and \mpiconst{MPI\_\-COMM\_\-SELF}
are automatically named by Open MPI. Naming communicators makes it
significantly easier to identify communicators of interest in the
debugger.
{\Huge JMS is this true?}
Any communicator that is not named will be displayed as ``{\tt
--unnamed--}''.
\item Message queue debugging of applications is not currently
supported for 64 bit executables. If you attempt to use the message
queue debugging functionality on a 64 bit executable, TotalView will
display a warning before disabling the message queue options.
\item Open MPI does not currently provide debugging support for
dynamic processes (e.g., \mpifunc{MPI\_\-COMM\_\-SPAWN}).
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Serial Debuggers}
\label{sec:debug-serial}
\index{serial debuggers}
\index{debuggers!serial}
Open MPI also allows the use of one or more serial debuggers when debugging
a parallel program.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Lauching Debuggers}
\index{debuggers!launching}
Open MPI allows the arbitrary execution of any executable in an MPI
context as long as an MPI executable is eventually launched. For
example, it is common to \icmd{mpirun} a debugger (or a script that
launches a debugger on some nodes, and directly runs the application
on other nodes) since the debugger will eventually launch the MPI
process.
{\Huge JMS may need some minor revamping}
However, one must be careful when running programs on remote nodes
that expect the use of \file{stdin} -- \file{stdin} on remote nodes is
redirected to \file{/dev/null}. For example, it is advantageous to
export the \ienvvar{DISPLAY} environment variable, and run a shell
script that invokes an \cmd{xterm} with ``\cmd{gdb}'' (for example)
running in it on each node. For example:
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ mpirun C -x DISPLAY xterm-gdb.csh
\end{lstlisting}
% Stupid emacs mode: $
Additionally, it may be desirable to only run the debugger on certain
ranks in \mcw. For example, with parallel jobs that include tens or
hundreds of MPI processes, it is really only feasible to attach
debuggers to a small number of processes. In this case, a script may
be helpful to launch debuggers for some ranks in \mcw and directly
launch the application in others.
{\Huge JMS needs revising}
The Open MPI environment variable \ienvvar{Open MPIRANK} can be
helpful in this situation. This variable is placed in the environment
before the target application is executed. Hence, it is visible to
shell scripts as well as the target MPI application. It is erroneous
to alter the value of this variable.
Consider the following script:
\lstset{style=ompi-shell}
\begin{lstlisting}
#!/bin/csh -f
# Which debugger to run
set debugger=gdb
# On MPI_COMM_WORLD rank 0, launch the process in the debugger.
# Elsewhere, just launch the process directly.
if (``$Open MPIRANK'' == ``0'') then
echo Launching $debugger on MPI_COMM_WORLD rank $Open MPIRANK
$debugger $*
else
echo Launching MPI executable on MPI_COMM_WORLD rank $Open MPIRANK
$*
endif
# All done
exit 0
\end{lstlisting}
% Stupid emacs mode: $
This script can be executed via \cmd{mpirun} to launch a debugger on
\mpiconst{MPI\_\-COMM\_\-WORLD} rank 0, and directly launch the MPI
process in all other cases.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Attaching Debuggers}
\index{debuggers!attaching}
In some cases, it is not possible or desirable to start debugging a
parallel application immediately. For example, it may only be
desirable to attach to certain MPI processes whose identity may not be
known until run-time.
In this case, the technique of attaching to a running process can be
used (this functionality is supported by many serial debuggers).
Specifically, determine which MPI process you want to attach to. Then
login to the node where it is running, and use the debugger's
``attach'' functionality to latch on to the running process.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Memory-Checking Debuggers}
\label{sec:debug-mem}
\index{debuggers!memory-checking}
Memory-checking debuggers are an invaluable tool when debugging
software (even parallel software). They can provide detailed reports
about memory leaks, bad memory accesses, duplicate/bad memory
management calls, etc. Some memory-checking debuggers include (but
are not limited to): the Solaris Forte debugger (including the
\cmd{bcheck} command-line memory checker), the Purify software
package, and the Valgrind software package.
Open MPI can be used with memory-checking debuggers. However, Open
MPI should be compiled with special support for such debuggers. This
is because in an attempt to optimize performance, there are many
structures used internally to Open MPI that do not always have all
memory positions initialized. For example, Open MPI's internal
\type{struct nmsg} is one of the underlying message constructs used to
pass data between Open MPI processes. But since the \type{struct
nmsg} is used in so many places, it is a generalized structure and
contains fields that are not used in every situation.
By default, Open MPI only initializes relevant struct members before
using a structure. Using a structure may involve sending the entire
structure (including uninitialized members) to a remote host. This is
not a problem for Open MPI; the remote host will also ignore the
irrelevant struct members (depending on the specific function being
invoked). More to the point -- Open MPI was designed this way to
avoid setting variables that will not be used; this is a slight
optimization in run-time performance. Memory-checking debuggers,
however, will flag this behavior with ``read from uninitialized''
warnings.
The \confflag{enable-mem-debug} option can be used with Open MPI's
\cmd{configure} script that will force Open MPI to zero out {\em all}
memory before it is used. This will eliminate the ``read from
uninitialized'' types of warnings that memory-checking debuggers will
identify deep inside Open MPI. This option can only be specified when
Open MPI is configured; it is not possible to enable or disable this
behavior at run-time. Since this option invokes a slight overhead
penalty in the run-time performance of Open MPI, it is not the
default.
% Close out the debuggers index entry
\index{debuggers|)}

@ -1,208 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\usepackage{times}
\usepackage[final]{graphicx}
\usepackage{fullpage}
\usepackage{url}
\usepackage{makeidx}
\usepackage[final]{listings}
% Make the index
\makeindex
% Version (gets substituted in by ``make dist'')
\include{version}
% PDF stuff
\ifx\pdfoutput\undefined
\usepackage[colorlinks=true,
linkcolor=blue,filecolor=blue,pagecolor=blue,urlcolor=blue
]{hyperref}
\else
\usepackage[pdftex,
colorlinks=true,
linkcolor=blue,filecolor=blue,pagecolor=blue,urlcolor=blue
]{hyperref}
\fi
% Some custom commands. Can't put spaces in these, or they'll show up
% with extra spaces in the text. :-(
\newcommand{\cmd}[1]{\texttt{#1}}
\newcommand{\icmd}[1]{\cmd{#1}\index{#1 command@\cmd{#1} command}\index{commands!#1@\cmd{#1}}}
\newcommand{\idepcmd}[1]{\cmd{#1}\index{#1 command (deprecated)@\cmd{#1} command (deprecated)}\index{commands!#1 (deprecated)@\cmd{#1} (deprecated)}}
\newcommand{\cmdindex}[2]{\index{#1 command@\cmd{#1} command!#2}\index{commands!#1@\cmd{#1}}}
\newcommand{\cmdarg}[1]{\texttt{#1}}
\newcommand{\func}[1]{\texttt{#1}}
\newcommand{\ifunc}[1]{\func{#1}\index{#1@\func{#1}}}
\newcommand{\mpifunc}[1]{\textsf{#1}\index{MPI functions!#1@\textsf{#1}}}
\newcommand{\mpidatatype}[1]{\textsf{#1}\index{MPI datatypes!#1@\textsf{#1}}}
\newcommand{\mpitype}[1]{\textsf{#1}\index{MPI types!#1@\textsf{#1}}}
\newcommand{\type}[1]{\texttt{#1}}
\newcommand{\mpiattr}[1]{\textsf{#1}\index{MPI attribute keyvals!#1@\textsf{#1}}}
\newcommand{\mpiconst}[1]{\textsf{#1}\index{MPI constants!#1@\textsf{#1}}}
\newcommand{\iconst}[1]{\const{#1}\index{#1@\const{#1}}}
\newcommand{\const}[1]{\textsf{#1}}
\def\mcw{\mpiconst{MPI\_\-COMM\_\-WORLD}}
\def\mcs{\mpiconst{MPI\_\-COMM\_\-SELF}}
\newcommand{\confflag}[1]{\texttt{--#1}\index{#1@\texttt{--#1} configure flag}\index{configure flags!--#1@\texttt{--#1}}}
\newcommand{\confflagtwo}[2]{\texttt{--#1=#2}\index{#1@\texttt{--#1} configure flag}\index{configure flags!--#1@\texttt{--#1}}}
\newcommand{\depconfflag}[1]{\texttt{--#1}\index{#1@\texttt{--#1}
deprecated configure flag}}
\newcommand{\depconfflagtwo}[2]{\texttt{--#1=#2}\index{#1@\texttt{--#1}
deprecated configure flag}}
\newcommand{\confarg}[1]{\textsf{#1}}
\newcommand{\manpage}[1]{\texttt{#1}\index{#1@\texttt{#1} manual page}\index{manual pages!#1@\texttt{#1}}}
\newcommand{\maketarget}[1]{\texttt{#1}\index{#1@\texttt{#1} make target}\index{make targets!#1@\texttt{#1}}}
\newcommand{\file}[1]{\texttt{#1}}
\newcommand{\ifile}[1]{\file{#1}\index{#1@\file{#1} file}\index{files!#1@\file{#1}} }
\newcommand{\envvar}[1]{\texttt{#1}}
\newcommand{\ienvvar}[1]{\envvar{#1}\index{#1 environment variable@\envvar{#1} environment variable}\index{environment variables!#1@\envvar{#1}}}
\newcommand{\idepenvvar}[1]{\envvar{#1}\index{#1 environment variable@\envvar{#1} environment variable (deprecated)}\index{environment variables!#1 (deprecated)@\envvar{#1} (deprecated)}}
\newcommand{\mcafw}[1]{\textsf{#1}}
\newcommand{\mcacomp}[1]{\textsf{#1}}
\newcommand{\mcaparam}[1]{\texttt{#1}}
\newcommand{\imcaparam}[1]{\mcaparam{#1}\index{#1 MCA parameter@\mcaparam{#1} MCA parameter}\index{MCA parameters!#1@\mcaparam{#1}}}
\newcommand{\mcavalue}[1]{\texttt{#1}}
\newcommand{\imcavalue}[2]{\mcavalue{#2}\index{MCA parameters!#1@\mcaparam{#1}!#2 value@\mcavalue{#2} value}}
\newcommand{\host}[1]{\texttt{#1}}
\newcommand{\user}[1]{\texttt{#1}}
\newcommand{\funcarg}[1]{\texttt{#1}}
\newcommand{\var}[1]{\texttt{#1}}
\newcommand{\signal}[1]{\textsf{#1}}
%
% Tables for MCA Parameters
%
\newenvironment{mcaparamtb}
{\noindent
\begin{center}
\begin{tabular}{| p{2.1in} | p{.9in} | p{3in} |} \hline
\multicolumn{1}{|c|}{MCA parameter name} &
\multicolumn{1}{|c|}{Default value} &
\multicolumn{1}{|c|}{Description} \\ \hline \hline}
{\end{tabular}\end{center}}
\newcommand{\mcaparamentry}[3]{\imcaparam{#1} & \multicolumn{1}{|c|}{#2} & #3 \\ \hline}
% Some defines
\def\trademark{$^{\sf (TM)}$}
\def\supportyes{yes}
\def\supportno{no}
% Define some lstlistings styles for convenience
\lstdefinestyle{ompi-c}{
language=C,
showspaces=false,
columns=fullflexible,
frame=single,
frameround=tttt
}
\lstdefinestyle{ompi-cxx}{
language=C++,
showspaces=false,
columns=fullflexible,
frameround=tttt
}
\lstdefinestyle{ompi-perl}{
language=Perl,
showspaces=false,
columns=fullflexible,
frameround=tttt
}
\lstdefinestyle{ompi-fortran}{
language=Fortran,
showspaces=false,
columns=fullflexible,
frame=single,
frameround=tttt
}
\lstdefinestyle{ompi-bourne}{
language=ksh,
showspaces=false,
frame=single,
frameround=tttt,
columns=fullflexible,
}
\lstdefinestyle{ompi-shell}{
language=csh,
showspaces=false,
frame=single,
frameround=tttt,
columns=fullflexible,
}
\lstdefinestyle{ompi-cmdline}{
language=csh,
showspaces=false,
columns=fullflexible,
frame=single,
frameround=tttt,
emph={shell$},
emphstyle=\bf
}
% Stupid emacs mode: $
\lstdefinestyle{ompi-ompiinfo}{
language=csh,
showspaces=false,
columns=fixed,
frame=single,
frameround=tttt,
emph={shell$},
emphstyle=\bf
}
% Stupid emacs mode: $
% Stoopid European-based Linux distributions...
% Gotta force letter size paper, not A4
\ExecuteOptions{letterpaper}
% Discussion item; stolen from the MPI standard
\newenvironment{discuss}{\begin{list}{}{}\item[]{\it Discussion item:}
\addcontentsline{toc}{subsection}{Discussion Item}
}{{\rm ({\it End of discussion item.})} \end{list}}
% Change bars
\newcommand{\changebegin}[1]{\marginpar[\hspace*{75pt}\mbox{\hspace*{10pt}
$\top$ \tiny (#1)}]{\mbox{$\top$ \tiny (#1)}}}
\newcommand{\changeend}[1]{\marginpar[\hspace*{75pt}\mbox{\hspace*{10pt}
$\bot$ \tiny (#1)}]{\mbox{$\bot$ \tiny (#1)}}}

@ -1,948 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Getting Started with Open MPI}
\label{sec:getting-started}
This chapter provides a summary tutorial describing some of the high
points of using Open MPI. It is not intended as a comprehensive
guide; the finer details of some situations will not be explained.
However, it is a good step-by-step guide for users who are new to MPI
and/or Open MPI.
Using Open MPI is conceptually simple:
\begin{itemize}
\item Optionally launch the Open MPI run-time environment, as known as
the Open Run-Time Environment (ORTE)
\item Repeat as necessary:
\begin{itemize}
\item Compile MPI program(s)
\item Run MPI program(s)
\end{itemize}
\item If ORTE was started, shut it down.
\end{itemize}
The tutorial below will describe each of these steps.
{\Huge JMS Needs massive overhauling}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{One-Time Setup}
This section describes actions that usually only need to be performed
once per user in order to setup LAM to function properly.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Setting the Path}
\label{sec:getting-started-path}
One of the main requirements for Open MPI to function properly is for
the LAM executables to be in your path. This step may vary from site
to site; for example, the LAM executables may already be in your path
-- consult your local administrator to see if this is the case.
{\bf NOTE:} If the LAM executables are already in your path, you can
skip this step and proceed to
Section~\ref{sec:getting-started-ssi}.
In many cases, if your system does not already provide the LAM
executables in your path, you can add them by editing your ``dot''
files that are executed automatically by the shell upon login (both
interactive and non-interactive logins). Each shell has a different
file to edit and corresponding syntax, so you'll need to know which
shell you are using.
Tables~\ref{tbl:getting-started-shells-interactive}
and~\ref{tbl:getting-started-shells-noninteractive} list several
common shells and the associated files that are typically used.
Consult the documentation for your shell for more information.
\begin{table}[htbp]
\centering
\begin{tabular}{|p{1in}|p{4in}|}
\hline
\multicolumn{1}{|c|}{Shell name} &
\multicolumn{1}{|c|}{Interactive login startup file} \\
%
\hline
\cmd{sh} (or Bash named ``\cmd{sh}'') & \ifile{.profile} \\
%
\hline
\cmd{csh} & \ifile{.cshrc} followed by \ifile{.login} \\
%
\hline
\cmd{tcsh} & \ifile{.tcshrc} if it exists, \ifile{.cshrc} if it
does not, followed by \ifile{.login} \\
%
\hline
\cmd{bash} & \ifile{.bash\_\-profile} if it exists, or
\ifile{.bash\_\-login} if it exists, or \ifile{.profile} if it
exists (in that order). Note that some Linux distributions
automatically come with \ifile{.bash\_\-profile} scripts for users
that automatically execute \ifile{.bashrc} as well. Consult the
\cmd{bash} manual page for more information. \\
\hline
\end{tabular}
\caption[List of common shells and the corresponding environment
setup files for interactive shells.]{List of common shells and
the corresponding environmental setup files commonly used with
each for interactive startups (e.g., normal login). All files
listed are assumed to be in the \file{\$HOME} directory.}
\label{tbl:getting-started-shells-interactive}
\end{table}
\begin{table}[htbp]
\centering
\begin{tabular}{|p{1in}|p{4in}|}
\hline
\multicolumn{1}{|c|}{Shell name} &
\multicolumn{1}{|c|}{Non-interactive login startup file} \\
%
\hline
\cmd{sh} (or Bash named ``\cmd{sh}'') & This shell does not
execute any file automatically, so LAM will execute the
\file{.profile} script before invoking LAM executables on remote
nodes \\
%
\hline
\cmd{csh} & \ifile{.cshrc} \\
%
\hline
\cmd{tcsh} & \ifile{.tcshrc} if it exists, \ifile{.cshrc} if it
does not \\
%
\hline
\cmd{bash} & \ifile{.bashrc} if it exists \\
\hline
\end{tabular}
\caption[List of common shells and the corresponding environment
setup files for non-interactive shells.]{List of common shells and
the corresponding environmental setup files commonly used with
each for non-interactive startups (e.g., normal login). All files
listed are assumed to be in the \file{\$HOME} directory.}
\label{tbl:getting-started-shells-noninteractive}
\end{table}
You'll also need to know the directory where LAM was installed. For
the purposes of this tutorial, we'll assume that LAM is installed in
\file{/usr/local/lam}. And to re-emphasize a critical point: these
are only guidelines -- the specifics may vary depending on your local
setup. Consult your local system or network administrator for more
details.
Once you have determined all three pieces of information (what shell
you are using, what directory LAM was installed to, and what the
appropriate ``dot'' file to edit), open the ``dot'' file in a text
editor and follow the general directions listed below:
\begin{itemize}
\index{shell setup!Bash/Bourne shells}
\item For the Bash, Bourne, and Bourne-related shells, add the
following lines:
\lstset{style=lam-bourne}
\begin{lstlisting}
PATH=/usr/local/lam/bin:$PATH
export PATH
\end{lstlisting}
% Stupid emacs mode: $
\index{shell setup!C shell (and related)}
\item For the C shell and related shells (such as \cmd{tcsh}), add the
following line:
\lstset{style=lam-shell}
\begin{lstlisting}
set path = (/usr/local/lam/bin $path)
\end{lstlisting}
% Stupid emacs mode: $
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Finding the LAM Manual Pages}
\index{manual pages}
LAM includes manual pages for all supported MPI functions as well as
all of the LAM executables. While this step {\em is not necessary}
for correct MPI functionality, it can be helpful when looking for MPI
or LAM-specific information.
Using Tables~\ref{tbl:getting-started-shells-interactive}
and~\ref{tbl:getting-started-shells-noninteractive}, find the right
``dot'' file to edit. Assuming again that LAM was installed to
\file{/usr/local/lam}, open the appropriate ``dot'' file in a text
editor and follow the general directions listed below:
\begin{itemize}
\index{shell setup!Bash/Bourne shells}
\item For the Bash, Bourne, and Bourne-related shells, add the
following lines:
\lstset{style=lam-bourne}
\begin{lstlisting}
MANPATH=/usr/local/lam/man:$MANPATH
export MANPATH
\end{lstlisting}
% Stupid emacs mode: $
\index{shell setup!C shell (and related)}
\item For the C shell and related shells (such as \cmd{tcsh}), add the
following lines:
\lstset{style=lam-shell}
\begin{lstlisting}
if ($?MANPATH == 0) then
setenv MANPATH /usr/local/lam/man
else
setenv MANPATH /usr/local/lam/man:$MANPATH
endif
\end{lstlisting}
% Stupid emacs mode: $
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{System Services Interface (SSI)}
\label{sec:getting-started-ssi}
Open MPI is built around a core of System Services Interface (SSI)
plugin modules. SSI allows run-time selection of different underlying
services within the Open MPI run-time environment, including tunable
parameters that can affect the performance of MPI programs.
While this tutorial won't go into much detail about SSI, just be aware
that you'll see mention of ``SSI'' in the text below. In a few
places, the tutorial passes parameters to various SSI modules through
either environment variables and/or the \cmdarg{-ssi} command line
parameter to several LAM commands.
See other sections in this manual for a more complete description of
SSI (Chapter~\ref{sec:ssi}, page~\pageref{sec:ssi}), how it works, and
what run-time parameters are available (Chapters~\ref{sec:lam-ssi}
and~\ref{sec:mpi-ssi}, pages~\pageref{sec:lam-ssi}
and~\pageref{sec:mpi-ssi}, respectively). Also, the
\manpage{lamssi(7)}, \manpage{lamssi\_\-boot(7)},
\manpage{lamssi\_\-coll(7)}, \manpage{lamssi\_\-cr(7)}, and
\manpage{lamssi\_\-rpi(7)} manual pages each provide additional
information on LAM's SSI mechanisms.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{What Does Your Open MPI Installation Support?}
Open MPI can be installed with a large number of configuration options.
It depends on what choices your system/network administrator made when
configuring and installing Open MPI. The \icmd{laminfo} command is
provided to show the end-user with information about what the
installed Open MPI supports. Running ``\cmd{laminfo}'' (with no
arguments) prints a list of LAM's capabilities, including all of its
SSI modules.
Among other things, this shows what language bindings the installed
Open MPI supports, what underlying network transports it supports, and
what directory LAM was installed to. The \cmdarg{-parsable} option
prints out all the same information, but in a conveniently
machine-parsable format (suitable for using with scripts).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Booting the LAM Run-Time Environment}
\label{sec:getting-started-booting}
\index{booting the LAM run-time environment}
Before any MPI programs can be executed, the LAM run-time environment
must be launched. This is typically called ``booting LAM.'' A
successfully boot process creates an instance of the LAM run-time
environment commonly referred to as the ``LAM universe.''
LAM's run-time environment can be executed in many different
environments. For example, it can be run interactively on a cluster
of workstations (even on a single workstation, perhaps to simulate
parallel execution for debugging and/or development). Or LAM can be
run in production batch scheduled systems.
This example will focus on a traditional \cmd{rsh} / \cmd{ssh}-style
workstation cluster (i.e., not under batch systems), where \cmd{rsh}
or \cmd{ssh} is used to launch executables on remote workstations.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The Boot Schema File (a.k.a, ``Hostfile'', ``Machinefile'')}
\label{sec:getting-started-hostfile}
When using \cmd{rsh} or \cmd{ssh} to boot LAM, you will need a text
file listing the hosts on which to launch the LAM run-time
environment. This file is typically referred to as a ``boot schema'',
``hostfile'', or ``machinefile.'' For example:
\lstset{style=lam-shell}
\begin{lstlisting}
# My boot schema
node1.cluster.example.com
node2.cluster.example.com
node3.cluster.example.com cpu=2
node4.cluster.example.com cpu=2
\end{lstlisting}
Four nodes are specified in the above example by listing their IP
hostnames. Note also the ``{\tt cpu=2}'' that follows the last two
entries. This tells LAM that these machines each have two CPUs
available for running MPI programs (e.g., \host{node3} and
\host{node4} are two-way SMPs). It is important to note that the
number of CPUs specified here has {\em no} correlation to the
physicial number of CPUs in the machine. It is simply a convenience
mechanism telling LAM how many MPI processes we will typically launch
on that node. The ramifications of the {\tt cpu} key will be discussed
later.
The location of this text file is irrelevant; for the purposes of this
example, we'll assume that it is named \file{hostfile} and is located
in the current working directory.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \icmd{lamboot} Command}
\label{sec:getting-started-lamboot}
The \cmd{lamboot} command is used to launch the LAM run-time
environment. For each machine listed in the boot schema, the
following conditions must be met for LAM's run-time environment to be
booted correctly:
\cmdindex{lamboot}{conditions for success}
\begin{itemize}
\item The machine must be reachable and operational.
\item The user must be able to non-interactively execute arbitrary
commands on the machine (e.g., without being prompted for a
password).
\item The LAM executables must be locatable on that machine, using the
user's shell search path.
\item The user must be able to write to the LAM session directory
(usually somewhere under \file{/tmp}).
\item The shell's start-up scripts must not print anything on standard
error.
\item All machines must be able to resolve the fully-qualified domain
name (FQDN) of all the machines being booted (including itself).
\end{itemize}
Once all of these conditions are met, the \cmd{lamboot} command is
used to launch the LAM run-time environment. For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamboot -v -ssi boot rsh hostfile
LAM 7.0/MPI 2 C++/ROMIO - Indiana University
n0<1234> ssi:boot:base:linear: booting n0 (node1.cluster.example.com)
n0<1234> ssi:boot:base:linear: booting n1 (node2.cluster.example.com)
n0<1234> ssi:boot:base:linear: booting n2 (node3.cluster.example.com)
n0<1234> ssi:boot:base:linear: booting n3 (node4.cluster.example.com)
n0<1234> ssi:boot:base:linear: finished
\end{lstlisting}
% Stupid emacs mode: $
The parameters passed to \cmd{lamboot} in the example above are as
follows:
\begin{itemize}
\item \cmdarg{-v}: Make \cmd{lamboot} be slightly verbose.
\item \cmdarg{-ssi boot rsh}: Ensure that LAM uses the
\cmd{rsh}/\cmd{ssh} boot module to boot the LAM universe.
Typically, LAM chooses the right boot module automatically (and
therefore this parameter is not typically necessary), but to ensure
that this tutorial does exactly what we want it to do, we use this
parameter to absolutely ensure that LAM uses \cmd{rsh} or \cmd{ssh}
to boot the universe.
\item \file{hostfile}: Name of the boot schema file.
\end{itemize}
Common causes of failure with the \cmd{lamboot} command include (but
are not limited to):
\cmdindex{lamboot}{common problems and solutions}
\begin{itemize}
\item User does not have permission to execute on the remote node.
This typically involves setting up a \file{\$HOME/.rhosts} file (if
using \cmd{rsh}), or properly configured SSH keys (using using
\cmd{ssh}).
Setting up \file{.rhosts} and/or SSH keys for password-less remote
logins are beyond the scope of this tutorial; consult local
documentation for \cmd{rsh} and \cmd{ssh}, and/or internet tutorials
on setting up SSH keys.\footnote{As of this writing, a Google search
for ``ssh keys'' turned up several decent tutorials; including any
one of them here would significantly increase the length of this
already-tremendously-long manual.}
\item The first time a user uses \cmd{ssh} to execute on a remote
node, \cmd{ssh} typically prints a warning to the standard error.
LAM will interpret this as a failure. If this happens,
\cmd{lamboot} will complain that something unexpectedly appeared on
\file{stderr}, and abort.
%
\changebegin{7.1}
%
One solution is to manually \cmd{ssh} to each node in the boot
schema once in order to eliminate the \file{stderr} warning, and
then try \cmd{lamboot} again. Another is to use the
\ssiparam{boot\_\-rsh\_\-ignore\_\-stderr} SSI parameter. We
haven't discussed SSI parameters yet, so it is probably easiest at
this point to manually \cmd{ssh} to a small number of nodes to get
the warning out of the way.
%
\changeend{7.1}
\end{itemize}
If you have having problems with \cmd{lamboot}, try using the
\cmdarg{-d} option to \cmd{lamboot}, which will print enormous amounts
of debugging output which can be helpful for determining what the
problem is. Additionally, check the \file{lamboot(1)} man page as
well as the LAM FAQ on the main LAM web
site\footnote{\url{http://www.lam-mpi.org/faq/}} under the section
``Booting LAM'' for more information.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \icmd{lamnodes} Command}
An easy way to see how many nodes and CPUs are in the current LAM
universe is with the \cmd{lamnodes} command. For example, with the
LAM universe that was created from the boot schema in
Section~\ref{sec:getting-started-hostfile}, running the \cmd{lamnodes}
command would result in the following output:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamnodes
n0 node1.cluster.example.com:1:origin,this_node
n1 node2.cluster.example.com:1:
n2 node3.cluster.example.com:2:
n3 node4.cluster.example.com:2:
\end{lstlisting}
% Stupid emacs mode: $
The ``{\tt n}'' number on the far left is the LAM node number. For
example, ``{\tt n3}'' uniquely refers to \host{node4}. Also note the
third column, which indicates how many CPUs are available for running
processes on that node. In this example, there are a total of 6 CPUs
available for running processes. This information is from the ``{\tt
cpu}'' key that was used in the hostfile, and is helpful for running
parallel processes (see below).
Finally, the ``{\tt origin}'' notation indicates which node
\cmd{lamboot} was executed from. ``{\tt this\_\-node}'' obviously
indicates which node \cmd{lamnodes} is running on.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Compiling MPI Programs}
\label{sec:getting-started-compiling}
\index{compiling MPI programs}
Note that it is {\em not} necessary to have LAM booted to compile MPI
programs.
Compiling MPI programs can be a complicated process:
\begin{itemize}
\item The same compilers should be used to compile/link user MPI
programs as were used to compile LAM itself.
\item Depending on the specific installation configuration of LAM, a
variety of \cmdarg{-I}, \cmdarg{-L}, and \cmdarg{-l} flags (and
possibly others) may be necessary to compile and/or link a user MPI
program.
\end{itemize}
Open MPI provides ``wrapper'' compilers to hide all of this complexity.
These wrapper compilers simply add the correct compiler/linker flags
and then invoke the underlying compiler to actually perform the
compilation/link. As such, LAM's wrapper compilers can be used just
like ``real'' compilers.
The wrapper compilers are named \icmd{mpicc} (for C programs),
\icmd{mpiCC} and \icmd{mpic++} (for C++ programs), and \icmd{mpif77}
(for Fortran programs). For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpicc -g -c foo.c
shell$ mpicc -g -c bar.c
shell$ mpicc -g foo.o bar.o -o my_mpi_program
\end{lstlisting}
% Stupid emacs mode: $
Note that no additional compiler and linker flags are required for
correct MPI compilation or linking. The resulting
\cmd{my\_\-mpi\_\-program} is ready to run in the LAM run-time
environment. Similarly, the other two wrapper compilers can be used
to compile MPI programs for their respective languages:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiCC -O c++_program.cc -o my_c++_mpi_program
shell$ mpif77 -O f77_program.f -o my_f77_mpi_program
\end{lstlisting}
% Stupid emacs mode: $
Note, too, that any other compiler/linker flags can be passed through
the wrapper compilers (such as \cmdarg{-g} and \cmdarg{-O}); they will
simply be passed to the back-end compiler.
Finally, note that giving the \cmdarg{-showme} option to any of the
wrapper compilers will show both the name of the back-end compiler
that will be invoked, and also all the command line options that would
have been passed for a given compile command. For example (line
breaks added to fit in the documentation):
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiCC -O c++_program.cc -o my_c++_program -showme
g++ -I/usr/local/lam/include -pthread -O c++_program.cc -o \
my_c++_program -L/usr/local/lam/lib -llammpio -llammpi++ -lpmpi \
-llamf77mpi -lmpi -llam -lutil -pthread
\end{lstlisting}
% Stupid emacs mode: $
\changebegin{7.1}
Note that the wrapper compilers only add all the Open MPI-specific
flags when a command-line argument that does not begin with a dash
(``-'') is present. For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpicc
gcc: no input files
shell$ mpicc --version
gcc (GCC) 3.2.2 (Mandrake Linux 9.1 3.2.2-3mdk)
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
\end{lstlisting}
\changeend{7.1}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Sample MPI Program in C}
\index{sample MPI program!C}
The following is a simple ``hello world'' C program.
\lstset{style=lam-c}
\begin{lstlisting}
#include <stdio.h>
#include <mpi.h>
int main(int argc, char *argv[]) {
int rank, size;
MPI_Init(&argc, &argv);
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
MPI_Comm_size(MPI_COMM_WORLD, &size);
printf(``Hello, world! I am %d of %d\n'', rank, size);
MPI_Finalize();
return 0;
}
\end{lstlisting}
This program can be saved in a text file and compiled with the
\icmd{mpicc} wrapper compiler.
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpicc hello.c -o hello
\end{lstlisting}
% Stupid emacs mode: $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Sample MPI Program in C++}
\index{sample MPI program!C++}
The following is a simple ``hello world'' C++ program.
\lstset{style=lam-cxx}
\begin{lstlisting}
#include <iostream>
#include <mpi.h>
using namespace std;
int main(int argc, char *argv[]) {
int rank, size;
MPI::Init(argc, argv);
rank = MPI::COMM_WORLD.Get_rank();
size = MPI::COMM_WORLD.Get_size();
cout << ``Hello, world! I am '' << rank << `` of '' << size << endl;
MPI::Finalize();
return 0;
}
\end{lstlisting}
This program can be saved in a text file and compiled with the
\icmd{mpiCC} wrapper compiler (or \cmd{mpic++} if on case-insensitive
filesystems, such as Mac OS X's HFS+).
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiCC hello.cc -o hello
\end{lstlisting}
% Stupid emacs mode: $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Sample MPI Program in Fortran}
\index{sample MPI program!Fortran}
The following is a simple ``hello world'' Fortran program.
\lstset{style=lam-fortran}
\begin{lstlisting}
program hello
include 'mpif.h'
integer rank, size, ierr
call MPI_INIT(ierr)
call MPI_COMM_RANK(MPI_COMM_WORLD, rank, ierr)
call MPI_COMM_SIZE(MPI_COMM_WORLD, size, ierr)
print *, "Hello, world! I am ", rank, " of ", size
call MPI_FINALIZE(ierr)
stop
end
\end{lstlisting}
This program can be saved in a text file and compiled with the
\icmd{mpif77} wrapper compiler.
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpif77 hello.f -o hello
\end{lstlisting}
% Stupid emacs mode: $
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Running MPI Programs}
\index{running MPI programs}
Once you have successfully established a LAM universe and compiled an
MPI program, you can run MPI programs in parallel.
In this section, we will show how to run a Single Program, Multiple
Data (SPMD) program. Specifically, we will run the \cmd{hello}
program (from the previous section) in parallel. The \cmd{mpirun} and
\cmd{mpiexec} commands are used for launching parallel MPI programs,
and the \cmd{mpitask} commands can be used to provide crude debugging
support. The \cmd{lamclean} command can be used to completely clean
up a failed MPI program (e.g., if an error occurs).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \icmd{mpirun} Command}
The \cmd{mpirun} command has many different options that can be used
to control the execution of a program in parallel. We'll explain only
a few of them here.
The simplest way to launch the \cmd{hello} program across all CPUs
listed in the boot schema is:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun C hello
\end{lstlisting}
% stupid emacs mode: $
The \cmdarg{C} option means ``launch one copy of \cmd{hello} on
every CPU that was listed in the boot schema.'' The \cmdarg{C}
notation is therefore convenient shorthand notation for launching a
set of processes across a group of SMPs.
Another method for running in parallel is:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun N hello
\end{lstlisting}
% stupid emacs mode: $
The \cmdarg{N} option has a different meaning than \cmdarg{C} -- it
means ``launch one copy of \cmd{hello} on every node in the LAM
universe.'' Hence, \cmdarg{N} disregards the CPU count. This can be
useful for multi-threaded MPI programs.
Finally, to run an absolute number of processes (regardless of how
many CPUs or nodes are in the LAM universe):
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun -np 4 hello
\end{lstlisting}
% stupid emacs mode: $
This runs 4 copies of \cmd{hello}. LAM will ``schedule'' how many
copies of \cmd{hello} will be run in a round-robin fashion on each
node by how many CPUs were listed in the boot schema
file.\footnote{Note that the use of the word ``schedule'' does not
imply that LAM has ties with the operating system for scheduling
purposes (it doesn't). LAM ``scheduled'' on a per-node basis; so
selecting a process to run means that it has been assigned and
launched on that node. The operating system is solely responsible
for all process and kernel scheduling.} For example, on the LAM
universe that we have previously shown in this tutorial, the following
would be launched:
\begin{itemize}
\item 1 \cmd{hello} would be launched on {\tt n0} (named
\host{node1})
\item 1 \cmd{hello} would be launched on {\tt n1} (named
\host{node2})
\item 2 \cmd{hello}s would be launched on {\tt n2} (named
\host{node3})
\end{itemize}
Note that any number can be used -- if a number is used that is
greater than how many CPUs are in the LAM universe, LAM will ``wrap
around'' and start scheduling starting with the first node again. For
example, using \cmdarg{-np 10} would result in the following
schedule:
\begin{itemize}
\item 2 \cmd{hello}s on {\tt n0} (1 from the first pass, and then a
second from the ``wrap around'')
\item 2 \cmd{hello}s on {\tt n1} (1 from the first pass, and then a
second from the ``wrap around'')
\item 4 \cmd{hello}s on {\tt n2} (2 from the first pass, and then 2
more from the ``wrap around'')
\item 2 \cmd{hello}s on {\tt n3}
\end{itemize}
The \file{mpirun(1)} man page contains much more information and
\cmd{mpirun} and the options available. For example, \cmd{mpirun}
also supports Multiple Program, Multiple Data (MPMD) programs,
although it is not discussed here. Also see
Section~\ref{sec:commands-mpirun} (page~\pageref{sec:commands-mpirun})
in this document.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \icmd{mpiexec} Command}
The MPI-2 standard recommends the use of \cmd{mpiexec} for portable
MPI process startup. In Open MPI, \cmd{mpiexec} is functionaly similar
to \cmd{mpirun}. Some options that are available to \cmd{mpirun} are
not available to \cmd{mpiexec}, and vice-versa. The end result is
typically the same, however -- both will launch parallel MPI programs;
which you should use is likely simply a personal choice.
That being said, \cmd{mpiexec} offers more convenient access in three
cases:
\begin{itemize}
\item Running MPMD programs
\item Running heterogeneous programs
\item Running ``one-shot'' MPI programs (i.e., boot LAM, run the
program, then halt LAM)
\end{itemize}
The general syntax for \cmd{mpiexec} is:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiexec <global_options> <cmd1> : <cmd2> : ...
\end{lstlisting}
% stupid emacs mode: $
%%%%%
\subsubsection{Running MPMD Programs}
For example, to run a manager/worker parallel program, where two
different executables need to be launched (i.e., \cmd{manager} and
\cmd{worker}, the following can be used:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiexec -n 1 manager : worker
\end{lstlisting}
% stupid emacs mode: $
This runs one copy of \cmd{manager} and one copy of \cmd{worker} for
every CPU in the LAM universe.
%%%%%
\subsubsection{Running Heterogeneous Programs}
Since LAM is a heterogeneous MPI implementation, it supports running
heterogeneous MPI programs. For example, this allows running a
parallel job that spans a Sun SPARC machine and an IA-32 Linux machine
(even though they are opposite endian machines). Although this can be
somewhat complicated to setup (remember that you will first need to
\cmd{lamboot} successfully, which essentially means that LAM must be
correctly installed on both architectures), the \cmd{mpiexec} command
can be helpful in actually running the resulting MPI job.
Note that you will need to have two MPI executables -- one compiled
for Solaris (e.g., \cmd{hello.solaris}) and one compiled for Linux
(e.g., \cmd{hello.linux}). Assuming that these executables both
reside in the same directory, and that directory is available on both
nodes (or the executables can be found in the \envvar{PATH} on their
respective machines), the following command can be used:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiexec -arch solaris hello.solaris : -arch linux hello.linux
\end{lstlisting}
% stupid emacs mode: $
This runs the \cmd{hello.solaris} command on all nodes in the LAM
universe that have the string ``solaris'' anywhere in their
architecture string, and \cmd{hello.linux} on all nodes that have
``linux'' in their architecture string. The architecture string of a
given LAM installation can be found by running the \cmd{laminfo}
command.
%%%%%
\subsubsection{``One-Shot'' MPI Programs}
In some cases, it seems like extra work to boot a LAM universe, run
a single MPI job, and then shut down the universe. Batch jobs are
good examples of this -- since only one job is going to be run, why
does it take three commands? \cmd{mpiexec} provides a convenient way
to run ``one-shot'' MPI jobs.
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpiexec -machinefile hostfile hello
\end{lstlisting}
% stupid emacs mode: $
This will invoke \cmd{lamboot} with the boot schema named
``\file{hostfile}'', run the MPI program \cmd{hello} on all available
CPUs in the resulting universe, and then shut down the universe with
the \cmd{lamhalt} command (which we'll discuss in
Section~\ref{sec:getting-started-lamhalt}, below).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \icmd{mpitask} Command}
The \cmd{mpitask} command is analogous to the sequential Unix command
\cmd{ps}. It shows the current status of the MPI program(s) being
executed in the LAM universe, and displays primitive information about
what MPI function each process is currently executing (if any). Note
that in normal practice, the \cmd{mpimsg} command only gives a
snapshot of what messages are flowing between MPI processes, and
therefore is usually only accurate at that single point in time. To
really debug message passing traffic, use a tool such as message
passing analyzer (e.g., XMPI), or a parallel debugger (e.g.,
TotalView).
\cmd{mpitask} can be run from any node in the LAM universe.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \icmd{lamclean} Command}
The \cmd{lamclean} command completely removed all running programs
from the LAM universe. This can be useful if a parallel job crashes
and/or leaves state in the LAM run-time environment (e.g., MPI-2
published names). It is usually run with no parameters:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamclean
\end{lstlisting}
% stupid emacs mode: $
\cmd{lamclean} is typically only necessary when developing / debugging
MPI applications -- i.e., programs that hang, messages that are left
around, etc. Correct MPI programs should terminate properly, clean up
all their messages, unpublish MPI-2 names, etc.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Shutting Down the LAM Universe}
\label{sec:getting-started-lamhalt}
When finished with the LAM universe, it should be shut down with the
\icmd{lamhalt} command:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamhalt
\end{lstlisting}
% Stupid emacs mode: $
In most cases, this is sufficient to kill all running MPI processes
and shut down the LAM universe.
However, in some rare conditions, \cmd{lamhalt} may fail. For
example, if any of the nodes in the LAM universe crashed before
running \cmd{lamhalt}, \cmd{lamhalt} will likely timeout and
potentially not kill the entire LAM universe. In this case, you will
need to use the \icmd{lamwipe} command to guarantee that the LAM
universe has shut down properly:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamwipe -v hostfile
\end{lstlisting}
% Stupid emacs mode: $
\noindent where \file{hostfile} is the same boot schema that was used to
boot LAM (i.e., all the same nodes are listed). \cmd{lamwipe} will
forcibly kill all Open MPI processes and terminate the LAM universe.
This is a slower process than \cmd{lamhalt}, and is typically not
necessary.

@ -1,96 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Introduction to Open MPI}
\label{sec:introduction}
This chapter provides a summary of the MPI standard and the
Open MPI implementation of that standard.
\section{About MPI}
The Message Passing Interface
(MPI)~\cite{geist96:_mpi2_lyon,mpi_forum93:_mpi}, is a set of API
functions enabling programmers to write high-performance parallel
programs that pass messages between processes to make up an
overall parallel job. MPI is the culmination of decades of research
in parallel computing, and was created by the MPI Forum~-- an open
group representing a wide cross-section of industry and academic
interests. More information, including the both volumes of the
official MPI standard, can be found at the MPI Forum web
site.\footnote{\url{http://www.mpi-forum.org/}}
MPI is suitable for ``big iron'' parallel machines such as the IBM SP,
SGI Origin, etc., but it also works in smaller environments such as a
group of workstations. Since clusters of workstations are readily
available at many institutions, it has become common to use them as a
single parallel computing resource running MPI programs.
%
The MPI standard was designed to support portability and platform
independence. As a result, users can enjoy cross-platform development
capability as well as transparent heterogenous communication. For
example, MPI codes which have been written on the RS-6000 architecture
running AIX can be ported to a SPARC architecture running Solaris with
little or no modifications.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{About Open MPI}
Open MPI is a project combining technologies and resources from
several other projects (FT-MPI, LA-MPI, LAM/MPI, and PACX-MPI) in
order to build the best MPI library available. A completely new MPI-2
compliant implementation, Open MPI offers advantages for system and
software vendors, application developers, and computer science
researchers.
Features implemented or in short-term development for Open MPI
include:
\begin{itemize}
\item Full MPI-2 standards conformance
\item Thread safety and concurrency
\item Dynamic process spawning
\item High performance on all platforms
\item Reliable and fast job management
\item Network and process fault tolerance
\item Support data and network heterogeneity
\item Single library supports all networks
\item Run-time instrumentation
\item Many job schedulers supported
\item Many OS's supported (32 and 64 bit)
\item Production quality software
\item Portable and maintainable
\item Tunable by installers and end-users
\item Extensive user and installer guides
\item Internationalized error messages
\item Component-based design, documented APIs
\item CPAN-like tool for component management
\item Active, responsive mailing list
\item Open source license based on the BSD license
\end{itemize}
The organizations (and newly-combined projects) contributing to Open
MPI are Indiana University (LAM/MPI), the University of Tennessee
(FT-MPI), and Los Alamos National Laboratory (LA-MPI). Additional
collaborators are at Sandia National Laboratories and the University
of Stuttgart. These developers bring many years of combined experience
to the project.

@ -1,41 +0,0 @@
%%
%% This is file `listings.cfg',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% lstdrvrs.dtx (with options: `config')
%%
%% (w)(c) 1996/1997/1998/1999/2000/2001/2002 Carsten Heinz and/or any
%% other author listed elsewhere in this file.
%%
%% This file is distributed under the terms of the LaTeX Project Public
%% License from CTAN archives in directory macros/latex/base/lppl.txt.
%% Either version 1.0 or, at your option, any later version.
%%
%% This file is completely free and comes without any warranty.
%%
%% Send comments and ideas on the package, error reports and additional
%% programming languages to <cheinz@gmx.de>.
%%
\ProvidesFile{listings.cfg}[2002/04/01 v1.0 listings configuration]
\def\lstlanguagefiles
{lstlang0.sty,lstlang1.sty,lstlang2.sty,lstlang3.sty}
\lstset{defaultdialect=[R/3 6.10]ABAP,
defaultdialect=[95]Ada,
defaultdialect=[68]Algol,
defaultdialect=[ANSI]C,
defaultdialect=[light]Caml,
defaultdialect=[1985]Cobol,
defaultdialect=[ISO]C++,
defaultdialect=[95]Fortran,
defaultdialect=[3.0]Mathematica,
defaultdialect=[OMG]OCL,
defaultdialect=[Standard]Pascal,
defaultdialect=[67]Simula,
defaultdialect=[plain]TeX,
defaultdialect=[97]VRML}
\lstalias[]{TclTk}[tk]{tcl}
\endinput
%%
%% End of file `listings.cfg'.

Разница между файлами не показана из-за своего большого размера Загрузить разницу

@ -1,466 +0,0 @@
%%
%% This is file `lstdoc.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% listings.dtx (with options: `doc')
%%
%% Please read the software license in listings.dtx or listings.dvi.
%%
%% (w)(c) 1996 -- 2002 Carsten Heinz and/or any other author
%% listed elsewhere in this file.
%%
%% This file is distributed under the terms of the LaTeX Project Public
%% License from CTAN archives in directory macros/latex/base/lppl.txt.
%% Either version 1.0 or, at your option, any later version.
%%
%% Permission is granted to modify the listings package as well as
%% lstdrvrs.dtx. You are not allowed to distribute a modified version
%% of the package or lstdrvrs.dtx unless you change the file names and
%% provide the original files. In any case it is better to contact the
%% address below; other users will welcome removed bugs, new features,
%% and additional programming languages.
%%
%% The listings package is free software.
%%
%% However, if you distribute the package as part of a commercial
%% product or if you use the package to prepare a commercial document
%% (books, journals, and so on), I'd like to encourage you to make a
%% donation to the LaTeX3 fund. The size of this `license fee' should
%% depend on the value of the package for your product. For more
%% information about LaTeX see http://www.latex-project.org
%%
%% No matter whether you use the package for a commercial or
%% non-commercial document, please send me a copy of the document (.dvi,
%% .ps, .pdf, hardcopy, etc.) to support further development---it is
%% easier to introduce new features or simplify things if I see how the
%% package is used by other people.
%%
%% Send comments and ideas on the package, error reports and additional
%% programming languages to <cheinz@gmx.de>.
%%
\def\filedate{2002/04/01}
\def\fileversion{1.0}
\ProvidesPackage{lstdoc}
[\filedate\space\fileversion\space(Carsten Heinz)]
\let\lstdoc@currversion\fileversion
\RequirePackage[writefile]{listings}[2002/04/01]
\newif\iffancyvrb \IfFileExists{fancyvrb.sty}{\fancyvrbtrue}{}
\newif\ifcolor \IfFileExists{color.sty}{\colortrue}{}
\newif\ifhyper \@ifundefined{pdfoutput}{}
{\IfFileExists{hyperref.sty}{\hypertrue}{}}
\newif\ifalgorithmic \IfFileExists{algorithmic.sty}{\algorithmictrue}{}
\iffancyvrb \RequirePackage{fancyvrb}\fi
\ifhyper \RequirePackage[colorlinks]{hyperref}\else
\def\href#1{\texttt}\fi
\ifcolor \RequirePackage{color}\fi
\ifalgorithmic \RequirePackage{algorithmic}\fi
\RequirePackage{nameref}
\renewcommand\ref{\protect\T@ref}
\renewcommand\pageref{\protect\T@pageref}
\def\lst@BeginRemark#1{%
\begin{quote}\topsep0pt\let\small\footnotesize\small#1:}
\def\lst@EndRemark{\end{quote}}
\newenvironment{TODO}
{\lst@BeginRemark{To do}}{\lst@EndRemark}
\newenvironment{ALTERNATIVE}
{\lst@BeginRemark{Alternative}}{\lst@EndRemark}
\newenvironment{REMOVED}
{\lst@BeginRemark{Removed}}{\lst@EndRemark}
\newenvironment{OLDDEF}
{\lst@BeginRemark{Old definition}}{\lst@EndRemark}
\def\advise{\par\list\labeladvise
{\advance\linewidth\@totalleftmargin
\@totalleftmargin\z@
\@listi
\let\small\footnotesize \small\sffamily
\parsep \z@ \@plus\z@ \@minus\z@
\topsep6\p@ \@plus1\p@\@minus2\p@
\def\makelabel##1{\hss\llap{##1}}}}
\let\endadvise\endlist
\def\advisespace{\hbox{}\qquad}
\def\labeladvise{$\to$}
\newenvironment{syntax}
{\list{}{\itemindent-\leftmargin
\def\makelabel##1{\hss\lst@syntaxlabel##1,,,,\relax}}}
{\endlist}
\def\lst@syntaxlabel#1,#2,#3,#4\relax{%
\llap{\scriptsize\itshape#3}%
\def\lst@temp{#2}%
\expandafter\lst@syntaxlabel@\meaning\lst@temp\relax
\rlap{\hskip-\itemindent\hskip\itemsep\hskip\linewidth
\llap{\ttfamily\lst@temp}\hskip\labelwidth
\def\lst@temp{#1}%
\ifx\lst@temp\lstdoc@currversion#1\fi}}
\def\lst@syntaxlabel@#1>#2\relax
{\edef\lst@temp{\zap@space#2 \@empty}}
\newcommand*\syntaxnewline{\newline\hbox{}\kern\labelwidth}
\newcommand*\syntaxor{\qquad or\qquad}
\newcommand*\syntaxbreak
{\hfill\kern0pt\discretionary{}{\kern\labelwidth}{}}
\let\syntaxfill\hfill
\def\alternative#1{\lst@true \alternative@#1,\relax,}
\def\alternative@#1,{%
\ifx\relax#1\@empty
\expandafter\@gobble
\else
\ifx\@empty#1\@empty\else
\lst@if \lst@false \else $\vert$\fi
\textup{\texttt{#1}}%
\fi
\fi
\alternative@}
\long\def\m@cro@#1#2#3{\endgroup \topsep\MacroTopsep \trivlist
\edef\saved@macroname{\string#3}%
\def\makelabel##1{\llap{##1}}%
\if@inlabel
\let\@tempa\@empty \count@\macro@cnt
\loop \ifnum\count@>\z@
\edef\@tempa{\@tempa\hbox{\strut}}\advance\count@\m@ne \repeat
\edef\makelabel##1{\llap{\vtop to\baselineskip
{\@tempa\hbox{##1}\vss}}}%
\advance \macro@cnt \@ne
\else \macro@cnt\@ne \fi
\edef\@tempa{\noexpand\item[%
#1%
\noexpand\PrintMacroName
\else
\expandafter\noexpand\csname Print#2Name\endcsname % MODIFIED
\fi
{\string#3}]}%
\@tempa
\global\advance\c@CodelineNo\@ne
#1%
\SpecialMainIndex{#3}\nobreak
\DoNotIndex{#3}%
\else
\csname SpecialMain#2Index\endcsname{#3}\nobreak % MODIFIED
\fi
\global\advance\c@CodelineNo\m@ne
\ignorespaces}
\def\macro{\begingroup
\catcode`\\12
\MakePrivateLetters \m@cro@ \iftrue {Macro}}% MODIFIED
\def\environment{\begingroup
\catcode`\\12
\MakePrivateLetters \m@cro@ \iffalse {Env}}% MODIFIED
\def\newdocenvironment#1#2#3#4{%
\@namedef{#1}{#3\begingroup \catcode`\\12\relax
\MakePrivateLetters \m@cro@ \iffalse {#2}}%
\@namedef{end#1}{#4\endmacro}%
\@ifundefined{Print#2Name}{\expandafter
\let\csname Print#2Name\endcsname\PrintMacroName}{}%
\@ifundefined{SpecialMain#2Index}{\expandafter
\let\csname SpecialMain#2Index\endcsname\SpecialMainIndex}{}}
\newdocenvironment{aspect}{Aspect}{}{}
\def\PrintAspectName#1{}
\def\SpecialMainAspectIndex#1{%
\@bsphack
\index{aspects:\levelchar\protect\aspectname{#1}\encapchar main}%
\@esphack}
\newdocenvironment{lstkey}{Key}{}{}
\def\PrintKeyName#1{\strut\keyname{#1}\ }
\def\SpecialMainKeyIndex#1{%
\@bsphack
\index{keys\levelchar\protect\keyname{#1}\encapchar main}%
\@esphack}
\newcounter{argcount}
\def\labelargcount{\texttt{\#\arabic{argcount}}\hskip\labelsep$=$}
\def\macroargs{\list\labelargcount
{\usecounter{argcount}\leftmargin=2\leftmargin
\parsep \z@ \@plus\z@ \@minus\z@
\topsep4\p@ \@plus\p@ \@minus2\p@
\itemsep\z@ \@plus\z@ \@minus\z@
\def\makelabel##1{\hss\llap{##1}}}}
\def\endmacroargs{\endlist\@endparenv}
\lst@RequireAspects{writefile}
\newbox\lst@samplebox
\lstnewenvironment{lstsample}[3][]
{\global\let\lst@intname\@empty
\gdef\lst@sample{#2}%
\setbox\lst@samplebox=\hbox\bgroup
\setkeys{lst}{language={},style={},tabsize=4,gobble=5,%
basicstyle=\small\ttfamily,basewidth=0.51em,point={#1}}
#3%
\lst@BeginAlsoWriteFile{\jobname.tmp}}
{\lst@EndWriteFile\egroup
\ifdim \wd\lst@samplebox>.5\linewidth
\begin{center}%
\hbox to\linewidth{\box\lst@samplebox\hss}%
\end{center}%
\lst@sampleInput
\else
\begin{center}%
\begin{minipage}{0.45\linewidth}\lst@sampleInput\end{minipage}%
\qquad
\begin{minipage}{0.45\linewidth}%
\hbox to\linewidth{\box\lst@samplebox\hss}%
\end{minipage}%
\end{center}%
\fi}
\lst@InstallKeywords{p}{point}{pointstyle}\relax{keywordstyle}{}ld
\lstnewenvironment{lstxsample}[1][]
{\begingroup
\setkeys{lst}{belowskip=-\medskipamount,language={},style={},%
tabsize=4,gobble=5,basicstyle=\small\ttfamily,%
basewidth=0.51em,point={#1}}
\lst@BeginAlsoWriteFile{\jobname.tmp}}
{\endgroup
\endgroup}
\def\lst@sampleInput{%
\MakePercentComment\catcode`\^^M=10\relax
\small\lst@sample
{\setkeys{lst}{SelectCharTable=\lst@ReplaceInput{\^\^I}%
{\lst@ProcessTabulator}}%
\leavevmode \input{\jobname.tmp}}\MakePercentIgnore}
\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
{1.25ex \@plus1ex \@minus.2ex}%
{-1em}%
{\normalfont\normalsize\bfseries}}
\def\lstref#1{\emph{\ref{#1} \nameref{#1}}}
\def\@part[#1]#2{\addcontentsline{toc}{part}{#1}%
{\parindent\z@ \raggedright \interlinepenalty\@M
\normalfont \huge \bfseries #2\markboth{}{}\par}%
\nobreak\vskip 3ex\@afterheading}
\renewcommand*\l@section[2]{%
\addpenalty\@secpenalty
\addvspace{.25em \@plus\p@}%
\setlength\@tempdima{1.5em}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode
\advance\leftskip\@tempdima
\hskip -\leftskip
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
\endgroup}
\renewcommand*\l@subsection{\@dottedtocline{2}{0pt}{2.3em}}
\renewcommand*\l@subsubsection{\@dottedtocline{3}{0pt}{3.2em}}
\newcommand\ikeyname[1]{%
\lstkeyindex{#1}{}%
\lstaspectindex{#1}{}%
\keyname{#1}}
\newcommand\ekeyname[1]{%
\@bsphack
\lstkeyindex{#1}{\encapchar usage}%
\lstaspectindex{#1}{\encapchar usage}%
\@esphack}
\newcommand\rkeyname[1]{%
\@bsphack
\lstkeyindex{#1}{\encapchar main}%
\lstaspectindex{#1}{\encapchar main}%
\@esphack{\rstyle\keyname{#1}}}
\newcommand\icmdname[1]{%
\@bsphack
\lstaspectindex{#1}{}%
\@esphack\texttt{\string#1}}
\newcommand\rcmdname[1]{%
\@bsphack
\lstaspectindex{#1}{\encapchar main}%
\@esphack\texttt{\rstyle\string#1}}
\def\lstaspectindex#1#2{%
\global\@namedef{lstkandc@\string#1}{}%
\@ifundefined{lstisaspect@\string#1}
{\index{unknown\levelchar
\protect\texttt{\protect\string\string#1}#2}}%
{\index{\@nameuse{lstisaspect@\string#1}\levelchar
\protect\texttt{\protect\string\string#1}#2}}%
}
\def\lstkeyindex#1#2{%
}
\def\lstisaspect[#1]#2{%
\global\@namedef{lstaspect@#1}{#2}%
\lst@AddTo\lst@allkeysandcmds{,#2}%
\@for\lst@temp:=#2\do
{\ifx\@empty\lst@temp\else
\global\@namedef{lstisaspect@\lst@temp}{#1}%
\fi}}
\gdef\lst@allkeysandcmds{}
\def\lstprintaspectkeysandcmds#1{%
\lst@true
\expandafter\@for\expandafter\lst@temp
\expandafter:\expandafter=\csname lstaspect@#1\endcsname\do
{\lst@if\lst@false\else, \fi \texttt{\lst@temp}}}
\def\lstcheckreference{%
\@for\lst@temp:=\lst@allkeysandcmds\do
{\ifx\lst@temp\@empty\else
\@ifundefined{lstkandc@\lst@temp}
{\typeout{\lst@temp\space not in reference guide?}}{}%
\fi}}
\newcommand*\lst{\texttt{lst}}
\newcommand*\Cpp{C\texttt{++}}
\let\keyname\texttt
\let\keyvalue\texttt
\let\hookname\texttt
\newcommand*\aspectname[1]{{\normalfont\sffamily#1}}
\DeclareRobustCommand\packagename[1]{%
{\leavevmode\text@command{#1}%
\switchfontfamily\sfdefault\rmdefault
\check@icl #1\check@icr
\expandafter}}%
\def\switchfontfamily#1#2{%
\begingroup\xdef\@gtempa{#1}\endgroup
\ifx\f@family\@gtempa\fontfamily#2%
\else\fontfamily#1\fi
\selectfont}
\ifcolor
\definecolor{darkgreen}{rgb}{0,0.6,0}
\def\rstyle{\color{darkgreen}}
\else
\let\rstyle\empty
\fi
\gdef\lst@emails{}
\newcommand*\lstthanks[2]
{#1\lst@AddTo\lst@emails{,#1,<#2>}%
\ifx\@empty#2\@empty\typeout{Missing email for #1}\fi}
\newcommand*\lsthelper[3]
{{\let~\ #1}%
\lst@IfOneOf#1\relax\lst@emails
{}{\typeout{^^JWarning: Unknown helper #1.^^J}}}
\lstdefinelanguage[doc]{Pascal}{%
morekeywords={alfa,and,array,begin,boolean,byte,case,char,const,div,%
do,downto,else,end,false,file,for,function,get,goto,if,in,%
integer,label,maxint,mod,new,not,of,or,pack,packed,page,program,%
procedure,put,read,readln,real,record,repeat,reset,rewrite,set,%
text,then,to,true,type,unpack,until,var,while,with,write,writeln},%
sensitive=false,%
morecomment=[s]{(*}{*)},%
morecomment=[s]{\{}{\}},%
morestring=[d]{'}}
\lstdefinestyle{}
{basicstyle={},%
keywordstyle=\bfseries,identifierstyle={},%
commentstyle=\itshape,stringstyle={},%
numberstyle={},stepnumber=1,%
pointstyle=\pointstyle}
\def\pointstyle{%
{\let\lst@um\@empty \xdef\@gtempa{\the\lst@token}}%
\expandafter\lstkeyindex\expandafter{\@gtempa}{}%
\expandafter\lstaspectindex\expandafter{\@gtempa}{}%
\rstyle}
\lstset{defaultdialect=[doc]Pascal,language=Pascal,style={}}
\def\lstscanlanguages#1#2#3{%
\begingroup
\def\lst@DefDriver@##1##2##3##4[##5]##6{%
\lst@false
\lst@lAddTo\lst@scan{##6(##5),}%
\begingroup
\@ifnextchar[{\lst@XDefDriver{##1}##3}{\lst@DefDriver@@##3}}%
\def\lst@XXDefDriver[##1]{}%
\lst@InputCatcodes
\def\lst@dontinput{#3}%
\let\lst@scan\@empty
\lst@for{#2}\do{%
\lst@IfOneOf##1\relax\lst@dontinput
{}%
{\InputIfFileExists{##1}{}{}}}%
\global\let\@gtempa\lst@scan
\endgroup
\let#1\@gtempa}
\def\lstprintlanguages#1{%
\def\do##1{\setbox\@tempboxa\hbox{##1\space\space}%
\ifdim\wd\@tempboxa<.5\linewidth \wd\@tempboxa.5\linewidth
\else \wd\@tempboxa\linewidth \fi
\box\@tempboxa\allowbreak}%
\begin{quote}
\par\noindent
\hyphenpenalty=\@M \rightskip=\z@\@plus\linewidth\relax
\lst@BubbleSort#1%
\expandafter\lst@NextLanguage#1\relax(\relax),%
\end{quote}}
\def\lst@NextLanguage#1(#2),{%
\ifx\relax#1\else
\def\lst@language{#1}\def\lst@dialects{(#2),}%
\expandafter\lst@NextLanguage@
\fi}
\def\lst@NextLanguage@#1(#2),{%
\def\lst@temp{#1}%
\ifx\lst@temp\lst@language
\lst@lAddTo\lst@dialects{(#2),}%
\expandafter\lst@NextLanguage@
\else
\do{\lst@language
\ifx\lst@dialects\lst@emptydialect\else
\expandafter\lst@NormedDef\expandafter\lst@language
\expandafter{\lst@language}%
\space(%
\lst@BubbleSort\lst@dialects
\expandafter\lst@PrintDialects\lst@dialects(\relax),%
)%
\fi}%
\def\lst@next{\lst@NextLanguage#1(#2),}%
\expandafter\lst@next
\fi}
\def\lst@emptydialect{(),}
\def\lst@PrintDialects(#1),{%
\ifx\@empty#1\@empty empty\else
\lst@PrintDialect{#1}%
\fi
\lst@PrintDialects@}
\def\lst@PrintDialects@(#1),{%
\ifx\relax#1\else
, \lst@PrintDialect{#1}%
\expandafter\lst@PrintDialects@
\fi}
\def\lst@PrintDialect#1{%
\lst@NormedDef\lst@temp{#1}%
\expandafter\ifx\csname\@lst dd@\lst@language\endcsname\lst@temp
\texttt{\underbar{#1}}%
\else
\texttt{#1}%
\fi}
\def\lst@IfLE#1#2\@empty#3#4\@empty{%
\ifx #1\relax
\let\lst@next\@firstoftwo
\else \ifx #3\relax
\let\lst@next\@secondoftwo
\else
\lowercase{\ifx#1#3}%
\def\lst@next{\lst@IfLE#2\@empty#4\@empty}%
\else
\lowercase{\ifnum`#1<`#3}\relax
\let\lst@next\@firstoftwo
\else
\let\lst@next\@secondoftwo
\fi
\fi
\fi \fi
\lst@next}
\def\lst@BubbleSort#1{%
\ifx\@empty#1\else
\lst@false
\expandafter\lst@BubbleSort@#1\relax,\relax,%
\expandafter\lst@BubbleSort@\expandafter,\lst@sorted
\relax,\relax,%
\let#1\lst@sorted
\lst@if
\def\lst@next{\lst@BubbleSort#1}%
\expandafter\expandafter\expandafter\lst@next
\fi
\fi}
\def\lst@BubbleSort@#1,#2,{%
\ifx\@empty#1\@empty
\def\lst@sorted{#2,}%
\def\lst@next{\lst@BubbleSort@@}%
\else
\let\lst@sorted\@empty
\def\lst@next{\lst@BubbleSort@@#1,#2,}%
\fi
\lst@next}
\def\lst@BubbleSort@@#1,#2,{%
\ifx\relax#1\else
\ifx\relax#2%
\lst@lAddTo\lst@sorted{#1,}%
\expandafter\expandafter\expandafter\lst@BubbleSort@@@
\else
\lst@IfLE #1\relax\@empty #2\relax\@empty
{\lst@lAddTo\lst@sorted{#1,#2,}}%
{\lst@true \lst@lAddTo\lst@sorted{#2,#1,}}%
\expandafter\expandafter\expandafter\lst@BubbleSort@@
\fi
\fi}
\def\lst@BubbleSort@@@#1\relax,{}
\endinput
%%
%% End of file `lstdoc.sty'.

@ -1,882 +0,0 @@
%%
%% This is file `lstlang1.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% lstdrvrs.dtx (with options: `lang1')
%%
%% (w)(c) 1996/1997/1998/1999/2000/2001/2002 Carsten Heinz and/or any
%% other author listed elsewhere in this file.
%%
%% This file is distributed under the terms of the LaTeX Project Public
%% License from CTAN archives in directory macros/latex/base/lppl.txt.
%% Either version 1.0 or, at your option, any later version.
%%
%% This file is completely free and comes without any warranty.
%%
%% Send comments and ideas on the package, error reports and additional
%% programming languages to <cheinz@gmx.de>.
%%
\ProvidesFile{lstlang1}
[2002/07/31 v1.0d listings language file]
%%
%% ACSL definition (c) 2000 by Andreas Matthias <amat@kabsi.at>
%%
\lst@definelanguage{ACSL}[90]{Fortran}%
{morekeywords={algorithm,cinterval,constant,derivative,discrete,%
dynamic,errtag,initial,interval,maxterval,minterval,%
merror,xerror,nsteps,procedural,save,schedule,sort,%
table,terminal,termt,variable},%
sensitive=false,%
morecomment=[l]!%
}[keywords, comments]%
%%
%% Ada 95 definition (c) Torsten Neuer <tneuer@inwise.de>
%%
\lst@definelanguage[95]{Ada}[83]{Ada}%
{morekeywords={abstract,aliased,protected,requeue,tagged,until}}%
\lst@definelanguage[83]{Ada}%
{morekeywords={abort,abs,accept,access,all,and,array,at,begin,body,%
case,constant,declare,delay,delta,digits,do,else,elsif,end,entry,%
exception,exit,for,function,generic,goto,if,in,is,limited,loop,%
mod,new,not,null,of,or,others,out,package,pragma,private,%
procedure,raise,range,record,rem,renames,return,reverse,select,%
separate,subtype,task,terminate,then,type,use,when,while,with,%
xor},%
sensitive=f,%
morecomment=[l]--,%
morestring=[m]",% percent not defined as stringizer so far
morestring=[m]'%
}[keywords,comments,strings]%
%%
%% Visual Basic definition (c) 2002 Robert Frank <rf7@ukc.ac.uk>
%%
\lst@definelanguage[Visual]{Basic}
{morekeywords={Abs,Array,Asc,AscB,AscW,Atn,Avg,CBool,CByte,CCur,%
CDate,CDbl,Cdec,Choose,Chr,ChrB,ChrW,CInt,CLng,Command,Cos,%
Count,CreateObject,CSng,CStr,CurDir,CVar,CVDate,CVErr,Date,%
DateAdd,DateDiff,DatePart,DateSerial,DateValue,Day,DDB,Dir,%
DoEvents,Environ,EOF,Error,Exp,FileAttr,FileDateTime,FileLen,%
Fix,Format,FreeFile,FV,GetAllStrings,GetAttr,%
GetAutoServerSettings,GetObject,GetSetting,Hex,Hour,IIf,%
IMEStatus,Input,InputB,InputBox,InStr,InstB,Int,Integer,IPmt,%
IsArray,IsDate,IsEmpty,IsError,IsMissing,IsNull,IsNumeric,%
IsObject,LBound,LCase,Left,LeftB,Len,LenB,LoadPicture,Loc,LOF,%
Log,Ltrim,Max,Mid,MidB,Min,Minute,MIRR,Month,MsgBox,Now,NPer,%
NPV,Oct,Partition,Pmt,PPmt,PV,QBColor,Rate,RGB,Right,RightB,Rnd,%
Rtrim,Second,Seek,Sgn,Shell,Sin,SLN,Space,Spc,Sqr,StDev,StDevP,%
Str,StrComp,StrConv,String,Switch,Sum,SYD,Tab,Tan,Time,Timer,%
TimeSerial,TimeValue,Trim,TypeName,UBound,Ucase,Val,Var,VarP,%
VarType,Weekday,Year},% functions
morekeywords=[2]{Accept,Activate,Add,AddCustom,AddFile,AddFromFile,%
AddFromTemplate,AddItem,AddNew,AddToAddInToolbar,%
AddToolboxProgID,Append,AppendChunk,Arrange,Assert,AsyncRead,%
BatchUpdate,BeginTrans,Bind,Cancel,CancelAsyncRead,CancelBatch,%
CancelUpdate,CanPropertyChange,CaptureImage,CellText,CellValue,%
Circle,Clear,ClearFields,ClearSel,ClearSelCols,Clone,Close,Cls,%
ColContaining,ColumnSize,CommitTrans,CompactDatabase,Compose,%
Connect,Copy,CopyQueryDef,CreateDatabase,CreateDragImage,%
CreateEmbed,CreateField,CreateGroup,CreateIndex,CreateLink,%
CreatePreparedStatement,CreatePropery,CreateQuery,%
CreateQueryDef,CreateRelation,CreateTableDef,CreateUser,%
CreateWorkspace,Customize,Delete,DeleteColumnLabels,%
DeleteColumns,DeleteRowLabels,DeleteRows,DoVerb,Drag,Draw,Edit,%
EditCopy,EditPaste,EndDoc,EnsureVisible,EstablishConnection,%
Execute,ExtractIcon,Fetch,FetchVerbs,Files,FillCache,Find,%
FindFirst,FindItem,FindLast,FindNext,FindPrevious,Forward,%
GetBookmark,GetChunk,GetClipString,GetData,GetFirstVisible,%
GetFormat,GetHeader,GetLineFromChar,GetNumTicks,GetRows,%
GetSelectedPart,GetText,GetVisibleCount,GoBack,GoForward,Hide,%
HitTest,HoldFields,Idle,InitializeLabels,InsertColumnLabels,%
InsertColumns,InsertObjDlg,InsertRowLabels,InsertRows,Item,%
KillDoc,Layout,Line,LinkExecute,LinkPoke,LinkRequest,LinkSend,%
Listen,LoadFile,LoadResData,LoadResPicture,LoadResString,%
LogEvent,MakeCompileFile,MakeReplica,MoreResults,Move,MoveData,%
MoveFirst,MoveLast,MoveNext,MovePrevious,NavigateTo,NewPage,%
NewPassword,NextRecordset,OLEDrag,OnAddinsUpdate,OnConnection,%
OnDisconnection,OnStartupComplete,Open,OpenConnection,%
OpenDatabase,OpenQueryDef,OpenRecordset,OpenResultset,OpenURL,%
Overlay,PaintPicture,Paste,PastSpecialDlg,PeekData,Play,Point,%
PopulatePartial,PopupMenu,Print,PrintForm,PropertyChanged,Pset,%
Quit,Raise,RandomDataFill,RandomFillColumns,RandomFillRows,%
rdoCreateEnvironment,rdoRegisterDataSource,ReadFromFile,%
ReadProperty,Rebind,ReFill,Refresh,RefreshLink,RegisterDatabase,%
Reload,Remove,RemoveAddInFromToolbar,RemoveItem,Render,%
RepairDatabase,Reply,ReplyAll,Requery,ResetCustom,%
ResetCustomLabel,ResolveName,RestoreToolbar,Resync,Rollback,%
RollbackTrans,RowBookmark,RowContaining,RowTop,Save,SaveAs,%
SaveFile,SaveToFile,SaveToolbar,SaveToOle1File,Scale,ScaleX,%
ScaleY,Scroll,Select,SelectAll,SelectPart,SelPrint,Send,%
SendData,Set,SetAutoServerSettings,SetData,SetFocus,SetOption,%
SetSize,SetText,SetViewport,Show,ShowColor,ShowFont,ShowHelp,%
ShowOpen,ShowPrinter,ShowSave,ShowWhatsThis,SignOff,SignOn,Size,%
Span,SplitContaining,StartLabelEdit,StartLogging,Stop,%
Synchronize,TextHeight,TextWidth,ToDefaults,TwipsToChartPart,%
TypeByChartType,Update,UpdateControls,UpdateRecord,UpdateRow,%
Upto,WhatsThisMode,WriteProperty,ZOrder},% methods
morekeywords=[3]{AccessKeyPress,AfterAddFile,AfterChangeFileName,%
AfterCloseFile,AfterColEdit,AfterColUpdate,AfterDelete,%
AfterInsert,AfterLabelEdit,AfterRemoveFile,AfterUpdate,%
AfterWriteFile,AmbienChanged,ApplyChanges,Associate,%
AsyncReadComplete,AxisActivated,AxisLabelActivated,%
AxisLabelSelected,AxisLabelUpdated,AxisSelected,%
AxisTitleActivated,AxisTitleSelected,AxisTitleUpdated,%
AxisUpdated,BeforeClick,BeforeColEdit,BeforeColUpdate,%
BeforeConnect,BeforeDelete,BeforeInsert,BeforeLabelEdit,%
BeforeLoadFile,BeforeUpdate,ButtonClick,ButtonCompleted,%
ButtonGotFocus,ButtonLostFocus,Change,ChartActivated,%
ChartSelected,ChartUpdated,Click,ColEdit,Collapse,ColResize,%
ColumnClick,Compare,ConfigChageCancelled,ConfigChanged,%
ConnectionRequest,DataArrival,DataChanged,DataUpdated,DblClick,%
Deactivate,DeviceArrival,DeviceOtherEvent,DeviceQueryRemove,%
DeviceQueryRemoveFailed,DeviceRemoveComplete,DeviceRemovePending,%
DevModeChange,Disconnect,DisplayChanged,Dissociate,%
DoGetNewFileName,Done,DonePainting,DownClick,DragDrop,DragOver,%
DropDown,EditProperty,EnterCell,EnterFocus,Event,ExitFocus,%
Expand,FootnoteActivated,FootnoteSelected,FootnoteUpdated,%
GotFocus,HeadClick,InfoMessage,Initialize,IniProperties,%
ItemActivated,ItemAdded,ItemCheck,ItemClick,ItemReloaded,%
ItemRemoved,ItemRenamed,ItemSeletected,KeyDown,KeyPress,KeyUp,%
LeaveCell,LegendActivated,LegendSelected,LegendUpdated,%
LinkClose,LinkError,LinkNotify,LinkOpen,Load,LostFocus,%
MouseDown,MouseMove,MouseUp,NodeClick,ObjectMove,%
OLECompleteDrag,OLEDragDrop,OLEDragOver,OLEGiveFeedback,%
OLESetData,OLEStartDrag,OnAddNew,OnComm,Paint,PanelClick,%
PanelDblClick,PathChange,PatternChange,PlotActivated,%
PlotSelected,PlotUpdated,PointActivated,PointLabelActivated,%
PointLabelSelected,PointLabelUpdated,PointSelected,%
PointUpdated,PowerQuerySuspend,PowerResume,PowerStatusChanged,%
PowerSuspend,QueryChangeConfig,QueryComplete,QueryCompleted,%
QueryTimeout,QueryUnload,ReadProperties,Reposition,%
RequestChangeFileName,RequestWriteFile,Resize,ResultsChanged,%
RowColChange,RowCurrencyChange,RowResize,RowStatusChanged,%
SelChange,SelectionChanged,SendComplete,SendProgress,%
SeriesActivated,SeriesSelected,SeriesUpdated,SettingChanged,%
SplitChange,StateChanged,StatusUpdate,SysColorsChanged,%
Terminate,TimeChanged,TitleActivated,TitleSelected,%
TitleActivated,UnboundAddData,UnboundDeleteRow,%
UnboundGetRelativeBookmark,UnboundReadData,UnboundWriteData,%
Unload,UpClick,Updated,Validate,ValidationError,WillAssociate,%
WillChangeData,WillDissociate,WillExecute,WillUpdateRows,%
WithEvents,WriteProperties},% VB-events
morekeywords=[4]{AppActivate,Base,Beep,Call,Case,ChDir,ChDrive,%
Const,Declare,DefBool,DefByte,DefCur,DefDate,DefDbl,DefDec,%
DefInt,DefLng,DefObj,DefSng,DefStr,Deftype,DefVar,DeleteSetting,%
Dim,Do,Else,ElseIf,End,Enum,Erase,Event,Exit,Explicit,FileCopy,%
For,ForEach,Friend,Function,Get,GoSub,GoTo,If,Implements,Kill,%
Let,LineInput,Lock,Lset,MkDir,Name,Next,OnError,On,Option,%
Private,Property,Public,Put,RaiseEvent,Randomize,ReDim,Rem,%
Reset,Resume,Return,RmDir,Rset,SavePicture,SaveSetting,%
SendKeys,SetAttr,Static,Sub,Then,Type,Unlock,Wend,While,Width,%
With,Write},% statements
sensitive=false,
keywordcomment=rem,%
MoreSelectCharTable=\def\lst@BeginKC@{% chmod
\lst@ResetToken
\lst@BeginComment\lst@GPmode{{\lst@commentstyle}%
\lst@Lmodetrue\lst@modetrue}\@empty}%
morecomment=[l]{'},
morecomment=[s]{/*}{*/},
morestring=[b]",
}[keywords,comments,strings,keywordcomments]
\lst@definelanguage[ANSI]{C++}[ISO]{C++}{}%
\lst@definelanguage[GNU]{C++}[ISO]{C++}%
{morekeywords={__attribute__,__extension__,__restrict,__restrict__,%
typeof,__typeof__},%
}%
\lst@definelanguage[Visual]{C++}[ISO]{C++}%
{morekeywords={__asm,__based,__cdecl,__declspec,dllexport,%
dllimport,__except,__fastcall,__finally,__inline,__int8,__int16,%
__int32,__int64,naked,__stdcall,thread,__try,__leave},%
}%
\lst@definelanguage[ISO]{C++}[ANSI]{C}%
{morekeywords={and,and_eq,asm,bad_cast,bad_typeid,bitand,bitor,bool,%
catch,class,compl,const_cast,delete,dynamic_cast,explicit,export,%
false,friend,inline,mutable,namespace,new,not,not_eq,operator,or,%
or_eq,private,protected,public,reinterpret_cast,static_cast,%
template,this,throw,true,try,typeid,type_info,typename,using,%
virtual,wchar_t,xor,xor_eq},%
}%
%%
%% Objective-C definition (c) 1997 Detlev Droege
%% <droege@informatik.uni-koblenz.de>
%%
\lst@definelanguage[Objective]{C}[ANSI]{C}
{morekeywords={bycopy,id,in,inout,oneway,out,self,super,%
@class,@defs,@encode,@end,@implementation,@interface,@private,%
@protected,@protocol,@public,@selector},%
moredirectives={import}%
}%
\lst@definelanguage[ANSI]{C}%
{morekeywords={auto,break,case,char,const,continue,default,do,double,%
else,enum,extern,float,for,goto,if,int,long,register,return,%
short,signed,sizeof,static,struct,switch,typedef,union,unsigned,%
void,volatile,while},%
sensitive,%
morecomment=[s]{/*}{*/},%
morecomment=[l]//,% nonstandard
morestring=[b]",%
morestring=[b]',%
moredirectives={define,elif,else,endif,error,if,ifdef,ifndef,line,%
include,pragma,undef,warning}%
}[keywords,comments,strings,directives]%
%%
%% C-Sharp definition (c) 2002 Martin Brodbeck <Martin.Brodbeck@gmx.de>
%%
\lst@definelanguage[Sharp]{C}%
{morekeywords={abstract,base,bool,break,byte,case,catch,char,checked,%
class,const,continue,decimal,default,delegate,do,double,else,%
enum,event,explicit,extern,false,finally,fixed,float,for,foreach,%
goto,if,implicit,in,int,interface,internal,is,lock,long,%
namespace,new,null,object,operator,out,override,params,private,%
protected,public,readonly,ref,return,sbyte,sealed,short,sizeof,%
static,string,struct,switch,this,throw,true,try,typeof,uint,%
ulong,unchecked,unsafe,ushort,using,virtual,void,while},%
sensitive,%
morecomment=[s]{/*}{*/},%
morecomment=[l]//,%
morestring=[b]"
}[keywords,comments,strings]%
%%
%% csh definition (c) 1998 Kai Below <below@tu-harburg.de>
%%
\lst@definelanguage{csh}
{morekeywords={alias,awk,cat,echo,else,end,endif,endsw,exec,exit,%
foreach,glob,goto,history,if,logout,nice,nohup,onintr,repeat,sed,%
set,setenv,shift,source,switch,then,time,while,umask,unalias,%
unset,wait,while,@,env,argv,child,home,ignoreeof,noclobber,%
noglob,nomatch,path,prompt,shell,status,verbose,print,printf,%
sqrt,BEGIN,END},%
morecomment=[l]\#,%
morestring=[d]"%
}[keywords,comments,strings]%
\lst@definelanguage[90]{Fortran}[95]{Fortran}{}
\lst@definelanguage[95]{Fortran}[77]{Fortran}%
{deletekeywords=SAVE,%
morekeywords={ACTION,ADVANCE,ALLOCATE,ALLOCATABLE,ASSIGNMENT,CASE,%
CONTAINS,CYCLE,DEALLOCATE,DEFAULT,DELIM,EXIT,INCLUDE,IN,NONE,IN,%
OUT,INTENT,INTERFACE,IOLENGTH,KIND,LEN,MODULE,NAME,NAMELIST,NMT,%
NULLIFY,ONLY,OPERATOR,OPTIONAL,OUT,PAD,POINTER,POSITION,PRIVATE,%
PUBLIC,READWRITE,RECURSIVE,RESULT,SELECT,SEQUENCE,SIZE,STAT,%
TARGET,USE,WHERE,WHILE,BLOCKDATA,DOUBLEPRECISION,ELSEIF,%
ENDBLOCKDATA,ENDDO,ENDFILE,ENDFUNCTION,ENDIF,ENDINTERFACE,%
ENDMODULE,ENDPROGRAM,ENDSELECT,ENDSUBROUTINE,ENDTYPE,ENDWHERE,%
GOTO,INOUT,SELECTCASE},%
deletecomment=[f],% no fixed comment line: 1998 Magne Rudshaug
morecomment=[l]!%
}%
\lst@definelanguage[77]{Fortran}%
{morekeywords={ACCESS,ASSIGN,BACKSPACE,BLANK,BLOCK,CALL,CHARACTER,%
CLOSE,COMMON,COMPLEX,CONTINUE,DATA,DIMENSION,DIRECT,DO,DOUBLE,%
ELSE,END,ENTRY,EOF,EQUIVALENCE,ERR,EXIST,EXTERNAL,FILE,FMT,FORM,%
FORMAT,FORMATTED,FUNCTION,GO,TO,IF,IMPLICIT,INQUIRE,INTEGER,%
INTRINSIC,IOSTAT,LOGICAL,NAMED,NEXTREC,NUMBER,OPEN,OPENED,%
PARAMETER,PAUSE,PRECISION,PRINT,PROGRAM,READ,REAL,REC,RECL,%
RETURN,REWIND,SEQUENTIAL,STATUS,STOP,SUBROUTINE,THEN,TYPE,%
UNFORMATTED,UNIT,WRITE,SAVE},%
sensitive=f,%% not Fortran standard %%
morecomment=[f]*,%
morecomment=[f]C,%
morecomment=[f]c,%
morestring=[d]"%
}[keywords,comments,strings]%
\lst@definelanguage{HTML}%
{morekeywords={A,ADDRESS,APPLET,B,BASE,BASEFONT,BIG,BLOCKQUOTE,BODY,%
BR,CENTER,CITE,CODE,DFN,DIR,DIV,DOCTYPE,EM,FONT,FORM,HEAD,HR,%
H1,H2,H3,H4,H5,H6,HTML,I,IMG,INPUT,ISINDEX,KBD,LI,LINK,LISTING,%
MAP,META,MENU,P,PLAINTEXT,PRE,OL,SAMP,SCRIPT,SELECT,SMALL,STRIKE,%
STRING,SUB,SUP,STYLE,TABLE,TEXTAREA,TITLE,TT,U,UL,VAR,XMP,%
action,align,alink,alt,background,bgcolor,border,cellpadding,%
cellspacing,checked,code,codebase,color,cols,colspan,entype,%
height,href,hspace,ismap,link,maxlength,method,multiple,name,%
noshade,nowrap,rel,rev,rows,rowspan,selected,shape,size,src,text,%
title,type,usemap,valign,value,vlink,vspace,width},%
keywordsinside=<>,
sensitive=f,%
morestring=[d]",% ??? doubled
MoreSelectCharTable=%
\lst@CArgX--\relax\lst@DefDelimB{}{}%
{\ifnum\lst@mode=\lst@insidemode\else
\expandafter\@gobblethree
\fi}%
\lst@BeginComment\lst@commentmode{{\lst@commentstyle}}%
\lst@CArgX--\relax\lst@DefDelimE{}{}{}%
\lst@EndComment\lst@commentmode
}[keywords,comments,strings,html]%
\lst@definelanguage{Java}%
{morekeywords={abstract,boolean,break,byte,case,catch,char,class,%
const,continue,default,do,double,else,extends,false,final,%
finally,float,for,goto,if,implements,import,instanceof,int,%
interface,label,long,native,new,null,package,private,protected,%
public,return,short,static,super,switch,synchronized,this,throw,%
throws,transient,true,try,void,volatile,while},%
sensitive,%
morecomment=[l]//,%
morecomment=[s]{/*}{*/},%
morestring=[b]",%
morestring=[b]',%
}[keywords,comments,strings]%
\lst@definelanguage{Matlab}%
{morekeywords={gt,lt,gt,lt,amp,abs,acos,acosh,acot,acoth,acsc,acsch,%
all,angle,ans,any,asec,asech,asin,asinh,atan,atan2,atanh,auread,%
auwrite,axes,axis,balance,bar,bessel,besselk,bessely,beta,%
betainc,betaln,blanks,bone,break,brighten,capture,cart2pol,%
cart2sph,caxis,cd,cdf2rdf,cedit,ceil,chol,cla,clabel,clc,clear,%
clf,clock,close,colmmd,Colon,colorbar,colormap,ColorSpec,colperm,%
comet,comet3,compan,compass,computer,cond,condest,conj,contour,%
contour3,contourc,contrast,conv,conv2,cool,copper,corrcoef,cos,%
cosh,cot,coth,cov,cplxpair,cputime,cross,csc,csch,csvread,%
csvwrite,cumprod,cumsum,cylinder,date,dbclear,dbcont,dbdown,%
dbquit,dbstack,dbstatus,dbstep,dbstop,dbtype,dbup,ddeadv,ddeexec,%
ddeinit,ddepoke,ddereq,ddeterm,ddeunadv,deblank,dec2hex,deconv,%
del2,delete,demo,det,diag,diary,diff,diffuse,dir,disp,dlmread,%
dlmwrite,dmperm,dot,drawnow,echo,eig,ellipj,ellipke,else,elseif,%
end,engClose,engEvalString,engGetFull,engGetMatrix,engOpen,%
engOutputBuffer,engPutFull,engPutMatrix,engSetEvalCallback,%
engSetEvalTimeout,engWinInit,eps,erf,erfc,erfcx,erfinv,error,%
errorbar,etime,etree,eval,exist,exp,expint,expm,expo,eye,fclose,%
feather,feof,ferror,feval,fft,fft2,fftshift,fgetl,fgets,figure,%
fill,fill3,filter,filter2,find,findstr,finite,fix,flag,fliplr,%
flipud,floor,flops,fmin,fmins,fopen,for,format,fplot,fprintf,%
fread,frewind,fscanf,fseek,ftell,full,function,funm,fwrite,fzero,%
gallery,gamma,gammainc,gammaln,gca,gcd,gcf,gco,get,getenv,%
getframe,ginput,global,gplot,gradient,gray,graymon,grid,griddata,%
gtext,hadamard,hankel,help,hess,hex2dec,hex2num,hidden,hilb,hist,%
hold,home,hostid,hot,hsv,hsv2rgb,if,ifft,ifft2,imag,image,%
imagesc,Inf,info,input,int2str,interp1,interp2,interpft,inv,%
invhilb,isempty,isglobal,ishold,isieee,isinf,isletter,isnan,%
isreal,isspace,issparse,isstr,jet,keyboard,kron,lasterr,lcm,%
legend,legendre,length,lin2mu,line,linspace,load,log,log10,log2,%
loglog,logm,logspace,lookfor,lower,ls,lscov,lu,magic,matClose,%
matDeleteMatrix,matGetDir,matGetFp,matGetFull,matGetMatrix,%
matGetNextMatrix,matGetString,matlabrc,matlabroot,matOpen,%
matPutFull,matPutMatrix,matPutString,max,mean,median,menu,mesh,%
meshc,meshgrid,meshz,mexAtExit,mexCallMATLAB,mexdebug,%
mexErrMsgTxt,mexEvalString,mexFunction,mexGetFull,mexGetMatrix,%
mexGetMatrixPtr,mexPrintf,mexPutFull,mexPutMatrix,mexSetTrapFlag,%
min,more,movie,moviein,mu2lin,mxCalloc,mxCopyCharacterToPtr,%
mxCopyComplex16ToPtr,mxCopyInteger4ToPtr,mxCopyPtrToCharacter,%
mxCopyPtrToComplex16,mxCopyPtrToInteger4,mxCopyPtrToReal8,%
mxCopyReal8ToPtr,mxCreateFull,mxCreateSparse,mxCreateString,%
mxFree,mxFreeMatrix,mxGetIr,mxGetJc,mxGetM,mxGetN,mxGetName,%
mxGetNzmax,mxGetPi,mxGetPr,mxGetScalar,mxGetString,mxIsComplex,%
mxIsFull,mxIsNumeric,mxIsSparse,mxIsString,mxIsTypeDouble,%
mxSetIr,mxSetJc,mxSetM,mxSetN,mxSetName,mxSetNzmax,mxSetPi,%
mxSetPr,NaN,nargchk,nargin,nargout,newplot,nextpow2,nnls,nnz,%
nonzeros,norm,normest,null,num2str,nzmax,ode23,ode45,orient,orth,%
pack,pascal,patch,path,pause,pcolor,pi,pink,pinv,plot,plot3,%
pol2cart,polar,poly,polyder,polyeig,polyfit,polyval,polyvalm,%
pow2,print,printopt,prism,prod,pwd,qr,qrdelete,qrinsert,quad,%
quad8,quit,quiver,qz,rand,randn,randperm,rank,rat,rats,rbbox,%
rcond,real,realmax,realmin,refresh,rem,reset,reshape,residue,%
return,rgb2hsv,rgbplot,rootobject,roots,rose,rosser,rot90,rotate,%
round,rref,rrefmovie,rsf2csf,save,saxis,schur,sec,sech,semilogx,%
semilogy,set,setstr,shading,sign,sin,sinh,size,slice,sort,sound,%
spalloc,sparse,spaugment,spconvert,spdiags,specular,speye,spfun,%
sph2cart,sphere,spinmap,spline,spones,spparms,sprandn,sprandsym,%
sprank,sprintf,spy,sqrt,sqrtm,sscanf,stairs,startup,std,stem,%
str2mat,str2num,strcmp,strings,strrep,strtok,subplot,subscribe,%
subspace,sum,surf,surface,surfc,surfl,surfnorm,svd,symbfact,%
symmmd,symrcm,tan,tanh,tempdir,tempname,terminal,text,tic,title,%
toc,toeplitz,trace,trapz,tril,triu,type,uicontrol,uigetfile,%
uimenu,uiputfile,unix,unwrap,upper,vander,ver,version,view,%
viewmtx,waitforbuttonpress,waterfall,wavread,wavwrite,what,%
whatsnew,which,while,white,whitebg,who,whos,wilkinson,wk1read,%
wk1write,xlabel,xor,ylabel,zeros,zlabel,zoom},%
sensitive,%
morecomment=[l]\%,%
morestring=[m]'%
}[keywords,comments,strings]%
%%
%% Mathematica definitions (c) 1999 Michael Wiese <wiese@itwm.uni-kl.de>
%%
\lst@definelanguage[3.0]{Mathematica}[1.0]{Mathematica}%
{morekeywords={Abort,AbortProtect,AbsoluteDashing,AbsolutePointSize,%
AbsoluteThickness,AbsoluteTime,AccountingFormAiry,AiPrime,AiryBi,%
AiryBiPrime,Alternatives,AnchoredSearch,AxesEdge,AxesOrigin,%
AxesStyle,Background,BetaRegularized,BoxStyle,C,CheckAbort,%
Circle,ClebschGordan,CMYKColor,ColorFunction,ColorOutput,Compile,%
Compiled,CompiledFunction,ComplexExpand,ComposeList,Composition,%
ConstrainedMax,ConstrainedMin,Contexts,ContextToFilename,%
ContourLines,Contours,ContourShading,ContourSmoothing,%
ContourStyle,CopyDirectory,CopyFile,CosIntegral,CreateDirectory,%
Cuboid,Date,DeclarePackage,DefaultColor,DefaultFont,Delete,%
DeleteCases,DeleteDirectory,DeleteFile,Dialog,DialogIndent,%
DialogProlog,DialogSymbols,DigitQ,Directory,DirectoryStack,Disk,%
Dispatch,DownValues,DSolve,Encode,Epilog,Erfc,Evaluate,%
ExponentFunction,FaceGrids,FileByteCount,FileDate,FileNames,%
FileType,Find,FindList,FixedPointList,FlattenAt,Fold,FoldList,%
Frame,FrameLabel,FrameStyle,FrameTicks,FromCharacterCode,%
FromDate,FullGraphics,FullOptions,GammaRegularized,%
GaussianIntegers,GraphicsArray,GraphicsSpacing,GridLines,%
GroebnerBasis,Heads,HeldPart,HomeDirectory,Hue,IgnoreCases,%
InputStream,Install,InString,IntegerDigits,InterpolatingFunction,%
InterpolatingPolynomial,Interpolation,Interrupt,InverseFunction,%
InverseFunctions,JacobiZeta,LetterQ,LinearProgramming,ListPlay,%
LogGamma,LowerCaseQ,MachineNumberQ,MantissaExponent,MapIndexed,%
MapThread,MatchLocalNames,MatrixExp,MatrixPower,MeshRange,%
MeshStyle,MessageList,Module,NDSolve,NSolve,NullRecords,%
NullWords,NumberFormat,NumberPadding,NumberSigns,OutputStream,%
PaddedForm,ParentDirectory,Pause,Play,PlayRange,PlotRegion,%
PolygonIntersections,PolynomialGCD,PolynomialLCM,PolynomialMod,%
PostScript,PowerExpand,PrecisionGoal,PrimePi,Prolog,%
QRDecomposition,Raster,RasterArray,RealDigits,Record,RecordLists,%
RecordSeparators,ReleaseHold,RenameDirectory,RenameFile,%
ReplaceHeldPart,ReplacePart,ResetDirectory,Residue,%
RiemannSiegelTheta,RiemannSiegelZ,RotateLabel,SameTest,%
SampleDepth,SampledSoundFunction,SampledSoundList,SampleRate,%
SchurDecomposition,SessionTime,SetAccuracy,SetDirectory,%
SetFileDate,SetPrecision,SetStreamPosition,Shallow,SignPadding,%
SinIntegral,SixJSymbol,Skip,Sound,SpellingCorrection,%
SphericalRegion,Stack,StackBegin,StackComplete,StackInhibit,%
StreamPosition,Streams,StringByteCount,StringConversion,%
StringDrop,StringInsert,StringPosition,StringReplace,%
StringReverse,StringTake,StringToStream,SurfaceColor,%
SyntaxLength,SyntaxQ,TableAlignments,TableDepth,%
TableDirections,TableHeadings,TableSpacing,ThreeJSymbol,TimeUsed,%
TimeZone,ToCharacterCode,ToDate,ToHeldExpression,TokenWords,%
ToLowerCase,ToUpperCase,Trace,TraceAbove,TraceBackward,%
TraceDepth,TraceDialog,TraceForward,TraceOff,TraceOn,%
TraceOriginal,TracePrint,TraceScan,Trig,Unevaluated,Uninstall,%
UnsameQ,UpperCaseQ,UpValues,ViewCenter,ViewVertical,With,Word,%
WordSearch,WordSeparators},%
morendkeywords={Stub,Temporary,$Aborted,$BatchInput,$BatchOutput,%
$CreationDate,$DefaultFont,$DumpDates,$DumpSupported,$Failed,%
$Input,$Inspector,$IterationLimit,$Language,$Letters,$Linked,%
$LinkSupported,$MachineEpsilon,$MachineID,$MachineName,%
$MachinePrecision,$MachineType,$MaxMachineNumber,$MessageList,%
$MessagePrePrint,$MinMachineNumber,$ModuleNumber,$NewMessage,%
$NewSymbol,$Notebooks,$OperatingSystem,$Packages,$PipeSupported,%
$PreRead,$ReleaseNumber,$SessionID,$SoundDisplayFunction,%
$StringConversion,$StringOrder,$SyntaxHandler,$TimeUnit,%
$VersionNumber}%
}%
\lst@definelanguage[1.0]{Mathematica}%
{morekeywords={Abs,Accuracy,AccurayGoal,AddTo,AiryAi,AlgebraicRules,%
AmbientLight,And,Apart,Append,AppendTo,Apply,ArcCos,ArcCosh,%
ArcCot,ArcCoth,ArcCsc,ArcCsch,ArcSec,ArcSech,ArcSin,ArcSinh,%
ArcTan,ArcTanh,Arg,ArithmeticGeometricMean,Array,AspectRatio,%
AtomQ,Attributes,Axes,AxesLabel,BaseForm,Begin,BeginPackage,%
BernoulliB,BesselI,BesselJ,BesselK,BesselY,Beta,Binomial,Blank,%
BlankNullSequence,BlankSequence,Block,Boxed,BoxRatios,Break,Byte,%
ByteCount,Cancel,Cases,Catch,Ceiling,CForm,Character,Characters,%
ChebyshevT,ChebyshevU,Check,Chop,Clear,ClearAll,ClearAttributes,%
ClipFill,Close,Coefficient,CoefficientList,Collect,ColumnForm,%
Complement,Complex,CompoundExpression,Condition,Conjugate,%
Constants,Context,Continuation,Continue,ContourGraphics,%
ContourPlot,Cos,Cosh,Cot,Coth,Count,Csc,Csch,Cubics,Cyclotomic,%
D,Dashing,Decompose,Decrement,Default,Definition,Denominator,%
DensityGraphics,DensityPlot,Depth,Derivative,Det,DiagonalMatrix,%
DigitBlock,Dimensions,DirectedInfinity,Display,DisplayFunction,%
Distribute,Divide,DivideBy,Divisors,DivisorSigma,Do,Dot,Drop,Dt,%
Dump,EdgeForm,Eigensystem,Eigenvalues,Eigenvectors,Eliminate,%
EllipticE,EllipticExp,EllipticF,EllipticK,EllipticLog,EllipticPi,%
EllipticTheta,End,EndPackage,EngineeringForm,Environment,Equal,%
Erf,EulerE,EulerPhi,EvenQ,Exit,Exp,Expand,ExpandAll,%
ExpandDenominator,ExpandNumerator,ExpIntegralE,ExpIntegralEi,%
Exponent,Expression,ExtendedGCD,FaceForm,Factor,FactorComplete,%
Factorial,Factorial2,FactorInteger,FactorList,FactorSquareFree,%
FactorSquareFreeList,FactorTerms,FactorTermsList,FindMinimum,%
FindRoot,First,Fit,FixedPoint,Flatten,Floor,FontForm,For,Format,%
FormatType,FortranForm,Fourier,FreeQ,FullDefinition,FullForm,%
Function,Gamma,GCD,GegenbauerC,General,Get,Goto,Graphics,%
Graphics3D,GrayLevel,Greater,GreaterEqual,Head,HermiteH,%
HiddenSurface,Hold,HoldForm,Hypergeometric0F1, Hypergeometric1F1,%
Hypergeometric2F1,HypergeometricU,Identity,IdentityMatrix,If,Im,%
Implies,In,Increment,Indent,Infix,Information,Inner,Input,%
InputForm,InputString,Insert,Integer,IntegerQ,Integrate,%
Intersection,Inverse,InverseFourier,InverseJacobiSN,%
InverseSeries,JacobiAmplitude,JacobiP,JacobiSN,JacobiSymbol,Join,%
Label,LaguerreL,Last,LatticeReduce,LCM,LeafCount,LegendreP,%
LegendreQ,LegendreType,Length,LerchPhi,Less,LessEqual,Level,%
Lighting,LightSources,Limit,Line,LinearSolve,LineBreak,List,%
ListContourPlot,ListDensityPlot,ListPlot,ListPlot3D,Literal,Log,%
LogicalExpand,LogIntegral,MainSolve,Map,MapAll,MapAt,MatchQ,%
MatrixForm,MatrixQ,Max,MaxBend,MaxMemoryUsed,MemberQ,%
MemoryConstrained,MemoryInUse,Mesh,Message,MessageName,Messages,%
Min,Minors,Minus,Mod,Modulus,MoebiusMu,Multinomial,N,NameQ,Names,%
NBernoulliB,Needs,Negative,Nest,NestList,NIntegrate,%
NonCommutativeMultiply,NonConstants,NonNegative,Normal,Not,%
NProduct,NSum,NullSpace,Number,NumberForm,NumberPoint,NumberQ,%
NumberSeparator,Numerator,O,OddQ,Off,On,OpenAppend,OpenRead,%
OpenTemporary,OpenWrite,Operate,Optional,Options,Or,Order,%
OrderedQ,Out,Outer,OutputForm,PageHeight,PageWidth,%
ParametricPlot,ParametricPlot3D,Part,Partition,PartitionsP,%
PartitionsQ,Pattern,Permutations,Plot,Plot3D,PlotDivision,%
PlotJoined,PlotLabel,PlotPoints,PlotRange,PlotStyle,Pochhammer,%
Plus,Point,PointSize,PolyGamma,Polygon,PolyLog,PolynomialQ,%
PolynomialQuotient,PolynomialRemainder,Position,Positive,Postfix,%
Power,PowerMod,PrecedenceForm,Precision,PreDecrement,Prefix,%
PreIncrement,Prepend,PrependTo,Prime,PrimeQ,Print,PrintForm,%
Product,Protect,PseudoInverse,Put,PutAppend,Quartics,Quit,%
Quotient,Random,Range,Rational,Rationalize,Raw,Re,Read,ReadList,%
Real,Rectangle,Reduce,Remove,RenderAll,Repeated,RepeatedNull,%
Replace,ReplaceAll,ReplaceRepeated,Rest,Resultant,Return,Reverse,%
RGBColor,Roots,RotateLeft,RotateRight,Round,RowReduce,Rule,%
RuleDelayed,Run,RunThrough,SameQ,Save,Scaled,Scan,ScientificForm,%
Sec,Sech,SeedRandom,Select,Sequence,SequenceForm,Series,%
SeriesData,Set,SetAttributes,SetDelayed,SetOptions,Shading,Share,%
Short,Show,Sign,Signature,Simplify,Sin,SingularValues,Sinh,%
Skeleton,Slot,SlotSequence,Solve,SolveAlways,Sort,%
SphericalHarmonicY,Splice,Sqrt,StirlingS1,StirlingS2,String,%
StringBreak,StringForm,StringJoin,StringLength,StringMatchQ,%
StringSkeleton,Subscript,Subscripted,Subtract,SubtractForm,Sum,%
Superscript,SurfaceGraphics,Switch,Symbol,Table,TableForm,TagSet,%
TagSetDelayed,TagUnset,Take,Tan,Tanh,ToString,TensorRank,TeXForm,%
Text,TextForm,Thickness,Thread,Through,Throw,Ticks,%
TimeConstrained,Times,TimesBy,Timing,ToExpression,Together,%
ToRules,ToString,TotalHeight,TotalWidth,Transpose,TreeForm,TrueQ,%
Unequal,Union,Unique,Unprotect,Unset,Update,UpSet,UpSetDelayed,%
ValueQ,Variables,VectorQ,ViewPoint,WeierstrassP,%
WeierstrassPPrime,Which,While,WorkingPrecision,Write,WriteString,%
Xor,ZeroTest,Zeta},%
morendkeywords={All,Automatic,Catalan,ComplexInfinity,Constant,%
Degree,E,EndOfFile,EulerGamma,False,Flat,GoldenRatio,HoldAll,%
HoldFirst,HoldRest,I,Indeterminate,Infinity,Listable,Locked,%
Modular,None,Null,OneIdentity,Orderless,Pi,Protected,%
ReadProtected,True,$CommandLine,$Context,$ContextPath,$Display,%
$DisplayFunction,$Echo,$Epilog,$IgnoreEOF,$Line,$Messages,%
$Output,$Path,$Post,$Pre,$PrePrint,$RecursionLimit,$System,%
$Urgent,$Version},%
sensitive,%
morecomment=[s]{(*}{*)},%
morestring=[d]"%
}[keywords,comments,strings]%
%%
%% Octave definition (c) 2001,2002 Ulrich G. Wortmann
%% <uliw@erdw.ethz.ch>
%%
\lst@definelanguage{Octave}%
{morekeywords={gt,lt,gt,lt,amp,abs,acos,acosh,acot,acoth,acsc,acsch,%
all,angle,ans,any,asec,asech,asin,asinh,atan,atan2,atanh,auread,%
auwrite,axes,axis,balance,bar,bessel,besselk,bessely,beta,%
betainc,betaln,blanks,bone,break,brighten,capture,cart2pol,%
cart2sph,caxis,cd,cdf2rdf,cedit,ceil,chol,cla,clabel,clc,clear,%
clf,clock,close,colmmd,Colon,colorbar,colormap,ColorSpec,colperm,%
comet,comet3,compan,compass,computer,cond,condest,conj,contour,%
contour3,contourc,contrast,conv,conv2,cool,copper,corrcoef,cos,%
cosh,cot,coth,cov,cplxpair,cputime,cross,csc,csch,csvread,%
csvwrite,cumprod,cumsum,cylinder,date,dbclear,dbcont,dbdown,%
dbquit,dbstack,dbstatus,dbstep,dbstop,dbtype,dbup,ddeadv,ddeexec,%
ddeinit,ddepoke,ddereq,ddeterm,ddeunadv,deblank,dec2hex,deconv,%
del2,delete,demo,det,diag,diary,diff,diffuse,dir,disp,dlmread,%
dlmwrite,dmperm,dot,drawnow,echo,eig,ellipj,ellipke,else,elseif,%
end,engClose,engEvalString,engGetFull,engGetMatrix,engOpen,%
engOutputBuffer,engPutFull,engPutMatrix,engSetEvalCallback,%
engSetEvalTimeout,engWinInit,eps,erf,erfc,erfcx,erfinv,%
errorbar,etime,etree,eval,exist,exp,expint,expm,expo,eye,fclose,%
feather,feof,ferror,feval,fft,fft2,fftshift,fgetl,fgets,figure,%
fill,fill3,filter,filter2,find,findstr,finite,fix,flag,fliplr,%
flipud,floor,flops,fmin,fmins,fopen,for,format,fplot,fprintf,%
fread,frewind,fscanf,fseek,ftell,full,function,funm,fwrite,fzero,%
gallery,gamma,gammainc,gammaln,gca,gcd,gcf,gco,get,getenv,%
getframe,ginput,global,gplot,gradient,gray,graymon,grid,griddata,%
gtext,hadamard,hankel,help,hess,hex2dec,hex2num,hidden,hilb,hist,%
hold,home,hostid,hot,hsv,hsv2rgb,if,ifft,ifft2,imag,image,%
imagesc,Inf,info,input,int2str,interp1,interp2,interpft,inv,%
invhilb,isempty,isglobal,ishold,isieee,isinf,isletter,isnan,%
isreal,isspace,issparse,isstr,jet,keyboard,kron,lasterr,lcm,%
legend,legendre,length,lin2mu,line,linspace,load,log,log10,log2,%
loglog,logm,logspace,lookfor,lower,ls,lscov,lu,magic,matClose,%
matDeleteMatrix,matGetDir,matGetFp,matGetFull,matGetMatrix,%
matGetNextMatrix,matGetString,matlabrc,matlabroot,matOpen,%
matPutFull,matPutMatrix,matPutString,max,mean,median,menu,mesh,%
meshc,meshgrid,meshz,mexAtExit,mexCallMATLAB,mexdebug,%
mexErrMsgTxt,mexEvalString,mexFunction,mexGetFull,mexGetMatrix,%
mexGetMatrixPtr,mexPrintf,mexPutFull,mexPutMatrix,mexSetTrapFlag,%
min,more,movie,moviein,mu2lin,mxCalloc,mxCopyCharacterToPtr,%
mxCopyComplex16ToPtr,mxCopyInteger4ToPtr,mxCopyPtrToCharacter,%
mxCopyPtrToComplex16,mxCopyPtrToInteger4,mxCopyPtrToReal8,%
mxCopyReal8ToPtr,mxCreateFull,mxCreateSparse,mxCreateString,%
mxFree,mxFreeMatrix,mxGetIr,mxGetJc,mxGetM,mxGetN,mxGetName,%
mxGetNzmax,mxGetPi,mxGetPr,mxGetScalar,mxGetString,mxIsComplex,%
mxIsFull,mxIsNumeric,mxIsSparse,mxIsString,mxIsTypeDouble,%
mxSetIr,mxSetJc,mxSetM,mxSetN,mxSetName,mxSetNzmax,mxSetPi,%
mxSetPr,NaN,nargchk,nargin,nargout,newplot,nextpow2,nnls,nnz,%
nonzeros,norm,normest,null,num2str,nzmax,ode23,ode45,orient,orth,%
pack,pascal,patch,path,pause,pcolor,pi,pink,pinv,plot,plot3,%
pol2cart,polar,poly,polyder,polyeig,polyfit,polyval,polyvalm,%
pow2,print,printopt,prism,prod,pwd,qr,qrdelete,qrinsert,quad,%
quad8,quit,quiver,qz,rand,randn,randperm,rank,rat,rats,rbbox,%
rcond,real,realmax,realmin,refresh,rem,reset,reshape,residue,%
return,rgb2hsv,rgbplot,rootobject,roots,rose,rosser,rot90,rotate,%
round,rref,rrefmovie,rsf2csf,save,saxis,schur,sec,sech,semilogx,%
semilogy,set,setstr,shading,sign,sin,sinh,size,slice,sort,sound,%
spalloc,sparse,spaugment,spconvert,spdiags,specular,speye,spfun,%
sph2cart,sphere,spinmap,spline,spones,spparms,sprandn,sprandsym,%
sprank,sprintf,spy,sqrt,sqrtm,sscanf,stairs,startup,std,stem,%
str2mat,str2num,strcmp,strings,strrep,strtok,subplot,subscribe,%
subspace,sum,surf,surface,surfc,surfl,surfnorm,svd,symbfact,%
symmmd,symrcm,tan,tanh,tempdir,tempname,terminal,text,tic,title,%
toc,toeplitz,trace,trapz,tril,triu,type,uicontrol,uigetfile,%
uimenu,uiputfile,unix,unwrap,upper,vander,ver,version,view,%
viewmtx,waitforbuttonpress,waterfall,wavread,wavwrite,what,%
whatsnew,which,while,white,whitebg,who,whos,wilkinson,wk1read,%
stderr,stdout,plot,set,endif,wk1write,xlabel,xor,ylabel,zeros,%
zlabel,zoom,endwhile,endfunction},%
sensitive=f,%
morecomment=[l]\#,%
morecomment=[l]\#\#,%
morestring=[m]',%
morestring=[m]"%
}[keywords,comments,strings]%
\lst@definelanguage[XSC]{Pascal}[Standard]{Pascal}
{deletekeywords={alfa,byte,pack,unpack},% 1998 Andreas Stephan
morekeywords={dynamic,external,forward,global,module,nil,operator,%
priority,sum,type,use,dispose,mark,page,release,cimatrix,%
cinterval,civector,cmatrix,complex,cvector,dotprecision,imatrix,%
interval,ivector,rmatrix,rvector,string,im,inf,re,sup,chr,comp,%
eof,eoln,expo,image,ival,lb,lbound,length,loc,mant,maxlength,odd,%
ord,pos,pred,round,rval,sign,substring,succ,trunc,ub,ubound}%
}%
\lst@definelanguage[Borland6]{Pascal}[Standard]{Pascal}
{morekeywords={asm,constructor,destructor,implementation,inline,%
interface,nil,object,shl,shr,string,unit,uses,xor},%
morendkeywords={Abs,Addr,ArcTan,Chr,Concat,Copy,Cos,CSeg,DiskFree,%
DiskSize,DosExitCode,DosVersion,DSeg,EnvCount,EnvStr,Eof,Eoln,%
Exp,FExpand,FilePos,FileSize,Frac,FSearch,GetBkColor,GetColor,%
GetDefaultPalette,GetDriverName,GetEnv,GetGraphMode,GetMaxMode,%
GetMaxX,GetMaxY,GetModeName,GetPaletteSize,GetPixel,GetX,GetY,%
GraphErrorMsg,GraphResult,Hi,ImageSize,InstallUserDriver,%
InstallUserFont,Int,IOResult,KeyPressed,Length,Lo,MaxAvail,%
MemAvail,MsDos,Odd,Ofs,Ord,OvrGetBuf,OvrGetRetry,ParamCount,%
ParamStr,Pi,Pos,Pred,Ptr,Random,ReadKey,Round,SeekEof,SeekEoln,%
Seg,SetAspectRatio,Sin,SizeOf,Sound,SPtr,Sqr,Sqrt,SSeg,Succ,%
Swap,TextHeight,TextWidth,Trunc,TypeOf,UpCase,WhereX,WhereY,%
Append,Arc,Assign,AssignCrt,Bar,Bar3D,BlockRead,BlockWrite,ChDir,%
Circle,ClearDevice,ClearViewPort,Close,CloseGraph,ClrEol,ClrScr,%
Dec,Delay,Delete,DelLine,DetectGraph,Dispose,DrawPoly,Ellipse,%
Erase,Exec,Exit,FillChar,FillEllipse,FillPoly,FindFirst,FindNext,%
FloodFill,Flush,FreeMem,FSplit,GetArcCoords,GetAspectRatio,%
GetDate,GetDefaultPalette,GetDir,GetCBreak,GetFAttr,%
GetFillSettings,GetFTime,GetImage,GetIntVec,GetLineSettings,%
GetMem,GetPalette,GetTextSettings,GetTime,GetVerify,%
GetViewSettings,GoToXY,Halt,HighVideo,Inc,InitGraph,Insert,%
InsLine,Intr,Keep,Line,LineRel,LineTo,LowVideo,Mark,MkDir,Move,%
MoveRel,MoveTo,MsDos,New,NormVideo,NoSound,OutText,OutTextXY,%
OvrClearBuf,OvrInit,OvrInitEMS,OvrSetBuf,PackTime,PieSlice,%
PutImage,PutPixel,Randomize,Rectangle,Release,Rename,%
RestoreCrtMode,RmDir,RunError,Sector,Seek,SetActivePage,%
SetAllPalette,SetBkColor,SetCBreak,SetColor,SetDate,SetFAttr,%
SetFillPattern,SetFillStyle,SetFTime,SetGraphBufSize,%
SetGraphMode,SetIntVec,SetLineStyle,SetPalette,SetRGBPalette,%
SetTextBuf,SetTextJustify,SetTextStyle,SetTime,SetUserCharSize,%
SetVerify,SetViewPort,SetVisualPage,SetWriteMode,Sound,Str,%
SwapVectors,TextBackground,TextColor,TextMode,Truncate,%
UnpackTime,Val,Window}%
}%
\lst@definelanguage[Standard]{Pascal}%
{morekeywords={alfa,and,array,begin,boolean,byte,case,char,const,div,%
do,downto,else,end,false,file,for,function,get,goto,if,in,%
integer,label,maxint,mod,new,not,of,or,pack,packed,page,program,%
put,procedure,read,readln,real,record,repeat,reset,rewrite,set,%
text,then,to,true,type,unpack,until,var,while,with,write,%
writeln},%
sensitive=f,%
morecomment=[s]{(*}{*)},%
morecomment=[s]{\{}{\}},%
morestring=[d]'%
}[keywords,comments,strings]%
\lst@definelanguage{Perl}%
{morekeywords={abs,accept,alarm,atan2,bind,binmode,bless,caller,%
chdir,chmod,chomp,chop,chown,chr,chroot,close,closedir,connect,%
continue,cos,crypt,dbmclose,dbmopen,defined,delete,die,do,dump,%
each,else,elsif,endgrent,endhostent,endnetent,endprotoent,%
endpwent,endservent,eof,eval,exec,exists,exit,exp,fcntl,fileno,%
flock,for,foreach,fork,format,formline,getc,getgrent,getgrgid,%
getgrnam,gethostbyaddr,gethostbyname,gethostent,getlogin,%
getnetbyaddr,getnetbyname,getnetent,getpeername,getpgrp,%
getppid,getpriority,getprotobyname,getprotobynumber,getprotoent,%
getpwent,getpwnam,getpwuid,getservbyname,getservbyport,%
getservent,getsockname,getsockopt,glob,gmtime,goto,grep,hex,if,%
import,index,int,ioctl,join,keys,kill,last,lc,lcfirst,length,%
link,listen,local,localtime,log,lstat,m,map,mkdir,msgctl,msgget,%
msgrcv,msgsnd,my,next,no,oct,open,opendir,ord,pack,package,pipe,%
pop,pos,print,printf,prototype,push,q,qq,quotemeta,qw,qx,rand,%
read,readdir,readlink,recv,redo,ref,rename,require,reset,return,%
reverse,rewinddir,rindex,rmdir,s,scalar,seek,seekdir,select,%
semctl,semget,semop,send,setgrent,sethostent,setnetent,setpgrp,%
setpriority,setprotoent,setpwent,setservent,setsockopt,shift,%
shmctl,shmget,shmread,shmwrite,shutdown,sin,sleep,socket,%
socketpair,sort,splice,split,sprintf,sqrt,srand,stat,study,sub,%
substr,symlink,syscall,sysopen,sysread,system,syswrite,tell,%
telldir,tie,tied,time,times,tr,truncate,uc,ucfirst,umask,undef,%
unless,unlink,unpack,unshift,untie,until,use,utime,values,vec,%
wait,waitpid,wantarray,warn,while,write,y},%
sensitive,%
morecomment=[l]\#,%
morestring=[b]",%
morestring=[b]',%
MoreSelectCharTable=%
\lst@ReplaceInput{\$\#}{\lst@ProcessOther\$\lst@ProcessOther\#}%
}[keywords,comments,strings]%
%%
%% POV definition (c) 1999 Berthold H\"ollmann
%% <bhoel@starship.python.net>
%%
\lst@definelanguage{POV}%
{morekeywords={abs,absorption,acos,acosh,adaptive,adc_bailout,agate,%
agate_turb,all,alpha,ambient,ambient_light,angle,aperture,append,%
arc_angle,area_light,array,asc,asin,asinh,assumed_gamma,atan,%
atan2,atanh,average,background,bezier_spline,bicubic_patch,%
black_hole,blob,blue,blur_samples,bounded_by,box,boxed,bozo,%
break,brick,brick_size,brightness,brilliance,bumps,bump_map,%
bump_size,camera,case,caustics,ceil,checker,chr,clipped_by,clock,%
clock_delta,color,color_map,colour,colour_map,component,%
composite,concat,cone,confidence,conic_sweep,control0,control1,%
cos,cosh,count,crackle,crand,cube,cubic,cubic_spline,cubic_wave,%
cylinder,cylindrical,debug,declare,default,defined,degrees,%
density,density_file,density_map,dents,difference,diffuse,%
dimensions,dimension_size,direction,disc,distance,%
distance_maximum,div,eccentricity,else,emission,end,error,%
error_bound,exp,extinction,fade_distance,fade_power,falloff,%
falloff_angle,false,fclose,file_exists,filter,finish,fisheye,%
flatness,flip,floor,focal_point,fog,fog_alt,fog_offset,fog_type,%
fopen,frequency,gif,global_settings,gradient,granite,%
gray_threshold,green,height_field,hexagon,hf_gray_16,hierarchy,%
hollow,hypercomplex,if,ifdef,iff,ifndef,image_map,include,int,%
interior,interpolate,intersection,intervals,inverse,ior,irid,%
irid_wavelength,jitter,julia_fractal,lambda,lathe,leopard,%
light_source,linear_spline,linear_sweep,local,location,log,%
looks_like,look_at,low_error_factor,macro,mandel,map_type,marble,%
material,material_map,matrix,max,max_intersections,max_iteration,%
max_trace_level,media,media_attenuation,media_interaction,merge,%
mesh,metallic,min,minimum_reuse,mod,mortar,nearest_count,no,%
normal,normal_map,no_shadow,number_of_waves,object,octaves,off,%
offset,omega,omnimax,on,once,onion,open,orthographic,panoramic,%
perspective,pgm,phase,phong,phong_size,pi,pigment,pigment_map,%
planar,plane,png,point_at,poly,polygon,poly_wave,pot,pow,ppm,%
precision,prism,pwr,quadratic_spline,quadric,quartic,quaternion,%
quick_color,quick_colour,quilted,radial,radians,radiosity,radius,%
rainbow,ramp_wave,rand,range,ratio,read,reciprocal,%
recursion_limit,red,reflection,reflection_exponent,refraction,%
render,repeat,rgb,rgbf,rgbft,rgbt,right,ripples,rotate,roughness,%
samples,scale,scallop_wave,scattering,seed,shadowless,sin,%
sine_wave,sinh,sky,sky_sphere,slice,slope_map,smooth,%
smooth_triangle,sor,specular,sphere,spherical,spiral1,spiral2,%
spotlight,spotted,sqr,sqrt,statistics,str,strcmp,strength,strlen,%
strlwr,strupr,sturm,substr,superellipsoid,switch,sys,t,tan,tanh,%
text,texture,texture_map,tga,thickness,threshold,tightness,tile2,%
tiles,torus,track,transform,translate,transmit,triangle,%
triangle_wave,true,ttf,turbulence,turb_depth,type,u,%
ultra_wide_angle,undef,union,up,use_color,use_colour,use_index,%
u_steps,v,val,variance,vaxis_rotate,vcross,vdot,version,vlength,%
vnormalize,vrotate,v_steps,warning,warp,water_level,waves,while,%
width,wood,wrinkles,write,x,y,yes,z},%
moredirectives={break,case,debug,declare,default,else,end,fclose,%
fopen,local,macro,read,render,statistics,switch,undef,version,%
warning,write},%
sensitive,%
morecomment=[l]//,%
morecomment=[s]{/*}{*/},%
morestring=[d]",%
}[keywords,directives,comments,strings]%
%%
%% Python definition (c) 1998 Michael Weber
%% <mweber@informatik.hu-berlin.de>
%%
\lst@definelanguage{Python}%
{morekeywords={access,and,break,class,continue,def,del,elif,else,%
except,exec,finally,for,from,global,if,import,in,is,lambda,not,%
or,pass,print,raise,return,try,while},%
sensitive=true,%
morecomment=[l]\#,%
morecomment=[s]{'''}{'''},% used for documentation text
morecomment=[s]{"""}{"""},% added by Philipp Matthias Hahn
morestring=[b]',%
morestring=[b]"%
}%
%%
%% SQL definition (c) 1998 Christian Haul
%% <haul@dvs1.informatik.tu-darmstadt.de>
%% and (c) 2002 Neil Conway <nconway@klamath.dyndns.org>
%%
\lst@definelanguage{SQL}%
{morekeywords={ABSOLUTE,ACTION,ADD,ALLOCATE,ALTER,ARE,AS,ASSERTION,%
AT,BETWEEN,BIT,BIT_LENGTH,BOTH,BY,CASCADE,CASCADED,CASE,CAST,%
CATALOG,CHAR,CHAR_LENGTH,CHARACTER_LENGTH,CLUSTER,COALESCE,%
COLLATE,COLLATION,COLUMN,CONNECT,CONNECTION,CONSTRAINT,%
CONSTRAINTS,CONVERT,CORRESPONDING,CREATE,CROSS,CURRENT_DATE,%
CURRENT_TIME,CURRENT_TIMESTAMP,CURRENT_USER,DATE,DAY,DEALLOCATE,%
DEC,DECIMAL,DEFERRABLE,DEFERED,DESCRIBE,DESCRIPTOR,DIAGNOSTICS,%
DISCONNECT,DOMAIN,DROP,ELSE,END,EXEC,EXCEPT,EXCEPTION,EXECUTE,%
EXTERNAL,EXTRACT,FALSE,FIRST,FLOAT,FOREIGN,FROM,FULL,GET,GLOBAL,%
GRAPHIC,HAVING,HOUR,IDENTITY,IMMEDIATE,INDEX,INITIALLY,INNER,%
INPUT,INSENSITIVE,INSERT,INT,INTO,INTEGER,INTERSECT,INTERVAL,%
ISOLATION,JOIN,KEY,LAST,LEADING,LEFT,LEVEL,LIMIT,LOCAL,LOWER,%
MATCH,MINUTE,MONTH,NAMES,NATIONAL,NATURAL,NCHAR,NEXT,NO,NOT,NULL,%
NULLIF,OCTET_LENGTH,ON,ONLY,ORDER,ORDERED,OUTER,OUTPUT,OVERLAPS,%
PAD,PARTIAL,POSITION,PREPARE,PRESERVE,PRIMARY,PRIOR,READ,%
RELATIVE,RESTRICT,REVOKE,RIGHT,ROWS,SCROLL,SECOND,SELECT,SESSION,%
SESSION_USER,SIZE,SMALLINT,SPACE,SQLSTATE,SUBSTRING,SYSTEM_USER,%
TABLE,TEMPORARY,THEN,TIME,TIMESTAMP,TIMEZONE_HOUR,%
TIMEZONE_MINUTE,TRAILING,TRANSACTION,TRANSLATE,TRANSLATION,TRIM,%
TRUE,UNIQUE,UNKNOWN,UPPER,USAGE,USING,VALUE,VALUES,VARCHAR,%
VARGRAPHIC,VARYING,WHEN,WHERE,WRITE,YEAR,ZONE},%
sensitive,%
morecomment=[l]--,%
morecomment=[s]{/*}{*/},%
morestring=[d]',%
morestring=[d]"%
}[keywords,comments,strings]%
%%
%% VHDL definition (c) 1997 Kai Wollenweber <kai@ece.wpi.edu>
%%
\lst@definelanguage{VHDL}%
{morekeywords={ALL,ARCHITECTURE,ABS,AND,ASSERT,ARRAY,AFTER,ALIAS,%
ACCESS,ATTRIBUTE,BEGIN,BODY,BUS,BLOCK,BUFFER,CONSTANT,CASE,%
COMPONENT,CONFIGURATION,DOWNTO,ELSE,ELSIF,END,ENTITY,EXIT,%
FUNCTION,FOR,FILE,GENERIC,GENERATE,GUARDED,GROUP,IF,IN,INOUT,IS,%
INERTIAL,IMPURE,LIBRARY,LOOP,LABEL,LITERAL,LINKAGE,MAP,MOD,NOT,%
NOR,NAND,NULL,NEXT,NEW,OUT,OF,OR,OTHERS,ON,OPEN,PROCESS,PORT,%
PACKAGE,PURE,PROCEDURE,POSTPONED,RANGE,REM,ROL,ROR,REPORT,RECORD,%
RETURN,REGISTER,REJECT,SIGNAL,SUBTYPE,SLL,SRL,SLA,SRA,SEVERITY,%
SELECT,THEN,TYPE,TRANSPORT,TO,USE,UNITS,UNTIL,VARIABLE,WHEN,WAIT,%
WHILE,XOR,XNOR},%
sensitive=f,% 1998 Gaurav Aggarwal
morecomment=[l]--,%
morestring=[d]{"}%
}[keywords,comments,strings]%
%%
%% VHDL-AMS definition (c) Steffen Klupsch
%%
\lst@definelanguage[AMS]{VHDL}[]{VHDL}%
{morekeywords={ACROSS,ARRAY,BREAK,DISCONNECT,NATURE,NOISE,PORT,%
PROCEDURAL,QUANTITY,SHARED,SPECTRUM,SUBNATURE,TERMINAL,THROUGH,%
TOLERANCE,UNAFFACTED,UNITS}}
\lst@definelanguage{XML}%
{keywords={,CDATA,DOCTYPE,ATTLIST,termdef,ELEMENT,EMPTY,ANY,ID,%
IDREF,IDREFS,ENTITY,ENTITIES,NMTOKEN,NMTOKENS,NOTATION,%
INCLUDE,IGNORE,SYSTEM,PUBLIC,NDATA,PUBLIC,%
PCDATA,REQUIRED,IMPLIED,FIXED,%%% preceded by #
xml,xml:space,xml:lang,version,standalone,default,preserve},%
alsoother=$,%
alsoletter=:,%
keywordsinside=<>,%
morestring=[d]",% ??? doubled
morestring=[d]',% ??? doubled
MoreSelectCharTable=%
\lst@CArgX--\relax\lst@DefDelimB{}{}%
{\ifnum\lst@mode=\lst@insidemode\else
\expandafter\@gobblethree
\fi}%
\lst@BeginComment\lst@commentmode{{\lst@commentstyle}}%
\lst@CArgX--\relax\lst@DefDelimE{}{}{}%
\lst@EndComment\lst@commentmode
\lst@CArgX[CDATA[\relax\lst@CDef{}%
{\ifnum\lst@mode=\lst@insidemode
\expandafter\lst@BeginCDATA
\else \expandafter\lst@CArgEmpty
\fi}%
\@empty
\lst@CArgX]]\relax\lst@CDef{}%
{\ifnum\lst@mode=\lst@GPmode
\expandafter\lst@EndComment
\else \expandafter\lst@CArgEmpty
\fi}%
\@empty
}[keywords,comments,strings,html]%
\endinput
%%
%% End of file `lstlang1.sty'.

Разница между файлами не показана из-за своего большого размера Загрузить разницу

@ -1,599 +0,0 @@
%%
%% This is file `lstlang3.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% lstdrvrs.dtx (with options: `lang3')
%%
%% (w)(c) 1996/1997/1998/1999/2000/2001/2002 Carsten Heinz and/or any
%% other author listed elsewhere in this file.
%%
%% This file is distributed under the terms of the LaTeX Project Public
%% License from CTAN archives in directory macros/latex/base/lppl.txt.
%% Either version 1.0 or, at your option, any later version.
%%
%% This file is completely free and comes without any warranty.
%%
%% Send comments and ideas on the package, error reports and additional
%% programming languages to <cheinz@gmx.de>.
%%
\ProvidesFile{lstlang3}
[2002/07/31 v1.0d listings language file]
\lst@definelanguage[68]{Algol}%
{morekeywords={abs,and,arg,begin,bin,bits,bool,by,bytes,case,channel,%
char,co,comment,compl,conj,divab,do,down,elem,elif,else,empty,%
end,entier,eq,esac,exit,false,fi,file,flex,for,format,from,ge,%
goto,gt,heap,if,im,in,int,is,isnt,le,leng,level,loc,long,lt,lwb,%
minusab,mod,modab,mode,ne,nil,not,od,odd,of,op,or,ouse,out,over,%
overab,par,plusab,plusto,pr,pragmat,prio,proc,re,real,ref,repr,%
round,sema,shl,short,shorten,shr,sign,skip,string,struct,then,%
timesab,to,true,union,up,upb,void,while},%
sensitive=f,% ???
morecomment=[s]{\#}{\#},%
keywordcomment={co,comment}%
}[keywords,comments,keywordcomments]%
\lst@definelanguage[60]{Algol}%
{morekeywords={array,begin,Boolean,code,comment,div,do,else,end,%
false,for,goto,if,integer,label,own,power,procedure,real,step,%
string,switch,then,true,until,value,while},%
sensitive=f,% ???
keywordcommentsemicolon={end}{else,end}{comment}%
}[keywords,keywordcomments]%
%%
%% x86masm definition (c) 2002 Andrew Zabolotny <zap@cobra.ru>
%%
\lst@definelanguage[x86masm]{Assembler}%
{morekeywords={al,ah,ax,eax,bl,bh,bx,ebx,cl,ch,cx,ecx,dl,dh,dx,edx,%
si,esi,di,edi,bp,ebp,sp,esp,cs,ds,es,ss,fs,gs,cr0,cr1,cr2,cr3,%
db0,db1,db2,db3,db4,db5,db6,db7,tr0,tr1,tr2,tr3,tr4,tr5,tr6,tr7,%
st,aaa,aad,aam,aas,adc,add,and,arpl,bound,bsf,bsr,bswap,bt,btc,%
btr,bts,call,cbw,cdq,clc,cld,cli,clts,cmc,cmp,cmps,cmpsb,cmpsw,%
cmpsd,cmpxchg,cwd,cwde,daa,das,dec,div,enter,hlt,idiv,imul,in,%
inc,ins,int,into,invd,invlpg,iret,ja,jae,jb,jbe,jc,jcxz,jecxz,%
je,jg,jge,jl,jle,jna,jnae,jnb,jnbe,jnc,jne,jng,jnge,jnl,jnle,%
jno,jnp,jns,jnz,jo,jp,jpe,jpo,js,jz,jmp,lahf,lar,lea,leave,lgdt,%
lidt,lldt,lmsw,lock,lods,lodsb,lodsw,lodsd,loop,loopz,loopnz,%
loope,loopne,lds,les,lfs,lgs,lss,lsl,ltr,mov,movs,movsb,movsw,%
movsd,movsx,movzx,mul,neg,nop,not,or,out,outs,pop,popa,popad,%
popf,popfd,push,pusha,pushad,pushf,pushfd,rcl,rcr,rep,repe,%
repne,repz,repnz,ret,retf,rol,ror,sahf,sal,sar,sbb,scas,seta,%
setae,setb,setbe,setc,sete,setg,setge,setl,setle,setna,setnae,%
setnb,setnbe,setnc,setne,setng,setnge,setnl,setnle,setno,setnp,%
setns,setnz,seto,setp,setpe,setpo,sets,setz,sgdt,shl,shld,shr,%
shrd,sidt,sldt,smsw,stc,std,sti,stos,stosb,stosw,stosd,str,sub,%
test,verr,verw,wait,wbinvd,xadd,xchg,xlatb,xor,fabs,fadd,fbld,%
fbstp,fchs,fclex,fcom,fcos,fdecstp,fdiv,fdivr,ffree,fiadd,ficom,%
fidiv,fidivr,fild,fimul,fincstp,finit,fist,fisub,fisubr,fld,fld1,%
fldl2e,fldl2t,fldlg2,fldln2,fldpi,fldz,fldcw,fldenv,fmul,fnop,%
fpatan,fprem,fprem1,fptan,frndint,frstor,fsave,fscale,fsetpm,%
fsin,fsincos,fsqrt,fst,fstcw,fstenv,fstsw,fsub,fsubr,ftst,fucom,%
fwait,fxam,fxch,fxtract,fyl2x,fyl2xp1,f2xm1},%
morekeywords=[2]{.align,.alpha,assume,byte,code,comm,comment,.const,%
.cref,.data,.data?,db,dd,df,dosseg,dq,dt,dw,dword,else,end,endif,%
endm,endp,ends,eq,equ,.err,.err1,.err2,.errb,.errdef,.errdif,%
.erre,.erridn,.errnb,.errndef,.errnz,event,exitm,extrn,far,%
.fardata,.fardata?,fword,ge,group,gt,high,if,if1,if2,ifb,ifdef,%
ifdif,ife,ifidn,ifnb,ifndef,include,includelib,irp,irpc,label,%
.lall,le,length,.lfcond,.list,local,low,lt,macro,mask,mod,.model,%
name,ne,near,offset,org,out,page,proc,ptr,public,purge,qword,.%
radix,record,rept,.sall,seg,segment,.seq,.sfcond,short,size,%
.stack,struc,subttl,tbyte,.tfcond,this,title,type,.type,width,%
word,.xall,.xcref,.xlist},%
alsoletter=.,alsodigit=?,%
sensitive=f,%
morestring=[b]",%
morestring=[b]',%
morecomment=[l];%
}[directives,keywords,comments,strings]
%%
%% Clean definition (c) 1999 Jos\'e Romildo Malaquias
%% <romildo@iceb.ufop.br>
%%
%% Clean 1.3 : some standard functional language: pure, lazy,
%% polymorphic type system, modules, type classes,
%% garbage collection, functions as first class citizens
%%
\lst@definelanguage{Clean}%
{otherkeywords={:,::,=,:==,=:,=>,->,<-,<-:,\{,\},\{|,|\},\#,\#!,|,\&,%
[,],!,.,\\\\,;,_},%
morekeywords={from,definition,implementation,import,module,system,%
case,code,if,in,let,let!,of,where,with,infix,infixl,infixr},%
morendkeywords={True,False,Start,Int,Real,Char,Bool,String,World,%
File,ProcId},%
sensitive,%
morecomment=[l]//,% missing comma: Markus Pahlow
morecomment=[n]{/*}{*/},%
morestring=[b]"%
}[keywords,comments,strings]%
\lst@definelanguage{Comal 80}%
{morekeywords={AND,AUTO,CASE,DATA,DEL,DIM,DIV,DO,ELSE,ENDCASE,ENDIF,%
ENDPROC,ENDWHILE,EOD,EXEC,FALSE,FOR,GOTO,IF,INPUT,INT,LIST,LOAD,%
MOD,NEW,NEXT,NOT,OF,OR,PRINT,PROC,RANDOM,RENUM,REPEAT,RND,RUN,%
SAVE,SELECT,STOP,TAB,THEN,TRUE,UNTIL,WHILE,ZONE},%
sensitive=f,% ???
morecomment=[l]//,%
morestring=[d]"%
}[keywords,comments,strings]%
\lst@definelanguage{Elan}%
{morekeywords={ABS,AND,BOOL,CAND,CASE,CAT,COLUMNS,CONCR,CONJ,CONST,%
COR,DECR,DEFINES,DET,DIV,DOWNTO,ELIF,ELSE,END,ENDIF,ENDOP,%
ENDPACKET,ENDPROC,ENDREP,ENDSELECT,FALSE,FI,FILE,FOR,FROM,IF,%
INCR,INT,INV,LEAVE,LENGTH,LET,MOD,NOT,OF,OP,OR,OTHERWISE,PACKET,%
PROC,REAL,REP,REPEAT,ROW,ROWS,SELECT,SIGN,STRUCT,SUB,TEXT,THEN,%
TRANSP,TRUE,TYPE,UNTIL,UPTO,VAR,WHILE,WITH,XOR,%
maxint,sign,abs,min,max,random,initializerandom,subtext,code,%
replace,text,laenge,pos,compress,change,maxreal,smallreal,floor,%
pi,e,ln,log2,log10,sqrt,exp,tan,tand,sin,sind,cos,cosd,arctan,%
arctand,int,real,lastconversionok,put,putline,line,page,get,%
getline,input,output,sequentialfile,maxlinelaenge,reset,eof,%
close,complexzero,complexone,complexi,complex,realpart,imagpart,%
dphi,phi,vector,norm,replace,matrix,idn,row,column,sub,%
replacerow,replacecolumn,replaceelement,transp,errorsstop,stop},%
sensitive,%
morestring=[d]"%
}[keywords,strings]%
\lst@definelanguage{ksh}
{morekeywords={alias,awk,cat,echo,else,elif,fi,exec,exit,%
for,in,do,done,select,case,esac,while,until,function,%
time,export,cd,eval,fc,fg,kill,let,pwd,read,return,rm,%
glob,goto,history,if,logout,nice,nohup,onintr,repeat,sed,%
set,setenv,shift,source,switch,then,umask,unalias,%
unset,wait,@,env,argv,child,home,ignoreeof,noclobber,%
noglob,nomatch,path,prompt,shell,status,verbose,print,printf,%
sqrt,BEGIN,END},%
morecomment=[l]\#,%
morestring=[d]",%
morestring=[d]'%
}[keywords,comments,strings]%
\lst@definelanguage{Logo}%
{morekeywords={and,atan,arctan,both,break,bf,bl,butfirst,butlast,%
cbreak, close,co,continue,cos,count,clearscreen,cs,debquit,%
describe,diff,difference,ed,edit,either,emptyp,equalp,er,erase,%
errpause,errquit,fifp,filefprint,fifty,fileftype,fip,fileprint,%
fird,fileread,fity,filetype,fiwd,fileword,f,first,or,fp,fprint,%
fput,fty,ftype,full,fullscreen,go,bye,goodbye,gprop,greaterp,%
help,if,iff,iffalse,ift,iftrue,nth,item,keyp,llast,lessp,list,%
local,lput,make,max,maximum,memberp,memtrace,min,minimum,namep,%
not,numberp,oflush,openr,openread,openw,openwrite,op,output,%
pause,plist,pots,pow,pprop,pps,pr,print,product,quotient,random,%
rc,readchar,rl,readlist,remprop,repcount,repeat,request,rnd,run,%
se,sentence,sentencep,setc,setcolor,setipause,setqpause,po,show,%
sin,split,splitscreen,sqrt,stop,sum,test,text,textscreen,thing,%
to,tone,top,toplevel,type,untrace,wait,word,wordp,yaccdebug,is,%
mod,remainder,trace,zerop,back,bk,bto,btouch,fd,forward,fto,%
ftouch,getpen,heading,hit,hitoot,ht,hideturtle,loff,lampoff,lon,%
lampon,lt,left,lot,lotoot,lto,ltouch,penc,pencolor,pd,pendown,pe,%
penerase,penmode,pu,penup,px,penreverse,rt,right,rto,rtouch,%
scrunch,seth,setheading,setscrun,setscrunch,setxy,shownp,st,%
showturtle,towardsxy,clean,wipeclean,xcor,ycor,tur,turtle,%
display,dpy},%
sensitive=f% ???
}[keywords]%
\lst@definelanguage{Modula-2}%
{morekeywords={AND,ARRAY,BEGIN,BY,CASE,CONST,DIV,DO,ELSE,ELSIF,END,%
EXIT,EXPORT,FOR,FROM,IF,IMPLEMENTATION,IMPORT,IN,MOD,MODULE,NOT,%
OF,OR,POINTER,PROCEDURE,QUALIFIED,RECORD,REPEAT,RETURN,SET,THEN,%
TYPE,UNTIL,VAR,WHILE,WITH,ABS,BITSET,BOOLEAN,CAP,CARDINAL,CHAR,%
CHR,DEC,EXCL,FALSE,FLOAT,HALT,HIGH,INC,INCL,INTEGER,LONGCARD,%
LONGINT,LONGREAL,MAX,MIN,NIL,ODD,ORD,PROC,REAL,SIZE,TRUE,TRUNC,%
VAL,DEFINITION,LOOP},% added keywords due to Peter Bartke 99/07/22
sensitive,%
morecomment=[n]{(*}{*)},%
morestring=[d]',%
morestring=[d]"%
}[keywords,comments,strings]%
\lst@definelanguage{NASTRAN}
{morekeywords={ENDDATA},%
morecomment=[l]$,%
MoreSelectCharTable=%
\lst@CArgX BEGIN\ BULK\relax\lst@CDef{}%
{\lst@ifmode\else \ifnum\lst@length=\z@
\lst@EnterMode{\lst@GPmode}{\lst@modetrue
\let\lst@currstyle\lst@gkeywords@sty}%
\fi \fi}%
{\ifnum\lst@mode=\lst@GPmode
\lst@XPrintToken \lst@LeaveMode
\fi}%
}[keywords,comments]%
\lst@definelanguage{Oberon-2}%
{morekeywords={ARRAY,BEGIN,BOOLEAN,BY,CASE,CHAR,CONST,DIV,DO,ELSE,%
ELSIF,END,EXIT,FALSE,FOR,IF,IMPORT,IN,INTEGER,IS,LONGINT,%
LONGREAL,LOOP,MOD,MODULE,NIL,OF,OR,POINTER,PROCEDURE,REAL,RECORD,%
REPEAT,RETURN,SET,SHORTINT,THEN,TO,TRUE,TYPE,UNTIL,VAR,WHILE,%
WITH,ABS,ASH,CAP,CHR,COPY,DEC,ENTIER,EXCL,HALT,INC,INCL,LEN,LONG,%
MAX,MIN,NEW,ODD,ORD,SHORT,SIZE},%
sensitive,%
morecomment=[n]{(*}{*)},%
morestring=[d]',%
morestring=[d]"%
}[keywords,comments,strings]%
%%
%% OCL definition (c) 2000 Achim D. Brucker
%% <brucker@informatik.uni-freiburg.de>
%%
%% You are allowed to use, modify and distribute this code either under
%% the terms of the LPPL (version 1.0 or later) or the GPL (version 2.0
%% or later).
%%
\lst@definelanguage[decorative]{OCL}[OMG]{OCL}
{otherkeywords={@pre},%
morendkeywords={name,attributes,associatoinEnds,operations,%
supertypes,allSupertypes,allInstances,oclIsKindOf,oclIsTypeOf,%
oclAsType,oclInState,oclIsNew,evaluationType,abs,floor,round,max,%
min,div,mod,size,concat,toUpper,toLower,substring,includes,%
excludes,count,includesAll,exludesAll,isEmpty,notEmpty,sum,%
exists,forAll,isUnique,sortedBy,iterate,union,intersection,%
including,excluding,symmetricDifference,select,reject,collect,%
asSequence,asBag,asSequence,asSet,append,prepend,subSequence,at,%
first,last,true,false,isQuery}%
}%
\lst@definelanguage[OMG]{OCL}%
{morekeywords={context,pre,inv,post},%
ndkeywords={or,xor,and,not,implies,if,then,else,endif},%
morerdkeywords={Boolean,Integer,Real,String,Set,Sequence,Bag,%
OclType,OclAny,OclExpression,Enumeration,Collection,},%
sensitive=t,%
morecomment=[l]--,%
morestring=[d]'%
}[keywords,rdkeywords,comments,strings]%
\lst@definelanguage{PL/I}%
{morekeywords={ABS,ATAN,AUTOMATIC,AUTO,ATAND,BEGIN,BINARY,BIN,BIT,%
BUILTIN,BY,CALL,CHARACTER,CHAR,CHECK,COLUMN,COL,COMPLEX,CPLX,%
COPY,COS,COSD,COSH,DATA,DATE,DECIMAL,DEC,DECLARE,DCL,DO,EDIT,%
ELSE,END,ENDFILE,ENDPAGE,ENTRY,EXP,EXTERNAL,EXT,FINISH,FIXED,%
FIXEDOVERFLOW,FOFL,FLOAT,FORMAT,GET,GO,GOTO,IF,IMAG,INDEX,%
INITIAL,INIT,INTERNAL,INT,LABEL,LENGTH,LIKE,LINE,LIST,LOG,LOG2,%
LOG10,MAIN,MAX,MIN,MOD,NOCHECK,NOFIXEDOVERFLOW,NOFOFL,NOOVERFLOW,%
NOOFL,NOSIZE,NOUNDERFLOW,NOUFL,NOZERODIVIDE,NOZDIV,ON,OPTIONS,%
OVERFLOW,OFL,PAGE,PICTURE,PROCEDURE,PROC,PUT,READ,REPEAT,RETURN,%
RETURNS,ROUND,SIN,SIND,SINH,SIZE,SKIP,SQRT,STATIC,STOP,STRING,%
SUBSTR,SUM,SYSIN,SYSPRINT,TAN,TAND,TANH,THEN,TO,UNDERFLOW,UFL,%
VARYING,WHILE,WRITE,ZERODIVIDE,ZDIV},%
sensitive=f,%
morecomment=[s]{/*}{*/},%
morestring=[d]'%
}[keywords,comments,strings]%
\lst@definelanguage[IBM]{Simula}[DEC]{Simula}{}%
\lst@definelanguage[DEC]{Simula}[67]{Simula}%
{morekeywords={and,eq,eqv,ge,gt,hidden,imp,le,long,lt,ne,not,%
options,or,protected,short}%
}%
\lst@definelanguage[CII]{Simula}[67]{Simula}%
{morekeywords={and,equiv,exit,impl,not,or,stop}}%
\lst@definelanguage[67]{Simula}%
{morekeywords={activate,after,array,at,before,begin,boolean,%
character,class,comment,delay,detach,do,else,end,external,false,%
for,go,goto,if,in,inner,inspect,integer,is,label,name,new,none,%
notext,otherwise,prior,procedure,qua,reactivate,real,ref,resume,%
simset,simulation,step,switch,text,then,this,to,true,until,value,%
virtual,when,while},%
sensitive=f,%
keywordcommentsemicolon={end}{else,end,otherwise,when}{comment},%
morestring=[d]",%
morestring=[d]'%
}[keywords,keywordcomments,strings]%
\lst@definelanguage{S}[]{R}{}
\lst@definelanguage[PLUS]{S}[]{R}{}
\lst@definelanguage{R}%
{keywords={abbreviate,abline,abs,acos,acosh,action,add1,add,%
aggregate,alias,Alias,alist,all,anova,any,aov,aperm,append,apply,%
approx,approxfun,apropos,Arg,args,array,arrows,as,asin,asinh,%
atan,atan2,atanh,attach,attr,attributes,autoload,autoloader,ave,%
axis,backsolve,barplot,basename,besselI,besselJ,besselK,besselY,%
beta,binomial,body,box,boxplot,break,browser,bug,builtins,bxp,by,%
c,C,call,Call,case,cat,category,cbind,ceiling,character,char,%
charmatch,check,chol,chol2inv,choose,chull,class,close,cm,codes,%
coef,coefficients,co,col,colnames,colors,colours,commandArgs,%
comment,complete,complex,conflicts,Conj,contents,contour,%
contrasts,contr,control,helmert,contrib,convolve,cooks,coords,%
distance,coplot,cor,cos,cosh,count,fields,cov,covratio,wt,CRAN,%
create,crossprod,cummax,cummin,cumprod,cumsum,curve,cut,cycle,D,%
data,dataentry,date,dbeta,dbinom,dcauchy,dchisq,de,debug,%
debugger,Defunct,default,delay,delete,deltat,demo,de,density,%
deparse,dependencies,Deprecated,deriv,description,detach,%
dev2bitmap,dev,cur,deviance,off,prev,,dexp,df,dfbetas,dffits,%
dgamma,dgeom,dget,dhyper,diag,diff,digamma,dim,dimnames,dir,%
dirname,dlnorm,dlogis,dnbinom,dnchisq,dnorm,do,dotplot,double,%
download,dpois,dput,drop,drop1,dsignrank,dt,dummy,dump,dunif,%
duplicated,dweibull,dwilcox,dyn,edit,eff,effects,eigen,else,%
emacs,end,environment,env,erase,eval,equal,evalq,example,exists,%
exit,exp,expand,expression,External,extract,extractAIC,factor,%
fail,family,fft,file,filled,find,fitted,fivenum,fix,floor,for,%
For,formals,format,formatC,formula,Fortran,forwardsolve,frame,%
frequency,ftable,ftable2table,function,gamma,Gamma,gammaCody,%
gaussian,gc,gcinfo,gctorture,get,getenv,geterrmessage,getOption,%
getwd,gl,glm,globalenv,gnome,GNOME,graphics,gray,grep,grey,grid,%
gsub,hasTsp,hat,heat,help,hist,home,hsv,httpclient,I,identify,if,%
ifelse,Im,image,\%in\%,index,influence,measures,inherits,install,%
installed,integer,interaction,interactive,Internal,intersect,%
inverse,invisible,IQR,is,jitter,kappa,kronecker,labels,lapply,%
layout,lbeta,lchoose,lcm,legend,length,levels,lgamma,library,%
licence,license,lines,list,lm,load,local,locator,log,log10,log1p,%
log2,logical,loglin,lower,lowess,ls,lsfit,lsf,ls,machine,Machine,%
mad,mahalanobis,make,link,margin,match,Math,matlines,mat,matplot,%
matpoints,matrix,max,mean,median,memory,menu,merge,methods,min,%
missing,Mod,mode,model,response,mosaicplot,mtext,mvfft,na,nan,%
names,omit,nargs,nchar,ncol,NCOL,new,next,NextMethod,nextn,%
nlevels,nlm,noquote,NotYetImplemented,NotYetUsed,nrow,NROW,null,%
numeric,\%o\%,objects,offset,old,on,Ops,optim,optimise,optimize,%
options,or,order,ordered,outer,package,packages,page,pairlist,%
pairs,palette,panel,par,parent,parse,paste,path,pbeta,pbinom,%
pcauchy,pchisq,pentagamma,persp,pexp,pf,pgamma,pgeom,phyper,pico,%
pictex,piechart,Platform,plnorm,plogis,plot,pmatch,pmax,pmin,%
pnbinom,pnchisq,pnorm,points,poisson,poly,polygon,polyroot,pos,%
postscript,power,ppoints,ppois,predict,preplot,pretty,Primitive,%
print,prmatrix,proc,prod,profile,proj,prompt,prop,provide,%
psignrank,ps,pt,ptukey,punif,pweibull,pwilcox,q,qbeta,qbinom,%
qcauchy,qchisq,qexp,qf,qgamma,qgeom,qhyper,qlnorm,qlogis,qnbinom,%
qnchisq,qnorm,qpois,qqline,qqnorm,qqplot,qr,Q,qty,qy,qsignrank,%
qt,qtukey,quantile,quasi,quit,qunif,quote,qweibull,qwilcox,%
rainbow,range,rank,rbeta,rbind,rbinom,rcauchy,rchisq,Re,read,csv,%
csv2,fwf,readline,socket,real,Recall,rect,reformulate,regexpr,%
relevel,remove,rep,repeat,replace,replications,report,require,%
resid,residuals,restart,return,rev,rexp,rf,rgamma,rgb,rgeom,R,%
rhyper,rle,rlnorm,rlogis,rm,rnbinom,RNGkind,rnorm,round,row,%
rownames,rowsum,rpois,rsignrank,rstandard,rstudent,rt,rug,runif,%
rweibull,rwilcox,sample,sapply,save,scale,scan,scan,screen,sd,se,%
search,searchpaths,segments,seq,sequence,setdiff,setequal,set,%
setwd,show,sign,signif,sin,single,sinh,sink,solve,sort,source,%
spline,splinefun,split,sqrt,stars,start,stat,stem,step,stop,%
storage,strstrheight,stripplot,strsplit,structure,strwidth,sub,%
subset,substitute,substr,substring,sum,summary,sunflowerplot,svd,%
sweep,switch,symbol,symbols,symnum,sys,status,system,t,table,%
tabulate,tan,tanh,tapply,tempfile,terms,terrain,tetragamma,text,%
time,title,topo,trace,traceback,transform,tri,trigamma,trunc,try,%
ts,tsp,typeof,unclass,undebug,undoc,union,unique,uniroot,unix,%
unlink,unlist,unname,untrace,update,upper,url,UseMethod,var,%
variable,vector,Version,vi,warning,warnings,weighted,weights,%
which,while,window,write,\%x\%,x11,X11,xedit,xemacs,xinch,xor,%
xpdrows,xy,xyinch,yinch,zapsmall,zip},%
otherkeywords={!,!=,~,$,*,\&,\%/\%,\%*\%,\%\%,<-,<<-,_,/},%
alsoother={._$},%
sensitive,%
morecomment=[l]\#,%
morestring=[d]",%
morestring=[d]'% 2001 Robert Denham
}%
\lst@definelanguage{SAS}%
{procnamekeys={proc},%
morekeywords={DATA,AND,OR,NOT,EQ,GT,LT,GE,LE,NE,INFILE,INPUT,DO,BY,%
TO,SIN,COS,OUTPUT,END,PLOT,RUN,LIBNAME,VAR,TITLE,FIRSTOBS,OBS,%
DELIMITER,DLM,EOF,ABS,DIM,HBOUND,LBOUND,MAX,MIN,MOD,SIGN,SQRT,%
CEIL,FLOOR,FUZZ,INT,ROUND,TRUNC,DIGAMMA,ERF,ERFC,EXP,GAMMA,%
LGAMMA,LOG,LOG2,LOG10,ARCOS,ARSIN,ATAN,COSH,SINH,TANH,TAN,%
POISSON,PROBBETA,PROBBNML,PROBCHI,PROBF,PROBGAM,PROBHYPR,%
PROBNEGB,PROBNORM,PROBT,BETAINV,CINV,FINV,GAMINV,PROBIT,TINV,CSS,%
CV,KURTOSIS,MEAN,NMISS,RANGE,SKEWNESS,STD,STDERR,SUM,USS,NORMAL,%
RANBIN,RANCAU,RANEXP,RANGAM,RANNOR,RANPOI,RANTBL,RANTRI,RANUNI,%
UNIFORM,IF,THEN,ELSE,WHILE,UNTIL,DROP,KEEP,LABEL,DEFAULT,ARRAY,%
MERGE,CARDS,CARDS4,PUT,SET,UPDATE,ABORT,DELETE,DISPLAY,LIST,%
LOSTCARD,MISSING,STOP,WHERE,ARRAY,DROP,KEEP,WINDOW,LENGTH,RENAME,%
RETAIN,MEANS,UNIVARIATE,SUMMARY,TABULATE,CORR,FREQ,FOOTNOTE,NOTE,%
SHOW},%
otherkeywords={!,!=,~,$,*,\&,_,/,<,>=,=<,>},%
morestring=[d]'%
}[keywords,comments,strings,procnames]%
\lst@definelanguage[AlLaTeX]{TeX}[LaTeX]{TeX}%
{moretexcs={AtBeginDocument,AtBeginDvi,AtEndDocument,AtEndOfClass,%
AtEndOfPackage,ClassError,ClassInfo,ClassWarning,%
ClassWarningNoLine,CurrentOption,DeclareErrorFont,%
DeclareFixedFont,DeclareFontEncoding,DeclareFontEncodingDefaults,%
DeclareFontFamily,DeclareFontShape,DeclareFontSubstitution,%
DeclareMathAccent,DeclareMathAlphabet,DeclareMathAlphabet,%
DeclareMathDelimiter,DeclareMathRadical,DeclareMathSizes,%
DeclareMathSymbol,DeclareMathVersion,DeclareOldFontCommand,%
DeclareOption,DeclarePreloadSizes,DeclareRobustCommand,%
DeclareSizeFunction,DeclareSymbolFont,DeclareSymbolFontAlphabet,%
DeclareTextAccent,DeclareTextAccentDefault,DeclareTextCommand,%
DeclareTextCommandDefault,DeclareTextComposite,%
DeclareTextCompositeCommand,DeclareTextFontCommand,%
DeclareTextSymbol,DeclareTextSymbolDefault,ExecuteOptions,%
GenericError,GenericInfo,GenericWarning,IfFileExists,%
InputIfFileExists,LoadClass,LoadClassWithOptions,MessageBreak,%
OptionNotUsed,PackageError,PackageInfo,PackageWarning,%
PackageWarningNoLine,PassOptionsToClass,PassOptionsToPackage,%
ProcessOptionsProvidesClass,ProvidesFile,ProvidesFile,%
ProvidesPackage,ProvideTextCommand,RequirePackage,%
RequirePackageWithOptions,SetMathAlphabet,SetSymbolFont,%
TextSymbolUnavailable,UseTextAccent,UseTextSymbol},%
morekeywords={array,center,displaymath,document,enumerate,eqnarray,%
equation,flushleft,flushright,itemize,list,lrbox,math,minipage,%
picture,sloppypar,tabbing,tabular,trivlist,verbatim}%
}%
\lst@definelanguage[LaTeX]{TeX}[common]{TeX}%
{moretexcs={a,AA,aa,addcontentsline,addpenalty,addtocontents,%
addtocounter,addtolength,addtoversion,addvspace,alph,Alph,and,%
arabic,array,arraycolsep,arrayrulewidth,arraystretch,author,%
baselinestretch,begin,bezier,bfseries,bibcite,bibdata,bibitem,%
bibliography,bibliographystyle,bibstyle,bigskip,boldmath,%
botfigrule,bottomfraction,Box,caption,center,CheckCommand,circle,%
citation,cite,cleardoublepage,clearpage,cline,columnsep,%
columnseprule,columnwidth,contentsline,dashbox,date,dblfigrule,%
dblfloatpagefraction,dblfloatsep,dbltextfloatsep,dbltopfraction,%
defaultscriptratio,defaultscriptscriptratio,depth,Diamond,%
displaymath,document,documentclass,documentstyle,doublerulesep,%
em,emph,endarray,endcenter,enddisplaymath,enddocument,%
endenumerate,endeqnarray,endequation,endflushleft,endflushright,%
enditemize,endlist,endlrbox,endmath,endminipage,endpicture,%
endsloppypar,endtabbing,endtabular,endtrivlist,endverbatim,%
enlargethispage,ensuremath,enumerate,eqnarray,equation,%
evensidemargin,extracolsep,fbox,fboxrule,fboxsep,filecontents,%
fill,floatpagefraction,floatsep,flushbottom,flushleft,flushright,%
fnsymbol,fontencoding,fontfamily,fontseries,fontshape,fontsize,%
fontsubfuzz,footnotemark,footnotesep,footnotetext,footskip,frac,%
frame,framebox,fussy,glossary,headheight,headsep,height,hline,%
hspace,I,include,includeonly,index,inputlineno,intextsep,%
itemindent,itemize,itemsep,iterate,itshape,Join,kill,label,%
labelsep,labelwidth,LaTeX,LaTeXe,leadsto,lefteqn,leftmargin,%
leftmargini,leftmarginii,leftmarginiii,leftmarginiv,leftmarginv,%
leftmarginvi,leftmark,lhd,lim,linebreak,linespread,linethickness,%
linewidth,list,listfiles,listfiles,listparindent,lrbox,%
makeatletter,makeatother,makebox,makeglossary,makeindex,%
makelabel,MakeLowercase,MakeUppercase,marginpar,marginparpush,%
marginparsep,marginparwidth,markboth,markright,math,mathbf,%
mathellipsis,mathgroup,mathit,mathrm,mathsf,mathsterling,mathtt,%
mathunderscore,mathversion,mbox,mdseries,mho,minipage,%
multicolumn,multiput,NeedsTeXFormat,newcommand,newcounter,%
newenvironment,newfont,newhelp,newlabel,newlength,newline,%
newmathalphabet,newpage,newsavebox,newtheorem,nobreakspace,%
nobreakspace,nocite,nocorr,nocorrlist,nofiles,nolinebreak,%
nonumber,nopagebreak,normalcolor,normalfont,normalmarginpar,%
numberline,obeycr,oddsidemargin,oldstylenums,onecolumn,oval,%
pagebreak,pagenumbering,pageref,pagestyle,paperheight,paperwidth,%
paragraphmark,parbox,parsep,partopsep,picture,poptabs,pounds,%
protect,pushtabs,put,qbezier,qbeziermax,r,raggedleft,raisebox,%
ref,refstepcounter,renewcommand,renewenvironment,restorecr,%
reversemarginpar,rhd,rightmargin,rightmark,rmfamily,roman,Roman,%
rootbox,rule,samepage,sbox,scshape,secdef,section,sectionmark,%
selectfont,setcounter,settodepth,settoheight,settowidth,sffamily,%
shortstack,showoutput,showoverfull,sloppy,sloppypar,slshape,%
smallskip,sqsubset,sqsupset,SS,stackrel,stepcounter,stop,stretch,%
subparagraphmark,subsectionmark,subsubsectionmark,sum,%
suppressfloats,symbol,tabbing,tabbingsep,tabcolsep,tabular,%
tabularnewline,textasciicircum,textasciitilde,textbackslash,%
textbar,textbf,textbraceleft,textbraceright,textbullet,%
textcircled,textcompwordmark,textdagger,textdaggerdbl,textdollar,%
textellipsis,textemdash,textendash,textexclamdown,textfloatsep,%
textfraction,textgreater,textheight,textit,textless,textmd,%
textnormal,textparagraph,textperiodcentered,textquestiondown,%
textquotedblleft,textquotedblright,textquoteleft,textquoteright,%
textregistered,textrm,textsc,textsection,textsf,textsl,%
textsterling,textsuperscript,texttrademark,texttt,textunderscore,%
textup,textvisiblespace,textwidth,thanks,thefootnote,thempfn,%
thempfn,thempfootnote,thepage,thepage,thicklines,thinlines,%
thispagestyle,title,today,topfigrule,topfraction,topmargin,%
topsep,totalheight,tracingfonts,trivlist,ttfamily,twocolumn,%
typein,typeout,unboldmath,unitlength,unlhd,unrhd,upshape,usebox,%
usecounter,usefont,usepackage,value,vector,verb,verbatim,vline,%
vspace,width,%
normalsize,small,footnotesize,scriptsize,tiny,large,Large,LARGE,%
huge,Huge}%
}%
\lst@definelanguage[plain]{TeX}[common]{TeX}%
{moretexcs={advancepageno,beginsection,bf,bffam,bye,cal,cleartabs,%
columns,dosupereject,endinsert,eqalign,eqalignno,fiverm,fivebf,%
fivei,fivesy,folio,footline,hang,headline,it,itemitem,itfam,%
leqalignno,magnification,makefootline,makeheadline,midinsert,mit,%
mscount,nopagenumbers,normalbottom,of,oldstyle,pagebody,%
pagecontents,pageinsert,pageno,plainoutput,preloaded,proclaim,rm,%
settabs,sevenbf,seveni,sevensy,sevenrm,sl,slfam,supereject,%
tabalign,tabs,tabsdone,tabsyet,tenbf,tenex,teni,tenit,tenrm,%
tensl,tensy,tentt,textindent,topglue,topins,topinsert,tt,ttfam,%
ttraggedright,vfootnote}%
}%
\lst@definelanguage[common]{TeX}[primitive]{TeX}
{moretexcs={active,acute,ae,AE,aleph,allocationnumber,allowbreak,%
alpha,amalg,angle,approx,arccos,arcsin,arctan,arg,arrowvert,%
Arrowvert,ast,asymp,b,backslash,bar,beta,bgroup,big,Big,bigbreak,%
bigcap,bigcirc,bigcup,bigg,Bigg,biggl,Biggl,biggm,Biggm,biggr,%
Biggr,bigl,Bigl,bigm,Bigm,bigodot,bigoplus,bigotimes,bigr,Bigr,%
bigskip,bigskipamount,bigsqcup,bigtriangledown,bigtriangleup,%
biguplus,bigvee,bigwedge,bmod,bordermatrix,bot,bowtie,brace,%
braceld,bracelu,bracerd,braceru,bracevert,brack,break,breve,%
buildrel,bullet,c,cap,cases,cdot,cdotp,cdots,centering,%
centerline,check,chi,choose,circ,clubsuit,colon,cong,coprod,%
copyright,cos,cosh,cot,coth,csc,cup,d,dag,dagger,dashv,ddag,%
ddagger,ddot,ddots,deg,delta,Delta,det,diamond,diamondsuit,dim,%
displaylines,div,do,dospecials,dot,doteq,dotfill,dots,downarrow,%
Downarrow,downbracefill,egroup,eject,ell,empty,emptyset,endgraf,%
endline,enskip,enspace,epsilon,equiv,eta,exists,exp,filbreak,%
flat,fmtname,fmtversion,footins,footnote,footnoterule,forall,%
frenchspacing,frown,gamma,Gamma,gcd,ge,geq,gets,gg,goodbreak,%
grave,H,hat,hbar,heartsuit,hglue,hideskip,hidewidth,hom,%
hookleftarrow,hookrightarrow,hphantom,hrulefill,i,ialign,iff,Im,%
imath,in,inf,infty,int,interdisplaylinepenalty,%
interfootnotelinepenalty,intop,iota,item,j,jmath,joinrel,jot,%
kappa,ker,l,L,lambda,Lambda,land,langle,lbrace,lbrack,lceil,%
ldotp,ldots,le,leavevmode,leftarrow,Leftarrow,leftarrowfill,%
leftharpoondown,leftharpoonup,leftline,leftrightarrow,%
Leftrightarrow,leq,lfloor,lg,lgroup,lhook,lim,liminf,limsup,line,%
ll,llap,lmoustache,ln,lnot,log,longleftarrow,Longleftarrow,%
longleftrightarrow,Longleftrightarrow,longmapsto,longrightarrow,%
Longrightarrow,loop,lor,lq,magstep,magstep,magstephalf,mapsto,%
mapstochar,mathhexbox,mathpalette,mathstrut,matrix,max,maxdimen,%
medbreak,medskip,medskipamount,mid,min,models,mp,mu,multispan,%
nabla,narrower,natural,ne,nearrow,neg,negthinspace,neq,newbox,%
newcount,newdimen,newfam,newif,newinsert,newlanguage,newmuskip,%
newread,newskip,newtoks,newwrite,next,ni,nobreak,nointerlineskip,%
nonfrenchspacing,normalbaselines,normalbaselineskip,%
normallineskip,normallineskiplimit,not,notin,nu,null,nwarrow,o,O,%
oalign,obeylines,obeyspaces,odot,oe,OE,offinterlineskip,oint,%
ointop,omega,Omega,ominus,ooalign,openup,oplus,oslash,otimes,%
overbrace,overleftarrow,overrightarrow,owns,P,parallel,partial,%
perp,phantom,phi,Phi,pi,Pi,pm,pmatrix,pmod,Pr,prec,preceq,prime,%
prod,propto,psi,Psi,qquad,quad,raggedbottom,raggedright,rangle,%
rbrace,rbrack,rceil,Re,relbar,Relbar,removelastskip,repeat,%
rfloor,rgroup,rho,rhook,rightarrow,Rightarrow,rightarrowfill,%
rightharpoondown,rightharpoonup,rightleftharpoons,rightline,rlap,%
rmoustache,root,rq,S,sb,searrow,sec,setminus,sharp,showhyphens,%
sigma,Sigma,sim,simeq,sin,sinh,skew,slash,smallbreak,smallint,%
smallskip,smallskipamount,smash,smile,sp,space,spadesuit,sqcap,%
sqcup,sqrt,sqsubseteq,sqsupseteq,ss,star,strut,strutbox,subset,%
subseteq,succ,succeq,sum,sup,supset,supseteq,surd,swarrow,t,tan,%
tanh,tau,TeX,theta,Theta,thinspace,tilde,times,to,top,tracingall,%
triangle,triangleleft,triangleright,u,underbar,underbrace,%
uparrow,Uparrow,upbracefill,updownarrow,Updownarrow,uplus,%
upsilon,Upsilon,v,varepsilon,varphi,varpi,varrho,varsigma,%
vartheta,vdash,vdots,vec,vee,vert,Vert,vglue,vphantom,wedge,%
widehat,widetilde,wlog,wp,wr,xi,Xi,zeta}%
}%
\lst@definelanguage[primitive]{TeX}%
{moretexcs={above,abovedisplayshortskip,abovedisplayskip,aftergroup,%
abovewithdelims,accent,adjdemerits,advance,afterassignment,atop,%
atopwithdelims,badness,baselineskip,batchmode,begingroup,%
belowdisplayshortskip,belowdisplayskip,binoppenalty,botmark,box,%
boxmaxdepth,brokenpenalty,catcode,char,chardef,cleaders,closein,%
closeout,clubpenalty,copy,count,countdef,cr,crcr,csname,day,%
deadcycles,def,defaulthyphenchar,defaultskewchar,delcode,%
delimiter,delimiterfactor,delimitershortfall,dimen,dimendef,%
discretionary,displayindent,displaylimits,displaystyle,%
displaywidowpenalty,displaywidth,divide,doublehyphendemerits,dp,%
edef,else,emergencystretch,end,endcsname,endgroup,endinput,%
endlinechar,eqno,errhelp,errmessage,errorcontextlines,%
errorstopmode,escapechar,everycr,everydisplay,everyhbox,everyjob,%
everymath,everypar,everyvbox,exhyphenpenalty,expandafter,fam,fi,%
finalhypendemerits,firstmark,floatingpenalty,font,fontdimen,%
fontname,futurelet,gdef,global,globaldefs,halign,hangafter,%
hangindent,hbadness,hbox,hfil,hfill,hfilneg,hfuzz,hoffset,%
holdinginserts,hrule,hsize,hskip,hss,ht,hyphenation,hyphenchar,%
hyphenpenalty,if,ifcase,ifcat,ifdim,ifeof,iffalse,ifhbox,ifhmode,%
ifinner,ifmmode,ifnum,ifodd,iftrue,ifvbox,ifvmode,ifvoid,ifx,%
ignorespaces,immediate,indent,input,insert,insertpenalties,%
interlinepenalty,jobname,kern,language,lastbox,lastkern,%
lastpenalty,lastskip,lccode,leaders,left,lefthyphenmin,leftskip,%
leqno,let,limits,linepenalty,lineskip,lineskiplimits,long,%
looseness,lower,lowercase,mag,mark,mathaccent,mathbin,mathchar,%
mathchardef,mathchoice,mathclose,mathcode,mathinner,mathop,%
mathopen,mathord,mathpunct,mathrel,mathsurround,maxdeadcycles,%
maxdepth,meaning,medmuskip,message,mkern,month,moveleft,%
moveright,mskip,multiply,muskip,muskipdef,newlinechar,noalign,%
noboundary,noexpand,noindent,nolimits,nonscript,nonstopmode,%
nulldelimiterspace,nullfont,number,omit,openin,openout,or,outer,%
output,outputpenalty,over,overfullrule,overline,overwithdelims,%
pagedepth,pagefilllstretch,pagefillstretch,pagefilstretch,%
pagegoal,pageshrink,pagestretch,pagetotal,par,parfillskip,%
parindent,parshape,parskip,patterns,pausing,penalty,%
postdisplaypenalty,predisplaypenalty,predisplaysize,pretolerance,%
prevdepth,prevgraf,radical,raise,read,relax,relpenalty,right,%
righthyphenmin,rightskip,romannumeral,scriptfont,%
scriptscriptfont,scriptscriptstyle,scriptspace,scriptstyle,%
scrollmode,setbox,setlanguage,sfcode,shipout,show,showbox,%
showboxbreadth,showboxdepth,showlists,showthe,skewchar,skip,%
skipdef,spacefactor,spaceskip,span,special,splitbotmark,%
splitfirstmark,splitmaxdepth,splittopskip,string,tabskip,%
textfont,textstyle,the,thickmuskip,thinmuskip,time,toks,toksdef,%
tolerance,topmark,topskip,tracingcommands,tracinglostchars,%
tracingmacros,tracingonline,tracingoutput,tracingpages,%
tracingparagraphs,tracingrestores,tracingstats,uccode,uchyph,%
underline,unhbox,unhcopy,unkern,unpenalty,unskip,unvbox,unvcopy,%
uppercase,vadjust,valign,vbadness,vbox,vcenter,vfil,vfill,%
vfilneg,vfuzz,voffset,vrule,vsize,vskip,vsplit,vss,vtop,wd,%
widowpenalty,write,xdef,xleaders,xspaceskip,year},%
sensitive,%
alsoother={0123456789$_},%
morecomment=[l]\%%
}[keywords,tex,comments]%
\endinput
%%
%% End of file `lstlang3.sty'.

Разница между файлами не показана из-за своего большого размера Загрузить разницу

@ -1,464 +0,0 @@
%%
%% This is file `lstpatch.sty', generated manually.
%%
%% Please read the software license in listings.dtx or listings.dvi.
%%
%% (w)(c) 2002 Carsten Heinz
%%
%% This file is distributed under the terms of the LaTeX Project Public
%% License from CTAN archives in directory macros/latex/base/lppl.txt.
%% Either version 1.0 or, at your option, any later version.
%%
%% Send comments and ideas on the package, error reports and additional
%% programming languages to <cheinz@gmx.de>.
%%
%% This patch file will remove the following bugs from the listings package.
%% Each item contains the bug finder with date of report and first bug fix
%% version, a short description of the problem, and the reason for the bug
%% in parenthesis.
%%
%% 1) Jochen Schneider, 2002/04/03, 1.0a (2002/04/05)
%%
%% undefined control sequence \lst@CommentB with HTML, XML, tcl
%% (I didn't renamed them to \lst@DefDelimB|E)
%%
%% 2) Michael Niedermair, 2002/04/07, 1.0b
%%
%% undefined control sequence \lst@commentmode with XML
%% (mode not defined any more)
%%
%% 3) Carsten Heinz, 2002/04/08, 1.0b
%%
%% bad PODs (investigating bugs 1 and 2)
%% (definition doesn't use 1.0 style)
%%
%% 4) Peter Bartke, 2002/04/10, 1.0b
%%
%% various problems with fancyvrb interface: string ".5" at beginning
%% of first line when using lineskip; ditto "perhaps a missing \item
%% error"; wrong placed characters , and - when using fancyvrb
%% (bad use of \strip@pt; TeX is not in vertical mode when leaving
%% Verbatim; bad `noligs' handling)
%%
%% 5) Rolf Niepraschk, 2002/04/12, 1.0b
%%
%% \RequirePackage is missing keywordstyle when near the top of a page
%% (\lst@lastother not saved away across page breaks)
%%
%% 6) Peter Ruckdeschel, 2002/04/12, 1.0b
%% Timothy Van Zandt analyzed and fixed the bug
%%
%% incompatibility with seminar class
%% (bad assignment of \lst@do@noligs in \lst@SelectCharTable)
%%
%% 7) Rene H. Larsen, 2002/04/12, 1.0b
%%
%% \lstinputlistings and texcl conflict
%% (^^M not active to reenter modes)
%%
%% 8) Carsten Heinz, 2002/04/15, 1.0b (2002/04/15)
%%
%% gobble doesn't always work (investigating problem with VTeX)
%% (\lst@BOLGobble@ must test against \lst@Process{FormFeed|Tabulator}X)
%%
%% 9) Peter Bartke, 2002/04/17, 1.0c
%%
%% TeX capacity exceeded with fancyvrb
%% (\let\lst@entermodes\@empty must stay in \lstFV@VerbatimBegin)
%%
%% 10) Svend Tollak Munkejord, 2002/04/17, 1.0c
%% Heiko Oberdiek analyzed and fixed the bug
%%
%% package incompatible with Lucida .fd files
%% (parentheses have active catcodes when reading the file)
%%
%% 11) Carsten Hamm, 2002/04/19, 1.0c (2002/04/24)
%%
%% wrong frame rules with breaklines and xleftmargin>0pt
%% (missing \kern-\lst@xleftmargin in \lst@discretionary)
%%
%% 12) Michael Niedermair, 2002/05/14, 1.0d
%%
%% backgroundcolor take effect on bottom captions
%% (wrong order of \everypar{} and \lsthk@ExitVars in \lst@DeInit)
%%
%% 13) Georg Rehm, 2002/05/14, 1.0d
%%
%% bad baselineskip with captionpos=b
%% (missing \normalbaselines)
%%
%% 14) Herfried Karl Wagner, 2002/05/11, 1.0d
%%
%% undefined control sequence \lst@entermodes
%% (\output called before first \lst@EnterMode)
%%
%% 15) Peter K\"oller, 2002/05/24, 1.0d
%%
%% XML keywords don't have keywordstyle
%% (missing \ifx... in implementation of contentsstyle)
%%
%% 16) Stephen Reindl, 2002/05/28, 1.0d
%%
%% \inaccessible using Cobol
%% (\lst@Delim@option didn't enclose option in [])
%%
%% 17) Stephen Reindl, 2002/06/04, 1.0d (2002/06/12)
%%
%% frames not deactivated for text style listings
%%
%% 18) Carsten Heinz, 2002/07/27, 1.0e (2002/07/31)
%%
%% broken keywordcomments
%% (\lst@KCpost inside group level 2; bad \lst@BeginComment call)
%%
%% 19) Kris Luyten, 2002/07/30, 1.0f (2002/08/03)
%%
%% Undefined control sequence \lst@thestyle
%% (undefined \lst@directives after _loading_ C)
%%
%% 20) Kris Luyten, 2002/08/03, 1.0g (2002/08/06)
%%
%% Undefined control sequence \lst@thestyle
%% (side effect of 19-bugfix on \lst@ProvideFamily)
%%
%% 21) Venkatesh Prasad Ranganath, 2002/08/31, 1.0h
%%
%% Undefined control sequence \thelstnumber with 0.21-option
%% (\let must be changed to a \def inition)
%%
%% 22) Fermin Reig, 2002/09/04, 1.0h (2002/09/09)
%%
%% Bad top frame inside figure+centering
%% (reset of leftskip, rightskip and parfillskip comes too late)
%%
%% 23) Hermann H\"uttler, 2002/10/05, 1.0i (2002/10/13)
%%
%% C++-string "... \\" does not end with second double quote
%% (missing \let\lst@lastother\@empty in old fix)
%%
%%
%% Moreover the following functionality is added.
%%
%% a) option "final" (Rolf Niepraschk, Enrico Straube)
%%
%% b) keys "fvcmdparams" and "morefvcmdparams" (Denis Girou)
%%
%% c) key "contentstyle" (Peter K\"oller)
%%
%% d) key "numberfirstline" (Georg Rehm)
%%
%%
\ProvidesFile{lstpatch.sty}[2002/10/13 1.0i (Carsten Heinz)]
\lst@CheckVersion{1.0}
{\typeout{^^J%
***^^J%
*** This is a patch for `listings.sty' version 1.0, but^^J%
*** you're using version \lst@version.^^J%
***^^J
*** Patch file not loaded.^^J%
***^^J}%
\endinput
}
%
% 1) Define the missing control sequences. (Not needed any more.)
\def\lstpatch@comments{%
\global\let\lst@CommentB\lst@DefDelimB
\global\let\lst@CommentE\lst@DefDelimE}
%
% 2) Define \lst@commentmode.
\lst@NewMode\lst@commentmode
%
% 3) Introduce \lst@ifxpodcomment as master-clause and define 1.0 style
% contents for SelectCharTable.
\def\lstpatch@pod{%
\lst@Key{podcomment}{false}[t]{\lstKV@SetIf{##1}\lst@ifxpodcomment}%
\lst@AddToHookExe{SetLanguage}{\let\lst@ifxpodcomment\iffalse}%
\lst@AddToHook{SelectCharTable}%
{\lst@ifxpodcomment
\lst@CArgX =\relax\lst@DefDelimB{}{}%
{\ifnum\@tempcnta=\z@
\lst@ifprintpod\else
\def\lst@bnext{\lst@BeginDropOutput\lst@PODmode}%
\expandafter\expandafter\expandafter\@gobblethree
\fi
\else
\expandafter\@gobblethree
\fi}%
\lst@BeginComment\lst@PODmode{{\lst@commentstyle}}% modified
\lst@CArgX =cut\^^M\relax\lst@DefDelimE
{\lst@CalcColumn}%
{\ifnum\@tempcnta=\z@\else
\expandafter\@gobblethree
\fi}%
{}%
\lst@EndComment\lst@PODmode
\fi}%
}
%
% 4) Redefine lineskip like podcomment above and don't use \strip@pt
% together with \divide.
\def\lstpatch@lineshape{%
\lst@Key{lineskip}{\z@}{\def\lst@xlineskip{##1\relax}}
\lst@AddToHook{Init}
{\ifdim\z@=\lst@xlineskip\else
\@tempdima\baselineskip
\advance\@tempdima\lst@xlineskip
\multiply\@tempdima\@cclvi
\divide\@tempdima\baselineskip\relax
\multiply\@tempdima\@cclvi
\edef\baselinestretch{\strip@pt\@tempdima}%
\selectfont
\fi}%
% 11) Add \kern-\lst@xleftmargin.
\gdef\lst@discretionary{%
\discretionary{\let\space\lst@spacekern\lst@prebreak}%
{\llap{\lsthk@EveryLine
\kern\lst@breakcurrindent\kern-\lst@xleftmargin}%
\let\space\lst@spacekern\lst@postbreak}{}}%
}
% Back to 4): Insert \par for vertical mode.
\def\lstpatch@fancyvrb{%
\gdef\lstFV@VerbatimEnd{%
\ifx\FancyVerbFormatLine\lstFV@FancyVerbFormatLine
\global\setbox\lstFV@gtempboxa\box\@tempboxa
\global\let\@gtempa\FV@ProcessLine
\lst@mode\lst@Pmode
\lst@DeInit
\let\FV@ProcessLine\@gtempa
\setbox\@tempboxa\box\lstFV@gtempboxa
\par % modified
\fi}%
% 9) Redefined \lstFV@VerbatimBegin removed.
% b) Refine conversion definitions to either work as usual or to ...
\gdef\lst@FVConvert{\@tempcnta\z@ \lst@FVConvertO@}%
\gdef\lst@FVConvertO@{%
\ifcase\@tempcnta \expandafter
\futurelet\expandafter\@let@token\expandafter\lst@FVConvert@@
\else
% append arguments as they are.
\expandafter\lst@FVConvertO@a
\fi}%
\gdef\lst@FVConvertO@a##1{%
\lst@lAddTo\lst@arg{{##1}}\advance\@tempcnta\m@ne
\lst@FVConvertO@}%
% Here, ...
\gdef\lst@FVConvert@##1{%
\ifx \@nil##1\else
\if\relax\noexpand##1%
\lst@lAddTo\lst@arg{\lst@OutputLostSpace\lst@PrintToken##1}%
% ... actually here, we check for commands with arguments and set the
% value of \@tempcnta as required.
\def\lst@temp####1,##1####2,####3####4\relax{%
\ifx####3\@empty \else \@tempcnta####2\relax \fi}%
\expandafter\lst@temp\lst@FVcmdparams,##1\z@,\@empty\relax
\else
\lccode`\~=`##1\lowercase{\lst@lAddTo\lst@arg~}%
\fi
\expandafter\lst@FVConvertO@
\fi}
% Eventually we define user keys to adjust \lst@FVcmdparams. The base
% set of commands and parameter numbers was provided by Denis Girou.
\lst@Key{fvcmdparams}%
% D.G. suggestion begin - 2002/05/31
{\overlay\@ne}%
% D.G. suggestion end
{\def\lst@FVcmdparams{,##1}}%
\lst@Key{morefvcmdparams}\relax{\lst@lAddTo\lst@FVcmdparams{,##1}}%
}
%
% 5) Extend \lst@SaveToken to save \lst@lastother.
\def\lst@SaveToken{%
\global\let\lst@gthestyle\lst@thestyle
\global\let\lst@glastother\lst@lastother
\xdef\lst@RestoreToken{\noexpand\lst@token{\the\lst@token}%
\noexpand\lst@length\the\lst@length\relax
\noexpand\let\noexpand\lst@thestyle
\noexpand\lst@gthestyle
\noexpand\let\noexpand\lst@lastother
\noexpand\lst@glastother}%
}
%
% 6) Assign \lst@do@noligs to \do.
\def\lst@SelectCharTable{%
\lst@SelectStdCharTable
\lst@ifactivechars
\catcode9\active \catcode12\active \catcode13\active
\@tempcnta=32\relax
\@whilenum\@tempcnta<128\do
{\catcode\@tempcnta\active\advance\@tempcnta\@ne}%
\fi
\lst@ifec \lst@DefEC \fi
\let\do\lst@do@noligs \verbatim@nolig@list % modified
\lsthk@SelectCharTable
\lst@DeveloperSCT
\ifx\lst@Backslash\relax\else
\lst@LetSaveDef{"5C}\lsts@backslash\lst@Backslash
\fi}
% 4)+6) And we need correct versions of \lst@do@noligs[@].
\def\lst@do@noligs#1{%
\begingroup \lccode`\~=`#1\lowercase{\endgroup
\lst@do@noligs@~}}
\def\lst@do@noligs@#1{%
\expandafter\expandafter\expandafter\def
\expandafter\expandafter\expandafter#1%
\expandafter\expandafter\expandafter{\expandafter\lst@NoLig#1}}
%
% 7) Make ^^M active.
\def\lst@InputListing#1{%
\begingroup
\lsthk@PreSet \gdef\lst@intname{#1}%
\expandafter\lstset\expandafter{\lst@set}%
\lsthk@DisplayStyle
\catcode\active=\active % added
\lst@Init\relax \let\lst@gobble\z@
\lst@SkipToFirst
\lst@ifprint \def\lst@next{\input{#1}}%
\else \let\lst@next\@empty \fi
\lst@next
\lst@DeInit
\endgroup}
%
% 8) Replace \lst@Process{FormFeed|Tabulator}.
\def\lst@ProcessFormFeedX{\lst@ProcessFormFeed}
\def\lst@ProcessTabulatorX{\lst@ProcessTabulator}
\def\lst@BOLGobble@#1{%
\let\lst@next#1%
\ifx \lst@next\relax\else
\ifx \lst@next\lst@MProcessListing\else
\ifx \lst@next\lst@ProcessFormFeedX\else
\ifx \lst@next\lstenv@backslash
\let\lst@next\lstenv@BOLGobble@@
\else
\let\lst@next\lst@BOLGobble@@
\ifx #1\lst@ProcessTabulatorX
\advance\@tempcnta-\lst@tabsize\relax
\ifnum\@tempcnta<\z@
\lst@length-\@tempcnta \lst@PreGotoTabStop
\fi
\else
\advance\@tempcnta\m@ne
\fi
\fi \fi \fi \fi
\lst@next}
%
% 10) Add some \@makeother to \lst@nfss@catcodes.
\def\lst@nfss@catcodes{%
\lst@makeletter
ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz\relax
\@makeother (\@makeother )\@makeother ,\@makeother :\@makeother &%
\@makeother 0\@makeother 1\@makeother 2\@makeother 3\@makeother 4%
\@makeother 5\@makeother 6\@makeother 7\@makeother 8\@makeother 9%
\@makeother =\lsts@nfss@catcodes}
%
% 12) and 13) Deactivate \everypar and use normal baseline parameters.
\lst@AddToHook{DeInit}{\everypar{}\normalbaselines}
%
% 14) Define \lst@entermodes.
\let\lst@entermodes\@empty
%
% 16) Insert [ and ] in replacement text.
\def\lst@Delim@option[#1]{\def\lst@arg{[#1]}\lst@Delim@delim}
%
% 17) Just empty `frame' and top, right, bottom, and left shape.
\lst@AddToHook{TextStyle}
{\let\lst@frame\@empty
\let\lst@frametshape\@empty
\let\lst@framershape\@empty
\let\lst@framebshape\@empty
\let\lst@framelshape\@empty}
%
% 18) Execute \lst@BeginKC and \lst@BeginKCS outside the two groups.
% Modify third argument to \lst@BeginComment to work properly.
\def\lstpatch@keywordcomments{%
\gdef\lst@BeginKC{\aftergroup\aftergroup\aftergroup\lst@BeginKC@}%
\gdef\lst@BeginKC@{%
\lst@ResetToken
\lst@BeginComment\lst@KCmode{{\lst@commentstyle}\lst@modetrue}\@empty}%
\gdef\lst@BeginKCS{\aftergroup\aftergroup\aftergroup\lst@BeginKCS@}%
\gdef\lst@BeginKCS@{%
\lst@ResetToken
\lst@BeginComment\lst@KCSmode{{\lst@commentstyle}\lst@modetrue}\@empty}%
\gdef\lst@EndKC{\lst@SaveToken \lst@LeaveMode \lst@RestoreToken
\let\lst@thestyle\lst@identifierstyle \lsthk@Output}% renew style selection
}
%
% 19) Init \lst@directives.
\def\lstpatch@directives{%
\global\let\lst@directives\@empty}
%
% 20) Use new prefix for a family -- the now initialized \lst@directives
% clashes with the default.
\def\lstpatch@keywords{%
\gdef\lst@ProvideFamily##1{%
\@ifundefined{lstfam@##1\ifnum\@tempcnta=\@ne\else \the\@tempcnta \fi}%
{\@namedef{lstfam@##1\ifnum\@tempcnta=\@ne\else \the\@tempcnta \fi}{}%
\expandafter\expandafter\expandafter\lst@ProvideFamily@
\csname\@lst @##1@data\endcsname
{\ifnum\@tempcnta=\@ne\else \the\@tempcnta \fi}}%
{}}%
}
% 21) Define \thelstnumber every listing via \def.
\@namedef{lstpatch@021}{%
\lst@AddToHook{Init}{\def\thelstnumber{\thelstlabel}}%
}
% 22) Reset the registers in PreInit hook
\lst@AddToHook{PreInit}
{\rightskip\z@ \leftskip\z@ \parfillskip\z@ plus 1fil}
%
% 23) Add \let\lst@lastother\@empty
\lst@AddToHook{SelectCharTable}{%
\lst@ifbstring
\lst@CArgX \\\\\relax \lst@CDefX{}%
{\lst@ProcessOther\lstum@backslash
\lst@ProcessOther\lstum@backslash
\let\lst@lastother\@empty}%
{}%
\fi}
%
% a) Just declare the option.
\DeclareOption{final}{\let\lst@ifdraft\iffalse}
%
% c) Define contentstyle and use it.
\def\lstpatch@html{%
\lst@Key{contentstyle}{}{\def\lst@contentstyle{##1}}%
\lst@AddToHook{Init}%
{\ifx\lst@DefInside\@empty\else
\let\lst@tagstyle\lst@identifierstyle
\let\lst@identifierstyle\lst@contentstyle
\fi}%
\lst@AddToHook{Output}%
{\ifnum\lst@mode=\lst@insidemode
% 15) Check for keywordstyle.
\ifx\lst@thestyle\lst@gkeywords@sty\else
\lst@ifusekeysinside \let\lst@thestyle\lst@tagstyle
\else \let\lst@thestyle\lst@gkeywords@sty \fi
\fi\fi}%
\lst@AddToHook{OutputOther}%
{\lst@ifmode\else \ifnum\lst@mode=\lst@insidemode\else
\ifx\lst@DefInside\@empty\else
\let\lst@thestyle\lst@contentstyle
\fi
\fi\fi}%
}
%
% d) Define key and adjust \lst@SkipOrPrintLabel.
\def\lstpatch@labels{%
\lst@Key{numberfirstline}{f}[t]{\lstKV@SetIf{##1}\lst@ifnumberfirstline}%
\gdef\lst@numberfirstlinefalse{\let\lst@ifnumberfirstline\iffalse}
\gdef\lst@SkipOrPrintLabel{%
\ifnum\lst@skipnumbers=\z@
\global\advance\lst@skipnumbers-\lst@stepnumber\relax
\lst@PlaceNumber
\lst@numberfirstlinefalse
\else
\lst@ifnumberfirstline
\lst@PlaceNumber
\lst@numberfirstlinefalse
\fi
\fi
\global\advance\lst@skipnumbers\@ne}%
}
%%
\endinput
%%
%% End of file `lstpatch.sty'.

Разница между файлами не показана из-за своего большого размера Загрузить разницу

@ -1,854 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Available ORTE Components}
\label{sec:mca-orte}
There is currently only type of ORTE component that is visible to
users: \kind{boot}, which is used to start the Open MPI run-time
environment, most often through the \icmd{lamboot} command. The
\cmd{lamboot} command itself is discussed in
Section~\ref{sec:commands-lamboot}
(page~\pageref{sec:commands-lamboot}); the discussion below focuses on
the boot modules that make up the ``back end'' implementation of
\cmd{lamboot}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Using the Open Run-Time Environment}
\label{sec:mca-orte-pls}
\index{ORTE MCA components|(}
\index{MCA boot components|see {boot MCA components}}
{\Huge JMS needs massive overhaul}
Open MPI provides a number of modules for starting the \cmd{lamd}
control daemons. In most cases, the \cmd{lamd}s are started using the
\icmd{lamboot} command. In previous versions of Open MPI,
\icmd{lamboot} could only use \icmd{rsh} or \icmd{ssh} for starting
the Open MPI run-time environment on remote nodes. In Open MPI
\ompiversion, it is possible to use a variety of mechanisms for this
process startup. The following mechanisms are available in Open MPI
\ompiversion:
\begin{itemize}
\item BProc
\item Globus (beta-level support)
\item \cmd{rsh} / \cmd{ssh}
\item OpenPBS / PBS Pro / Torque (using the Task Management interface)
\changebegin{7.1}
\item SLURM (using its native interface)
\changeend{7.1}
\end{itemize}
These mechanisms are discussed in detail below. Note that the
sections below each assume that support for these modules have been
compiled into Open MPI. The \icmd{laminfo} command can be used to
determine exactly which modules are supported in your installation
(see Section~\ref{sec:commands-laminfo},
page~\pageref{sec:commands-laminfo}).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Boot Schema Files (a.k.a., ``Hostfiles'' or
``Machinefiles'')}
\label{sec:mca-orte-pls-schema}
\index{boot schema}
\index{hostfile|see {boot schema}}
\index{machinefile|see {boot schema}}
\cmdindex{lamboot}{boot schema file}
Before discussing any of the specific boot MCA modules, this section
discusses the boot schema file, commonly referred to as a ``hostfile''
or a ``machinefile''. Most (but not all) boot MCA modules require a
boot schema, and the text below makes frequent mention of them.
Hence, it is worth discussing them before getting into the details of
each boot MCA.
A boot schema is a text file that, in its simplest form, simply lists
every host that the Open MPI run-time environment will be invoked on. For
example:
\lstset{style=lam-shell}
\begin{lstlisting}
# This is my boot schema
inky.cluster.example.com
pinky.cluster.example.com
blinkly.cluster.example.com
clyde.cluster.example.com
\end{lstlisting}
Lines beginning with ``{\tt \#}'' are treated as comments and are
ignored. Each non-blank, non-comment line must, at a minimum, list a
host. Specifically, the first token on each line must specify a host
(although the definition of how that host is specified may vary differ
between boot modules).
However, each line can also specify arbitrary ``key=value'' pairs. A
common global key is ``{\tt cpu}''. This key takes an integer value
and indicates to Open MPI how many CPUs are available for Open MPI to use. If
the key is not present, the value of 1 is assumed. This number does
{\em not} need to reflect the physical number of CPUs -- it can be
smaller than, equal to, or greater than the number of physical CPUs in
the machine. It is solely used as a shorthand notation for
\icmd{mpirun}'s ``C'' notation, meaning ``launch one process per CPU
as specified in the boot schema file.'' For example, in the following
boot schema:
\lstset{style=lam-shell}
\begin{lstlisting}
inky.cluster.example.com cpu=2
pinky.cluster.example.com cpu=4
blinkly.cluster.example.com cpu=4
# clyde doesn't mention a cpu count, and is therefore implicitly 1
clyde.cluster.example.com
\end{lstlisting}
\noindent issuing the command ``{\tt mpirun C foo}'' would actually
launch 11 copies of \cmd{foo}: 2 on \host{inky}, 4 on \host{pinky}, 4
on \host{blinky}, and 1 on \host{clyde}.
Note that listing a host more than once has the same effect as
incrementing the CPU count. The following boot schema has the same
effect as the previous example (i.e., CPU counts of 2, 4, 4, and 1,
respectively):
\lstset{style=lam-shell}
\begin{lstlisting}
# inky has a CPU count of 2
inky.cluster.example.com
inky.cluster.example.com
# pinky has a CPU count of 4
pinky.cluster.example.com
pinky.cluster.example.com
pinky.cluster.example.com
pinky.cluster.example.com
# blinky has a CPU count of 4
blinkly.cluster.example.com
blinkly.cluster.example.com
blinkly.cluster.example.com
blinkly.cluster.example.com
# clyde only has 1 CPU
clyde.cluster.example.com
\end{lstlisting}
Other keys are defined on a per-boot-MCA-module, and are described
below.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Minimum Requirements}
\label{sec:mca-orte-pls-min-reqs}
In order to successfully launch a process on a remote node, several
requirements must be met. Although each of the boot modules have
different specific requirements, all of them share the following
conditions for successful operation:
\begin{enumerate}
\item Each target host must be reachable and operational.
\item The user must be able to execute arbitrary processes on the
target.
\item The Open MPI executables must be locatable on that machine. This
typically involves using: the shell's search path, the
\ienvvar{Open MPIHOME} environment variable, or a boot-module-specific
mechanism.
\item The user must be able to write to the Open MPI session directory
(typically somewhere under \file{/tmp}; see
Section~\ref{sec:misc-session-directory},
page~\pageref{sec:misc-session-directory}).
\item All hosts must be able to resolve the fully-qualified domain
name (FQDN) of all the machines being booted (including itself).
\item Unless there is only one host being booted, any host
resolving to the IP address 127.0.0.1 cannot be included in the list
of hosts.
\end{enumerate}
If all of these conditions are not met, \cmd{lamboot} will fail.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Selecting a \kind{boot} Module}
Only one \kind{boot} module will be selected; it will be used for the
life of the Open MPI universe. As such, module priority values are the
only factor used to determine which available module should be
selected.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{\kind{boot} MCA Parameters}
On many kinds of networks, Open MPI can know exactly which nodes should be
making connections while booting the Open MPI run-time environment, and
promiscuous connections (i.e., allowing any node to connect) are
discouraged. However, this is not possible in some complex network
configurations and promiscuous connections {\em must} be enabled.
By default, Open MPI's base \kind{boot} MCA startup protocols disable
promiscuous connections. However, this behavior can be overridden
when Open MPI is configured and at run-time. If the MCA parameter
\issiparam{boot\_\-base\_\-promisc} set to an empty value, or set to
the integer value 1, promiscuous connections will be accepted when
than Open MPI RTE is booted.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \boot{bproc} Module}
\index{bproc boot MCA module@\boot{bproc} boot MCA module}
\index{boot MCA modules!bproc@\boot{bproc}}
The Beowulf Distributed Process Space (BProc)
project\footnote{\url{http://bproc.sourceforge.net/}} is set of kernel
modifications, utilities and libraries which allow a user to start
processes on other machines in a Beowulf-style cluster. Remote
processes started with this mechanism appear in the process table of
the front-end machine in a cluster.
Open MPI functionality has been tested with BProc version 3.2.5. Prior
versions had a bug that affected at least some Open MPI functionality.
It is strongly recommended to upgrade to at least version 3.2.5 before
attempting to use the Open MPI native BProc capabilities.
%%%%%
\subsubsection{Minimum Requirements}
Several of the minimum requirements listed in
Section~\ref{sec:mca-orte-pls-min-reqs} will already be met in a BProc
environment because BProc will copy \cmd{lamboot}'s entire environment
(including the \envvar{PATH}) to the remote node. Hence, if
\cmd{lamboot} is in the user's path on the local node, it will also
[automatically] be in the user's path on the remote node.
However, one of the minimum requirements conditions (``The user must
be able to execute arbitrary processes on the target'') deserves a
BProc-specific clarification. BProc has its own internal permission
system for determining if users are allowed to execute on specific
nodes. The system is similar to the user/group/other mechanism
typically used in many Unix filesystems. Hence, in order for a user
to successfully \cmd{lamboot} on a BProc cluster, he/she must have
BProc execute permissions on each of the target nodes. Consult the
BProc documentation for more details.
%%%%%
\subsubsection{Usage}
In most situations, the \cmd{lamboot} command (and related commands)
should automatically ``know'' to use the \boot{bproc} boot MCA module
when running on the BProc head node; no additional command line
parameters or environment variables should be required.
%
Specifically, when running in a BProc environment, the \boot{bproc}
module will report that it is available, and artificially inflate its
priority relatively high in order to influence the boot module
selection process.
%
However, the BProc boot module can be forced by specifying the
\issiparam{boot} MCA parameter with the value of
\issivalue{boot}{bproc}.
Running \cmd{lamboot} on a BProc cluster is just like running
\cmd{lamboot} in a ``normal'' cluster. Specifically, you provide a
boot schema file (i.e., a list of nodes to boot on) and run
\cmd{lamboot} with it. For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamboot hostfile
\end{lstlisting}
% stupid emacs mode: $
Note that when using the \boot{bproc} module, \cmd{lamboot} will only
function properly from the head node. If you launch \cmd{lamboot}
from a client node, it will likely either fail outright, or fall back
to a different boot module (e.g., \cmd{rsh}/\cmd{ssh}).
It is suggested that the \file{hostfile} file contain hostnames in the
style that BProc prefers -- integer numbers. For example,
\file{hostfile} may contain the following:
\lstset{style=lam-shell}
\begin{lstlisting}
-1
0
1
2
3
\end{lstlisting}
\noindent which boots on the BProc front end node (-1) and four slave
nodes (0, 1, 2, 3). Note that using IP hostnames will also work, but
using integer numbers is recommended.
%%%%%
\subsubsection{Tunable Parameters}
Table~\ref{tbl:mca-orte-pls-bproc-mca-params} lists the MCA parameters
that are available to the \boot{bproc} module.
\begin{table}[htbp]
\begin{ssiparamtb}
%
\ssiparamentry{boot\_\-bproc\_\-priority}{50}{Default priority level.}
\end{ssiparamtb}
\caption{MCA parameters for the \boot{bproc} boot module.}
\label{tbl:mca-orte-pls-bproc-mca-params}
\end{table}
%%%%%
\subsubsection{Special Notes}
After booting, Open MPI will, by default, not schedule to run MPI jobs on
the BProc front end. Specifically, Open MPI implicitly sets the
``no-schedule'' attribute on the -1 node in a BProc cluster. See
Section~\ref{sec:commands-lamboot}
(page~\pageref{sec:commands-lamboot}) for more detail about this
attribute and boot schemas in general, and
\ref{sec:commands-lamboot-no-schedule} (page
\pageref{sec:commands-lamboot-no-schedule}).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \boot{globus} Module}
\index{globus boot MCA module@\boot{globus} boot MCA module}
\index{boot MCA modules!globus@\boot{globus}}
Open MPI \ompiversion\ includes beta support for Globus.
Specifically, only limited types of execution are possible. The Open
MPI Team would appreciate feedback from the Globus community on
expanding Globus support in Open MPI.
%%%%%
\subsubsection{Minimum Requirements}
Open MPI jobs in Globus environment can only be started on nodes using
the ``fork'' job manager for the Globus gatekeeper. Other job
managers are not yet supported.
%%%%%
\subsubsection{Usage}
Starting the Open MPI run-time environmetn in Globus environment makes use
of the Globus Resource Allocation Manager (GRAM) client
\icmd{globus-job-run}.
%
The Globus boot MCA module will never run automatically; it must
always be specifically requested setting the \issiparam{boot} MCA
parameter to \issivalue{boot}{globus}. Specifically, although the
\boot{globus} module will report itself available if
\icmd{globus-job-run} can be found in the \envvar{PATH}, the default
priority will be quite low, effectively ensuring that it will not be
selected unless it is the only module available (which will only occur
if the \ssiparam{boot} parameter is set to \issivalue{boot}{globus}).
Open MPI needs to be able to find the Globus executables. This can be
accompilshed either by adding the appropriate directory to your path,
or by setting the \ienvvar{GLOBUS\_\-LOCATION} environment variable.
Additionally, the \ienvvar{Open MPI\_\-MPI\_\-SEMCAON\_\-SUFFIX}
environment variable should be set to a unique value. This ensures
that this instance of the Open MPI universe does not conflict with any
other, concurrent Open MPI universes that are running under the same
username on nodes in the Globus environment. Although any value can
be used for this variable, it is probably best to have some kind of
organized format, such as {\tt
<your\_\-username>-<some\_\-long\_\-random\_\-number>}.
Next, create a boot schema to use with \cmd{lamboot}.
%
Hosts are listed by their Globus contact strings (see the Globus
manual for more information about contact strings). In cases where
the Globus gatekeeper is running as a \cmd{inetd} service on the node,
the contact string will simply be the hostname. If the contact string
contains whitespace, the {\em entire} contact string must be enclosed
in quotes (i.e., not just the values with whitespaces).
%
For example, if your contact string is:
\centerline{\tt host1:port1:/O=xxx/OU=yyy/CN=aaa bbb ccc}
Then you will need to have it listed as:
\centerline{\tt "host1:port1:/O=xxx/OU=yyy/CN=aaa bbb ccc"}
The following will not work:
\centerline{\tt host1:port1:/O=xxx/OU=yyy/CN="aaa bbb ccc"}
Each host in the boot schema must also have a ``{\tt
lam\_\-install\_\-path}'' key indicating the absolute directory
where Open MPI is installed. This value is mandatory because you
cannot rely on the \ienvvar{PATH} environment variable in Globus
environment because users' ``dot'' files are not executed in Globus
jobs (and therefore the \envvar{PATH} environment variable is not
provided). Other keys can be used as well; {\tt
lam\_\-install\_\-path} is the only mandatory key.
Here is a sample Globus boot schema:
\changebegin{7.0.5}
\lstset{style=lam-shell}
\begin{lstlisting}
# Globus boot schema
``inky.mycluster:12853:/O=MegaCorp/OU=Mine/CN=HPC Group'' prefix=/opt/lam cpu=2
``pinky.yourcluster:3245:/O=MegaCorp/OU=Yours/CN=HPC Group'' prefix=/opt/lam cpu=4
``blinky.hiscluster:23452:/O=MegaCorp/OU=His/CN=HPC Group'' prefix=/opt/lam cpu=4
``clyde.hercluster:82342:/O=MegaCorp/OU=Hers/CN=HPC Group'' prefix=/software/lam
\end{lstlisting}
\changeend{7.0.5}
Once you have this boot schema, the \cmd{lamboot} command can be used
to launch it. Note, however, that unlike the other boot MCA modules,
the Globus boot module will never be automatically selected by Open MPI --
it must be selected manually with the \issiparam{boot} MCA parameter
with the value \issivalue{boot}{globus}.
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamboot -ssi boot globus hostfile
\end{lstlisting}
% stupid emacs mode: $
%%%%%
\subsubsection{Tunable Parameters}
Table~\ref{tbl:mca-orte-pls-globus-mca-params} lists the MCA
parameters that are available to the \boot{globus} module.
\begin{table}[htbp]
\begin{ssiparamtb}
%
\ssiparamentry{boot\_\-globus\_\-priority}{3}{Default priority level.}
\end{ssiparamtb}
\caption{MCA parameters for the \boot{globus} boot module.}
\label{tbl:mca-orte-pls-globus-mca-params}
\end{table}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \boot{rsh} Module (including \cmd{ssh})}
\index{rsh (ssh) boot MCA module@\boot{rsh} (\cmd{ssh}) boot MCA module}
\index{boot MCA modules!rsh (rsh/ssh)@\boot{rsh} (\cmd{rsh}/\cmd{ssh})}
The \cmd{rsh}/\cmd{ssh} boot MCA module is typically the ``least
common denominator'' boot module. When not in an otherwise
``special'' environment (such as a batch scheduler), the
\cmd{rsh}/\cmd{ssh} boot module is typically used to start the Open MPI
run-time environment.
%%%%%
\subsubsection{Minimum Requirements}
In addition to the minimum requirements listed in
Section~\ref{sec:mca-orte-pls-min-reqs}, the following additional
conditions must also be met for a successful \cmd{lamboot} using the
\cmd{rsh} / \cmd{ssh} boot module:
\begin{enumerate}
\item The user must be able to execute arbitrary commands on each
target host without being prompted for a password.
\item The shell's start-up script must not print anything on standard
error. The user can take advantage of the fact that \cmd{rsh} /
\cmd{ssh} will start the shell non-interactively. The start-up
script can exit early in this case, before executing many commands
relevant only to interactive sessions and likely to generate output.
\changebegin{7.1}
This has now been changed in version 7.1; if the MCA parameter
\issiparam{boot\_\-rsh\_\-ignore\_\-stderr} is nonzero, any output
on standard error will {\em not} be treated as an error.
\changeend{7.1}
\end{enumerate}
Section~\ref{sec:getting-started} (page~\pageref{sec:getting-started})
provides a short tutorial on using the \cmd{rsh} / \cmd{ssh} boot
module, including tips on setting up ``dot'' files, setting up
password-less remote execution, etc.
%%%%%
\subsubsection{Usage}
Using \cmd{rsh}, \cmd{ssh}, or other remote-execution agent is
probably the most common method for starting the Open MPI run-time
execution environment. The boot schema typically lists the hostnames,
CPU counts, and an optional username (if the user's name is different
on the remote machine).
\changebegin{7.1}
The boot schema can also list an optional ``prefix'', which specifies
the Open MPI installatation to be used on the particular host listed in
the boot schema. This is typically used if the user has mutliple
Open MPI installations on a host and want to switch between them
without changing the dot files or \envvar{PATH} environment variables,
or if the user has Open MPI installed under different paths on
different hosts. If the prefix is not specified for a host in the
boot schema file, then the Open MPI installation which is available in
the \envvar{PATH} will be used on that host, or if the \cmdarg{-prefix
$<$/lam/install/path$>$} option is specified for \cmd{lamboot}, the
$<$/lam/install/path$>$ installation will be used. The prefix option
in the boot schema file however overrides any prefix option specified
on the \cmd{lamboot} command line for that host.
For example:
\lstset{style=lam-shell}
\begin{lstlisting}
# rsh boot schema
inky.cluster.example.com cpu=2
pinky.cluster.example.com cpu=4 prefix=/home/joe/lam7.1/install/
blinky.cluster.example.com cpu=4
clyde.cluster.example.com user=jsmith
\end{lstlisting}
\changeend{7.1}
The \cmd{rsh} / \cmd{ssh} boot module will usually run when no other
boot module has been selected. It can, however, be manually selected,
even when another module would typically [automatically] be selected
by specifying the \issiparam{boot} MCA parameter with the value of
\issivalue{boot}{rsh}. For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamboot -ssi boot rsh hostfile
\end{lstlisting}
% stupid emacs mode: $
%%%%%
\subsubsection{Tunable Parameters}
\changebegin{7.1}
Table~\ref{tbl:mca-orte-pls-rsh-mca-params} lists the MCA parameters that
are available to the \boot{rsh} module.
\changeend{7.1}
\begin{table}[htbp]
\begin{ssiparamtb}
%
\ssiparamentry{boot\_\-rsh\_\-agent}{From configure}{Remote shell
agent to use.}
%
\ssiparamentry{boot\_\-rsh\_\-ignore\_\-stderr}{0}{If nonzero,
ignore output from \file{stderr} when booting; don't treat it as
an error.} \ssiparamentry{boot\_\-rsh\_\-priority}{10}{Default
priority level.}
%
\ssiparamentry{boot\_\-rsh\_\-no\_\-n}{0}{If nonzero, don't use
``\cmd{-n}'' as an argument to the boot agent}
%
\ssiparamentry{boot\_\-rsh\_\-no\_\-profile}{0}{If nonzero, don't
attempt to run ``\file{.profile}'' for Bourne-type shells.}
%
\ssiparamentry{boot\_\-rsh\_\-username}{None}{Username to use if
different than login name.}
\end{ssiparamtb}
\caption{MCA parameters for the \boot{rsh} boot module.}
\label{tbl:mca-orte-pls-rsh-mca-params}
\end{table}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \boot{slurm} Module}
\index{batch queue systems!SLURM boot MCA module}
\index{slurm boot MCA module@\boot{slurm} boot MCA module}
\index{boot MCA modules!slurm@\boot{slurm}}
\changebegin{7.1}
As its name implies, the Simple Linux Utility for Resource Management
(SLURM)\footnote{http://www.llnl.gov/linux/slurm/} package is commonly
used for managing Linux clusters, typically in high-performance
computing environments. SLURM contains a native system for launching
applications across the nodes that it manages. When using SLURM,
\cmd{rsh}/\cmd{ssh} is not necessary to launch jobs on remote nodes.
Instead, the \boot{slurm} boot module will automatically use SLURM's
native job-launching interface to start Open MPI daemons.
The advantages of using SLURM's native interface are:
\begin{itemize}
\item SLURM can generate proper accounting information for all nodes in
a parallel job.
\item SLURM can kill entire jobs properly when the job ends.
\item \icmd{lamboot} executes significantly faster when using SLURM as
compared to when it uses \cmd{rsh} / \cmd{ssh}.
\end{itemize}
%%%%%
\subsubsection{Usage}
SLURM allows running jobs in multiple ways. The \boot{slurm} boot
module is only supported in some of them:
\begin{itemize}
\item ``Batch'' mode: where a script is submitted via the \icmd{srun}
command and is executed on the first node from the set that SLURM
allocated for the job. The script runs \icmd{lamboot},
\icmd{mpirun}, etc., as is normal for a Open MPI job.
This method is supported, and is perhaps the most common way to run
Open MPI automated jobs in SLURM environments.
\item ``Allocate'' mode: where the ``\cmdarg{-A}'' option is given to
\icmd{srun}, meaning that the shell were \icmd{lamboot} runs is
likely to {\em not} be one of the nodes that SLURM has allocated for
the job. In this case, Open MPI daemons will be launched on all nodes
that were allocated by SLURM as well as the origin (i.e., the node
where \cmd{lamboot} was run. The origin will be marked as
``no-schedule,'' meaning that applications launched by \cmd{mpirun}
and \cmd{lamexec} will not be run there unless specifically
requested (see See Section~\ref{sec:commands-lamboot},
page~\pageref{sec:commands-lamboot}, for more detail about this
attribute and boot schemas in general).
This method is supported, and is perhaps the most common way to run
Open MPI interactive jobs in SLURM environments.
\item ``\icmd{srun}'' mode: where a script is submitted via the
\icmd{srun} command and is executed on {\em all} nodes that SLURM
allocated for the job. In this case, the commands in the script
(e.g., \icmd{lamboot}, \icmd{mpirun}, etc.) will be run on {\em all}
nodes simultaneously, which is most likely not what you want.
This mode is not supported.
\end{itemize}
When running in any of the supported SLURM modes, Open MPI will
automatically detect that it should use the \boot{slurm} boot module
-- no extra command line parameters or environment variables should be
necessary.
%
Specifically, when running in a SLURM job, the \boot{slurm} module
will report that it is available, and artificially inflate its
priority relatively high in order to influence the boot module
selection process.
%
However, the \boot{slurm} boot module can be forced by specifying the
\issiparam{boot} MCA parameter with the value of
\issivalue{boot}{slurm}.
Unlike the \cmd{rsh}/\cmd{ssh} boot module, you do not need to specify
a hostfile for the \boot{slurm} boot module. Instead, SLURM itself
provides a list of nodes (and associated CPU counts) to Open MPI. Using
\icmd{lamboot} is therefore as simple as:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamboot
\end{lstlisting}
% stupid emacs mode: $
\changebegin{7.1}
Note that in environments with multiple TCP networks, SLURM may be
configured to use a network that is specifically designated for
commodity traffic -- another network may exist that is specifically
allocated for high-speed MPI traffic. By default, Open MPI will use the
same hostnames that SLURM provides for all of its traffic. This means
that Open MPI will send all of its MPI traffic across the same network that
SLURM uses.
However, Open MPI has the ability to boot using one set of hostnames /
addresses and then use a second set of hostnames / addresses for MPI
traffic. As such, Open MPI can redirect its TCP MPI traffic across a
secondary network. It is possible that your system administrator has
already configured Open MPI to operate in this manner.
If a secondary TCP network is intended to be used for MPI traffic, see
the section entitled ``Separating Open MPI and MPI TCP Traffic'' in the
Open MPI Installation Guide. Note that this functionality has no
effect on non-TCP \kind{rpi} modules (such as Myrinet, Infiniband,
etc.).
\changeend{7.1}
%%%%%
\subsubsection{Tunable Parameters}
Table~\ref{tbl:mca-orte-pls-slurm-mca-params} lists the MCA parameters
that are available to the \boot{slurm} module.
\begin{table}[htbp]
\begin{ssiparamtb}
%
\ssiparamentry{boot\_\-slurm\_\-priority}{50}{Default priority level.}
\end{ssiparamtb}
\caption{MCA parameters for the \boot{slurm} boot module.}
\label{tbl:mca-orte-pls-slurm-mca-params}
\end{table}
%%%%%
\subsubsection{Special Notes}
Since the \boot{slurm} boot module is designed to work in SLURM jobs,
it will fail if the \boot{slurm} boot module is manually specified and
Open MPI is not currently running in a SLURM job.
The \boot{slurm} module does not start a shell on the remote node.
Instead, the entire environment of \cmd{lamboot} is pushed to the
remote nodes before starting the Open MPI run-time environment.
\changeend{7.1}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{The \boot{tm} Module (OpenPBS / PBS Pro / Torque)}
\index{batch queue systems!OpenPBS / PBS Pro / Torque (TM) boot MCA module}
\index{tm boot MCA module@\boot{tm} boot MCA module}
\index{boot MCA modules!tm (PBS / Torque)@\boot{tm} (PBS / Torque)}
Both OpenPBS and PBS Pro (both products of Altair Grid Technologies,
LLC), contain support for the Task Management (TM) interface. Torque,
the open source fork of the Open MPI product, also contains the TM
interface. When using TM, \cmd{rsh}/\cmd{ssh} is not necessary to
launch jobs on remote nodes.
The advantages of using the TM interface are:
\begin{itemize}
\item PBS/Torque can generate proper accounting information for all
nodes in a parallel job.
\item PBS/Torque can kill entire jobs properly when the job ends.
\item \icmd{lamboot} executes significantly faster when using TM as
compared to when it uses \cmd{rsh} / \cmd{ssh}.
\end{itemize}
%%%%%
\subsubsection{Usage}
When running in a PBS/Torque batch job, Open MPI will automatically detect
that it should use the \boot{tm} boot module -- no extra command line
parameters or environment variables should be necessary.
%
Specifically, when running in a PBS/Torque job, the \boot{tm} module
will report that it is available, and artificially inflate its
priority relatively high in order to influence the boot module
selection process.
%
However, the \boot{tm} boot module can be forced by specifying the
\issiparam{boot} MCA parameter with the value of \issivalue{boot}{tm}.
Unlike the \cmd{rsh}/\cmd{ssh} boot module, you do not need to specify
a hostfile for the \boot{tm} boot module. Instead, PBS/Torque itself
provides a list of nodes (and associated CPU counts) to Open MPI. Using
\icmd{lamboot} is therefore as simple as:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ lamboot
\end{lstlisting}
% stupid emacs mode: $
The \boot{tm} boot modules works in both interactive and
non-interactive batch jobs.
\changebegin{7.1}
Note that in environments with multiple TCP networks, PBS / Torque may
be configured to use a network that is specifically designated for
commodity traffic -- another network may exist that is specifically
allocated for high-speed MPI traffic. By default, Open MPI will use the
same hostnames that the TM interface provides for all of its traffic.
This means that Open MPI will send all of its MPI traffic across the same
network that PBS / Torque uses.
However, Open MPI has the ability to boot using one set of hostnames /
addresses and then use a second set of hostnames / addresses for MPI
traffic. As such, Open MPI can redirect its TCP MPI traffic across a
secondary network. It is possible that your system administrator has
already configured Open MPI to operate in this manner.
If a secondary TCP network is intended to be used for MPI traffic, see
the section entitled ``Separating Open MPI and MPI TCP Traffic'' in the
Open MPI Installation Guide. Note that this has no effect on non-TCP
\kind{rpi} modules (such as Myrinet, Infiniband, etc.).
\changeend{7.1}
%%%%%
\subsubsection{Tunable Parameters}
Table~\ref{tbl:mca-orte-pls-tm-mca-params} lists the MCA parameters
that are available to the \boot{tm} module.
\begin{table}[htbp]
\begin{ssiparamtb}
%
\ssiparamentry{boot\_\-tm\_\-priority}{50}{Default priority level.}
\end{ssiparamtb}
\caption{MCA parameters for the \boot{tm} boot module.}
\label{tbl:mca-orte-pls-tm-mca-params}
\end{table}
%%%%%
\subsubsection{Special Notes}
Since the \boot{tm} boot module is designed to work in PBS/Torque
jobs, it will fail if the \boot{tm} boot module is manually specified
and Open MPI is not currently running in a PBS/Torque job.
The \boot{tm} module does not start a shell on the remote node.
Instead, the entire environment of \cmd{lamboot} is pushed to the
remote nodes before starting the Open MPI run-time environment.
Also note that the Altair-provided client RPMs for PBS Pro do not
include the \icmd{pbs\_\-demux} command, which is necessary for proper
execution of TM jobs. The solution is to copy the executable from the
server RPMs to the client nodes.
Finally, TM does not provide a mechanism for path searching on the
remote nodes, so the \cmd{lamd} executable is required to reside in
the same location on each node to be booted.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Close of index
\index{ORTE MCA components|)}

@ -1,423 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Modular Component Architecture (MCA) Overview}
\label{sec:mca}
\index{MCA!overview|(}
\index{Modular Component Architecture|see {MCA}}
The Modular Component Architecture (MCA) makes up the core of Open MPI.
It influences how many commands and MPI processes are executed. This
chapter provides an overview of what MCA is and what users need to
know about how to use it to maximize performance of MPI applications.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Frameworks and Components}
\index{MCA!component frameworks}
The MCA provides component frameworks for the Open MPI run-time
environment (otherwise known as the Open Run-Time Environment, or
ORTE) and the MPI communications layer. Components are selected from
each type at run-time and used to effect the RTE and MPI library.
{\Huge JMS Right ideas, but needs much overhauling}
There are currently four types of components used by
Open MPI:
\begin{itemize}
\item \kind{boot}: Starting the Open MPI run-time environment, used mainly
with the \cmd{lamboot} command.
\item \kind{coll}: MPI collective communications, only used within MPI
processes.
\item \kind{cr}: Checkpoint/restart functionality, used both within
Open MPI commands and MPI processes.
\item \kind{rpi}: MPI point-to-point communications, only used within
MPI processes.
\end{itemize}
The Open MPI distribution includes instances of each component type
referred to as modules. Each module is an implementation of the
component type which can be selected and used at run-time to provide
services to the Open MPI RTE and MPI communications layer.
Chapters~\ref{sec:lam-mca} and~\ref{sec:mca-ompi} list the modules that
are available in the Open MPI distribution.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Terminology}
\begin{description}
\item[Available] The term ``available'' is used to describe a module
that reports (at run-time) that it is able to run in the current
environment. For example, an RPI module may check to see if
supporting network hardware is present before reporting that it is
available or not.
Chapters~\ref{sec:lam-mca} and~\ref{sec:mca-ompi} list the modules
that are included in the Open MPI distribution, and detail the
requirements for each of them to indicate whether they are available
or not.
\item[Selected] The term ``selected'' means that a module has been
chosen to be used at run-time. Depending on the module type, zero
or more modules may be selected.
\item[Scope] Each module selection has a scope depending on the type
of the module. ``Scope'' refers to the duration of the module's
selection. Table~\ref{tbl:mca-module-scopes} lists the scopes for
each module type.
\end{description}
\begin{table}[htbp]
\centering
\begin{tabular}{|l|p{4in}|}
\hline
\multicolumn{1}{|c|}{Type} &
\multicolumn{1}{|c|}{Scope description} \\
\hline
\hline
\kind{boot} & A module is selected at the beginning of
\cmd{lamboot} (or \cmd{recon}) and is used for the duration of the
Open MPI universe. \\
\hline
\kind{coll} & A module is selected every time an MPI communicator
is created (including \mpiconst{MPI\_\-COMM\_\-WORLD} and
\mpiconst{MPI\_\-COMM\_\-SELF}). It remains in use until that
communicator has been freed. \\
\hline
\kind{cr} & Checkpoint/restart modules are selected at the
beginning of an MPI job and remain in use until the job
completes. \\
\hline
\kind{rpi} & RPI modules are selected during \mpifunc{MPI\_\-INIT}
and remain in use until \mpifunc{MPI\_\-FINALIZE} returns. \\
\hline
\end{tabular}
\caption{MCA module types and their corresponding scopes.}
\label{tbl:mca-module-scopes}
\end{table}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MCA Parameters}
\label{sec:commands-mca-module-parameters}
\index{MCA!parameter overview}
One of the founding principles of MCA is to allow the passing of
run-time parameters through the MCA framework. This allows both the
selection of which modules will be used at run-time (by passing
parameters to the MCA framework itself) as well as tuning run-time
performance of individual modules (by passing parameters to each
module).
%
Although the specific usage of each MCA module parameter is defined by
either the framework or the module that it is passed to, the value of
most parameters will be resolved by the following:
\begin{enumerate}
\item If a valid value is provided via a run-time MCA parameter, use
that.
\item Otherwise, attempt to calculate a meaningful value at run-time
or use a compiled-in default value.\footnote{Note that many MCA
modules provide configure flags to set compile-time defaults
for ``tweakable'' parameters.
See~\cite{lamteam03:_lam_mpi_install_guide}.}
\end{enumerate}
As such, it is typically possible to set a parameter's default value
when Open MPI is configured/compiled, but use a different value at run
time.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Naming Conventions}
MCA parameter names are generally strings containing only letters and
underscores, and can typically be broken down into three parts. For
example, the parameter \mcaparam{boot\_\-rsh\_\-agent} can be broken
into its three components:
\begin{itemize}
\item MCA module type: The first string of the name. In this case, it
is \mcaparam{boot}.
\item MCA module name: The second string of the name, corresponding to
a specific MCA module. In this case, it is \mcaparam{rsh}.
\item Parameter name: The last string in the name. It may be an
arbitrary string, and include multiple underscores. In this case,
it is \mcaparam{agent}.
\end{itemize}
Although the parameter name is technically only the last part of the
string, it is only proper to refer to it within its overall context.
Hence, it is correct to say ``the \mcaparam{boot\_\-rsh\_\-agent}
parameter'' as well as ``the \mcaparam{agent} parameter to the
\boot{rsh} boot module''.
Note that the reserved string \mcaparam{base} may appear as a module
name, referring to the fact that the parameter applies to all modules
of a give type.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Setting Parameter Values}
MCA parameters each have a unique name and can take a single string
value. The parameter/value pairs can be passed by multiple different
mechanisms. Depending on the target module and the specific
parameter, mechanisms may include:
\begin{itemize}
\item Using command line flags when Open MPI was configured.
\item Setting environment variables before invoking Open MPI commands.
\item Using the \cmdarg{-mca} command line switch to various Open MPI
commands.
\item Setting attributes on MPI communicators.
\end{itemize}
Users are most likely to utilize the latter three methods. Each is
described in detail, below. Listings and explanations of available
MCA parameters are provided in Chapters~\ref{sec:lam-mca}
and~\ref{sec:mca-ompi} (pages~\pageref{sec:lam-mca}
and~\pageref{sec:mca-ompi}, respectively), categorized by MCA type and
module.
%%%%%
\subsubsection{Environment Variables}
MCA parameters can be passed via environment variables prefixed with
\envvar{Open MPI\_\-MPI\_\-MCA}. For example, selecting which RPI module
to use in an MPI job can be accomplished by setting the environment
variable \envvar{Open MPI\_\-MPI\_\-MCA\_\-rpi} to a valid RPI module name
(e.g., \cmdarg{tcp}).
Note that environment variables must be set {\em before} invoking the
corresponding Open MPI commands that will use them.
%%%%%
\subsubsection{\cmdarg{-mca} Command Line Switch}
Open MPI commands that interact with MCA modules accept the
\cmdarg{-mca} command line switch. This switch expects two parameters
to follow: the name of the MCA parameter and its corresponding value.
For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun C -mca rpi tcp my_mpi_program
\end{lstlisting}
% stupid emacs mode: $
\noindent runs the \cmd{my\_\-mpi\_\-program} on all available CPUs in
the Open MPI universe using the \rpi{tcp} RPI module.
%%%%%
\subsubsection{Communicator Attributes}
Some MCA types accept MCA parameters via MPI communicator attributes
(notably the MPI collective communication modules). These parameters
follow the same rules and restrictions as normal MPI attributes. Note
that for portability between 32 and 64 bit systems, care should be
taken when setting and getting attribute values. The following is an
example of portable attribute C code:
\lstset{style=lam-c}
\begin{lstlisting}
int flag, attribute_val;
void *set_attribute;
void **get_attribute;
MPI_Comm comm = MPI_COMM_WORLD;
int keyval = Open MPI_MPI_MCA_COLL_BASE_ASSOCIATIVE;
/* Set the value */
set_attribute = (void *) 1;
MPI_Comm_set_attr(comm, keyval, &set_attribute);
/* Get the value */
get_attribute = NULL;
MPI_Comm_get_attr(comm, keyval, &get_attribute, &flag);
if (flag == 1) {
attribute_val = (int) *get_attribute;
printf(``Got the attribute value: %d\n'', attribute_val);
}
\end{lstlisting}
% stupid emacs mode: $
Specifically, the following code is neither correct nor portable:
\lstset{style=lam-c}
\begin{lstlisting}
int flag, attribute_val;
MPI_Comm comm = MPI_COMM_WORLD;
int keyval = Open MPI_MPI_MCA_COLL_BASE_ASSOCIATIVE;
/* Set the value */
attribute_val = 1;
MPI_Comm_set_attr(comm, keyval, &attribute_val);
/* Get the value */
attribute_val = -1;
MPI_Comm_get_attr(comm, keyval, &attribute_val, &flag);
if (flag == 1)
printf(``Got the attribute value: %d\n'', attribute_val);
\end{lstlisting}
% stupid emacs mode: $
\index{MCA!overview|)}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Dynamic Shared Object (DSO) Modules}
\changebegin{7.1}
Open MPI has the capability of building MCA modules statically as part of
the MPI libraries or as dynamic shared objects (DSOs). DSOs are
discovered and loaded into Open MPI processes at run-time. This allows
adding (or removing) functionality from an existing Open MPI installation
without the need to recompile or re-link user applications.
The default location for DSO MCA modules is \file{\$prefix/lib/lam}.
If otherwise unspecified, this is where Open MPI will look for DSO MCA
modules. However, the MCA parameter
\imcaparam{base\_\-module\_\-path} can be used to specify a new
colon-delimited path to look for DSO MCA modules. This allows users
to specify their own location for modules, if desired.
Note that specifying this parameter overrides the default location.
If users wish to augment their search path, they will need to include
the default location in the path specification.
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun C -mca base_module_path $prefix/lib/lam:$HOME/my_lam_modules ...
\end{lstlisting}
% stupid emacs mode: $
\changeend{7.1}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Selecting Modules}
As implied by the previous sections, modules are selected at run-time
either by examining (in order) user-specified parameters, run-time
calculations, and compiled-in defaults. The selection process
involves a flexible negotitation phase which can be both tweaked and
arbitrarily overridden by the user and system administrator.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Specifying Modules}
Each MCA type has an implicit MCA parameter corresponding to the type
name indicating which module(s) to be considered for selection. For
example, to specify in that the \rpi{tcp} RPI module should be used,
the MCA parameter \mcaparam{rpi} should be set to the value
\mcaparam{tcp}. For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun C -mca rpi tcp my_mpi_program
\end{lstlisting}
% stupid emacs mode: $
The same is true for the other MCA types (\kind{boot}, \kind{cr}, and
\kind{coll}), with the exception that the \kind{coll} type can be used
to specify a comma-separated list of modules to be considered as each
MPI communicator is created (including
\mpiconst{MPI\_\-COMM\_\-WORLD}). For example:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ mpirun C -mca coll smp,shmem,lam_basic my_mpi_program
\end{lstlisting}
% stupid emacs mode: $
\noindent indicates that the \coll{smp} and \coll{lam\_\-basic}
modules will potentially both be considered for selection for each MPI
communicator.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Setting Priorities}
Although typically not useful to individual users, system
administrators may use priorities to set system-wide defaults that
influence the module selection process in Open MPI jobs.
Each module has an associated priority which plays role in whether a
module is selected or not. Specifically, if one or more modules of a
given type are available for selection, the modules' priorities will
be at least one of the factors used to determine which module will
finally be selected. Priorities are in the range $[-1, 100]$, with
$-1$ indicating that the module should not be considered for
selection, and $100$ being the highest priority. Ties will be broken
arbitrarily by the MCA framework.
A module's priorty can be set run-time through the normal MCA
parameter mechanisms (i.e., environment variables or using the
\cmdarg{-mca} parameter). Every module has an implicit priority MCA
parameter in the form \mcaparam{$<$type$>$\_\-$<$module
name$>$\_\-priority}.
For example, a system administrator may set environment variables in
system-wide shell setup files (e.g., \file{/etc/profile},
\file{/etc/bashrc}, or \file{/etc/csh.cshrc}) to change the default
priorities.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Selection Algorithm}
For each component type, the following general selection algorithm is
used:
\begin{itemize}
\item A list of all available modules is created. If the user
specified one or more modules for this type, only those modules are
queried to see if they are available. Otherwise, all modules are
queried.
\item The module with the highest priority (and potentially meeting
other selection criteria, depending on the module's type) will be
selected.
\end{itemize}
Each MCA type may define its own additional selection rules. For
example, the selection of \kind{coll}, \kind{cr}, and \kind{rpi}
modules may be inter-dependant, and depend on the supported MPI thread
level. Chapter~\ref{sec:mca-ompi} (page~\pageref{sec:mca-ompi})
details the selection algorithm for MPI MCA modules.

@ -1,305 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Miscellaneous}
\label{sec:misc}
This chapter covers a variety of topics that don't conveniently fit
into other chapters.
{\Huge JMS Needs a lot of overhauling}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Singleton MPI Processes}
It is possible to run an MPI process without the \cmd{mpirun} or
\cmd{mpiexec} commands -- simply run the program as one would normally
launch a serial program:
\lstset{style=lam-cmdline}
\begin{lstlisting}
shell$ my_mpi_program
\end{lstlisting}
% Stupid emacs mode: $
Doing so will create an \mcw with a single process. This process can
either run by itself, or spawn or connect to other MPI processes and
become part of a larger MPI jobs using the MPI-2 dynamic function
calls.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI-2 I/O Support}
\index{ROMIO}
\index{MPI-2 I/O support|see {ROMIO}}
\index{I/O support|see {ROMIO}}
MPI-2 I/O support is provided through the ROMIO
package~\cite{thak99a,thak99b}. ROMIO has been fully integrated into
Open MPI. As such, \mpitype{MPI\_\-Request} objects can be used .....
ROMIO includes its own documentation and listings of known issues and
limitations. See the \file{README} file in the ROMIO directory in the
Open MPI distribution.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Fortran Process Names}
\index{fortran process names}
\cmdindex{mpitask}{fortran process names}
Since Fortran does not portably provide the executable name of the
process (similar to the way that C programs get an array of {\tt
argv}), the \icmd{mpitask} command lists the name ``Open MPI MPI Fortran
program'' by default for MPI programs that used the Fortran binding
for \mpifunc{MPI\_\-INIT} or \mpifunc{MPI\_\-INIT\_\-THREAD}.
The environment variable \ienvvar{Open MPI\_\-MPI\_\-PROCESS\_\-NAME} can
be used to override this behavior.
%
Setting this environment variable before invoking \icmd{mpirun} will
cause \cmd{mpitask} to list that name instead of the default title.
%
This environment variable only works for processes that invoke the
Fortran binding for \mpifunc{MPI\_\-INIT} or
\mpifunc{MPI\_\-INIT\_\-THREAD}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI Thread Support}
\label{sec:misc-threads}
\index{threads and MPI}
\index{MPI and threads|see {threads and MPI}}
\def\mtsingle{\mpiconst{MPI\_\-THREAD\_\-SINGLE}}
\def\mtfunneled{\mpiconst{MPI\_\-THREAD\_\-FUNNELED}}
\def\mtserial{\mpiconst{MPI\_\-THREAD\_\-SERIALIZED}}
\def\mtmultiple{\mpiconst{MPI\_\-THREAD\_\-MULTIPLE}}
\def\mpiinit{\mpifunc{MPI\_\-INIT}}
\def\mpiinitthread{\mpifunc{MPI\_\-INIT\_\-THREAD}}
Open MPI currently implements support for \mtsingle, \mtfunneled, and
\mtserial. The constant \mtmultiple\ is provided, although Open MPI will
never return \mtmultiple\ in the \funcarg{provided} argument to
\mpiinitthread.
Open MPI makes no distinction between \mtsingle\ and \mtfunneled. When
\mtserial\ is used, a global lock is used to ensure that only one
thread is inside any MPI function at any time.
\subsection{Thread Level}
Selecting the thread level for an MPI job is best described in terms
of the two parameters passed to \mpiinitthread: \funcarg{requested}
and \funcarg{provided}. \funcarg{requested} is the thread level that
the user application requests, while \funcarg{provided} is the thread
level that Open MPI will run the application with.
\begin{itemize}
\item If \mpiinit\ is used to initialize the job, \funcarg{requested}
will implicitly be \mtsingle. However, if the
\ienvvar{Open MPI\_\-MPI\_\-THREAD\_\-LEVEL} environment variable is set
to one of the values in Table~\ref{tbl:mpi-env-thread-level}, the
corresponding thread level will be used for \funcarg{requested}.
\item If \mpiinitthread\ is used to initialized the job, the
\funcarg{requested} thread level is the first thread level that the
job will attempt to use. There is currently no way to specify lower
or upper bounds to the thread level that Open MPI will use.
The resulting thread level is largely determined by the SSI modules
that will be used in an MPI job; each module must be able to support
the target thread level. A complex algorithm is used to attempt to
find a thread level that is acceptable to all SSI modules.
Generally, the algorithm starts at \funcarg{requested} and works
backwards towards \mpiconst{MPI\_\-THREAD\_\-SINGLE} looking for an
acceptable level. However, any module may {\em increase} the thread
level under test if it requires it. At the end of this process, if
an acceptable thread level is not found, the MPI job will abort.
\end{itemize}
\begin{table}[htbp]
\centering
\begin{tabular}{|c|l|}
\hline
Value & \multicolumn{1}{|c|}{Meaning} \\
\hline
\hline
undefined & \mtsingle \\
0 & \mtsingle \\
1 & \mtfunneled \\
2 & \mtserial \\
3 & \mtmultiple \\
\hline
\end{tabular}
\caption{Valid values for the \envvar{Open MPI\_\-MPI\_\-THREAD\_\-LEVEL}
environment variable.}
\label{tbl:mpi-env-thread-level}
\end{table}
Also note that certain SSI modules require higher thread support
levels than others. For example, any checkpoint/restart SSI module
will require a minimum of \mtserial, and will attempt to adjust the
thread level upwards as necessary (if that CR module will be used
during the job).
Hence, using \mpiinit\ to initialize an MPI job does not imply that
the provided thread level will be \mtsingle.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI-2 Name Publishing}
\index{published names}
\index{dynamic name publishing|see {published names}}
\index{name publising|see {published names}}
Open MPI supports the MPI-2 functions \mpifunc{MPI\_\-PUBLISH\_\-NAME}
and \mpifunc{MPI\_\-UNPUBLISH\_\-NAME} for publishing and unpublishing
names, respectively. Published names are stored within the Open MPI
daemons, and are therefore persistent, even when the MPI process that
published them dies.
As such, it is important for correct MPI programs to unpublish their
names before they terminate. However, if stale names are left in the
Open MPI universe when an MPI process terminates, the \icmd{lamclean}
command can be used to clean {\em all} names from the Open MPI RTE.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Batch Queuing System Support}
\label{sec:misc-batch}
\index{batch queue systems}
\index{Portable Batch System|see {batch queue systems}}
\index{PBS|see {batch queue systems}}
\index{PBS Pro|see {batch queue systems}}
\index{OpenPBS|see {batch queue systems}}
\index{Load Sharing Facility|see {batch queue systems}}
\index{LSF|see {batch queue systems}}
\index{Clubmask|see {batch queue systems}}
Open MPI is now aware of some batch queuing systems. Support is currently
included for PBS, LSF, and Clubmask-based
systems. There is also a generic functionality that allows users of
other batch queue systems to take advantages of this functionality.
\begin{itemize}
\item When running under a supported batch queue system, Open MPI will take
precautions to isolate itself from other instances of Open MPI in
concurrent batch jobs. That is, the multiple Open MPI instances from the
same user can exist on the same machine when executing in batch.
This allows a user to submit as many Open MPI jobs as necessary, and even
if they end up running on the same nodes, a \cmd{lamclean} in one
job will not kill MPI applications in another job.
\item This behavior is {\em only} exhibited under a batch environment.
Other batch systems can easily be supported -- let the Open MPI Team know
if you'd like to see support for others included. Manually setting
the environment variable \ienvvar{Open MPI\_\-MPI\_\-SESSION\_\-SUFFIX}
on the node where \icmd{lamboot} is run achieves the same ends.
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Location of Open MPI's Session Directory}
\label{sec:misc-session-directory}
\index{session directory}
By default, Open MPI will create a temporary per-user session directory
in the following directory:
\centerline{\file{<tmpdir>/lam-<username>@<hostname>[-<session\_suffix>]}}
\noindent Each of the components is described below:
\begin{description}
\item[\file{<tmpdir>}]: Open MPI will set the prefix used for the session
directory based on the following search order:
\begin{enumerate}
\item The value of the \ienvvar{Open MPI\_\-MPI\_\-SESSION\_\-PREFIX}
environment variable
\item The value of the \ienvvar{TMPDIR} environment variable
\item \file{/tmp/}
\end{enumerate}
It is important to note that (unlike
\ienvvar{Open MPI\_\-MPI\_\-SESSION\_\-SUFFIX}), the environment
variables for determining \file{<tmpdir>} must be set on each node
(although they do not necessarily have to be the same value).
\file{<tmpdir>} must exist before \icmd{lamboot} is run, or
\icmd{lamboot} will fail.
\item[\file{<username>}]: The user's name on that host.
\item[\file{<hostname>}]: The hostname.
\item[\file{<session\_suffix>}]: Open MPI will set the suffix (if any) used
for the session directory based on the following search order:
\begin{enumerate}
\item The value of the \ienvvar{Open MPI\_\-MPI\_\-SESSION\_\-SUFFIX}
environment variable.
\item If running under a supported batch system, a unique session
ID (based on information from the batch system) will be used.
\end{enumerate}
\end{description}
\ienvvar{Open MPI\_\-MPI\_\-SESSION\_\-SUFFIX} and the batch information
only need to be available on the node from which \icmd{lamboot} is
run. \icmd{lamboot} will propagate the information to the other
nodes.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Signal Catching}
\index{signals}
Open MPI MPI catches the signals SEGV, BUS, FPE, and ILL. The
signal handler terminates the application. This is useful in batch
jobs to help ensure that \icmd{mpirun} returns if an application
process dies. To disable the catching of signals use the
\cmdarg{-nsigs} option to \icmd{mpirun}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI Attributes}
\begin{discuss}
Need to have discussion of built-in attributes here, such as
MPI\_\-UNIVERSE\_\-SIZE, etc. Should specifically mention that
MPI\_\-UNIVERSE\_\-SIZE is fixed at \mpifunc{MPI\_\-INIT} time (at
least it is as of this writing -- who knows what it will be when we
release 7.1? :-).
This whole section is for 7.1.
\end{discuss}

@ -1,705 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Supported MPI Functionality}
\label{sec:mpi-functionality}
This chapter discusses the exact levels of MPI functionality that is
supported by Open MPI.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI-1 Support}
Open MPI \ompiversion\ has support for all MPI-1 functionality.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Language Bindings}
\label{sec:mpi-details-mpi1-language}
Open MPI provides C, C++, Fortran 77, and Fortran 90 bindings for all
MPI-1 functions, types, and constants.
%
Profiling support is available in all four languages (if Open MPI was
configured and compiled with profiling support). The \icmd{ompi\_info}
command can be used to see if profiling support was included in
Open MPI.
{\Huge JMS needs massive overhauling}
Support for optional Fortran types has now been added.
Table~\ref{tbl:mpi-details-optional-fortran-dtypes} lists the new
datatypes. Note that \mpidatatype{MPI\_\-INTEGER8} and
\mpidatatype{MPI\_\-REAL16} are listed even though they are not
defined by the MPI standard. Support for these types is included per
request from Open MPI users.
\begin{table}[htbp]
\centering
\begin{tabular}{|ll|}
\hline
\multicolumn{2}{|c|}{Supported Datatypes} \\
\hline
\hline
\mpidatatype{MPI\_\-INTEGER1} &
\mpidatatype{MPI\_\-INTEGER2} \\
%
\mpidatatype{MPI\_\-INTEGER4} &
\mpidatatype{MPI\_\-INTEGER8} \\
%
\mpidatatype{MPI\_\-REAL4} &
\mpidatatype{MPI\_\-REAL8} \\
%
\mpidatatype{MPI\_\-REAL16} &
~ \\
\hline
\end{tabular}
\caption{Supported optional fortran datatypes.}
\label{tbl:mpi-details-optional-fortran-dtypes}
\end{table}
\changeend{7.1}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{\mpifunc{MPI\_\-CANCEL}}
\mpifunc{MPI\_\-CANCEL} works properly for receives, but will almost
never work on sends. \mpifunc{MPI\_\-CANCEL} is most frequently used
with unmatched \mpifunc{MPI\_\-IRECV}'s that were made ``in case'' a
matching message arrived. This simply entails removing the receive
request from the local queue, and is fairly straightforward to
implement.
Actually canceling a send operation is much more difficult because
some meta information about a message is usually sent immediately. As
such, the message is usually at least partially sent before an
\mpifunc{MPI\_\-CANCEL} is issued. Trying to chase down all the
particular cases is a nightmare, to say the least.
As such, the Open MPI Team decided not to implement \mpifunc{MPI\_\-CANCEL}
on sends, and instead concentrate on other features.
But in true MPI Forum tradition, we would be happy to discuss any code
that someone would like to submit that fully implements
\mpifunc{MPI\_\-CANCEL}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI-2 Support}
Open MPI \lamversion\ has support for many MPI-2 features. The main
chapters of the MPI-2 standard are listed below, along with a summary
of the support provided for each chapter.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Miscellany}
%%%%%
\paragraph{Portable MPI Process Startup.}
The \icmd{mpiexec} command is now supported. Common examples include:
\lstset{style=lam-shell}
\begin{lstlisting}
# Runs 4 copes of the MPI program my_mpi_program
shell$ mpiexec -n 4 my_mpi_program
# Runs my_linux_program on all available Linux machines, and runs
# my_solaris_program on all available Solaris machines
shell$ mpiexec -arch linux my_linux_program : -arch solaris my_solaris_program
# Boot the Open MPI run-time environment, run my_mpi_program on all
# available CPUs, and then shut down the Open MPI run-time environment.
shell$ mpiexec -machinefile hostfile my_mpi_program
\end{lstlisting}
% stupid emacs mode: $
See the \file{mpiexec(1)} man page for more details on supported
options as well as more examples.
%%%%%
\paragraph{Passing \const{NULL} to \mpifunc{MPI\_\-INIT}.}
Passing \const{NULL} as both arguments to \mpifunc{MPI\_\-INIT} is
fully supported.
%%%%%
\paragraph{Version Number.}
Open MPI \lamversion\ reports its MPI version as 1.2 through the function
\mpifunc{MPI\_\-GET\_\-VERSION}.
%%%%%
\paragraph{Datatype Constructor \mpifunc{MPI\_\-TYPE\_\-CREATE\_\-INDEXED\_\-BLOCK}.}
The MPI function \mpifunc{MPI\_\-TYPE\_\-CREATE\_\-INDEXED\_\-BLOCK}
is not supported by Open MPI.
%%%%%
\paragraph{Treatment of \mpitype{MPI\_\-Status}.}
Although Open MPI supports the constants \mpiconst{MPI\_\-STATUS\_\-IGNORE}
and \mpiconst{MPI\_\-STATUSES\_\-IGNORE}, the function
\mpifunc{MPI\_\-REQUEST\_\-GET\_\-STATUS} is not provided.
%%%%%
\paragraph{Error class for invalid keyval.}
The error class for invalid keyvals, \mpiconst{MPI\_\-ERR\_\-KEYVAL},
is fully supported.
%%%%%
\paragraph{Committing committed datatype.}
Committing a committed datatype is fully supported; its end effect is
a no-op.
%%%%%
\paragraph{Allowing user functions at process termination.}
Attaching attributes to \mpiconst{MPI\_\-COMM\_\-SELF} that have
user-specified delete functions will now trigger these functions to be
invoked as the first phase of \mpifunc{MPI\_\-FINALIZE}. When these
functions are run, MPI is still otherwise fully functional.
%%%%%
\paragraph{Determining whether MPI has finished.}
The function \mpifunc{MPI\_\-FINALIZED} is fully supported.
%%%%%
\paragraph{The {\sf Info} object.}
Full support for \mpitype{MPI\_\-Info} objects is provided. See
Table~\ref{tbl:mpi-details-info-functions}.
\begin{table}[htbp]
\centering
\begin{tabular}{|lll|}
\hline
\multicolumn{3}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-INFO\_\-CREATE} &
\mpifunc{MPI\_\-INFO\_\-FREE} &
\mpifunc{MPI\_\-INFO\_\-GET\_\-NTHKEY} \\
%
\mpifunc{MPI\_\-INFO\_\-DELETE} &
\mpifunc{MPI\_\-INFO\_\-GET} &
\mpifunc{MPI\_\-INFO\_\-GET\_\-VALUELEN} \\
%
\mpifunc{MPI\_\-INFO\_\-DUP} &
\mpifunc{MPI\_\-INFO\_\-GET\_\-NKEYS} &
\mpifunc{MPI\_\-INFO\_\-SET} \\
\hline
\end{tabular}
\caption{Supported MPI-2 info functions.}
\label{tbl:mpi-details-info-functions}
\end{table}
%%%%%
\paragraph{Memory allocation.}
The \mpifunc{MPI\_\-ALLOC\_\-MEM} and \mpifunc{MPI\_\-FREE\_\-MEM}
functions will return ``special'' memory that enable fast memory
passing in RPIs that support it.
%
These functions are simply wrappers to \func{malloc()} and
\func{free()} (respectively) in RPI modules that do not take advantage
of ``special'' memory.
%
These functions can be used portably for potential performance gains.
%%%%%
\paragraph{Language interoperability.}
Inter-language interoperability is supported. It is possible to
initialize Open MPI from either C or Fortran and mix MPI calls from
both languages. Handle conversions for inter-language
interoperability are fully supported. See
Table~\ref{tbl:mpi-details-handle-conversion-functions}.
\begin{table}[htbp]
\centering
\begin{tabular}{|ll|}
\hline
\multicolumn{2}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-COMM\_\-F2C} &
\mpifunc{MPI\_\-COMM\_\-C2F} \\
%
\mpifunc{MPI\_\-GROUP\_\-F2C} &
\mpifunc{MPI\_\-GROUP\_\-C2F} \\
%
\mpifunc{MPI\_\-TYPE\_\-F2C} &
\mpifunc{MPI\_\-TYPE\_\-C2F} \\
%
\mpifunc{MPI\_\-REQUEST\_\-F2C} &
\mpifunc{MPI\_\-REQUEST\_\-C2F} \\
%
\mpifunc{MPI\_\-INFO\_\-F2C} &
\mpifunc{MPI\_\-INFO\_\-C2F} \\
%
\mpifunc{MPI\_\-WIN\_\-F2C} &
\mpifunc{MPI\_\-WIN\_\-C2F} \\
%
\mpifunc{MPI\_\-STATUS\_\-F2C} &
\mpifunc{MPI\_\-STATUS\_\-C2F} \\
\hline
\end{tabular}
\caption{Supported MPI-2 handle conversion functions.}
\label{tbl:mpi-details-handle-conversion-functions}
\end{table}
%%%%%
\paragraph{Error handlers.}
Communicator and window error handler functions are fully supported;
this functionality is not yet supported for \mpitype{MPI\_\-File}
handles. See Table~\ref{tbl:mpi-details-err-handler-functions}
\begin{table}[htbp]
\centering
\begin{tabular}{|ll|}
\hline
\multicolumn{2}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-COMM\_\-CREATE\_\-ERRHANDLER} &
\mpifunc{MPI\_\-WIN\_\-CREATE\_\-ERRHANDLER} \\
%
\mpifunc{MPI\_\-COMM\_\-GET\_\-ERRHANDLER} &
\mpifunc{MPI\_\-WIN\_\-GET\_\-ERRHANDLER} \\
%
\mpifunc{MPI\_\-COMM\_\-SET\_\-ERRHANDLER} &
\mpifunc{MPI\_\-WIN\_\-SET\_\-ERRHANDLER} \\
\hline
\end{tabular}
\caption{Supported MPI-2 error handler functions.}
\label{tbl:mpi-details-err-handler-functions}
\end{table}
%%%%%
\paragraph{New datatype manipulation functions.}
Several new datatype manipulation functions are provided.
Table~\ref{tbl:mpi-details-new-dtype-manip-functions} lists the new
functions.
\begin{table}[htbp]
\centering
\begin{tabular}{|ll|}
\hline
\multicolumn{2}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-GET\_\-ADDRESS} &
\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-SUBARRAY} \\
%
\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-DARRAY} &
\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-STRUCT} \\
%
\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-HINDEXED} &
\mpifunc{MPI\_\-TYPE\_\-GET\_\-EXTENT} \\
%
\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-HVECTOR} &
\mpifunc{MPI\_\-TYPE\_\-GET\_\-TRUE\_\-EXTENT} \\
%
\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-RESIZED} &
~ \\
\hline
\end{tabular}
\caption{Supported MPI-2 new datatype manipulation functions.}
\label{tbl:mpi-details-new-dtype-manip-functions}
\end{table}
%%%%%
\paragraph{New predefined datatypes.}
Support has been added for the
\mpidatatype{MPI\_\-LONG\_\-LONG\_\-INT},
\mpidatatype{MPI\_\-UNSIGNED\_\-LONG\_\-LONG} and
\mpidatatype{MPI\_\-WCHAR} basic datatypes.
%%%%%
\paragraph{Canonical \mpifunc{MPI\_\-PACK}, \mpifunc{MPI\_\-UNPACK}.}
Support is not provided for \mpifunc{MPI\_\-PACK\_\-EXTERNAL},
\mpifunc{MPI\_\-UNPACK\_\-EXTERNAL}, or
\mpifunc{MPI\_\-PACK\_\-EXTERNAL\_\-SIZE}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Process Creation and Management}
Open MPI supports all MPI-2 dynamic process management.
Table~\ref{tbl:mpi-details-dynamic-functions} lists all the supported
functions.
\begin{table}[htbp]
\centering
\begin{tabular}{|lll|}
\hline
\multicolumn{3}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-CLOSE\_\-PORT} &
\mpifunc{MPI\_\-COMM\_\-GET\_\-PARENT} &
\mpifunc{MPI\_\-LOOKUP\_\-NAME} \\
%
\mpifunc{MPI\_\-COMM\_\-ACCEPT} &
\mpifunc{MPI\_\-COMM\_\-JOIN} &
\mpifunc{MPI\_\-OPEN\_\-PORT} \\
%
\mpifunc{MPI\_\-COMM\_\-SPAWN} &
\mpifunc{MPI\_\-COMM\_\-CONNECT} &
\mpifunc{MPI\_\-PUBLISH\_\-NAME} \\
%
\mpifunc{MPI\_\-COMM\_\-DISCONNECT} &
\mpifunc{MPI\_\-COMM\_\-SPAWN\_\-MULTIPLE} &
\mpifunc{MPI\_\-UNPUBLISH\_\-NAME} \\
\hline
\end{tabular}
\caption{Supported MPI-2 dynamic functions.}
\label{tbl:mpi-details-dynamic-functions}
\end{table}
As requested by Open MPI users, \mpifunc{MPI\_\-COMM\_\-SPAWN} and
\mpifunc{MPI\_\-COMM\_\-SPAWN\_\-MULTIPLE} supports some
\mpitype{MPI\_\-Info} keys for spawning MPMD applications and for more
fine-grained control about where children processes are spawned. See
the \file{MPI\_\-Comm\_\-spawn(3)} man page for more details.
These functions supersede the \mpifunc{MPIL\_\-COMM\_\-SPAWN} function
that Open MPI introduced in version 6.2b. Hence,
\mpifunc{MPIL\_\-COMM\_\-SPAWN} is no longer available.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{One-Sided Communication}
Support is provided for get/put/accumulate data transfer operations
and for the post/wait/start/complete and fence synchronization
operations. No support is provided for window locking.
The datatypes used in the get/put/accumulate operations are restricted
to being basic datatypes or single level contiguous/vectors of basic
datatypes.
The implementation of the one-sided operations is layered on top of
the point-to-point functions, and will thus perform no better than
them. Nevertheless it is hoped that providing this support will aid
developers in developing and debugging codes using one-sided
communication.
Table~\ref{tbl:mpi-details-one-sided-functions} lists the functions
related to one-sided communication that have been implemented.
\begin{table}[htbp]
\centering
\begin{tabular}{|lll|}
\hline
\multicolumn{3}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-ACCUMULATE} &
\mpifunc{MPI\_\-WIN\_\-CREATE} &
\mpifunc{MPI\_\-WIN\_\-POST} \\
%
\mpifunc{MPI\_\-GET} &
\mpifunc{MPI\_\-WIN\_\-FENCE} &
\mpifunc{MPI\_\-WIN\_\-START} \\
%
\mpifunc{MPI\_\-PUT} &
\mpifunc{MPI\_\-WIN\_\-FREE} &
\mpifunc{MPI\_\-WIN\_\-WAIT} \\
%
\mpifunc{MPI\_\-WIN\_\-COMPLETE} &
\mpifunc{MPI\_\-WIN\_\-GET\_\-GROUP} &
~ \\
\hline
\end{tabular}
\caption{Supported MPI-2 one-sided functions.}
\label{tbl:mpi-details-one-sided-functions}
\end{table}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Extended Collective Operations}
\label{sec:mpi:extended-collectives}
\changebegin{7.1}
Open MPI implements the new MPI-2 collective functions
\mpifunc{MPI\_\-EXSCAN} and \mpifunc{MPI\_\-ALLTOALLW} for
intracommunicators.
Intercommunicator collectives are implemented for all the functions
listed in Table~\ref{tbl:mpi-details-intercomm-collective-functions}.
Notably, intercommunicator collectives are {\em not} defined for
\mpifunc{MPI\_\-SCAN} (because the MPI standard does not define it),
\mpifunc{MPI\_\-ALLGATHERV}, and
\mpifunc{MPI\_\-EXSCAN}.\footnote{These two functions were
unfortunately overlooked and forgotten about when Open MPI v7.1 was
frozen for release.}
\begin{table}[htbp]
\centering
\begin{tabular}{|lll|}
\hline
\multicolumn{3}{|c|}{Supported Functions} \\
\hline
\hline
\mpifunc{MPI\_\-ALLGATHER} &
\mpifunc{MPI\_\-ALLGATHERV} &
\mpifunc{MPI\_\-ALLTOALL} \\
%
\mpifunc{MPI\_\-ALLTOALLV} &
\mpifunc{MPI\_\-ALLTOALLW} &
\mpifunc{MPI\_\-ALLREDUCE} \\
%
\mpifunc{MPI\_\-REDUCE\_\-SCATTER} &
\mpifunc{MPI\_\-GATHER} &
\mpifunc{MPI\_\-GATHERV} \\
%
\mpifunc{MPI\_\-REDUCE} &
\mpifunc{MPI\_\-BCAST} &
\mpifunc{MPI\_\-SCATTER} \\
%
\mpifunc{MPI\_\-SCATTERV} &
\mpifunc{MPI\_\-BARRIER} &
~ \\
\hline
\end{tabular}
\caption{Supported MPI-2 intercommunicator collective functions.}
\label{tbl:mpi-details-intercomm-collective-functions}
\end{table}
\changeend{7.1}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{External Interfaces}
The external interfaces chapter lists several different major topics.
Open MPI's support for these topics is summarized in
Table~\ref{tbl:mpi-details-ext-int-summary}, and the exact list of
functions that are supported is listed
in~\ref{tbl:mpi-details-ext-int-functions}.
\begin{table}[htbp]
\centering
\begin{tabular}{|c|p{3in}|}
\hline
\multicolumn{1}{|c|}{Supported} &
\multicolumn{1}{|c|}{Description} \\
\hline
\hline
%
\supportno & Generalized requests \\
%
\supportno & Associating information with \mpitype{MPI\_\-Status} \\
%
\supportyes & Naming objects \\
%
\supportno & Error classes \\
\supportno & Error codes \\
\supportyes & Error handlers \\
%
\supportyes & Decoding a datatype \\
%
\supportyes & MPI and threads \\
%
\supportyes & New attribute caching functions \\
%
\supportyes & Duplicating a datatype \\
\hline
\end{tabular}
\caption{Major topics in the MPI-2 chapter ``External Interfaces'',
and Open MPI's level of support.}
\label{tbl:mpi-details-ext-int-summary}
\end{table}
\begin{table}[htbp]
\centering
\begin{tabular*}{\textwidth}{llllll|}
\hline
\multicolumn{6}{|c|}{Supported Functions} \\
\hline \hline
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-SET\_\-NAME}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-SET\_\-NAME}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-SET\_\-NAME}} \\
%
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-GET\_\-NAME}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-GET\_\-NAME}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-GET\_\-NAME}} \\
%
\hline
%
\hline
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-COMM\_\-CREATE\_\-ERRHANDLER}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-WIN\_\-CREATE\_\-ERRHANDLER}} \\
%
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-COMM\_\-GET\_\-ERRHANDLER}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-WIN\_\-GET\_\-ERRHANDLER}} \\
%
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-COMM\_\-SET\_\-ERRHANDLER}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-WIN\_\-SET\_\-ERRHANDLER}} \\
%
\hline
%
\hline
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-TYPE\_\-GET\_\-CONTENTS}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-INIT\_\-THREAD}} \\
%
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-TYPE\_\-GET\_\-ENVELOPE}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-QUERY\_\-THREAD}} \\
%
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-TYPE\_\-GET\_\-EXTENT}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-IS\_\-THREAD\_\-MAIN}} \\
%
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-TYPE\_\-GET\_\-TRUE\_\-EXTENT}} &
\multicolumn{3}{|l|}{\mpifunc{MPI\_\-TYPE\_\-DUP}} \\
%
\hline
%
\hline
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-CREATE\_\-KEYVAL}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-CREATE\_\-KEYVAL}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-CREATE\_\-KEYVAL}} \\
%
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-FREE\_\-KEYVAL}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-FREE\_\-KEYVAL}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-FREE\_\-KEYVAL}} \\
%
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-DELETE\_\-ATTR}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-DELETE\_\-ATTR}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-DELETE\_\-ATTR}} \\
%
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-GET\_\-ATTR}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-GET\_\-ATTR}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-GET\_\-ATTR}} \\
%
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-COMM\_\-SET\_\-ATTR}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-TYPE\_\-SET\_\-ATTR}} &
\multicolumn{2}{|l|}{\mpifunc{MPI\_\-WIN\_\-SET\_\-ATTR}} \\
%
\hline
\end{tabular*}
\caption{Supported MPI-2 external interface functions, grouped by
function.}
\label{tbl:mpi-details-ext-int-functions}
\end{table}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{I/O}
MPI-IO support is provided by including the ROMIO package from Argonne
National Labs,\footnote{\url{http://www.mcs.anl.gov/romio/}} version
1.2.5.1.
%
The Open MPI wrapper compilers (\icmd{mpicc}, \icmd{mpiCC}/\icmd{mpic++},
and \icmd{mpif77}) will automatically provide all the necessary flags
to compile and link programs that use ROMIO function calls.
Although the ROMIO group at Argonne has included support for Open MPI in
their package, there are still a small number of things that the Open MPI
Team had to do to make ROMIO compile and install properly with
Open MPI. As such, if you try to install the ROMIO package manually
with Open MPI, you will experience some difficulties.
There are some important limitations to ROMIO that are discussed in
the \file{romio/README} file.
%
One limitation that is not currently listed in the ROMIO README file
is that atomic file access will not work with AFS. This is because of
file locking problems with AFS (i.e., AFS iteself does not support
file locking). The ROMIO test program \cmd{atomicity} will fail if
you specify an output file on AFS.
Additionally, ROMIO does not support the following Open MPI functionality:
\begin{itemize}
\item Open MPI MPI-2 datatypes cannot be used with ROMIO; ROMIO makes the
fundamental assumption that MPI-2 datatypes are built upon MPI-1
datatypes. Open MPI builds MPI-2 datatypes natively -- ROMIO cannot
presently handle this case.
This will hopefully be fixed in some future release of ROMIO. The
ROMIO test programs \cmd{coll\_\-test}, \cmd{fcoll\_\-test},
\cmd{large\_\-array}, and \cmd{coll\_\-perf} will fail because they
use the MPI-2 datatype \mpidatatype{MPI\_\-DARRAY}.
\end{itemize}
Please see the sections ``ROMIO Users Mailing List'' and ``Reporting
Bugs'' in \file{romio/README} for how to submit questions and bug
reports about ROMIO (that do not specifically pertain to Open MPI).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Language Bindings}
Open MPI provides C, C++, and Fortran 77 bindings for all supported MPI-2
functions, types, and constants. Open MPI does not provide a Fortran 90
module.
%
However, it is possible to use the Fortran 77 bindings with a Fortran
90 compiler by specifying the F90 compiler as your Fortran compiler
when configuring/compiling Open MPI. See the Open MPI Installation
Guide~\cite{lamteam03:_lam_mpi_install_guide} for more details.
The C++ bindings include support for the C++ only \mpitype{MPI::BOOL},
\mpitype{MPI::COMPLEX}, \mpitype{MPI::DOUBLE\_\-COMPLEX}, and
\mpitype{MPI::LONG\_\-DOUBLE\_\-COMPLEX} datatypes.
Note that there are some issues with using MPI and Fortran 90
together. See the F90 / C++ chapter in the MPI-2
standard~\cite{geist96:_mpi2_lyon} for more information on using MPI
with Fortran 90.
As mentioned in Section~\ref{sec:mpi-details-mpi1-language}, profiling
support is available in all three languages (if Open MPI was compiled
with profiling support). The \icmd{ompi\_info} command can be used to
see if profiling support was included in Open MPI.

Двоичные данные
doc/user/openmpi_logo-only.png

Двоичный файл не отображается.

До

(image error) Размер: 10 KiB

@ -1,186 +0,0 @@
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
@Manual{gnu-code-standards,
title = {GNU Coding Standards},
author = {Richard Stallman et al.},
organization = {Free Software Foundation},
month = {October},
year = 2001,
note = {Included in the GNU {\tt autoconf} distribution; see {\tt ftp://ftp.gnu.org/gnu/autoconf/}}
}
@Manual{lamteam03:_lam_mpi_user_guide,
title = {Open MPI User's Guide},
author = {The Open MPI Team},
organization = {The Open MPI Project}
}
@Manual{lamteam03:_lam_mpi_install_guide,
title = {Open MPI Installation Guide},
author = {The Open MPI Team},
organization = {The Open MPI Project}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% ROMIO
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@InProceedings{thak99b,
author = {Rajeev Thakur and William Gropp and Ewing Lusk},
title = {On Implementing {MPI-IO} Portably and with High Performance},
booktitle = {Proceedings of the 6th Workshop on I/O in Parallel and
Distributed Systems},
pages = {23--32},
year = {1999},
month = {May},
pubaddress = "New York, NY",
publisher = {ACM Press}
}
@InProceedings{thak99a,
author = {Rajeev Thakur and William Gropp and Ewing Lusk},
title = {Data Sieving and Collective {I/O} in {ROMIO}},
booktitle = {Proceedings of the 7th Symposium on the Frontiers of Massively
Parallel Computation},
pages = {182--189},
year = {1999},
month = {February},
publisher = {IEEE Computer Society Press}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% MPI
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@Book{ gropp94:_using_mpi,
author = "William Gropp and Ewing Lusk and Anthony Skjellum",
title = "Using {MPI}: {P}ortable {P}arallel {P}rogramming
with the {M}essage {P}assing {I}nterface",
publisher = "MIT Press",
year = 1994
}
@Book{ gropp99:_using_mpi_2,
author = "William Gropp and Ewing Lusk and Rajeev Thakur",
title = "Using {MPI-2}: {A}dvanced {F}eatures of the
{M}essage {P}assing {I}nterface",
publisher = "MIT Press",
year = 1999
}
@Book{ snir96:_mpi_the_compl_refer,
author = "Marc Snir and Steve W. Otto and Steve Huss-Lederman
and David W. Walker and Jack Dongarra",
title = "{MPI}: {T}he {C}omplete {R}eference",
address = "Cambridge, MA",
publisher = "MIT Press",
year = 1996
}
@Book{gropp98:_mpi2,
author = {William Gropp and Steven Huss-Lederman and Andrew
Lumsdaine and Ewing Lusk and Bill Nitzberg and
William Saphir and Marc Snir},
title = {{MPI} --- {T}he Complete Reference: {V}olume 2, the
{MPI}-2 Extensions},
publisher = {MIT Press},
year = 1998
}
@inproceedings{ mpi_forum93:_mpi,
title = "{MPI}: {A} {M}essage {P}assing {I}nterface",
author = "{Message Passing Interface Forum}",
booktitle = "Proc.~of Supercomputing '93",
publisher = "{IEEE} Computer Society Press",
place = "Portland, OR",
month = "November",
pages = "878--883",
year = 1993
}
@InProceedings{ geist96:_mpi2_lyon,
author = "Al Geist and William Gropp and Steve Huss-Lederman
and Andrew Lumsdaine and Ewing Lusk and William
Saphir and Tony Skjellum and Marc Snir",
title = "{MPI}-2: {E}xtending the {M}essage-{P}assing {I}nterface",
booktitle = "Euro-Par '96 Parallel Processing",
editor = "Luc Bouge and Pierre Fraigniaud and Anne Mignotte
and Yves Robert",
number = 1123,
series = "Lecture Notes in Computer Science",
year = 1996,
publisher = "Springer Verlag",
pages = "128--135"
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% MagPIe
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@inproceedings{kielmann++:00:magpie_bandwidth,
author = {Thilo Kielmann and Henri E. Bal and Sergei Gorlatch},
title = {{Bandwidth-efficient Collective Communication
for Clustered Wide Area Systems}},
booktitle = {{International Parallel and Distributed Processing Symposium
(IPDPS 2000)}},
address = {Cancun, Mexico},
month = {May},
year = 2000,
pages = {492--499},
publisher = {IEEE}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% BLCR
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@Misc{BLCR02,
author = {Jason Duell and Paul Hargrove and Eric Roman},
title = {{T}he {D}esign and {I}mplementation of {B}erkeley {L}ab's
{L}inux {C}heckpoint/{R}estart},
year = {2002}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% random
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@Misc{Netpipe96,
author = "Q. Snell and A. Mikler and J. Gustafson",
title = "{NetPIPE}: {A} {N}etwork {P}rotocol {I}ndependent {P}erformace
{E}valuator",
text = "Q.O. Snell, A.Mikler, and J.L. Gustafson. Netpipe: A Network
Protocol Independent Performance Evaluator. In IASTED International Conference
on Intelligent Information Management and Systems, June 1996.",
year = "1996"
}

@ -1,145 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Release Notes}
\label{sec:release-notes}
\index{release notes|(}
This chapter contains release notes as they pertain to the run-time
operation of Open MPI. The Installation Guide contains additional
release notes on the configuration, compilation, and installation of
Open MPI.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Alpha Release}
Greetings!
The Open MPI development team is pleased to announce an alpha-quality
release of the current state of our software to a limited set of
"friends" -- those who are knowledgeable about MPI and can provide
intelligent feedback to us before a public release. Our intent with
this release is to get the Open MPI software onto other people's
machines and see what creative ways you can come up with to break it,
and to send us your comments and suggestions.
However, we want to stress the following points:
\begin{itemize}
\item This is an {\em alpha} quality release. We're quite aware that
there are several things still broken (but report them anyway!).
\item Most notably, if you run basic performance testing, you'll
notice that, for example, the GM numbers are still a microsecond or
two too high (we've been concentrating on functionality for the last
month -- performance tuning is coming shortly).
\item Since the competition in the HPC community is rather fierce,
please do not redistribute this software without our permission.
Also, please do not publish any results (good or bad) because, as
mentioned above, this is pre-release software and we still have
performance tuning to do.
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Release Frequency / Updates}
You have probably downloaded this tarball from
\url{http://www.open-mpi.org/nightly/}. This directory is updated at
least once a day around 2am US/Indiana time (assuming that there is
new code to release). It may be updated more frequently if a critical
bug fix is reported and fixed.
The best way to report bugs, send comments, or ask questions is to
sign up on the \url{mailto:devel@open-mpi.org} mailing list:
\centerline{\url{http://www.open-mpi.org/mailman/listinfo.cgi/devel}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Known Issues}
This tarball is an alpha release of Open MPI. It is not yet complete,
mainly in the following areas:
\begin{itemize}
\item Support for Infiniband (both verbs and OpenIB) is missing
\item Support for Quadrics is missing
\item Support for Myrinet needs performance tuning
\item Support for MX needs performance tuning
\item Support for TCP needs performance tuning
\item Support for shared memory is not fully debugged
If this becomes a problem during your testing, run the following:
\lstset{style=ompi-cmdline}
\begin{lstlisting}
shell$ rm -f <prefix>/lib/openmpi/*sm*
\end{lstlisting}
% Stupid emacs mode: $
where \cmdarg{<prefix>} is the directory where you installed Open
MPI.
\item Striping MPI messages across multiple networks is supported (and
happens automatically when multiple networks are available), but
needs performance tuning
\item The only run-time systems supported are:
\begin{itemize}
\item \cmd{rsh} / \cmd{ssh}
\item BProc of the flavor that is used at Los Alamos National Labs (in
particular, it must be used with the BJS scheduler)
\end{itemize}
\item TotalView and other parallel debugger support is missing.
\item Complete user and system administrator documentation is missing
(this file comprises the majority of the current user documentation)
\item The only systems that have been tested on are:
\begin{itemize}
\item Linux, 32 bit, with \cmd{gcc}
\end{itemize}
\item Other systems have been lightly (but not fully tested):
\begin{itemize}
\item Linux, 64 bit, with \cmd{gcc}
\item OS X (10.3), 32 bit, with \cmd{gcc}
\end{itemize}
\item Missing MPI functionality:
\begin{itemize}
\item The Fortran 90 MPI API is disabled (it is not complete).
\item MPI-2 dynamic functionality is temporarily broken.
\item MPI-2 one-sided functionality will not be included in the
first few releases of Open MPI
\end{itemize}
\item After running MPI applications, the directory
\file{/tmp/openmpi-sessions-<username>@<hostname>*} will exist (but
will likely be empty). It is safe to remove.
\end{itemize}
\index{release notes|)}

@ -1,52 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\title{Open MPI User's Guide \\
Version \ompiversion \\
\ \\
\centerline{\includegraphics[width=2in]{openmpi_logo-only}}}
\author{The Open MPI Team \\
\url{http://www.open-mpi.org/}}
\maketitle
\thispagestyle{empty}
\newpage
\vspace*{6in}
\noindent
Copyright $\copyright$ 2004-2005 The Trustees of Indiana University.
All rights reserved. \\
Copyright $\copyright$ 2004-2005 The Trustees of the University of
Tennessee.
All rights reserved. \\
Copyright $\copyright$ 2004-2005 High Performance Computing Center
Stuttgart, University of Stuttgart. All rights
reserved. \\
Copyright $\copyright$ 2004-2005 The Regents of the University of
California.
All rights reserved. \\
Additional copyrights may follow
{\Huge JMS need to find event library copyright notice}
{\Huge JMS need to find ROMIO copyright notice}

@ -1,249 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\chapter{Troubleshooting}
\label{sec:troubleshooting}
{\Huge JMS Not bad, but needs tweaking}
Although Open MPI is a robust run-time environment, and its MPI layer
is a mature software system, errors do occur. Particularly when using
Open MPI for the first time, some of the initial, per-user setup can
be confusing (e.g., setting up \ifile{.rhosts} or SSH keys for
password-less remote logins). This section aims to identify a few
common problems and solutions.
Much more information can be found on the Open MPI FAQ on the main
Open MPI web site.\footnote{\url{http://www.open-mpi.org/faq/}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{The Open MPI Mailing Lists}
\label{troubleshooting:mailing-lists}
\index{e-mail lists}
\index{mailing lists}
\index{listserv mailing lists}
There are two mailing lists: one for Open MPI announcements, and
another for questions and user discussion of Open MPI.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Announcements}
This is a low-volume list that is used to announce new version of
Open MPI, important patches, etc. To subscribe to the Open MPI announcement
list, visit its list information page (you can also use that page to
unsubscribe or change your subscription options):
\vspace{11pt}
\centerline{\url{http://www.lam-mpi.org/mailman/listinfo.cgi/lam-announce}}
\vspace{11pt}
\noindent {\bf NOTE: Users cannot post to this list; all such posts
are automatically rejected -- only the Open MPI Team can post to this
list.}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{General Discussion / User Questions}
{\bf BEFORE YOU POST TO THIS LIST:} {\em Please} check all the other
resources listed in this chapter first. Search the mailing list to
see if anyone else had a similar problem before you did. Re-read the
error message that Open MPI displayed to you (Open MPI can sometimes give {\em
incredibly} detailed error messages that tell you {\em exactly} how
to fix the problem). This, unfortunately, does not stop some users
from cut-n-pasting the entire error message, verbatim (including the
solution to their problem) into a mail message, sending it to the
list, and asking ``How do I fix this problem?'' So please: think (and
read) before you post.\footnote{Our deep appologies if some of the
information in this section appears to be repetitive and
condescending. Believe us when we say that we have tried all other
approaches -- some users simply either do not read the information
provided, or only read the e-mail address to send ``help!'' e-mails
to. It is our hope that big, bold print will catch some people's
eyes and enable them to help themselves rather than having to wait
for their post to distribute around the world and then further wait
for someone to reply telling them that the solution to their problem
was already printed on their screen. Thanks for your time in
reading all of this!}
\vspace{11pt}
This list is used for general questions and discussion of Open MPI.
User can post questions, comments, etc. to this list. {\bf Due to
recent increases in spam, only subscribers are allowed to post to
the list}. If you are not subscribed to the list, your posts will
be discarded.
To subscribe or unsubscribe from the list, visit the list information
page:
\vspace{11pt}
\centerline{\url{http://www.lam-mpi.org/mailman/listinfo.cgi/lam}}
\vspace{11pt}
After you have subscribed (and received a confirmation e-mail), you
can send mail to the list at the following address:
\vspace{11pt}
\centerline{{\bf You must be subscribed in order to post to the list}}
\centerline{\url{lam@lam-mpi.org}}
\centerline{{\bf You must be subscribed in order to post to the list}}
\vspace{11pt}
Be sure to include the following information in your e-mail:
\begin{itemize}
\item The \file{config.log} file from the top-level Open MPI directory, if
available ({\bf please compress!}).
\item The output of ``\icmd{laminfo}\ \ \cmdarg{-all}''.
\item A {\em detailed} description of what is failing. The more
details that you provide, the better. E-mails saying ``My
application doesn't work!'' will inevitably be answered with
requests for more information about {\em exactly what doesn't work};
so please include as much detailed information in your initial
e-mail as possible.
\end{itemize}
{\bf NOTE:} People tend to only reply to the list; if you subscribe,
post, and then unsubscribe from the list, you will likely miss
replies.
Also please be aware that the list goes to several hundred people
around the world -- it is not uncommon to move a high-volume exchange
off the list, and only post the final resolution of the problem/bug
fix to the list. This prevents exchanges like ``Did you try X?'',
``Yes, I tried X, and it did not work.'', ``Did you try Y?'', etc.
from cluttering up peoples' inboxes.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Open MPI Run-Time Environment Problems}
Some common problems with the Open MPI run-time environment are listed
below.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Problems with the \icmd{lamboot} Command}
Many first-time Open MPI users do not have their environment properly
configured for Open MPI to boot properly. Refer to
Section~\ref{sec:getting-started-lamboot} for the list of conditions
that Open MPI requires to boot properly. User problems with \cmd{lamboot}
typically fall into one of the following categories:
\begin{itemize}
\item \cmd{rsh}/\cmd{ssh} is not set up properly for password-less
logins to remote nodes.
{\bf Solution:} Set up \cmd{rsh}/\cmd{ssh} properly for
password-less remote logins. Consult local documentation or
internet tutorials for how to set up \file{\$HOME/.rhosts} and SSH
keys. Note that the Open MPI Team {\bf STRONGLY} discourages the use of
\cmdarg{+} in \file{.rhosts} or \file{host.equiv} files!
\item \cmd{rsh}/\cmd{ssh} prints something on \file{stderr}.
{\bf Solution:} Clean up system or user ``dot'' files so that
nothing is printed on \file{stderr} during a remote login.
\item A Open MPI daemon is unable to open a connection back to
\cmd{lamboot}.
{\bf Solution:} Many Linux distributions ship with firewalls
enabled. Open MPI uses random TCP ports to communicate, and
therefore firewall support must be either disabled or opened between
machines that will be using Open MPI.
\item Open MPI is unable to open a session directory.
{\bf Solution:} Open MPI needs to use a per-user, per-session temporary
directory, typically located under \file{/tmp} (see
Section~\ref{sec:misc-session-directory},
page~\pageref{sec:misc-session-directory}). Open MPI must be able to
read/write in this session directory; check permissions in this
tree.
\item Open MPI is unable to find the current host in the boot schema.
{\bf Solution:} Open MPI can only boot a universe that includes the
current node. If the current node is not listed in the hostfile, or
is not listed by a name that can be resolved and identified as the
current node, \cmd{lamboot} (and friends) will abort.
\item Open MPI is unable to resolve all names in the boot schema.
{\bf Solution:} All names in the boot schema must be resolvable by
the boot SSI module that is being used. This typically means that
there end up being IP hostnames that must be resolved to IP
addresses. Resolution can occur by any valid OS mechanism (e.g.,
through DNS, local file lookup, etc.). Note that the name ``{\tt
localhost}'' (or any address that resolves to 127.0.0.1) cannot be
used in a boot schema that includes more than one host -- otherwise
the other nodes in the resulting Open MPI universe will not be able to
contact that host.
\end{itemize}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{MPI Problems}
For the most part, Open MPI implements the MPI standard similarly to other
MPI implementations. Hence, most MPI programmers are not too
surprised by how Open MPI handles various errors, etc. However, there are
some cases that Open MPI handles in its own unique fashion. In these cases
Open MPI tries to display a helpful message discussing what happened.
Here's some more background on a few of the messages:
\begin{itemize}
\item ``One of the processes started by mpirun has exited with a
nonzero exit code.''
This means that at least one MPI process has exited after invoking
\mpifunc{MPI\_\-INIT}, but before invoking
\mpifunc{MPI\_\-FINALIZE}. This is therefore an error, and Open MPI
will abort the entire MPI application. The last line of the error
message indicates the PID, node, and exit status of the failed
process.
\item ``MPI\_{\tt <function>}: process in local group is dead (rank
{\tt <N>}, MPI\_\-COMM\_\-WORLD)''
This means that some MPI function tried to communicate with a peer
MPI process and discovered that the peer process is dead. Common
causes of this problem include attempting to communicate with
processes that have failed (which, in some cases, won't generate the
``One of the processes started by mpirun has exited...'' messages),
or have already invoked \mpifunc{MPI\_\-FINALIZE}. Communication
should not be initiated that could involve processes that have
already invoked \mpifunc{MPI\_\-FINALIZE}. This may include using
\mpiconst{MPI\_\-ANY\_\-SOURCE} or collectives on communicators that
include processes that have already finalized.
\end{itemize}

@ -1,49 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\documentclass[11pt]{book}
\input{defs}
\begin{document}
\include{titlepage}
\tableofcontents
%\listoftables
%\include{audience}
\include{introduction}
\include{release-notes}
%\include{getting-started}
%\include{mpi-details}
%\include{mca}
%\include{commands}
%\include{mca-orte}
%\include{mca-ompi}
%\include{debuggers}
%\include{troubleshooting}
%\include{misc}
\include{bibliography}
\printindex
\end{document}

@ -1,20 +0,0 @@
% -*- latex -*-
%
% Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
% University Research and Technology
% Corporation. All rights reserved.
% Copyright (c) 2004-2005 The University of Tennessee and The University
% of Tennessee Research Foundation. All rights
% reserved.
% Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
% University of Stuttgart. All rights reserved.
% Copyright (c) 2004-2005 The Regents of the University of California.
% All rights reserved.
% $COPYRIGHT$
%
% Additional copyrights may follow
%
% $HEADER$
%
\def\ompiversion{@OMPI_VERSION@}