Top Up Prev Next Bottom Contents Index Search

Chapter 2. Support for multithreading


Authors: Joseph T. Buck
Multithreading means that there are multiple threads of control, or lightweight processes, in the same Ptolemy process. The principal consequence of the existence of multithreading is that it is necessary to provide mechanisms that guarantee exclusive access to resources. The Ptolemy kernel does not provide a multithreading library, as this is currently a very OS and CPU-specific operation. There are a variety of such libraries that might be used; Sun's lightweight processes library and the University of Colorado's Awesime package are two examples. What the kernel does provide is a locking mechanism for implementing critical regions, noninterruptable regions of code in which only one thread can be active at a time. This facility is used to protect critical resources in the kernel that might be accessed by multiple threads.



Top Up Prev Next Bottom Contents Index Search

ptolemy@eecs.berkeley.edu
Copyright © 1990-1997, University of California. All rights reserved.