The Pensieve project: a compiler infrastructure for memory models
Chi-Leung Wong; Zehra Sura; Xing Fang; Midkiff, S.P.; Jaejin Lee; Padua, D.
Parallel Architectures, Algorithms and Networks, 2002. I-SPAN apos;02. Proceedings. International Symposium on
Volume , Issue , 2002 Page(s):209 - 214
Digital Object Identifier 10.1109/ISPAN.2002.1004288
Summary:The design of memory consistency models for both hardware and
software is a difficult task. It is particularly difficult for a
programming language because the target audience is much wider than the
target audience for a machine language, making usability a more
important criterion. Adding to this problem is the fact that the
programming language community has little experience with designing
programming language consistency models, and therefore each new attempt
is very much a voyage into uncharted territory. A concrete example of
the difficulties of the task is the current Java memory model. Although
designed to be easy to use by Java programmers, it is poorly understood,
and at least one common idiom (the "double-check idiom") to exploit the
model is unsafe. In this paper, we describe the design of an optimizing
Java compiler that accepts, as either input or as an interface
implementation, a consistency model for the code to be compiled. The
compiler uses escape analysis, D. Shasha and M. Snir's (1988) delay set
analysis, and our own CSSA (concurrent static single assignment) program
representation to normalize the effects of different consistency models
on optimizations and analysis. The compiler is intended to serve as a
testbed to prototype new memory models and to measure the differences
between different memory models in terms of program performance
View citation and abstract |