- Extending Thread class
- Implementing the Runnable interface



• Supported by the Kernel
• Slower to create and manage threads than are user threads
• If a thread performs a blocking system call, then the kernel can schedule another thread in the application for execution.• Multiple threads are able to run in parallel on multiprocessors.
• Examples
- Windows NT/2000
- Solaris 2
- Tru64 UNIX
- BeOS
- Linux
• Thread management done by user-level threads library
• Fast to create and manage threads
• If the kernel is single-threaded, then any user-level thread performing a blocking system call
will cause the entire process to block
• No need for kernel intervention
• Drawback : all may run in single process. If one blocks, all block.
• Examples
- POSIX Pthreads
- Mach C-treads
- Solaris UI-threads
- Can run even if one thread blocked or bus
- Web browser example – one thread per client
- Creating and context switching threads is low cost
- Solaris 2 : creating 30x, context switch 5x slower for procs

Copyright 2009 - The Great Symbian
Blogspot Theme designed by: Ray Creations, Ray Hosting.