Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Computing > NZ Computing > QOTW

Reply
 
 
Enkidu
Guest
Posts: n/a
 
      10-08-2010
On 08/10/10 16:50, Lawrence D'Oliveiro wrote:
> In message<CbidneZlpMmX4zPRnZ2dnUVZ_tednZ2d@giganews. com>, Allistar
> wrote:
>
>> Lawrence D'Oliveiro wrote:
>>
>>> In message<(E-Mail Removed)>,
>>> Allistar wrote:
>>>
>>>> Lawrence D'Oliveiro wrote:
>>>>
>>>>> Premature optimization is the root of all evil.
>>>>
>>>> On that we disagree.
>>>
>>> Then you know nothing of computing.
>>>
>>>

>> <http://www.google.com/search?q=premature+optimization+is+the+root+of+all +evil>
>>
>>
>>

I know nothing about computing because I disagree with a quote that one
>> particular person has said?

>
> Go do some reading, You might learn something.
>

Ignore the dimwit Allistar. He's not worth the expenditure of even
minimal energy.

Cheers,

Cliff

--

The ends justifies the means - Niccolň di Bernardo dei Machiavelli.

The end excuses any evil - Sophocles
 
Reply With Quote
 
 
 
 
Matty F
Guest
Posts: n/a
 
      10-08-2010
On Oct 7, 10:26 am, Allistar <(E-Mail Removed)> wrote:
> Matty F wrote:
> > Lawrence D'Oliveiro wrote:
> >> “Whenever faced with a problem, some people say `Lets use
> >> multithreading.' two they problems. Now, have.”

>
> >> (Found on Twitter. Ahem.)

>
> > I know of a nationwide hotel booking system that was specially
> > programmed to work on a machine using multithreading. Task switching
> > was a lengthy affair. Each hotel had to be locked in case another
> > thread took the last rooms left, then unlocked again later. Booking a
> > tour in many hotels around NZ took so long that the system timed out
> > after a few minutes.
> > The system was rewritten for another machine using single threading. A
> > maximum sized tour took about one second, since the one thread had the
> > whole machine's resources available and didn't need to lock anything.

>
> Either this was a long time ago (running on inefficient hardware) or was
> developed very poorly.


It was written about 1980. The inefficient machine was a Data General
I think.

I did post this reply some days ago but posting from Google has not
worked for a few days.
 
Reply With Quote
 
 
 
 
John Little
Guest
Posts: n/a
 
      10-10-2010
Lawrence D'Oliveiro wrote:

(Just found a bounce for this in my spam.)

>Premature optimization is the root of all evil.


I've never liked that:
- There are computing evils that cannot be even remotely related to
premature optimization.
- It's used to excuse pessimization, premature or otherwise.
- It's not practical to take "doing things efficiently" out of "doing
things right".

> Threading is a performance hack.


Not always. It can be a way to cope with operations that block,
especially inhomogeneous ones.

Regards, John
 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-11-2010
In message
<(E-Mail Removed)>, John
Little wrote:

> - It's used to excuse pessimization, premature or otherwise.


Agreed, that’s a misuse.

> - It's not practical to take "doing things efficiently" out of "doing
> things right".


Doing things right must come first.

>> Threading is a performance hack.

>
> Not always. It can be a way to cope with operations that block,
> especially inhomogeneous ones.


The usual *nix way of dealing with those is forking, not threading.
 
Reply With Quote
 
John Little
Guest
Posts: n/a
 
      10-11-2010
On Oct 11, 2:23*pm, Lawrence D'Oliveiro <l...@geek-
central.gen.new_zealand> wrote:

> > - It's not practical to take "doing things efficiently" out of "doing
> > things right".

>
> Doing things right must come first.


But my point still stands.

> >> Threading is a performance hack.

>
> > Not always. *It can be a way to cope with operations that block,
> > especially inhomogeneous ones.

>
> The usual *nix way of dealing with those is forking, not threading.


For windows the usual way(I'm told) is threading, forking not
performing well, and I'd argue that this led to instability of much
windows software.
For *nix, I agree, but for some applications the need for sharing data
leads to shared memory, mutexes, potential for race conditions, and so
on, and you've got most of the downside of threading. You're still
redesigning stuff for performance. Another alternative to threading
(that I've resolved to favour) to cope with operations that block,
especially homogeneous ones, is multiplexing; again, with subtleties
and redesign for performance.

Regards, John
 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-11-2010
In message
<(E-Mail Removed)>, John
Little wrote:

> On Oct 11, 2:23 pm, Lawrence D'Oliveiro <l...@geek-
> central.gen.new_zealand> wrote:
>
>> > - It's not practical to take "doing things efficiently" out of "doing
>> > things right".

>>
>> Doing things right must come first.

>
> But my point still stands.


Saying your point stands doesn’t make it stand.

>>>> Threading is a performance hack.

>>
>>> Not always. It can be a way to cope with operations that block,
>>> especially inhomogeneous ones.

>>
>> The usual *nix way of dealing with those is forking, not threading.

>
> For windows the usual way(I'm told) is threading, forking not
> performing well, and I'd argue that this led to instability of much
> windows software.
> For *nix, I agree, but for some applications the need for sharing data
> leads to shared memory, mutexes, potential for race conditions, and so
> on, and you've got most of the downside of threading.


The one thing you don’t get is sharing-by-default. Instead, everything you
want shared must be explicitly shared. That already avoids a lot of
problems.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
+1 QOTW... skip@pobox.com Python 0 03-13-2009 12:12 PM
+1 QOTW Lawrence D'Oliveiro NZ Computing 1 01-18-2007 02:39 AM
+1 QOTW olsongt@verizon.net Python 8 09-24-2006 07:53 PM
QOTW from Ryan Tomayko Robert Brewer Python 1 01-20-2005 06:03 PM
QOTW! (was RE: Random thoughts from an aspiring Pythonista) Robert Brewer Python 4 07-12-2004 10:13 AM



Advertisments