Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Poor performance of Ruby 1.8.7 when installed with MacPorts
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  15 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
abc  
View profile  
 More options Nov 1 2008, 6:59 am
Newsgroups: comp.lang.ruby
From: abc <arcadiorubiogar...@gmail.com>
Date: Sat, 1 Nov 2008 03:59:24 -0700 (PDT)
Local: Sat, Nov 1 2008 6:59 am
Subject: Poor performance of Ruby 1.8.7 when installed with MacPorts
Hi,

I've just upgraded to Ruby 1.8.7 using MacPorts (ruby @1.8.7-
p72_1+thread_hooks) and while it runs flawlessly, the performance is
really really poor.

I'm talking in comparison with the Ruby distro that ships with
Leopard, and with my previous installation of 1.8.6 also done with
MacPorts.

For instance a bunch of rspecs i have take 6x to get executed, and ri
takes noticeably more time than previously to load any doc.

Is anyone experiencing the same problem? Do you know how to fix it?

Thanks in advance.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Brian Adkins  
View profile  
 More options Nov 1 2008, 12:46 pm
Newsgroups: comp.lang.ruby
From: Brian Adkins <lojicdot...@gmail.com>
Date: Sat, 01 Nov 2008 12:46:59 -0400
Local: Sat, Nov 1 2008 12:46 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts

abc <arcadiorubiogar...@gmail.com> writes:
> Hi,

> I've just upgraded to Ruby 1.8.7 using MacPorts (ruby @1.8.7-
> p72_1+thread_hooks) and while it runs flawlessly, the performance is
> really really poor.

> I'm talking in comparison with the Ruby distro that ships with
> Leopard, and with my previous installation of 1.8.6 also done with
> MacPorts.

> For instance a bunch of rspecs i have take 6x to get executed, and ri
> takes noticeably more time than previously to load any doc.

> Is anyone experiencing the same problem? Do you know how to fix it?

http://hivelogic.com/articles/2008/02/ruby-rails-leopard


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
abc  
View profile  
 More options Nov 2 2008, 6:34 am
Newsgroups: comp.lang.ruby
From: abc <arcadiorubiogar...@gmail.com>
Date: Sun, 2 Nov 2008 03:34:39 -0800 (PST)
Local: Sun, Nov 2 2008 6:34 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Fine, thanks for the info.

Do you know what is the exact issue with MacPorts though?


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
nakatani katsumi  
View profile  
 More options Nov 3 2008, 5:01 am
Newsgroups: comp.lang.ruby
From: nakatani katsumi <al...@kcat.zaq.ne.jp>
Date: Mon, 3 Nov 2008 05:01:36 -0500
Local: Mon, Nov 3 2008 5:01 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Hi

On Sat, 1 Nov 2008 19:58:54 +0900

abc <arcadiorubiogar...@gmail.com> wrote:
> I've just upgraded to Ruby 1.8.7 using MacPorts (ruby @1.8.7-
> p72_1+thread_hooks) and while it runs flawlessly, the performance is
> really really poor.
> Is anyone experiencing the same problem? Do you know how to fix it?

The same problem reported at ruby-list-45593.(but Japanese only)

Summary is below.
1. On MacOS X(10.5.5), Ruby1.8.7(p72) compiled with --enable-pthread excute slowly,
   as Ruby use time of 70% at rb_call()->getcontext() in fib.rb

2. In MacPorts, ./configure with --enable-pthread option makes config.h using getcontext
like below
#define HAVE_GETCONTEXT 1
#define HAVE_SETCONTEXT 1

3. If you comment out these two lines, you will get normal speed Ruby1.8.7.

4. As Ruby1.9 don't use getcontext()/setcontext(), Ruby1.9 don't care --enable-pthread.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
abc  
View profile  
 More options Nov 4 2008, 8:22 am
Newsgroups: comp.lang.ruby
From: abc <arcadiorubiogar...@gmail.com>
Date: Tue, 4 Nov 2008 05:22:47 -0800 (PST)
Local: Tues, Nov 4 2008 8:22 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Thanks for the explanation!

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
abc  
View profile  
 More options Nov 6 2008, 1:30 pm
Newsgroups: comp.lang.ruby
From: abc <arcadiorubiogar...@gmail.com>
Date: Thu, 6 Nov 2008 10:30:29 -0800 (PST)
Local: Thurs, Nov 6 2008 1:30 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
I filed a bug report and they've just fixed it:

