[comp.sys.amiga] Multitasking -multiprocessing

DAVEA%CERNVM.BITNET@cunyvm.cuny.edu (David Almond) (04/06/89)

The difference is like looking at an eggtimer with a common focal point
, better utilisation of cpu. Multitasking is the ability to perform
more than one task at atime, usually on one cpu whereas multiprocessing
is the more complicated process of spliting computation into chunks
which are processed usually by a group of cpus. In that the amiga
has dedicated processers for graphics etc it is, to some degree multitasking,
but not in any sophisticated, scheduled sense. The transputer is the classic
multiprocessing machine so far.


            ............. Dave

kevin@cbmvax.UUCP (Kevin Klop) (04/07/89)

In article <12479@louie.udel.EDU> DAVEA%CERNVM.BITNET@cunyvm.cuny.edu (David Almond) writes:
>
>The difference is like looking at an eggtimer with a common focal point
>, better utilisation of cpu. Multitasking is the ability to perform
>more than one task at atime, usually on one cpu whereas multiprocessing
>is the more complicated process of spliting computation into chunks
>which are processed usually by a group of cpus. In that the amiga
>has dedicated processers for graphics etc it is, to some degree multitasking,
>but not in any sophisticated, scheduled sense. The transputer is the classic
>multiprocessing machine so far.
>
>
>            ............. Dave


As Dave said, Multi-tasking is an attempt to more fully utilize
a CPU.  Many programs need to stop and wait fairly often for
an outside even, whether it is a for a floppy disk to finish an
I/O operation, the RS-232 Port to dump out a byte, or (by far
the slowest I/O device) the user to make a decision and respond.

There are other times that a single-tasking machine might be
just "burning CPU time", like in a real time simulation where
the program actually simulates the process faster than would
actually happen.  In that case, the CPU sits and "does nothing"
to stay in synch with the simulation.

This wasted CPU time (on a single tasking machine) can be used
by other programs to do things.  Of course, there are times
when two programs both want the CPU at the same time, or are
greedy about CPU time and don't want to relinquish it.  In that
case there has to be some arbitration or scheduling, for which
several schemes are possible.

Multi-processing, on the other hand, can be implemented in
many different ways.  The two that come to mind readily are
A) One processor per task, each processor executing
   (relatively) independent of each other, and each
   processor completing a whole task by themselves.
B) More than one processor to a task, wherein a task
   is broken down into several parallel processing
   units, and each unit is given to a separate processor,
   which merrily chugs out it's part of the solution,
   passing any necessary intermediate results out
   for use by other processors, etc.

The Amiga multitasks the main 680x0 processor via
the operating system, and multiprocesses much
of the I/O through the custom chips.  Note that
multi-processing does not mean that one must have
IDENTICAL processors.

     -- Kevin --

Kevin Klop		{uunet|rutgers|amiga}!cbmvax!kevin
Commodore-Amiga, Inc.

The number, 111-111-1111 has been changed.  The new number is:
134-253-2452-243556-678893-3567875645434-4456789432576-385972

hans@nlgvax.UUCP (Hans Zuidam) (04/07/89)

There's some confusion on multi-tasking and multi-processsing.
The definitions below are derived from Burroughs terminology which
are clean enough (for me at least ;-)).

Multi-Tasking:
     The abillity to run another second task while a first task
     is waiting for resource to become available. Thus you split
     a single *physical* CPU in multiple *virual* CPUs. A resource
     might be the block of data the first one is reading from a disk.

Multi-Processing:
    The abillity to run multiple tasks *at the same time* on a number
    of *physical* CPUs.

A task is defined as a unit of work. It is a single stream of
instructions which are executed from beginning to end. Thus there is no
parallelism within a task. An amount of work submitted to the machine
is called a job. Within a job you can have multiple, concurrently
running tasks. A program is *not* equal to a task.

It follows that splitting a single task into pieces and running each
piece on a separate processor is wrong terminology. That is: you split
a job into several tasks which can then run in parallel.

Of course with the disaperance of batch systems the distinction between
jobs and tasks has disappeared also. But for clean discussion it is
often useful to fall back on the old (from around '65 or so!)
definitions.

So when your Amiga program builds a copper list and fires it off, you
end up with three things: your program which I would call a job, the
actual running 68000 code which is one task and the copper list which
is the other task.

							Hans
-- 
Hans Zuidam                                    E-Mail: hans@pcg.philips.nl
Philips Telecommunications and Data Systems,   Tel: +31 40 892288
Project Centre Geldrop, Building XR
Willem Alexanderlaan 7B, 5664 AN Geldrop       The Netherlands

daveh@cbmvax.UUCP (Dave Haynie) (04/08/89)

in article <12479@louie.udel.EDU>, DAVEA%CERNVM.BITNET@cunyvm.cuny.edu (David Almond) says:

> Multitasking is the ability to perform more than one task at atime, usually 
> on one cpu whereas multiprocessing is the more complicated process of 
> spliting computation into chunks which are processed usually by a group of 
> cpus. 

So far, so good....

> In that the amiga has dedicated processers for graphics etc it is, to some 
> degree multitasking, but not in any sophisticated, scheduled sense. 

Do you write for BYTE, by any chance?  That's dead wrong, on every account.

The Amiga is FULLY multitasking, in the sense that the processor is time
sliced among many processes.  Much in the same vein as UNIX, OS/9, Aegis,
VMS, etc.

The fact that some work is offloaded to decicated auxiliary processors
should tell you that the Amiga does some multiprocessing.  In that the
bimmer can be drawing a line on the screen at the same time as the CPU is
calculating a square root.  This is, of course, not general multiprocessing
in that the bimmer is not a general purpose processor.  That's not really
a bad thing, though, depending on what you're after.  The bimmer in Agnus
can do many graphics operations considerably faster than a 68000 could,
so as long as you've got enough of those type of tasks scheduled, the 
bimmer + 68000 gets more work done than a general setup of two 68000s.

> The transputer is the classic multiprocessing machine so far.

Well, it's one.  The Transputer is designed to handle loosely coupled
multiprocessing.  Such a system has no definite limit on the number of
processors that could be employed, but it generally requires a decent
architecture, and an operating system smart enough to schedule tasks at
a corse grain, in order to be effective.  The architecture cleverness
is based on the fact that only 4 Transputers are ever directly connected.
So you resort to interconnection in large networks, maybe a modified
hypercube or something.  The corse grain in based on the fact that a
transfer between two processors will take longer than the entire run
time of a small task.  Finally, the main reason Transputers are used for
this type of multiprocessing is that they have on-chip support for serial
links.  It's nice, at the right price, but it's nothing that couldn't be
supported by external hardware and any other processor, at possibly even
higher transfer rates (examples -- Connection Machine, Intel Hypercubes).

Most of the other efforts are in tightly coupled multiprocessing.  The 
number of tightly coupled processors is limited by the bus architecture,
and rarely goes above 7 or 8.  However, the communication between processors
is instant.  It does require significant design considerations to work well.
Many new RISC chips have hooks for tight multiprocessing, including the
Motorola 88000 family, Motorola 68040, Apollo PRISM, and several others.

>             ............. Dave
-- 
Dave Haynie  "The 32 Bit Guy"     Commodore-Amiga  "The Crew That Never Rests"
   {uunet|pyramid|rutgers}!cbmvax!daveh      PLINK: D-DAVE H     BIX: hazy
              Amiga -- It's not just a job, it's an obsession

warb@faatcrl.UUCP (Dan Warburton) (04/20/89)

From my point of view the Amiga is fully multitasking and somewhat
multi-processing. The Amiga has a full blown scheduler/dispatcher that
time slices the cpu resource to individule tasks?processes. The
graphic chip set also performs work in parallel with the cpu. This is
multi-processing, although normally I would be looking for another cpu
to be doing the work...