![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
The Oblivious One
Join Date: May 2005
Location: Ontario, Canada
Posts: 630
Rep Power: 4
![]() |
Ruby speed improvements with YARV
In case you didn't know, a new virtual machine for Ruby called YARV (Yet Another Ruby VM) has been integrated into testing for Ruby 1.9.
In my own (very informal) testing, I've gotten speed ups of 2x to about 8x. You can download it from the ruby-lang.org website. Also, take a glance at this page for some benchmarks. http://www.antoniocangiano.com/artic...us-vs-cardinal ![]() EDIT: I thought I'd add a little example. ruby Syntax (Toggle Plain Text)
python Syntax (Toggle Plain Text)
Ruby 1.8.5 $ time ruby fib.rb real 0m15.306s user 0m13.273s sys 0m1.984s Python 2.4.4 $ time python fib.py real 0m6.857s user 0m6.736s sys 0m0.036s Ruby 1.9 (2007 - 02 - 25) $ time /usr/local/src/ruby/ruby fib.rb real 0m2.048s user 0m2.012s sys 0m0.016s
__________________
Dr. Zoidberg: [ecstatic] I'm going to a movie... with FRIENDS! Last edited by Jessehk; Feb 26th, 2007 at 8:09 PM. |
|
|
|
|
|
#2 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
I'm going to muse that if one needs to be concerned about performance, then one needs a language that reflects one's ability to code, and not a language that reflects the abilities of some version of its own implementation. The latter approach leaves one chasing after chimera, rather than ability.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#3 |
|
The Oblivious One
Join Date: May 2005
Location: Ontario, Canada
Posts: 630
Rep Power: 4
![]() |
I'd agree that speed is not as important as the ability to be efficient when writing code.
I just made a point of this because many Ruby people have been complaining about the slow speed of the language. Now, there is some progress being made in that area. It's exciting. ![]()
__________________
Dr. Zoidberg: [ecstatic] I'm going to a movie... with FRIENDS! Last edited by Jessehk; Feb 26th, 2007 at 8:28 PM. Reason: Missed DaWei's point completely. I was sick today, so I have an excuse. ;) |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Ruby or Python? | titaniumdecoy | Other Scripting Languages | 2 | May 30th, 2006 12:51 AM |
| Ruby guides/References list | Jessehk | Ruby | 2 | Mar 21st, 2006 11:31 PM |
| Ruby Classes tutorial | bulio | Ruby | 5 | Oct 29th, 2005 11:32 PM |
| Assignment of numbers to variables without asking | Haz | C# | 26 | May 23rd, 2005 10:30 AM |
| C# Pilot Program | Haz | Existing Project Development | 9 | May 2nd, 2005 9:27 AM |