MCS 572: Introduction to Supercomputing
The goal of the course is to study parallel algorithms and
their implementation on distributed and shared memory computers,
using message passing, OpenMP, and threads.
In the second part of the course we will consider general purpose
graphics processing units. Prerequisites are a working knowledge
of C (or willingness to acquire programming skills) and a familiary
with algorithms at the level of introductory numerical analysis.
The evaluation of the course consists mainly of homework and
computer projects. Exams are scheduled as preparation for the
computational science prelim.
The recommended (not required) textbooks are
- "Parallel Programming. Techniques
and Applications Using Networked Workstations and Parallel
Computers"
by Barry Wilkinson and Michael Allen, Pearson Prentice Hall,
second edition, 2005.
- "Programming Massively Parallel Processors.
A Hands-on Approach"
by David B. Kirk and Wen-mei W. Hwu,
Elsevier/Morgan Kaufmann Publishers, 2010; second edition, 2013.
Lecture notes are available
The lecture notes are still a work in progress.
Slides for the lectures will be posted below.
- L-1 08/22/16: welcome to mcs 572.
We define supercomputing, speedup and efficiency.
Gustafson's Law reevaluates Ahmdahl's Law.
Slides
- L-2 08/24/16: scalability and classifications.
We classify computers and introduce network topology and terminology.
Slides
- L-3 08/26/16: high level parallel processing.
We show high level parallel processing with three examples:
GPU acceleration in Maple, Python multiprocessing and Ada multitasking.
Slides
Maple worksheets
enablecuda.mw and
enablecuda2.mw.
Python scripts:
multiprocess.py,
simpson4pi.py,
simpson4pi1.py, and
simpson4pi2.py.
Ada programs:
simpson4pi.adb and
simpson4pitasking.adb.
- L-4 08/29/16: basics of MPI.
We are getting started with message passing, using C and Python.
Our first MPI programs execute a broadcast of data.
Slides
Simple C programs:
mpi_hello_world.c,
broadcast_integer.c, and
broadcast_doubles.c.
Python scripts:
mpi4py_hello_world.py,
mpi4py_hello_world3.py (for Python 3),
mpi4py_broadcast.py and
mpi4py_broadcast3.py (for Python 3).
- L-5 08/31/16: using MPI.
We introduced the broadcasting of data and gathering of results with MPI.
Point-to-point communications happen with the send and receive commands.
Slides
Simple C programs
parallel_sum.c and
parallel_square.c.
Python scripts using mpi4py
mpi4py_point2point.py and
mpi4py_parallel_sum.py.
- L-6 09/02/16: Pleasingly Parallel Computations
are parallel computations with minimal communication overhead.
Slides
Simple C programs
sprng_hello.c,
sprng_seed.c,
sprng_estpi.c,
sprng_estpi_mpi.c,
sprng_normal.c,
sprng_normald.c, and
sprng_mtbf.c.
- L-7 09/07/16: Load Balancing.
We illustrate static and dynamic load balancing on the parallel
computation of the Mandelbrot set.
Slides
Some simple C programs:
mandelbrot.c,
static_loaddist.c, and
dynamic_loaddist.c.
- L-8 09/09/16: Data Partitioning.
We define the fan out broadcast and the fanning in of results.
Slides.
A simple C program:
fan_out_integers.c.
- L-9 09/12/16: Introduction to OpenMP.
To write parallel programs for shared memory computers
we can use OpenMP.
Slides.
Simple C programs:
hello_openmp0.c,
hello_openmp1.c,
comptrap.c, and
comptrap_omp.c.
- L-10 09/14/16: Introduction to Pthreads.
Pthreads is a C language threads programming interface
to program shared memory parallel computers with POSIX threads,
where POSIX stands for Portable Operating System Interface.
We illustrate the implementation of the work crew model.
Slides.
Two simple C programs:
hello_pthreads.c and
process_jobqueue.c.
- L-11 09/16/16: Introduction
to the Intel Threading Building Blocks.
Today we introduce a third tool to write parallel programs
on parallel shared memory computers.
Slides.
Some simple C++ programs
hello_task_group.cpp,
powers_serial.cpp,
powers_tbb.cpp, and
parsum_tbb.cpp.
- L-12 09/19/16: Parallel Sorting Algorithms.
We study parallel bucket sort on distributed memory computers.
On shared memory computers, we examine a parallel quicksort.
Slides.
Simple C programs using qsort:
use_qsort.c,
time_qsort.c,
part_qsort.c, and
part_qsort_omp.c.
simple C++ programs using STL sort:
use_stl_sort.cpp,
time_stl_sort.cpp, and
tbb_sort.cpp.
- L-13 09/21/16: Parallel Numerical Integration.
We take a look at Romberg integration, and consider parallel versions
for shared memory with OpenMP and Intel TBB.
Slides.
Simple C++ programs:
qd4sqrt2.cpp,
romberg4piqd.cpp,
romberg4piqd_omp.cpp, and
parsumqd_tbb.cpp.
- L-14 09/23/16: Parallel FFT and Isoefficiency.
The Fast Fourier Transform has many applications
and we illustrate its use through the FFTW software library,
which runs in parallel.
The definition of isoefficiency provides another look at scalability.
Slides.
Some simple C programs:
fftw_use.c,
fftw_timing.c, and
fftw_timing_omp.c.
- L-15 09/26/16: Pipelined Computations.
As in the manufactoring of cars, arranging the stages in a computation
along a pipeline speeds up the computations.
Slides.
Some simple C programs:
pipe_ring.c and
pipe_sum.c.
- L-16 09/28/16: Pipelined Sorting.
We illustrate pipelined sorting algorithms with the MPI and the Intel
Threading Building Blocks. Slides.
Some simple C/C++ programs:
pipe_sort.c,
pipe_tbb.cpp, and
primes_main.cpp.
- L-17 09/30/16: Solving Triangular Systems.
We introduce the third type of pipelines
and apply them to solving triangular linear systems.
Slides.
Some simple C/C++ programs:
triangularsolve.c,
triangularsolve_qd.cpp (with QD), and
triangularsolve_qd_omp.cpp
(with QD and OpenMP).
- L-18 10/03/16: Barriers for Synchronizations.
For message passing, we distinguish between a linear, a tree, and
a butterfly barrier. We end with a simple illustration of barriers
with Pthreads.
Slides.
Some simple C programs:
use_sendrecv.c,
prefix sum.c, and
pthread_barrier example.c.
- L-19 10/05/16: Parallel Iterative Methods for Linear Systems.
We look at Jacobi's method. Slides.
Some simple C programs:
use_allgather.c,
jacobi.c, and
jacobi_mpi.c.
- L-20 10/07/16: Solving the Heat Equation.
We continue our investigations into parallel synchronized iterations.
Slides.
Some simple C programs:
gauss_seidel.c and
gauss_seidel_omp.c.
- L-21 10/10/16: parallel Gaussian elimination.
We consider tiled Cholesky and LU factorizations.
Slides.
- L-22 10/12/16: parallel numerical linear algebra.
We continue the previous lecture with a tiled QR decomposition
and Krylov subspace iterations.
Slides.
- L-23 10/14/16: disk based parallelism.
Not all applications are computationally intensive
but involve massive amounts of data.
The topic of today is disk based parallelism.
Slides.
- L-24 10/17/16: introduction to Hadoop.
Hadoop is an open source tool which implements the MapReduce paradigm
to process massive data sets.
Slides.
- L-25 10/19/16: review for the midterm exam.
- L-26 10/21/16: midterm exam on the first 24
lectures.
In the second part of the course we look at massively parallel algorithms
on a general purpose graphics processing unit (GPGPU).