How to speed up ruby and make it as fast as possible

Hi Justin,
I am glad that Ruby 2 is being worked on, which will bring speed and
other improvements. What prompted my original statement on this issue
was a message that simply told someone to use C when the question was
asked about ways to speed up Ruby programs. I think a more constructive
response to such questions begins by acknowledging this current problem
in Ruby, partly to reassure him or her that the problem is not just a
matter of programming deficiency. The response might then remind one of
the ease of development benefits that one gets in return, as well as
summarizing projects underway to improve performance as well. I think
it's fine to explain how C may be used for time-sensitive parts of an
application if one already knows C. In general, however, I do not think
it is reasonable to expect someone to learn a fundamentally different,
low level language for this purpose. It is definitely not constructive
to demean their programming interest and skills if they do not know or
want to learn C.

Regards,
Jamal

···

-----Original Message-----
From: Justin Collins [mailto:collinsj@seattleu.edu]
Sent: Friday, July 14, 2006 1:50 PM
To: ruby-talk ML
Subject: Re: How to speed up ruby and make it as fast as possible

I don't think people are ignoring Ruby's performance or rationalizing it

away. That's why all that work is going into YARV for Ruby2. That's why
there is ruby2c. There are people who are consciously working towards a
better performing Ruby. As far as I understand it, there is plenty of
room for Ruby to improve (performance has not been a top priority
previously), so I have no doubt that we will see a faster Ruby in the
future.

However, if you want an immediate solution, then the solution is to use
another language or link to another language from Ruby. The helpful
people on this list are also very practical, so when someone says, "How
do I make my Ruby program run faster?" instead of answering, "Sorry, you

can't" they give practical advice.

Sorry to be blunt, but if you are not contributing to improving Ruby's
performance, then you (and I :slight_smile: will need to be patient and wait for the

newer, faster, even more awesome versions of Ruby to come out.

-Justin

You insist that this is a "problem".

But you neither qualify or quantify the problem. Why is current Ruby performance a problem, and at what level of performance does it cease to be a problem?

Kirk Haines

···

On Sat, 15 Jul 2006, Jamal Mazrui wrote:

Hi Justin,
I am glad that Ruby 2 is being worked on, which will bring speed and
other improvements. What prompted my original statement on this issue
was a message that simply told someone to use C when the question was
asked about ways to speed up Ruby programs. I think a more constructive
response to such questions begins by acknowledging this current problem
in Ruby, partly to reassure him or her that the problem is not just a

Jamal,
Stop being a troll.

Ruby is comparable in speed to other interpreted languages. If you'd
like to speed up your code profiling your code and cleaning up
algorithmic bottlenecks is the simplest way. After that, optimizing in
C is the way to go. You don't have to do it this way, but it is one of
the few answers to the problem and is a valid response to the
question.

···

--
Kevin Clark
http://glu.ttono.us

khaines@enigo.com wrote:

···

On Sat, 15 Jul 2006, Jamal Mazrui wrote:

Hi Justin,
I am glad that Ruby 2 is being worked on, which will bring speed and
other improvements. What prompted my original statement on this issue
was a message that simply told someone to use C when the question was
asked about ways to speed up Ruby programs. I think a more constructive
response to such questions begins by acknowledging this current problem
in Ruby, partly to reassure him or her that the problem is not just a

You insist that this is a "problem".

But you neither qualify or quantify the problem. Why is current Ruby performance a problem, and at what level of performance does it cease to be a problem?

Kirk Haines

The Goal of all programs and languages is to execute in O(0) Time :wink: