[Libevent-users] Libevent tutorial and reference manual

2009-04-23 Thread Nick Mathewson
Hi, all. I've started work on a tutorial and reference manual for Libevent. Right now, they're far from complete: the tutorial only has a few examples, and the reference manual has nothing but instructions on how to create and use an event_base. You can get the latest version from http://wan

[Libevent-users] Evhttp's HTTP protocol version handling

2009-04-23 Thread Haiping Zhao
Hey, I just found evhttp's pretty picky about HTTP request without correct protocol version. For example, "GET /status.php\r\n", instead of "GET /status.php HTTP/1.1\r\n". So I'm suggesting this change, --- http.c 2008-12-19 14:27:27.0 -0800 +++ /var/users/hzhao/hphp/external/libeven

Re: [Libevent-users] Libevent 1.4.9-stable slower than 1.3c?

2009-04-23 Thread Haiping Zhao
I was thinking about an easier change, which is to add another timer update before timeout_correct(base, &tv). This is the function that could be using an out-of-date timestamp, if event_process_active(base) takes longer than expected. But sorry I really couldn't find any bandwidth to verify whe

Re: [Libevent-users] epoll keyed wakeups - Patch merged on 2.6.30-rc1

2009-04-23 Thread Niels Provos
On Thu, Apr 23, 2009 at 9:38 AM, Nick Mathewson wrote: > Reading over the test code, I can't figure out if there is actually a > new API here.  If I understand correctly, we may be getting the > benefits of this for free on any system with the new kernel code.  Am > I missing something that we'd n

Re: [Libevent-users] epoll keyed wakeups - Patch merged on 2.6.30-rc1

2009-04-23 Thread Nick Mathewson
On Wed, Apr 08, 2009 at 08:33:58AM -0700, Raine Fan wrote: > Hi! I'm just curious if libevent 1.5/2.0 will be carrying this > improvements (epoll keyed wakeups - see article on LWN.net: > http://lwn.net/Articles/317489/) from epoll patch set that was > merged recently on kernel 2.6.30-rc1 this week

Re: [Libevent-users] epoll_wait problems

2009-04-23 Thread Nick Mathewson
On Mon, Mar 23, 2009 at 02:23:37PM +0100, Richter, J??rg wrote: > Hi, > > Not really libevent specific, but perhaps someone here has seen this before > and can help me with this one. > > The problem is that epoll_wait hangs longer than requested. > This is a "strace -t -T -e epoll_wait" output

Re: [Libevent-users] Libevent 1.4.9-stable slower than 1.3c?

2009-04-23 Thread Nick Mathewson
On Tue, Apr 14, 2009 at 11:23:24PM -0700, Haiping Zhao wrote: [...] > Anyways, I'll have to re-think our model. At the same time, may I > ask why the change? Was that for calling gettimeofday() less number > of times to be more efficient? But the code only updates > base->tv_cache once per loop,