Structured Exception Semantics for Parallel Loops

Joel A. Winstead

January 2002

A Thesis
Presented to
the faculty of the School of Engineering and Applied Science
University of Virginia


In Partial Fullment
of the requirements of the Degree
Master of Science

Abstract

Concurrent languages have offered parallel loop constructs for some time to allow a parallel computation to be expressed in a simple and straightforward fashion. Modern programming languages include exceptions to allow for clean handling of errors or unexpected conditions, but few concurrent languages incorporate exception handling into their models for parallel loops. As a result, programmers that use parallel loops cannot use exceptions to simplify their programs. We present a semantics for handling exceptions in parallel loops that is predictable and that reduces to the familiar semantics for sequential loops. This semantics provides guarantees about the behavior of parallel loops even in the presence of exceptions, and facilitates the implementation of parallel algorithms. A Java library implementation of this semantics is presented, along with a description of a source-to-source translation.

Complete Paper (56 pages) [PDF], [PS]