Multi-tasking OSes

Feb 27, 2001
142
0
0
My opinion:
Windows is not multitasking because it can only actively attend one task at a time.
Im trying to get the point accross to the people who think Windows is multitasking.
So all you Unix/Linux (or other multitasking OSes) gurus, can you explain this ehole "true multitasking" issue?
Im looking for simple yet not completely dumb explanations.
Thanks
 

martind1

Senior member
Jul 3, 2003
777
0
0
Dude,

actively attend?

What do you want it to do?

I don't see how it ISN'T multitasking.


Why do you think Windows is NOT and the *nix's are?

Why don't you make a point rather than depending on us to solve a homework question for you.
 

buleyb

Golden Member
Aug 12, 2002
1,301
0
0
Ok, I'll bite, what is your scope here...multi-cpu systems(physical or virtual), or single cpu systems?
 

Jeff7

Lifer
Jan 4, 2001
41,596
20
81
No OS can really multitask on a single CPU (well, maybe the Hyperthreaded P4's can) because the CPU can only do one thing at a time. It just switches back and forth between processes so quickly that it looks like multitasking. And even a dual-CPU setup can only do two things at a time - one per CPU, at best efficiency, whether it be Windows or Linux.
 

buleyb

Golden Member
Aug 12, 2002
1,301
0
0
This is pretty much what I was shooting for (and I'd look at the HT P4 the same way OSes do, 2 virtual CPUs).

 
Feb 27, 2001
142
0
0
This is what I picked up on the web:

Advantage: True Multitasking and Multiuser System
Unix is designed from the ground up to handle many users and to do many things at one time. Windows and Mac aren't. Obviously these are disireable characteristics in a web server.

Can anybody elaborate on that if they have the knowledge and not flame, please!
 

martind1

Senior member
Jul 3, 2003
777
0
0
you still have yet to answer the questions people above you have asked.

so far they ahve answered you and said that no single cpu machien can truly multi-task.
 

buleyb

Golden Member
Aug 12, 2002
1,301
0
0
Regardless of that...older windows systems were the scrutiny of this discussion...newer NT based OSes are multitasking OSes, and multiuser, for the same reason that Macs are now up to snuff in this regard. Macs used to fake multitasking, they now do it for real.

 

zephyrprime

Diamond Member
Feb 18, 2001
7,512
2
81
Unix is designed from the ground up to handle many users and to do many things at one time. Windows and Mac aren't. Obviously these are disireable characteristics in a web server.
This is just a dated statedment. Really dated. Like, before the advent of the web dated.

Win 3x was only a non pre-emptive multitasking system. It was cooperative. That means processes had to willingly and deliberately yield their time slices every once in a while.
But Win 9x was pre-emptive like the unix os's.
But NT is a better multitasker than 9x because it's a better scheduler.

Mac OS was only task switching until OS 10. But OS 10 is itself based on BSD which is a Unix.

And being multiuser isn't really useful for a web server since there's only one user on such a system: the web server.

No OS can really multitask on a single CPU (well, maybe the Hyperthreaded P4's can) because the CPU can only do one thing at a time
Absulutely right.
 
Feb 27, 2001
142
0
0
Originally posted by: martind1
you still have yet to answer the questions people above you have asked.

so far they ahve answered you and said that no single cpu machien can truly multi-task.

Dude, get off my case, I was asking for an opinion because I know there are various views on it.
At least so far I have an idea of what I was looking for. I came here with a question and others are guiding me to an answer, thats what this forum is for after all.

My question now is:
Is what they call multitasking in single cpu systems just a way of managing tasks and allocating each one at a time? Is task switching the same thing?
 

Mingon

Diamond Member
Apr 2, 2000
3,012
0
0
What about the SSE/3dnowetc instructions sets dont they effectively do more than one thing at a timea lbeit at a code level
 

buleyb

Golden Member
Aug 12, 2002
1,301
0
0
yes, SSE and related technologies have additional registers and units to be used with specific op-codes (architecture specific optimizations). These can do multiple operations at the same time, but doing multiple tasks at the same time would be application/OS/CPU dependent.
 

uart

Member
May 26, 2000
174
0
0
My question now is:
Is what they call multitasking in single cpu systems just a way of managing tasks and allocating each one at a time? Is task switching the same thing?
No, multitasking and task switching are not really the same thing. Certainly a multitasking OS must also be able to task switch but the reverse is not necessarily true. Simple OS?es (even some pre-win3.1 versions of DOS for example) can ?task switch? (as in save the state of a program and switch to another), but the program once switched out is completely inactive (receiving zero cpu attenttion).

As others have already told you, multitasking on a single CPU involves ?time-slicing? between the various running programs in such a way that to the user they all appear to be running concurrently. In one sense you could say that the better the OS is at multitasking the better this ?appearance? of concurrence is.


What about the SSE/3dnowetc instructions sets dont they effectively do more than one thing at a timea lbeit at a code level.
Completely different thing. You are confusing parallelism with multitasking. Most modern CPU?s contain many forms of hardware parallelism. SIMDs like MMX/3DNOW and SSE are just explicit instruction level parallelism. SIMD literally stands for ?Single Instruction Multiple Data?, a SIMD is essentially a simple vector processor. Even without using the SIMDs, modern cpus can process more than one instruction at the same time due. What is called ?superscalar? design essentially means that they have execution unit parallelism.


 

rjain

Golden Member
May 1, 2003
1,475
0
0
Originally posted by: derekblankmccoy
This is what I picked up on the web:

Advantage: True Multitasking and Multiuser System
Unix is designed from the ground up to handle many users and to do many things at one time. Windows and Mac aren't. Obviously these are disireable characteristics in a web server.

Can anybody elaborate on that if they have the knowledge and not flame, please!

Multiuser systems can be used by multiple people at the same time. E.g., I can log in to a unix system with many other users also logged into it (some sitting directly at the machine, some remote), and run apps just like any other user logged into it. In windows, you can't interactively be logged in as multiple users and get the same capabilities as the user logged in directly to the machine.
 

AlexWade

Member
Sep 27, 2003
89
0
0
All modern OS's are multi-tasking. But this is only an illusion. The CPU can only perform one action at a time.

Each OS has their own schedular. Windows 2000 and XP is complicated; I was just reading about it and own got the gist of it. Linux is a little simplier. In fact, I have a class on OSes right now, and we just finished discussing Linux scheduling. If you want, I can give you some specifics about Windows 2000/XP or Linux scheduling; I can't help you with Windows 95/98/ME/NT or Unix or MacOS.

But the key is no OS is parallel, it seems to be. Each process has its own registers and virtual memory space. The OS manages all memory addresses. When Process A reference an address, and Process B references the exact same address, they point to different locations, assuming Process A and Process B are totally independent. Task switching has very little overhead. And each process runs in fractions of seconds.

Windows is multi-tasking. If Windows is not, then neither is Linux nor Unix nor MacOS. Just because Windows is not as robust as Linux or Unix in handling lots of users does not mean it is not multi-tasking.
 

sao123

Lifer
May 27, 2002
12,656
207
106
Multiuser systems can be used by multiple people at the same time. E.g., I can log in to a unix system with many other users also logged into it (some sitting directly at the machine, some remote), and run apps just like any other user logged into it. In windows, you can't interactively be logged in as multiple users and get the same capabilities as the user logged in directly to the machine.

Not only can a machine support 2 individual users, 1 unix workstation can borrow anothers CPU...this is known as edit rlogin. The real reason behind this is that every copy of Unix has server component edit remote login built into the edit default install package. In other words, theres no distinguishing characteristic between a server and a client, they both run the same OS, with the same features.

In Windows there is a difference, there is the windows server OS and the client windows desktop OS (which can be thought of Windows Server Lite). However, if you setup every workstation/pc in your network with Windows Server running terminal services for applications and cluster services, then it has the same properties as edit mult-user unix.

BTW...the terminal connection to unix is very limited in abilities. It wont run 3d graphics, games etc, it can only do CPU work. So unless your gonna crunch numbers or use office programs...who wants a terminal client.


Now on a side note...[insert flame here] :|
multiuser system != multitasking system
 

GoHAnSoN

Senior member
Mar 21, 2001
732
0
0
Originally posted by: derekblankmccoy
My opinion:
Windows is not multitasking because it can only actively attend one task at a time.
Im trying to get the point accross to the people who think Windows is multitasking.
So all you Unix/Linux (or other multitasking OSes) gurus, can you explain this ehole "true multitasking" issue?
Im looking for simple yet not completely dumb explanations.
Thanks

no, OS can be multi tasking.
one example, transfer a huge file from disk A to disk B, and post a thread in AT forum.
OS will command CPU to exucute the transfer(ala DMA style) and straight away concentrate on the posting thread process.
the os/cpu is accually excuting a process while transfering file. so it's multitasking.

on a non multitasking OS, it will wait until the transferring is done, well, after 1 minutes maybe? and then only focus back to your beloved AT forum.

so, OS is multitasking from software point of view. Of course, the core execution of the cpu can only be one task at a time. but, that's not your question right ?

well, this is just one exmple that i can think of, my 2 cent.

 

Extrarius

Senior member
Jul 8, 2001
259
0
0
All modern operating systems truly multitask. Multitasking IS switching between tasks so quickly that they seem to be running at the same time. Multiprocessing is what requires more than one processor to happen.

That quote about unix is just saying it was designed to have multiple users 'at once' so that it is probably more efficient than Windows etc where it was added on later as an afterthought.
 

pyrojunkie

Senior member
Jul 30, 2003
243
0
0
I see all these points about a CPU not being able to truely multi-task, thus making the OS not multi-task. However wouldn't this all be different when we speak of a multi-processor system. A system with multiple processors then would be able to handle 2 or more instructions simultaneously, thus making the OS a true multi-tasker. Certain versions of Windows can handle multiple CPU's thus meaning these versions true multi-taskers.

GoHAnSoN was bringing up a good point too. Even if a CPU can do one instruction at a time, isn't the OS running simultaneous tasks upon it? The OS is not concentrated on one program at a time, but instead is prioritizing and shifting instructions in order to complete all its tasks. I guess this comes down to your definition of multi-tasking.

At the machine level its doing one thing at a time on a single processor(non-HT CPU), but the OS is still handling every task it receives and queueing it for the processor.
 

rjain

Golden Member
May 1, 2003
1,475
0
0
Originally posted by: sao123
Not only can a machine support 2 individual users, 1 unix workstation can borrow anothers CPU...this is known as clustering
The real reason behind this is that every copy of Unix has server processes (including CPU clustering/load sharing) built into the kernal. In other words, theres no distinguishing characteristic between a server and a client, they both run the same OS, with the same features.
I don't know where you get the idea that clustering has anything to do with a generic unix kernel. Yes, rlogin exists, but that's a totally different issue, nothing to do with the kernel.
In Windows there is a difference, there is the windows server OS and the client windows desktop OS (which can be thought of Windows Server Lite). However, if you setup every workstation/pc in your network with Windows Server running terminal services for applications and cluster services, then it has the same properties as the true multitasking unix.
You mean multiuser unix, no? (I don't know much about windows terminal services.)
BTW...the terminal connection to unix is very limited in abilities. It wont run 3d graphics, games etc, it can only do CPU work. So unless your gonna crunch numbers or use office programs...who wants a terminal client.
Wrong. You can run OpenGL (GLX) Quake just fine remotely. Works great on an IRIX box.
 

rjain

Golden Member
May 1, 2003
1,475
0
0
Originally posted by: pyrojunkie
I see all these points about a CPU not being able to truely multi-task, thus making the OS not multi-task. However wouldn't this all be different when we speak of a multi-processor system. A system with multiple processors then would be able to handle 2 or more instructions simultaneously, thus making the OS a true multi-tasker. Certain versions of Windows can handle multiple CPU's thus meaning these versions true multi-taskers.
Correct. That's referred to as concurrent or parallel multi-tasking.
GoHAnSoN was bringing up a good point too. Even if a CPU can do one instruction at a time, isn't the OS running simultaneous tasks upon it?
Eh? How is the CPU running two tasks at the same time when it can only do one instruction at a time? That's like saying that a person with one arm can write two different things at the same time.
The OS is not concentrated on one program at a time, but instead is prioritizing and shifting instructions in order to complete all its tasks. I guess this comes down to your definition of multi-tasking.
The OS doesn't do anything with instructions. It switches which task the CPU is running when certain situations occur (which depend on the design of the CPU and OS).
At the machine level its doing one thing at a time on a single processor(non-HT CPU), but the OS is still handling every task it receives and queueing it for the processor.
Right, but that doesn't mean that it's doing those things at the same time, which is what this thread was originally about.
 

pyrojunkie

Senior member
Jul 30, 2003
243
0
0
GoHAnSoN was bringing up a good point too. Even if a CPU can do one instruction at a time, isn't the OS running simultaneous tasks upon it?
Eh? How is the CPU running two tasks at the same time when it can only do one instruction at a time? That's like saying that a person with one arm can write two different things at the same time.

The point being is the CPU doesn't wait for the task to finish before starting on the next one. The CPU may only be working on one instruction at a time, but in the process is completing multiple tasks.

I know thats still not true multi-tasking, but if the question is about Windows being less of a multi-task OS than any Unix flavor, the answer would be they are limited to the same hardware limitations thus equal. Until processors handle 2 instructions simultaneously, no single processor ran OS can be considered a "true multi-tasker"
 

rjain

Golden Member
May 1, 2003
1,475
0
0
Originally posted by: pyrojunkie
GoHAnSoN was bringing up a good point too. Even if a CPU can do one instruction at a time, isn't the OS running simultaneous tasks upon it?
Eh? How is the CPU running two tasks at the same time when it can only do one instruction at a time? That's like saying that a person with one arm can write two different things at the same time.

The point being is the CPU doesn't wait for the task to finish before starting on the next one. The CPU may only be working on one instruction at a time, but in the process is completing multiple tasks.
But not at the same time, which is what the discussion is about.
I know thats still not true multi-tasking, but if the question is about Windows being less of a multi-task OS than any Unix flavor, the answer would be they are limited to the same hardware limitations thus equal. Until processors handle 2 instructions simultaneously, no single processor ran OS can be considered a "true multi-tasker"
Until? Single processors have been handling 2 instructions simultaneously for 10-15 years, at least. (And that's ignoring Crays where it's hard to define what is a "single" processor".) The issue has nothing to do with instructions, it has to do with tasks.
 

pyrojunkie

Senior member
Jul 30, 2003
243
0
0
If instructions for all tasks are being worked on before any single task is completed why would anyone reject this as true multitasking?
 

rjain

Golden Member
May 1, 2003
1,475
0
0
Originally posted by: pyrojunkie
If instructions for all tasks are being worked on before any single task is completed why would anyone reject this as true multitasking?
Because they're not being run on independent processors. That's what "true" multitasking is: having a separate processor for each task. Of course, that's foolishly wasteful, as a well-designed OS can interleave waiting for I/O and processing of various tasks to give the illusion that each task is being run at the same time. The trick is using interrupts to suspend a task that is processing and give the one waiting for the I/O correpsonding to that interrupt a chance to respond to it. This gives the impression that the interactive app has been busy-waiting.