Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Ruby 2.0 joint Ruby/Perl/Python backend ?

Reply
Thread Tools

Ruby 2.0 joint Ruby/Perl/Python backend ?

 
 
surf
Guest
Posts: n/a
 
      01-18-2007

At the back of the Nutshell book it mentions a possibilty of a joint
backend of Ruby/Perl/Python.

Anyone ever heard much on that ? The really cool thing about that
would be that might be that if you could get access to all the Perl
stuff on CPAN and call it through Ruby then you could leverage that,
otherwise Ruby developers would have to reinvent the wheel on that
stuff and there is a ton of stuff available.

 
Reply With Quote
 
 
 
 
pat eyler
Guest
Posts: n/a
 
      01-18-2007
On 1/18/07, surf <> wrote:
>
> At the back of the Nutshell book it mentions a possibilty of a joint
> backend of Ruby/Perl/Python.
>
> Anyone ever heard much on that ? The really cool thing about that
> would be that might be that if you could get access to all the Perl
> stuff on CPAN and call it through Ruby then you could leverage that,
> otherwise Ruby developers would have to reinvent the wheel on that
> stuff and there is a ton of stuff available.
>


That's the lure of Cardinal (Ruby on Parrot):
http://cardinal2.rubyforge.org

It's not very far along at this point, bu you can read about an interview
with the lead hacker here:
http://on-ruby.blogspot.com/2006/09/...kevin-tew.html

>
>



--
thanks,
-pate
-------------------------
http://on-ruby.blogspot.com

 
Reply With Quote
 
 
 
 
M. Edward (Ed) Borasky
Guest
Posts: n/a
 
      01-18-2007
surf wrote:
> At the back of the Nutshell book it mentions a possibilty of a joint
> backend of Ruby/Perl/Python.
>
> Anyone ever heard much on that ? The really cool thing about that
> would be that might be that if you could get access to all the Perl
> stuff on CPAN and call it through Ruby then you could leverage that,
> otherwise Ruby developers would have to reinvent the wheel on that
> stuff and there is a ton of stuff available.
>

s/Perl/Java/ and you have Java, JRuby and Jython running on the Java
Virtual Machine. With all due respect to the Parrot and Cardinal
projects, the JVM has many engineer-decades of industrial strength
software development under its belt and is now Open Source -- GPL, even!
If you *must* have Perl, it seems to me the path of least resistance
would be to build a JPerl. I don't know for a fact that there isn't such
a project.

--
M. Edward (Ed) Borasky, FBG, AB, PTA, PGS, MS, MNLP, NST, ACMC(P)
http://borasky-research.blogspot.com/

If God had meant for carrots to be eaten cooked, He would have given rabbits fire.


 
Reply With Quote
 
micathom
Guest
Posts: n/a
 
      01-18-2007
> s/Perl/Java/ and you have Java, JRuby and Jython running on the Java
> Virtual Machine.


I think there is a difference between having an interpreter running in
the jvm running ruby code or ruby source code being translated/compiled
to bytecode running in a vm (maybe using a JIT compiler) -- and the jvm
is AFAIK rather java centric.

 
Reply With Quote
 
Charles Oliver Nutter
Guest
Posts: n/a
 
      01-18-2007
micathom wrote:
>> s/Perl/Java/ and you have Java, JRuby and Jython running on the Java
>> Virtual Machine.

>
> I think there is a difference between having an interpreter running in
> the jvm running ruby code or ruby source code being translated/compiled
> to bytecode running in a vm (maybe using a JIT compiler) -- and the jvm
> is AFAIK rather java centric.


Jython already compiles to bytecode. I've been working on JRuby's
compiler, and it's going very well. There's not really anything about
the JVM that would prevent these languages from getting compiled to
bytecode, and there are plans to expand/improve the JVM to make it
easier to do so.

As an example, here's a fib(34) benchmark running under Ruby 1.8.5 and
in JRuby trunk with my prototype JIT compiler enabled:

(the "compiled" line is logging from JRuby's JIT)

~/NetBeansProjects/jruby$ ruby test/bench/bench_fib_recursive.rb
12.740000 1.790000 14.530000 ( 14.531119)
12.800000 1.750000 14.550000 ( 14.55770
~/NetBeansProjects/jruby$ jruby test/bench/bench_fib_recursive.rb
compiled: Object.fib_ruby
8.178000 0.000000 8.178000 ( 8.178000)
7.199000 0.000000 7.199000 ( 7.199000)

- Charlie

 
Reply With Quote
 
Ben Bleything
Guest
Posts: n/a
 
      01-18-2007
On Fri, Jan 19, 2007, micathom wrote:

<snip>

> to bytecode running in a vm (maybe using a JIT compiler) -- and the jvm
> is AFAIK rather java centric.


I don't think this is true... it's just (relatively) primitive. My
university's architecture and assembly class used the JVM as the example
machine

Ben

 
Reply With Quote
 
micathom
Guest
Posts: n/a
 
      01-18-2007
> Jython already compiles to bytecode. I've been working on JRuby's
> compiler, and it's going very well. There's not really anything about
> the JVM that would prevent these languages from getting compiled to
> bytecode, and there are plans to expand/improve the JVM to make it
> easier to do so.


Well, I vaguely remember some papers explaining why the CLR is better
suited than the JVM as a generic VM and why some tricks are simply
impossible (or unlikely) with the JVM. But please don't ask me about
details, and you will probably know papers coming to exactly the
opposite conclusion. Anyway, my personal impression was that most
jsomething compilers/interpreters often were frustratingly slow and
IMHO never quite kept up with their creator's promises. But I have to
admit that this information is not, well, up to date and I'm very glad
to hear that it maybe isn't true (any longer?) and will improve. Thanks
for the info.

 
Reply With Quote
 
Giles Bowkett
Guest
Posts: n/a
 
      01-18-2007
On 1/18/07, M. Edward (Ed) Borasky <> wrote:
> surf wrote:
> > At the back of the Nutshell book it mentions a possibilty of a joint
> > backend of Ruby/Perl/Python.
> >
> > Anyone ever heard much on that ? The really cool thing about that
> > would be that might be that if you could get access to all the Perl
> > stuff on CPAN and call it through Ruby then you could leverage that,
> > otherwise Ruby developers would have to reinvent the wheel on that
> > stuff and there is a ton of stuff available.


Speaking as a former Perl hacker, even a one-time "Perl Guru" -- not
really, but they called me that at one particular company -- I have to
tell you, reinventing the wheel is only bad when the existing wheel is
circular. There may be one or two square wheels on CPAN, and if so,
reinventing them would probably be okay. I mean you could make the
case that Rails is nothing but a square ring of square wheels
reinvented recursively to be circular (although the metaphor breaks
down pretty painfully).

> s/Perl/Java/ and you have Java, JRuby and Jython running on the Java
> Virtual Machine. With all due respect to the Parrot and Cardinal
> projects, the JVM has many engineer-decades of industrial strength
> software development under its belt and is now Open Source -- GPL, even!
> If you *must* have Perl, it seems to me the path of least resistance
> would be to build a JPerl. I don't know for a fact that there isn't such
> a project.


I think this is a very good point. (Which is probably it took over the
entire thread.) The Parrot and Cardinal projects **sound** cool, but
I've always been skeptical of both -- honestly, I'm not sure why, but
I definitely have doubts -- while JRuby and Jython happened naturally,
and instead of being just around the corner for a decade or so, they
happened quickly, especially JRuby.

There's actually a very neat interview on InfoQ with Tim Bray (I
think? the Atom guy) about why Sun is interested in things like JRuby,
and the answer is, if Ruby runs on a JVM ten years from now, making
JVMs and hardware that runs them well is still a business.

That being said, I heard Jython might actually be dead in the water.
Total rumor, though, I don't really know. I was up very late last
night and I'm still in a groggy morning mode, so if the post seems
grumpy and/or ill-informed, sorry about that.

--
Giles Bowkett
http://www.gilesgoatboy.org
http://gilesbowkett.blogspot.com
http://gilesgoatboy.blogspot.com

 
Reply With Quote
 
Rich Morin
Guest
Posts: n/a
 
      01-18-2007
At 10:15 PM +0900 1/18/07, surf wrote:
> At the back of the Nutshell book it mentions a possibilty of a joint
> backend of Ruby/Perl/Python.
>
> Anyone ever heard much on that ? The really cool thing about that
> would be that might be that if you could get access to all the Perl
> stuff on CPAN and call it through Ruby then you could leverage that,
> otherwise Ruby developers would have to reinvent the wheel on that
> stuff and there is a ton of stuff available.


The Perl 6 back end is called Parrot (a Monty Python reference, FWIW).
An attempt is being made to create front ends for Python, Ruby, etc.
The Ruby front end is called Cardinal. See:

http://rubyforge.org/projects/cardinal/

Note that there are also efforts under way to run Ruby on top of the
Java Virtual Machine (JRuby) and .NET (e.g., NETRuby, Ruby.NET).

-r
--
http://www.cfcl.com/rdm Rich Morin
http://www.cfcl.com/rdm/resume
http://www.cfcl.com/rdm/weblog +1 650-873-7841

Technical editing and writing, programming, and web development

 
Reply With Quote
 
pat eyler
Guest
Posts: n/a
 
      01-18-2007
On 1/18/07, Rich Morin <> wrote:
> At 10:15 PM +0900 1/18/07, surf wrote:
> > At the back of the Nutshell book it mentions a possibilty of a joint
> > backend of Ruby/Perl/Python.
> >
> > Anyone ever heard much on that ? The really cool thing about that
> > would be that might be that if you could get access to all the Perl
> > stuff on CPAN and call it through Ruby then you could leverage that,
> > otherwise Ruby developers would have to reinvent the wheel on that
> > stuff and there is a ton of stuff available.

>
> The Perl 6 back end is called Parrot (a Monty Python reference, FWIW).
> An attempt is being made to create front ends for Python, Ruby, etc.
> The Ruby front end is called Cardinal. See:
>
> http://rubyforge.org/projects/cardinal/


actually, cardinal is dead, cardinal2 is the project you want

>
> Note that there are also efforts under way to run Ruby on top of the
> Java Virtual Machine (JRuby) and .NET (e.g., NETRuby, Ruby.NET).
>
> -r
> --
> http://www.cfcl.com/rdm Rich Morin
> http://www.cfcl.com/rdm/resume
> http://www.cfcl.com/rdm/weblog +1 650-873-7841
>
> Technical editing and writing, programming, and web development
>
>



--
thanks,
-pate
-------------------------
http://on-ruby.blogspot.com

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Simple task works when MS SQL Server is the backend but not when MySQL is the backend. Ted ASP .Net 1 02-22-2007 08:33 PM
New releases: Rent, Narnia & Spike Lee Joint Collection: Updated complete downloadable R1 DVD DB & info lists Doug MacLean DVD Video 0 01-17-2006 05:44 AM
Call For Papers: June 26-29, 2006, joint conferences in computer science, computer engineering & applied computing; USA A. M. G. Solo VHDL 0 01-13-2006 09:51 AM
Call For Papers: 2006 PDPTA, ICAI, SERP + more (28 joint conferences); Las Vegas, USA, June 2006 A. M. G. Solo VHDL 0 11-21-2005 04:53 AM
Entrepreneur seeks like minded programmers for joint venture. VJL Java 0 10-12-2003 10:35 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57