Advantages and Disadvantages of Threads over Multi processes, Basic Computer Science

Advantages:-
• Sharing Treads permit the sharing of a lot resources that cannot be shared in process, for instance, sharing code section, data section, Operating System resources like open file etc.
• Context Switching Threads are very reasonably priced to create and destroy, and they are inexpensive to represent. For instance, they require space to store, the PC, the SP, and the common-purpose registers, but they do not need space to share memory information, Information about open files of I/O devices in use, etc. With so little circumstance, it is much faster to switch between threads. In other words, it is comparatively simpler for a circumstance switch using threads.

Disadvantages:-
• Security Since there is, a wide sharing among threads there is a potential difficulty of security. It is quite possible that one thread over writes the stack of a different thread (or damaged shared data) although it is very unlikely since threads are destined to cooperate on a single task.
• Blocking The major drawback if that if the kernel is single threaded, a system call of one thread will block the entire process and CPU may be idle during the blocking period.
Posted Date: 5/2/2012 7:14:52 AM | Location : United States







Related Discussions:- Advantages and Disadvantages of Threads over Multi processes, Assignment Help, Ask Question on Advantages and Disadvantages of Threads over Multi processes, Get Answer, Expert's Help, Advantages and Disadvantages of Threads over Multi processes Discussions

Write discussion on Advantages and Disadvantages of Threads over Multi processes
Your posts are moderated
Related Questions
Classify computer systems according to capacity. How they are different from computers according to the classification of technology. Provide comparative study also.

wrap that computes a customer water bill. The bill include Rs.100 water demand charge + a consumption charge of Rs.1.5 for every thousand gallons used. Consumption is figured from

Another way of classifying a computer system is based upon its size and capabilities: Microcomputers: Microcomputers are systems based on the use of microprocessors. A Micr

Find the corresponding matrix of the digraph above

how to set up the location (e.g. plaza, hall of fame, lecture theater or etc.) and services that will be used during the exhibition; devices needed; and finally produced a compreh

QUESTION (a) Consider the graph below, use the Flow Decomposition technique to list the cycles and paths produced.                                                (b) Pr

Task 1 Study various types of systems and simulate a system of your own. Task 2 Study various models and enumerate the various steps for designing a corporate model

Product of first n natural numbers - Algorithm Working Procedure : 1. Take n = 8 2. Take I = 1 3. Take PROD = 1 4. Compute PROD = PROD * 1 5. add 1 to 1 6. If I≤ n, complete

Qestion 1 What is .Net Framework? Qestion 2 Write short notes on constructors and destructors Qestion 3 Explain boxing and unboxing with examples Qestion 4 What is

THE CENTRAL PROCESSING UNIT (CPU): The CPU is the heart of any computing system.  It executes the individual machine instructions, which make up a program. The CPU is formed fr