http://trac.macports.org/ticket/17092


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Brian Adkins  
View profile  
 More options Nov 6 2008, 11:18 pm
Newsgroups: comp.lang.ruby
From: Brian Adkins <lojicdot...@gmail.com>
Date: Thu, 06 Nov 2008 23:18:12 -0500
Local: Thurs, Nov 6 2008 11:18 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts

abc <arcadiorubiogar...@gmail.com> writes:
> I filed a bug report and they've just fixed it:

> http://trac.macports.org/ticket/17092

Wow, that was fast. Is the Ruby community great, or what? :) Thanks
for reporting back with the info.

--
Brian Adkins
http://www.lojic.com/
http://lojic.com/blog/


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Nit Khair  
View profile  
 More options Nov 6 2008, 11:55 pm
Newsgroups: comp.lang.ruby
From: Nit Khair <sentinel.2...@gmx.com>
Date: Thu, 6 Nov 2008 23:55:34 -0500
Local: Thurs, Nov 6 2008 11:55 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts

nakatani katsumi wrote:
> Hi

> On Sat, 1 Nov 2008 19:58:54 +0900
> abc <arcadiorubiogar...@gmail.com> wrote:

>> I've just upgraded to Ruby 1.8.7 using MacPorts (ruby @1.8.7-
>> p72_1+thread_hooks) and while it runs flawlessly, the performance is
>> really really poor.

Could someone explain this to to me. I checked the macports page a few
days back and it said it disables/deletes -enable-pthreads due to some
bug. So does that not mean that it's not there. As pointed above, it
uses thread_hooks instead.

1. Is there any commandline option or other way of my ascertaining
whether my install uses pthreads or not.

Another newb question:

2. One of the prev posts suggests altering config.h and running
/configure. However, if one is using sudo port install how does one do
this? I do not have a "configure" in my ruby folder and my config.h
(/opt/local/var/macports/software/ruby/1.8.7-p22_3+darwin_9_powerpc+thread_ hooks/opt/local/lib/ruby/1.8/powerpc-darwin9.4.0/config.h)
does not contain GETCONTEXT.

Thanks.
--
Posted via http://www.ruby-forum.com/.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Roger Pack  
View profile  
 More options Nov 7 2008, 4:36 pm
Newsgroups: comp.lang.ruby
From: Roger Pack <rogerpack2...@gmail.com>
Date: Fri, 7 Nov 2008 16:36:23 -0500
Local: Fri, Nov 7 2008 4:36 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts

> Could someone explain this to to me. I checked the macports page a few
> days back and it said it disables/deletes -enable-pthreads due to some
> bug. So does that not mean that it's not there. As pointed above, it
> uses thread_hooks instead.

apparently somebody said that the most recent macport of it now compiles
with pthreads disabled.

> 1. Is there any commandline option or other way of my ascertaining
> whether my install uses pthreads or not.

from [1]
Maybe try with "ldd" on the ruby binaries--can't remember what the mac
equivalent is but it exists.

> Another newb question:

> 2. One of the prev posts suggests altering config.h and running
> ./configure. However, if one is using sudo port install how does one do
> this? I do not have a "configure" in my ruby folder and my config.h
> (/opt/local/var/macports/software/ruby/1.8.7-p22_3+darwin_9_powerpc+thread_ hooks/opt/local/lib/ruby/1.8/powerpc-darwin9.4.0/config.h)
> does not contain GETCONTEXT.

If you install it from source you should be able to get at it
right...not sure using macports.

GL.
-=R

[1]
http://groups.google.com/group/comp.lang.ruby/browse_thread/thread/a3...
--
Posted via http://www.ruby-forum.com/.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Luc Heinrich  
View profile  
 More options Nov 8 2008, 3:53 am
Newsgroups: comp.lang.ruby
From: Luc Heinrich <l...@honk-honk.com>
Date: Sat, 8 Nov 2008 03:53:42 -0500
Local: Sat, Nov 8 2008 3:53 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
On 7 nov. 08, at 22:36, Roger Pack wrote:

> If you install it from source you should be able to get at it
> right...not sure using macports.

Using MacPorts, you just have to perform the various steps of the  
'install' task manually, like this:

% sudo port fetch ruby
% sudo port extract ruby
% sudo port configure ruby

Now go in the work directory and change what you need. You can see  
where that directory is by typing:
% port file ruby

After that, you can continue normally:
% sudo port install ruby

