[Eventmachine-talk] Ruby I/O

Tony Arcieri
Tue, 13 Mar 2007 10:08:20 -0000

Yes, it didn''t build.  It looks like it''s trying to cast a
pointer to an
int, and since I''m building it on 64-bit machines pointers are 64-bit
and
int 32-bit:

g++ -I. -I. -I/usr/local/lib/ruby/1.8/x86_64-linux -I. -DHAVE_OPENSSL_SSL_H
-DHAVE_OPENSSL_ERR_H  -DOS_UNIX -DBUILD_FOR_RUBY -DWITH_SSL -fPIC -g -O2
-c rubyhttp.cpp
rubyhttp.cpp: In function ''VALUE t_post_init(VALUE)'':
rubyhttp.cpp:166: error: cast from ''RubyHttpConnection_t*'' to
''int'' loses
precision
make: *** [rubyhttp.o] Error 1

- Tony

On 3/13/07, Francis Cianfrocca <garbagecat10 at gmail.com>
wrote:
>
> On 3/13/07, Tony Arcieri <tony at clickcaster.com> wrote:
> >
> >  I''ve seen a number of interesting things in gprof, including
a number
> > of platform-specific oddities.  On Linux, during an I/O handling event
loop,
> > Ruby spends a relatively large amount of time calling sigprocmask()
(this
> > doesn''t occur on MacOS X).  When running EventMachine, there
are a large
> > number of calls to gettimeofday() (which I assume EventMachine is
using for
> > its timer scheduling).  However, the overwhelming number of calls are
to
> > select(), although this number decreased with an increasing number of
> > connections.
>
>
>
> how expensive are the gettimeofday calls? Ruby calls sigprocmask because
> it uses a signal to schedule its thread scheduler.
>
> I''m running out of excuses to do an epoll implementation of EM.
> Incidentally, did you guys get a chance to look at the HTTP server I sent
> you?
>
>
> _______________________________________________
> Eventmachine-talk mailing list
> Eventmachine-talk at rubyforge.org
> http://rubyforge.org/mailman/listinfo/eventmachine-talk
>



--
Tony Arcieri
ClickCaster, Inc.
tony at clickcaster.com
(970) 232-4208
-------------- next part --------------
An HTML attachment was scrubbed...