[Stackless] Stackless Digest, Vol 70, Issue 5

Andrew Francis andrewfr_ice at yahoo.com
Fri Nov 6 01:24:44 CET 2009


Hi Ying:

Message: 2
Date: Thu, 05 Nov 2009 00:01:26 +0100
From: Ying Zhong <zhongying2008 at googlemail.com>
To: Stackless at stackless.com
Subject: [Stackless] (Performance-)Problem about Stackless-Twisted
    integration
Message-ID: <4AF207C6.2000002 at googlemail.com>
Content-Type: text/plain; charset=ISO-8859-15; format=flowed

>So the reactor is just there and doing "nothing", while the tasklets are
>changing data through a channel. With schedule_rate = 10 I got the
>normal results:
>sang #12 times in 1.109000 sec.
>sang #11 times in 1.094000 sec.
>...
>But with schedule_rate = 100, 1000, or even 100000, I always got results
>with the same rate at 65 messages per Sec.:
>sang #65 times in 1.015000 sec.
>sang #65 times in 1.016000 sec.
...

>Is there such a limit? or am I doing something wrong? Yes I also tried
>using another tasklet to force the reactor yield, 

>t.start(1.0/schedule_rate)

I recently posted some thoughts on the twisted mailing list about Stackless Twisted integration. I didn't get a response :-(

That said, my guess is that you are butting against two things: 

1) Clock resolution. 1/10 = .1 1/100 = .01 1/1000 = .0001 (?) 

2) Overhead from system I/O calls (under the hood, you are making a
call to select or epoll). Smaller the number, the faster you are 
driving the reactor loop.

Cheers,
Andrew


      




More information about the Stackless mailing list