ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> ruby-talk
ruby-talk
Re: threadify-0.0.1
by Ara.T.Howard other posts by this author
Jul 10 2008 8:56PM messages near this date
Re: threadify-0.0.1 | Re: [ANN] threadify-0.0.1
On Jul 10, 2008, at 8:39 PM, Daniel Berger wrote:

>  Pretty cool. I tried it with file-find. Here was the code:
> 
>  require 'file/find'
>  require 'threadify'
> 
>  rule = File::Find.new(
>    :pattern => "*.rb",
>    :path    => "C:\\ruby"
>  )
> 
>  start = Time.now
> 
>  rule.find.threadify(10){ |f|
>    p f
>  }
> 
>  p start
>  p Time.now
> 
>  Without threadify, it took 1:40 on my laptop. With threadify(10) it
>  dropped to 44 seconds.
> 
>  I think I'll add a "threads" option directly, and borrow some of your
>  code. :)
> 
>  Thanks,
> 
>  Dan



sweet.  i wouldn't launch rockets with it - but it a cheap speedup for  
a bunch of ruby code.  btw - check out my find method

   http://codeforpeople.com/lib/ruby/alib/alib-0.5.1/lib/alib-0.5.1/find2.rb

very stolen and hacked


a @ http://codeforpeople.com/
--
we can deny everything, except that we have the possibility of being  
better. simply reflect on that.
h.h. the 14th dalai lama
Thread:
Ara Howard
Daniel Berger
Ara.T.Howard
Charles Oliver Nutter
Michael Guterl
Charles Oliver Nutter
Michael Guterl
Ara.T.Howard
Charles Oliver Nutter
Charles Oliver Nutter
Ara.T.Howard
Ara.T.Howard
Ara.T.Howard
Charles Oliver Nutter
Martin DeMello
Charles Oliver Nutter
Martin DeMello
Ara.T.Howard
Fedzor

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved