Processes and threads, Operating System

Processes and threads each have their place in multi-programming, generally to hide latency and to maximize CPU utilization. With the continuing spread of multi-core processors in personal computers, threads are becoming more and more important every day. There are now threads in almost every type of application, including client applications, not just server applications. Soon, there are likely to be multi-core processors even on cellphones, and there will be threaded applications on cellphones.

These multiple cores make it possible to run several different lines of processing at the same time, allowing the computer to runmuch faster than usual; because of this, however, programmersmust now explicitly make use of multi-threaded programming. Unfortunately, parallel programming is very confusing and error prone.

In general, parallel programming can be implemented either by using several concurrent pro- cesses, or by using threads. While processes have each their own address space (separate program counters, heaps, stacks, etc), threads share their address spaces; the programmer can use either of these to obtain concurrency. Besidesmaximizing CPU utilization, the use of parallel programming also helps to hide latency (e.g. waiting for the disk while using the CPU) and to handle multiple asynchronous events.

As a rough analogy, different processes are like different housing subdivisions: quite separate and protected from each other, and with communication possible but relatively dif?cult. In this analogy, different threads within the same process are like roommates:

communication and sharing is easy, but there's much less protection from each other's mistakes.

Posted Date: 3/12/2013 4:11:18 AM | Location : United States







Related Discussions:- Processes and threads, Assignment Help, Ask Question on Processes and threads, Get Answer, Expert's Help, Processes and threads Discussions

Write discussion on Processes and threads
Your posts are moderated
Related Questions

What does Verification represent? Verification shows the set of activities that are carried out to confirm that the software correctly executes the specific functionality.

Q. Remapping of bad blocks by sector sparing or else sector slipping could influence performance. Presume that the drive in Subsequent Exercise has a total of 100 bad sectors at r

Q. What are the reasons for process suspension? Reasons for process suspension 1.  Swapping 2.  Timing 3.  Interactive user request 4.  Parent process request

write a linux command to display lines from 25 - 45 of directory "/edc/password" write a linux command to display directory in /edc

Explain the Per Thread Scoping Thread-level programming introduces new twists for application-level variable scoping. Threads are commonly used in one of two ways. To ex

Define the Programming Fundamentals for Client- Server Developers Coding for client - server enforces good programming fundamentals. In order for applications to become client

draw a state diagram showing the transissions of a process from creation to termination

FIFO page replacement This is the easiest page replacement algorithm. Here the 1 st page toward the inside is the 1 st to leave that is the oldest page leaves. To execute th

Write a short note about schedulers. Processes migrate between the various scheduling queues throughout its life time. The operating system should select for scheduling purpose