Basic HTML version of Foils prepared Sept 21 1998

Foil 6 Thread Execution and Concurrency

From Java Tutorial 98- 4: Multi-Treading, Useful Java Classes, I/O and Networking NAVO Tutorial -- Sept 23 1998. by Geoffrey C. Fox, Nancy McCracken


1 Threads are implemented by a scheduler in Java, which asks the local operating system to run threads in the "runnable" state.
2 Typically, the OS runs each thread in turn for a "time slice". However, some operating systems (early versions of Solaris, e.g.) run a thread to completion unless another thread of higher priority preempts the running thread.
3 Example of two threads running on one cpu: Each thread gives up execution voluntarily (by executing yield(), suspend(), etc.) or because its time slice has ended:
4 Thread A
5 Thread B

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Sat Nov 28 1998