Book contents
- Frontmatter
- Contents
- Preface
- 1 Introduction
- 2 Persistence
- 3 Some Familiar Data Structures in a Functional Setting
- 4 Lazy Evaluation
- 5 Fundamentals of Amortization
- 6 Amortization and Persistence via Lazy Evaluation
- 7 Eliminating Amortization
- 8 Lazy Rebuilding
- 9 Numerical Representations
- 10 Data-Structural Bootstrapping
- 11 Implicit Recursive Slowdown
- A Haskell Source Code
- Bibliography
- Index
10 - Data-Structural Bootstrapping
Published online by Cambridge University Press: 17 September 2009
- Frontmatter
- Contents
- Preface
- 1 Introduction
- 2 Persistence
- 3 Some Familiar Data Structures in a Functional Setting
- 4 Lazy Evaluation
- 5 Fundamentals of Amortization
- 6 Amortization and Persistence via Lazy Evaluation
- 7 Eliminating Amortization
- 8 Lazy Rebuilding
- 9 Numerical Representations
- 10 Data-Structural Bootstrapping
- 11 Implicit Recursive Slowdown
- A Haskell Source Code
- Bibliography
- Index
Summary
The term bootstrapping refers to “pulling yourself up by your bootstraps”. This seemingly nonsensical image is representative of a common situation in computer science: problems whose solutions require solutions to (simpler) instances of the same problem.
For example, consider loading an operating system from disk or tape onto a bare computer. Without an operating system, the computer cannot even read from the disk or tape! One solution is a bootstrap loader, a very tiny, incomplete operating system whose only purpose is to read in and pass control to a somewhat larger, more capable operating system that in turn reads in and passes control to the actual, desired operating system. This can be viewed as a instance of bootstrapping a complete solution from an incomplete solution.
Another example is bootstrapping a compiler. A common activity is to write the compiler for a new language in the language itself. But then how do you compile that compiler? One solution is to write a very simple, inefficient interpreter for the language in some other, existing language. Then, using the interpreter, you can execute the compiler on itself, thereby obtaining an efficient, compiled executable for the compiler. This can be viewed as an instance of bootstrapping an efficient solution from an inefficient solution.
- Type
- Chapter
- Information
- Purely Functional Data Structures , pp. 141 - 170Publisher: Cambridge University PressPrint publication year: 1998