[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [Libevent-users] epoll erros
On Wed, Sep 22, 2010 at 11:53 AM, Gilad Benjamini
<gilad@xxxxxxxxxxxxxxxxx> wrote:
>>
>> 2010/9/21 Gilad Benjamini <gilad@xxxxxxxxxxxxxxxxx>:
>> [...]
>> > Any chance you can hmake something out of the attached log ?
>>
>> That's pretty helpful! It's almost but not quite enough information
>> to figure out what's up here. There are a couple of epoll debugging
>> messages that don't give enough detail.
>>
>> I just added a couple more detailed debugging messages in the git
>> master branch to help try to figure out what exactly we're doing to
>> epoll fd, and why. If you can get the same output with the new stuff
>> from git master, that would be great.
>
>
> I can, but it would take me a few days.
> In the mean time, I do have a hunch, based on reading the code.
> In epoll_apply_changes, when precautionary_add is turned on, based on
> equality between old and new events, shouldn't that only be done if their
> value is non-zero ?
I'm not sure how that part of the code could be reached with
new_events equal to zero. It's inside an if block that gets invoked
when at least one of read_change and write_change is EV_CHANGE_ADD.
Given that, I think we're bound to call one of the blocks that sets
EV_READ or EV_WRITE in new_events.
That said, you could try adding an EVUTIL_ASSERT(new_events != 0)
inside the block that turns on precautionary add, and see whether it
ever triggers. If it does, we'll know I'm wrong.
--
Nick
***********************************************************************
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users in the body.