Thursday, October 17, 2013

Multi-Tasking Explained.

I have decided to start doing a series of real life computing posts, these will be posted not on a strict rota but as and when I'm free (have school most days and/or work). They will be based on how the hardware and software of a computer works. If you have any suggestions please feel free to tweet me (@roblox_tweeter) or pm me on ROBLOX but I'm rarely on ROBLOX any more  Also if you wish me to do Python Programming lessons, maybe on YouTube please ask as well. Thankyou.


Today I have decided to post on "multi-tasking", a method for allowing users to do more tasks as and when you need to without affecting the computer too much.

How a processor "multi-tasks"

What do you understand by multi-tasking, not much I imagine. What is it? How does it work? Why does the processor use it?

What is it?

Multi-tasking is when you can have multiple programs or pieces of code running on a processor. It is never actually running more than once instruction at a time as a processor is fast but can only focus it's registers and processing power on one thing at once.

How does it work?

Multi-tasking can be simulated in a few ways as it's just the processor quickly doing one task after another or parts of a task. Here are 2 examples of how it is simulated: 
  • Round Robin/Time Slicing - Each task is run for a short period of time (not necessarily until completion) then the next is run etc.
  • Priority Based - Each task is given a priority level and then run according to it's priority e.g. priority 1 could be a "Hardware malfunction" whereas priority 5 could be "Printer is out of paper". A bit of a silly example but obviously hardware malfunctions need to be resolves as soon as possible.

Why does the processor use it?

Each processor or core can only do one task at a time so when a user is trying to complete a task or simply listen to music whilst word processing the computer needs to be able to allow this; so the computer will give very short time slices to allow each task to work this allows a lot more user run applications to be run cocurrently (at the same time).

Cameron Stickley
LOLFUNNY12345
@roblox_tweeter


No comments:

Post a Comment

Write your comment here... OR Flingi will eat you