?? hpec2001_abstract.tex
字號(hào):
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\documentstyle[11pt,psfig]{article}\documentclass[11pt]{article}\usepackage{graphicx}%\usepackage[pdftex]{graphicx}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\setlength{\oddsidemargin}{-0.5in}\setlength{\evensidemargin}{-0.5in}\setlength{\topmargin}{-0.5in}\setlength{\textwidth}{7.5in}\setlength{\textheight}{10in}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% MACROS%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\def \BDM {\begin{displaymath}}\def \EDM {\end{displaymath}}\def \BEQ {\begin{equation}}\def \EEQ {\end{equation}}\def \BEQA {\begin{eqnarray}}\def \EEQA {\end{eqnarray}}\def \NN {\nonumber}\def \BL {\begin{list}}\def \EL {\end{list}}\def \BENUM {\begin{enumerate}}\def \EENUM {\end{enumerate}}\def \BITEM {\begin{itemize}}\def \EITEM {\end{itemize}}\def \BARR {\begin{array}}\def \EARR {\end{array}}\newcommand{\CVar}[1]{\texttt{#1}}\begin{document}%\DeclareGraphicsExtensions{.jpg,.pdf,.mps,.png}% Title information.\title{Parallel Programming with MatlabMPI\thanks{This work is sponsored by the High Performance Computing ModernizationOffice, under Air Force ContractF19628-00-C-0002. Opinions, interpretations, conclusions andrecommendations are those of the author and are not necessarily endorsedby the Department of Defense.}}\author{Jeremy Kepner (kepner@ll.mit.edu)MIT Lincoln Laboratory, Lexington, MA 02420 \\}\maketitle%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\begin{abstract}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% MatlabMPI is a Matlab implementation of the Message Passing Interface(MPI) standard and allows any Matlab program to exploit multipleprocessors. MatlabMPI currently implements the basic six functions thatare the core of the MPI point-to-point communications standard. The keytechnical innovation of MatlabMPI is that it implements the widely usedMPI ``look and feel'' on top of standard Matlab file I/O, resulting inan extremely compact ($\sim$100 lines) and ``pure'' implementation which runsanywhere Matlab runs. The performance has been tested on both sharedand distributed memory parallel computers. MatlabMPI can match thebandwidth of C based MPI at large message sizes. A test image filteringapplication using MatlabMPI achieved a speedup of $\sim$70 on a parallelcomputer.\end{abstract}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\section{Introduction}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Matlab \cite{Matlab} is the dominant programming language forimplementing numerical computations and is widely used for algorithmdevelopment, simulation, data reduction, testing and system evaluation. Many of these computations can benefit from faster execution on aparallel computer. There have been many previous attempts to provide anefficient mechanism for running Matlab programs on parallel computers\cite{MATABP,Morrow98,ParAl,RTExpress,Tseng99,MultiMATLAB, ParaMat,Fabozzi99,Matpar,MPITB,Quinn,CMTM}.These efforts of have faced numerous challenges and none havereceived widespread acceptance. In the world of parallel computing the Message Passing Interface (MPI)\cite{MPI} is the de facto standard for implementing programs on multipleprocessors. MPI defines C language functions for doing point-to-pointcommunication in a parallel program. MPI has proven to be an effectivemodel for implementing parallel programs and is used by many of theworlds' most demanding applications (weather modeling, weaponssimulation, aircraft design, and signal processing simulation). MatlabMPI consists of a set of Matlab scripts that implements a subsetof MPI and allows any Matlab program to be run on a parallel computer.The key innovation of MatlabMPI is that it implements the widely usedMPI ``look and feel'' on top of standard Matlab file I/O, resulting in a``pure'' Matlab implementation that is exceedingly small ($\sim$100 linesof code). Thus, MatlabMPI will run on any combination of computers thatMatlab supports.%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\section{System Requirements}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% On shared memory systems, MatlabMPI only requires a single Matlablicense since any user is allowed to launch many Matlab sessions. On adistributed memory system, MatlabMPI requires one Matlab license permachine. Because MatlabMPI uses file I/O for communication, there mustalso be a directory that is visible to every machine (this is usuallyalso required in order to install Matlab). This directory defaults tothe directory that the program is launched from, but can be changedwithin the MatlabMPI program.%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\section{Performance Test Results}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% The vast majority of potential Matlab applications are ``embarrassingly''parallel and require minimal performance out of MatlabMPI. Theseapplications exploit coarse grain parallelism and communicate rarely(if at all). Never-the-less, measuring performance is usefulfor determining which applications are most suitable for MatlabMPI. MatlabMPI has been run on several Unix platforms. It has beenbenchmarked and compared to the performance of C MPI on the SGI Origin2000. These results indicate that for large messages ($\sim$1 MByte)MatlabMPI is able to match the performance of C MPI (seeFigure~\ref{fig:bandwidth}). For smaller messages, MatlabMPI isdominated by its latency ($\sim$35 milliseconds), which is significantlylarger than C MPI. To further test MatlabMPI a test application using MatlabMPI in asimple image filtering application was written. The application executedrepeated 2D convolutions on a large image (1000 x 128,000 pixels $\sim$2 GBytes). This program demonstrates that the MPI standard is validwithin the Matlab environment and allows parallel programs to be writtenquickly and easily. Furthermore, this application achieved excellentspeedups (greater than 64 on 64 processors) and shows the classicsuper-linear speedup (due to better cache usage) that comes frombreaking a very large memory problem into many smaller problems (seeFigure~\ref{fig:speedup}).%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\section{Discussion and Future Work}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% MatlabMPI demonstrates that the standard approach to writing parallelprograms in C and Fortran (i.e. using MPI) is also valid in Matlab. Inaddition, by using Matlab file I/O, it was possible to implement MatlabMPIentirely within the Matlab environment, making it instantly portableto all computers that Matlab runs on. Most potential parallel Matlabapplications are trivially parallel and don't require high performance. Never-the-less, MatlabMPI can match C MPI performance on large messages. The use of file I/O as a parallel communication mechanism is not newand is now increasingly feasible with the availability of low cost highspeed disks. The extreme example of this approach are the now popularStorage Area Networks (SAN), which combine high speed routers and disksto provide server solutions. Although using file I/O increases thelatency of messages it normally will not effect the bandwidth. Furthermore, the use of file I/O has several additional functionaladvantages which make it easy to implement large buffer sizes,recordable messages, multi-casting, and one-sided messaging. Finally,the MatlabMPI approach is readily applied to any language (e.g. IDL,Python, and Perl). The simplicity and performance of MatlabMPI makes it a very reasonablechoice for programmers that want to speed up their Matlab code on aparallel computer. Further work will aim at enhancing the performance ofMatlabMPI and increase the number MPI functions.%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% FIGURE CAPTIONS%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\begin{figure}[tbh]\centerline{\includegraphics[width=4.5in]{MatlabMPI_bandwidth.eps}}\caption{ {\bf Bandwidth.} Communication performance as a function message size on the SGI Origin2000.MatlabMPI equals C MPI performance at large message sizes.}\label{fig:bandwidth}\end{figure}\begin{figure}[tbh]\centerline{\includegraphics[width=4.5in]{MatlabMPI_speedup.eps}}\caption{ {\bf Parallel Speedup.} Speed increase on the SGI Origin2000 of a parallel image filteringapplication as a function of the number of processors. Application shows``classic'' super-linear performance (due to better cache usage) thatresults when a very large memory problem is broken into multiple smallmemory problems.}\label{fig:speedup}\end{figure}\newpage%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\begin{thebibliography}{99}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\bibitem{Matlab} Matlab, The MathWorks, Inc., http://www.mathworks.com/products/matlab/\bibitem{MPI} Message Passing Interface (MPI), http://www.mpi-forum.org/\bibitem{MATABP} MATLAB*P, A. Edelman, MIT, http://www-math.mit.edu/$\sim$edelman/\bibitem{Morrow98} A Parallel Linear Algebra Server for Matlab-like Environments, G. Morrow and Robert van de Geijn, 1998, Supercomputing 98 http://www.supercomp.org/sc98/TechPapers/sc98\_FullAbstracts/Morrow779/index.htm\bibitem{ParAl} Automatic Array Alignment in Parallel Matlab Scripts, I. Milosavljevic and M. Jabri, 1998\bibitem{RTExpress} Parallel MATLAB Development for High Performance Computing with RTExpress, http://www.rtexpress.com/\bibitem{Tseng99} MATLAB Parallel Example, Kadin Tseng, http://scv.bu.edu/SCV/Origin2000/matlab/MATLABexample.shtml\bibitem{MultiMATLAB} MultiMATLAB: MATLAB on Multiple Processors A. Trefethen et al, http://www.cs.cornell.edu/Info/People/lnt/multimatlab.html\bibitem{ParaMat} ParaMat, http://www.alphadata.co.uk/dsheet/paramat.html\bibitem{Fabozzi99} Investigation of the Parallelization of AEW Simulations Written in MATLAB, Don Fabozzi 1999, HPEC99\bibitem{Matpar} Matpar: Parallel Extensions to MATLAB, http://hpc.jpl.nasa.gov/PS/MATPAR/\bibitem{MPITB} MPI Toolbox for Matlab (MPITB), http://atc.ugr.es/javier-bin/mpitb\_eng\bibitem{Quinn} A MATLAB Compiler for Parallel Computers. M. Quinn, http://www.cs.orst.edu/$\sim$quinn/matlab.html\bibitem{CMTM} Cornell Multitask Toolbox for MATLAB (CMTM), http://gremlin.tc.cornell.edu/er/media/2000/cmtm.html\end{thebibliography}\end{document}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -