Re: Demo: multithreading
From: Richard (riplin_at_Azonic.co.nz)
Date: 05/23/04
- Next message: Richard Steiner: "Re: Demo: multithreading"
- Previous message: James J. Gavan: "Re: OO Reuse"
- In reply to: Robert Wagner: "Demo: multithreading"
- Next in thread: Richard Steiner: "Re: Demo: multithreading"
- Reply: Richard Steiner: "Re: Demo: multithreading"
- Reply: Michael Wojcik: "Re: Demo: multithreading"
- Reply: Robert Wagner: "Re: Demo: multithreading"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 22 May 2004 23:08:16 -0700
robert.deletethis@wagner.net (Robert Wagner) wrote
> * Multithreading was invented by Sybase in the late '80s to help their
> * database run faster.
I think that you are quite far away from reality:
""" 1966
[26] The UNIVAC division of Sperry Rand Corporation delivers the first
multiprocessor 1108. Each contains up to 3 CPUs and 2 I/O controllers;
its EXEC 8 operating system provides interface for multithread program
execution.
---------------- """"
> * Although tasks and threads are both dispatched by
> * the operating system, some people thought a thread switch would be
> * faster than a task switch.
I don't know _anyone_ that thought that. What they _did_ think is
that creating a new thread would be much faster than creating a new
task. I recall when the ICL 2900 VME/B introduced threads. A new VM
task took around a million instructions to create while a thread
within an existing VM was just a few thousand. VME/B was using
threads in their servers in the early 70s.
> * The speed difference between the two methods is dramatic. Case 13,
> * mutex, took 5.9 seconds -- 3.3 times slower than single-threading.
> * Case 14 took .6 seconds, 3 times faster than single-threading, on a
> * machine with 4 CPUs.
Presumably the machine was doing nothing else at the time. If it was
running a normal mix of jobs, as you say: hundreds of tasks, then the
chance of getting the use of 2 CPUs at the same time is negligable.
- Next message: Richard Steiner: "Re: Demo: multithreading"
- Previous message: James J. Gavan: "Re: OO Reuse"
- In reply to: Robert Wagner: "Demo: multithreading"
- Next in thread: Richard Steiner: "Re: Demo: multithreading"
- Reply: Richard Steiner: "Re: Demo: multithreading"
- Reply: Michael Wojcik: "Re: Demo: multithreading"
- Reply: Robert Wagner: "Re: Demo: multithreading"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|