Using continuations to implement thread management and communication in operating systems

We have improved the performance of the Mach 3.0 operating system by redesigning its internal thread and interprocess communication facilities to use continuations as the basis for control transfer. Compared to previous versions of Mach 3.0, our new system consumes 85% less space per thread. Cross-address space remote procedure calls execute 14% faster. Exception handling runs over 60% faster.In addition to improving system performance, we have used continuations to generalize many control transfer optimizations that are common to operating systems, and have recast those optimizations in terms of a single implementation methodology. This paper describes our experiences with using continuations in the Mach operating system.

[1]  Brian N. Bershad,et al.  Scheduler activations: effective kernel support for the user-level management of parallelism , 1991, TOCS.

[2]  David L. Black Scheduling support for concurrency and parallelism in the Mach operating system , 1990, Computer.

[3]  Mitchell Wand,et al.  Continuation-Based Multiprocessing , 1980, High. Order Symb. Comput..

[4]  Michael Burrows,et al.  Performance of Firefly RPC , 1990, ACM Trans. Comput. Syst..

[5]  Robbert van Renesse,et al.  Amoeba A Distributed Operating System for the 1990 s Sape , 1990 .

[6]  David L. Black,et al.  Machine-independent virtual memory management for paged uniprocessor and multiprocessor architectures , 1987, ASPLOS 1987.

[7]  Ray Duncan Advanced MS-DOS: the Microsoft guide for assembly language and C programmers , 1986 .

[8]  Larry L. Peterson,et al.  RPC in the x-Kernel: evaluating new design techniques , 1989, SOSP '89.

[9]  Evangelos P. Markatos,et al.  First-class user-level threads , 1991, SOSP '91.

[10]  Robert H. Halstead,et al.  A Syntactic Theory of Message Passing , 1980, JACM.

[11]  Henry M. Levy,et al.  High-performance cross-address space communication , 1990 .

[12]  Henry M. Levy,et al.  Computer Programming and Architecture: The VAX-11 , 1980 .

[13]  Armando P. Stettner The design and implementation of the 4.3BSD UNIX operating system , 1988 .

[14]  Mahadev Satyanarayanan,et al.  The ITC distributed file system: principles and design , 1985, SOSP '85.

[15]  Michael Burrows,et al.  Performance of Firefly RPC , 1989, SOSP '89.

[16]  David L. Black,et al.  Microkernel operating system architecture and Mach , 1991 .

[17]  Alessandro Forin,et al.  UNIX as an Application Program , 1990, USENIX Summer.

[18]  A. Retrospective,et al.  The UNIX Time-sharing System , 1977 .

[19]  David L. Black,et al.  Machine-independent virtual memory management for paged uniprocessor and multiprocessor architectures , 1987, IEEE Trans. Computers.

[20]  David L. Black,et al.  The duality of memory and communication in the implementation of a multiprocessor operating system , 1987, SOSP '87.

[21]  Andrew W. Appel,et al.  Virtual memory primitives for user programs , 1991, ASPLOS IV.

[22]  Brian N. Bershad,et al.  Lightweight remote procedure call , 1989, TOCS.

[23]  J. Gregory Morrisett,et al.  Adding threads to Standard ML , 1990 .

[24]  Richard Draves,et al.  A Revised IPC Interface , 1990, USENIX MACH Symposium.

[25]  C Rose,et al.  Inside Macintosh , 1985 .

[26]  George G. Robertson,et al.  Accent: A communication oriented network operating system kernel , 1981, SOSP.

[27]  William J. Bolosky,et al.  Mach: A New Kernel Foundation for UNIX Development , 1986, USENIX Summer.

[28]  Henry M. Levy,et al.  The Performance Implications of Thread Management Alternatives for Shared-Memory Multiprocessors , 1989, IEEE Trans. Computers.

[29]  David L. Black,et al.  Scheduling and resource management techniques for multiprocessors , 1990 .

[30]  Samuel J. Leffler,et al.  The design and implementation of the 4.3 BSD Unix operating system , 1991, Addison-Wesley series in computer science.

[31]  V. Rich Personal communication , 1989, Nature.

[32]  Edwin H. Satterthwaite,et al.  Early experience with Mesa , 1977, CACM.

[33]  Lawrence C. Stewart,et al.  Firefly: a multiprocessor workstation , 1987, IEEE Trans. Computers.

[34]  David L. Black,et al.  The mach exception handling facility , 1988, PADD '88.

[35]  J. E. Ball,et al.  RIG, Rochester's Intelligent Gateway: System Overview , 1976, IEEE Transactions on Software Engineering.

[36]  Thomas E. Anderson,et al.  The performance implications of thread management alternatives for shared-memory multiprocessors , 1989, SIGMETRICS '89.

[37]  Roger L. Haskin,et al.  Recovery management in QuickSilver , 1988, TOCS.

[38]  Claude Kaiser,et al.  CHORUS Distributed Operating System , 1988, Comput. Syst..

[39]  Butler W. Lampson,et al.  On the transfer of control between contexts , 1974, Symposium on Programming.

[40]  Richard F. Rashid From RIG to Accent to Mach: An Evolution of a Network Operating System , 1986, FJCC.

[41]  Michael L. Scott,et al.  Evolution of an Operating System for Large-Scale Shared-Memory Multiprocessors , 1989 .

[42]  Christopher Strachey,et al.  A theory of programming language semantics , 1976 .

[43]  Daniel P. Friedman,et al.  Engines build process abstractions , 1984, LFP '84.

[44]  K. Thompson,et al.  The UNIX time-sharing system , 1978 .

[45]  Mahadev Satyanarayanan,et al.  The ITC distributed file system: principles and design , 1985, SOSP 1985.

[46]  David R. Cheriton,et al.  The V distributed system , 1988, CACM.