<br><br><div><span class="gmail_quote">On 7/6/07, <b class="gmail_sendername">Dave Hansen</b> <<a href="mailto:dave@sr71.net">dave@sr71.net</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On Fri, 2007-07-06 at 16:44 -0700, Brandon Martin-Anderson wrote:<br>> Agree'd: Ruby is best for small prototypes; it does not do heavy<br>> lifting well. The best thing you (or I) could do in the short term is<br>
> run a profiler on a small county and see what's eating up all the<br>> resources. It's likely that it can be optimized by a factor of two by<br>> optimizing the code within Ruby.<br><br>I've actually been using ruby-prof pretty heavily. I realized that
<br>ruby's function calls are horrific. My habits from coding in the Linux<br>kernel taught me to write quick, small functions. They were awful in<br>ruby.<br><br>> If that doesn't seem possible, it is relatively straightforward to
<br>> implement a Ruby function in C. A lot of the faster "Ruby" libraries<br>> are actually written in C with liberal use of the " ruby.h" header to<br>> give access to Ruby types.<br><br>Perhaps I'll give this a try. I'm going to post a new version in a bit.
<br>We'll see what people think of it.<br><br>How hard would it be for you to re-write the tiger parser in C? I<br>could do the OSM bits pretty easily.</blockquote><div><br>Oomph. I'll take a look at the latest code and see what I can do with it. The efficiency of the implementation of various function calls varies _wildly_. For example chunking a _huge_ string into an array using a regex is very, very efficient. I might be able to speed things up a bit. If all hope is lost, we'll see about C.
<br><br>-B<br> </div><br></div><br>