Forum: Ruby Mac OS X Leopard - Ruby is 3X faster with disable-pthreads

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
525128e48ca2b4c7fb6176ea166fccfd?d=identicon&s=25 Eric G. (gotskill10)
on 2008-10-26 05:59
I have a fast mac pro computer.

I ran simple benchmark, and my computer took 13 seconds when
equal/slower macs around my office were only taking 2.5 seconds to
complete the exact same task.

I also noticed that my ruby was generally less zippier.

So I configure ruby to run WITHOUT pthread support, and now its at the
same speed as the other computers.

I dont really know how this could potentially screw things up, but Im
definitely liking the speed increase. The compiler told me the
following:

**
** PTHREAD SUPPORT MODE ERROR:
**
**   Ruby is not compiled with --enable-pthread, but your Tcl/Tk
**   library seems to be compiled with pthread support. This
**   combination may cause frequent hang or segmentation fault
**   errors when Ruby/Tk is working. We recommend that you NEVER
**   create the library with such a combination of pthread support.
**
**   Please recompile Ruby with the "--enable-pthread" configure option
**   or recompile Tcl/Tk with the "--disable-threads" configure option.
**

What Im curious about is, why the big speed difference? Its a night and
day difference in performance. Is there any kind of other performance
issues that I have to watch out for now, like more frequent crashing or
something?
6076c22b65b36f5d75c30bdcfb2fda85?d=identicon&s=25 Ezra Zygmuntowicz (Guest)
on 2008-10-26 22:48
(Received via mailing list)
On Oct 25, 2008, at 9:59 PM, Aryk Grosz wrote:

>
> **   errors when Ruby/Tk is working. We recommend that you NEVER
> day difference in performance. Is there any kind of other performance
> issues that I have to watch out for now, like more frequent crashing
> or
> something?
> --
> Posted via http://www.ruby-forum.com/.
>


  As long as you aren't using tk at all then you have no issue to watch
out for. I compile *all* of my ruby's with pthreads disabled including
all engine yard slices.

Cheers-


Ezra Zygmuntowicz
ez@engineyard.com
3bb23e7770680ea44a2d79e6d10daaed?d=identicon&s=25 unknown (Guest)
on 2008-10-26 23:34
(Received via mailing list)
Quoting Ezra Zygmuntowicz <ezmobius@gmail.com>:

>>
>> **   Ruby is not compiled with --enable-pthread, but your Tcl/Tk
>> day difference in performance. Is there any kind of other performance
>> issues that I have to watch out for now, like more frequent crashing or
>> something?
>> --
>> Posted via http://www.ruby-forum.com/.
>>
>
>
>   As long as you aren't using tk at all then you have no issue to watch
> out for. I compile *all* of my ruby's with pthreads disabled including
> all engine yard slices.

You can also recompile "tcl" and "tk" with "pthreads" disabled. I
ended up having to run all three of them with pthreads for some other
dependency, although I don't remember which one. And I think Ruby 1.9
requires pthreads.
This topic is locked and can not be replied to.