perf
perf copied to clipboard
Check for non-empty event buffer on perfhup
Previously, if poll returned HUP, we would immediately return ErrDisabled, but this means we could miss events if there are events waiting in the buffer.
Fixes: #23
Please consider this patch carefully. I'm still not certain that this fixes all the underlying issues. I'll let you think about it before explaining what I understand, so that we each cover as much ground as possible :)
Friendly ping. My memory of this is fading. I spent a fair amount of time trying to understand this at the time, and concluded this was the right thing to do. Without it, I recall seeing events missing from the ring buffer.
Ping @acln0
Ping, it would be nice to try and resolve this some time. Hope all is well.