Hi all,
I've been somewhat confused by what these terms actually refer to.
Okay, multiprocessing means concurrent execution of programs on a multiprocessor architecture. But what is the difference between multiprogramming and multitasking. I tried to read many articles, but couldn't get a clear picture. Here's a link to a wikipedia
article that deals with the same.It says that multiprogramming is a subset of multitasking. Here's a snippet from the article:
Code:
Multiprogramming doesn't give any guarantee that a program will run in a timely manner.
Indeed, the very first program may very well run for hours without needing access to a peripheral.
As there were no users waiting at an interactive terminal, this was no problem: users handed a deck of punched cards to an operator, and came back a few hours later for printed results.
Multiprogramming greatly reduced the waiting.
Cooperative multitasking/time-sharing
When computer usage evolved from batch mode to interactive mode, multiprogramming was no longer a suitable approach.
Each user wanted to see his program running as if it was the only program in the computer.
Time sharing had to be used.
For Multiprogramming it says:
Code:
Several different programs in batch were loaded in the computer memory, and the first one began to run.
When the first program reached an instruction waiting for a peripheral, the context of this program was stored away, and the second program in memory was given a chance to run.
The process continued until all programs finished running.
From this I get that multitasking is an improvement over multiprogramming. The article also says that the aim of multiprogramming is just to maximize CPU usage. So, in multiprogramming a program will continue to run as long as it does not block. However, if we add concepts like time-sharing, preemptive sheduling to multiprogramming we get multitasking.
Is my interpretation correct?
Thanks in anticipation.