--
Luc Heinrich - l...@honk-honk.com


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Nit Khair  
View profile  
 More options Nov 8 2008, 6:24 am
Newsgroups: comp.lang.ruby
From: Nit Khair <sentinel.2...@gmx.com>
Date: Sat, 8 Nov 2008 06:24:16 -0500
Local: Sat, Nov 8 2008 6:24 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Luc Heinrich wrote:
> On 7 nov. 08, at 22:36, Roger Pack wrote:

>> If you install it from source you should be able to get at it
>> right...not sure using macports.

> Using MacPorts, you just have to perform the various steps of the
> 'install' task manually, like this:

Thanks a lot.

btw, will installing 1.9 from macports create a separate executable such
as ruby1.9 so we can run 8 and 9 in parallel. Or overwrite?

Is there any way via macports to have both running in parallel.
Thanks.
--
Posted via http://www.ruby-forum.com/.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Luc Heinrich  
View profile  
 More options Nov 8 2008, 9:41 am
Newsgroups: comp.lang.ruby
From: Luc Heinrich <l...@honk-honk.com>
Date: Sat, 8 Nov 2008 09:41:13 -0500
Local: Sat, Nov 8 2008 9:41 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
On 8 nov. 08, at 12:24, Nit Khair wrote:

> btw, will installing 1.9 from macports create a separate executable  
> such
> as ruby1.9 so we can run 8 and 9 in parallel. Or overwrite?

The ruby19 Portfile sets the --program-suffix argument of configure to  
1.9, so yes you could install Ruby 1.8 and Ruby 1.9 at the same time  
on the same machine.

--
Luc Heinrich - l...@honk-honk.com


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jason Lai  
View profile  
 More options Nov 24 2008, 11:55 pm
Newsgroups: comp.lang.ruby
From: Jason Lai <ja...@jasonlai.net>
Date: Mon, 24 Nov 2008 20:55:16 -0800 (PST)
Local: Mon, Nov 24 2008 11:55 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Hi Nakatani-san,

That was really helpful information. I digged a bit more based upon
that thread, and for those who compile Ruby 1.8.7 from source on OS X,
here's a more handy way: add 'ac_cv_func_getcontext=no
ac_cv_func_setcontext=no' along with --enable-pthread, e.g.:
./configure --enable-pthread --enable-shared ac_cv_func_getcontext=no
ac_cv_func_setcontext=no

Then the following lines won't appear on your config.h:
#define HAVE_GETCONTEXT 1
#define HAVE_SETCONTEXT 1

Just my 2 cents,
Jason

On 11月3日, 下午6时01分, nakatani katsumi <al...@kcat.zaq.ne.jp> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
nakatani katsumi  
View profile  
 More options Nov 28 2008, 8:00 am
Newsgroups: comp.lang.ruby
From: nakatani katsumi <al...@kcat.zaq.ne.jp>
Date: Fri, 28 Nov 2008 08:00:02 -0500
Local: Fri, Nov 28 2008 8:00 am
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Hi Jason

On Tue, 25 Nov 2008 13:55:31 +0900

Jason Lai <ja...@jasonlai.net> wrote:
> Hi Nakatani-san,

> That was really helpful information. I digged a bit more based upon
> that thread, and for those who compile Ruby 1.8.7 from source on OS X,
> here's a more handy way: add 'ac_cv_func_getcontext=no
> ac_cv_func_setcontext=no' along with --enable-pthread, e.g.:

Oh,I missed to follow this problem.
This bug was fixed with 1.8.7-p72_2 of MacPorts, that was reported at
ruby-list:45621(japanese only).
(ruby 1.8.7-p72_1 of MacPorts has bug)
You can use the most up-to-date ruby of  MacPorts without any extra option.

--
nakatani katsumi <al...@kcat.zaq.ne.jp>


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jason Lai  
View profile  
 More options Dec 2 2008, 1:45 pm
Newsgroups: comp.lang.ruby
From: Jason Lai <ja...@jasonlai.net>
Date: Tue, 2 Dec 2008 10:45:05 -0800 (PST)
Local: Tues, Dec 2 2008 1:45 pm
Subject: Re: Poor performance of Ruby 1.8.7 when installed with MacPorts
Hi Nakatani-san,

Thanks for the heads-up. But the issue is still there for those
compiling Ruby 1.8.7-p72 from source right? If so, my little tip may
be of some help.

Cheers,
Jason

On Nov 28, 9:00 pm, nakatani katsumi <al...@kcat.zaq.ne.jp> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google