Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Computing > NZ Computing > QOTW

Reply
 
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-05-2010
“Whenever faced with a problem, some people say `Lets use multithreading.'
two they problems. Now, have.”

(Found on Twitter. Ahem.)
 
Reply With Quote
 
 
 
 
Matty F
Guest
Posts: n/a
 
      10-06-2010
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.
 
Reply With Quote
 
 
 
 
Sweetpea
Guest
Posts: n/a
 
      10-06-2010
On Thu, 07 Oct 2010 10:26:58 +1300, Allistar wrote:

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


I wouldn't mind seeing the name of that application.

Is the current version still available?


--
"Filtering the Internet is like trying to boil the ocean"
 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-07-2010
In message
<(E-Mail Removed)>, Matty F
wrote:

> 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.


All together now: “Premature optimization is the root of all evil”.

Threading is a performance hack. Like all such hacks, it’s not something you
put in unless you can show that it actually improves performance. Otherwise,
it just complicates your code to no end.
 
Reply With Quote
 
Enkidu
Guest
Posts: n/a
 
      10-07-2010
On 07/10/10 10:26, Allistar 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.
>

Well, the threading libraries were new then, and have improved
enormously, and some early applications that were 'advertised' as
multi-threading actually just spawned task after task, after task.

Cheers,

Cliff

--

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

The end excuses any evil - Sophocles
 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-07-2010
In message <(E-Mail Removed)>, Allistar wrote:

> Threading is a performance hack? That's like saying "caching is a
> performance hack".


Out of the mouths of babes...

> A well designed application that needs threading would have it built in
> from the ground up. Not forced in as an after thought.


Premature optimization is the root of all evil.
 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-08-2010
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>
 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      10-08-2010
In message <(E-Mail Removed)>, 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.
 
Reply With Quote
 
Enkidu
Guest
Posts: n/a
 
      10-08-2010
On 08/10/10 15:01, 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.
>

Hehehehehehehehehe! This from the guy who still thinks software RAID is
a good idea! Hehehehehehehe!

Cheers,

Cliff

--

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

The end excuses any evil - Sophocles
 
Reply With Quote
 
Enkidu
Guest
Posts: n/a
 
      10-08-2010
On 08/10/10 15:12, 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?
>
> I have been involved in many systems where efficiency and optimisation was
> ignored and I have seen the consequences of that. It often result is major
> rearchitecturing which is both costly and disruptive.
>
> While I agree that the architecture of a system shouldn't be driven entirely
> by performance considerations, I do think such considerations are quite
> important to the end result. There's no point having a very elegantly
> designed solution if it performs like crap and annoys users.
>

Exactly.

Cheers,

Cliff

--

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

The end excuses any evil - Sophocles
 
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