Henry Massalin & Calton Pu @ Columbia Univ
Proceedings of the 12th ACM Symposium on OS Principles, 1995
![]() |
Design goals
|
||||||||||
![]() |
Problems & solutions
|
![]() |
Model: a von Neumann machine with threads, memory protection boundary, and I/O devices |
||||||||||
![]() |
Thread graph
|
||||||||||
![]() |
Thread
|
||||||||||
![]() |
I/O devices move data between threads |
![]() |
Code synthesizer generates special versions of code for specific situations |
||||||||||||
![]() |
Methods of code synthesize
|
![]() |
Synthesis kernel is composed of quajects |
||||||||||||||||||||||||||||||
![]() |
Quaject
|
||||||||||||||||||||||||||||||
![]() |
Building blocks
|
||||||||||||||||||||||||||||||
![]() |
Quaject creation
|
||||||||||||||||||||||||||||||
![]() |
Quaject execution
|
![]() |
Code Isolation: If two process works on different parts of the shared data, why synchronize?
|
||||||
![]() |
Procedure Chaining
|
||||||
![]() |
Optimistic Synchronization - Interference between threads is rare. So,
|
![]() |
SP-SC (Single Producer & Single Consumer): Fig-1
|
||||||||||||
![]() |
MP-SC: Multiple producer & single consumer, atomic insertion of multiple item
|
![]() |
Synthesis thread - lightweight process |
||||||||||||||||
![]() |
Each thread executes in a context, which is called TTE and has fields:
|
||||||||||||||||
![]() |
Unix like system call handling |
||||||||||||||||
![]() |
Waiting list per resource |
![]() |
Floating-pointer registers are not saved during the context switch, on the assumption that ordinary threads do not use any of them
|
||||||
![]() |
No 'dispatcher' procedure
|
![]() |
Unix-like signal handling |
![]() |
Debug support by signal |
![]() |
User threads can catch error trap and handles it as it does signals! |
![]() |
Policy
|
||||
![]() |
Priority
|
![]() |
I/O - all data flow among hardware devices and quaspaces |
![]() |
Stream - data move along logical channels, which connect source and destination |
![]() |
Device server - physical I/O device encapsulated in a quaject |
||||||||
![]() |
write - data movement from caller to callee |
||||||||
![]() |
read - data movement from callee to caller |
||||||||
![]() |
Each device server has its own thread or not |
||||||||
![]() |
High-level server may be composed from more basic servers
|
||||||||
![]() |
File system server is composed of several filter stages |
![]() |
Stream model can be described as a composition of different types of consumer/producer |
||||||||
![]() |
Passive producer - passive consumer
|
||||||||
![]() |
Active-passive
|
||||||||
![]() |
Active-active: a queue need to be inserted between producer and consumer
|
![]() |
Difference from Unix interrupt handling
|
||||
![]() |
Interrupt handling is done in the context of the currently running thread |
||||
![]() |
Signal handling within interrupt handling routine
|
||||
![]() |
Each thread has its own interrupt, trap, system call routines
|
![]() |
Incremental optimization! |
![]() |
Quaject synthesizing seems quite dynamic, right?. Running quajects could be very fast, but what is the overhead of dynamic fabrication of quaject (at run time)? |