University of Wollongong
Browse

A low-cost implementation of coroutines for C

Download (525.31 kB)
preprint
posted on 2024-11-16, 00:19 authored by Paul A Bailes
We identify a set of primitive operations supporting coroutines, and demonstrate their usefulness. We then address their implementation in C according to a set of criteria aimed at maintaining simplicity, and achieve a satisfactory compromise between it and effectiveness. Our package for the PDP-II under UNIX allows users of coroutines in C programs to gain access to the primitives via an included definitions file and an object library; no penalty is imposed upon non-coroutine users.

History

Article/chapter number

83-9

Total pages

24

Language

English

Usage metrics

    Exports

    RefWorks
    BibTeX
    Ref. manager
    Endnote
    DataCite
    NLM
    DC