[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: need for threads

Daniel Nugent

2/21/2006 6:10:00 PM

Uh, yeah, that's pretty much why not all code is threaded.

On the other hand, in programs above a certain size, or ones that have
graphical user interface, there usually is something else that you can
do while you're waiting on that resource.

On 2/21/06, tony summerfelt <snowzone5@hotmail.com> wrote:
> a discussion of tcl threads came up in that newsgroup.
>
> one of the posts stopped me cold. the msg boiled down to:
>
> on a single non-ht cpu if your program can't do soemthnig while
> waiting on a resource there's no real need for threaded code.
>
> threading will actually slow down your program overall.
>
> http://home.cogeco.ca/~ts...
> telnet://ventedspleen.dyndns.org
>
>


--
-Dan Nugent


1 Answer

Robert Klemme

2/21/2006 6:30:00 PM

0

Daniel Nugent <nugend@gmail.com> wrote:
> Uh, yeah, that's pretty much why not all code is threaded.
>
> On the other hand, in programs above a certain size, or ones that have
> graphical user interface, there usually is something else that you can
> do while you're waiting on that resource.

Like reading from or writing to another resource. Exactly. Ruby's
multithreading is only at a loss on a multi CPU machine with heavy
computation because it doesn't use more than one CPU.

Kind regards

robert