ACM Home Page
Please provide us with feedback. Feedback
The implementation of the Cilk-5 multithreaded language
Full text PdfPdf (1.56 MB)
Source ACM SIGPLAN Notices archive
Volume 33 ,  Issue 5  (May 1998) table of contents
Pages: 212 - 223  
Year of Publication: 1998
ISSN:0362-1340
Also published in ...
Authors
Matteo Frigo  MIT Laboratory for Computer Science, 545 Technology Square, Cambridge, Massachusetts
Charles E. Leiserson  MIT Laboratory for Computer Science, 545 Technology Square, Cambridge, Massachusetts
Keith H. Randall  MIT Laboratory for Computer Science, 545 Technology Square, Cambridge, Massachusetts
Publisher
ACM  New York, NY, USA
Bibliometrics
Downloads (6 Weeks): 43,   Downloads (12 Months): 266,   Citation Count: 71
Additional Information:

abstract   references   cited by   index terms   collaborative colleagues  

Tools and Actions: Request Permissions Request Permissions    Review this Article  
DOI Bookmark: Use this link to bookmark this Article: http://doi.acm.org/10.1145/277652.277725
What is a DOI?

ABSTRACT

The fifth release of the multithreaded language Cilk uses a provably good "work-stealing" scheduling algorithm similar to the first system, but the language has been completely redesigned and the runtime system completely reengineered. The efficiency of the new implementation was aided by a clear strategy that arose from a theoretical analysis of the scheduling algorithm: concentrate on minimizing overheads that contribute to the work, even at the expense of overheads that contribute to the critical path. Although it may seem counterintuitive to move overheads onto the critical path, this "work-first" principle has led to a portable Cilk-5 implementation in which the typical cost of spawning a parallel thread is only between 2 and 6 times the cost of a C function call on a variety of contemporary machines. Many Cilk programs run on one processor with virtually no degradation compared to equivalent C programs. This paper describes how the work-first principle was exploited in the design of Cilk-5's compiler and its runtime system. In particular, we present Cilk-5's novel "two-clone" compilation strategy and its Dijkstra-like mutual-exclusion protocol for implementing the ready deque in the work-stealing scheduler.


REFERENCES

Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.

 
1
Andrew W. Appel and Zhong Shao. Empirical and analytic study of stack versus heap cost for languages with closures. Journal of Functional Programming, 6(1):47-74, 1996.
2
 
3
 
4
 
5
Robert D. Blumofe and Charles E. Leiserson. Scheduling multithreaded computations by work stealing. In Proceed* ings of the 35th Annual Symposium on Foundations of Corn* puter Science (FOCS), pages 356-368, Santa Fe, New Mexico, November 1994.
6
7
 
8
Cilk-5.1 (Beta 1) Reference Manual. Available on the Internet from http://theory.lcs .mit .edu/'cilk.
 
9
10
11
12
13
 
14
 
15
R. L. Graham. Bounds on multiprocessing timing anomalies. SIAM Journal on Applied Mathematics, 17(2):416-429, March 1969.
 
16
Dirk Grunwald. Heaps o' stacks: Time and space efficient threads without operating system support. Technical Report CU-CS-750-94, University of Colorado, November 1994.
17
 
18
19
 
20
Leslie Lamport. How to make a multiprocessor computer that correctly executes multiprocess programs. IEEE 7~nsactions on Computers, C-28(9):690-691, September 1979.
 
21
Phillip Lisiecki and Alberto Medina. Personal communication.
 
22
 
23
Robert C. Miller. A type-checking preprocessor for Cilk 2, a multithreaded C language. Master's thesis, Department of Electrical Engineering and Computer Science, Massachusetts Institute of Technology, May 1995.
 
24
 
25
 
26
 
27
28

CITED BY  71

Collaborative Colleagues:
Matteo Frigo: colleagues
Charles E. Leiserson: colleagues
Keith H. Randall: colleagues