Toby,<br><br>Good work!<br><br>There is several questions for your implementation:<br><br>1) If you play with the Completion port, there is no reason to use the hEvent&nbsp; in the OVERLAPPED structure. Why do you use it?<br><br>
2)I suppose socket_internal_iocp_read is called before you invoke the callback to let the callback consume the received data. Why do you call socket_internal_iocp_read firstly?<br><br>3)Is there any plan to support all of the Async operations, such as connect, listen, accept, read and write?
<br><br>BTW: your implementation has a lot of difference with libevent. The most important one is libevent is a &quot;single-threaded event-driven&quot; library. This could relieve the programmer from the burden of explicitly synchronization, althouth it can't explore the capability of SMP.
<br><br>best regards,<br>hanzhu<br><div><span class="gmail_quote">On 12/10/06, <b class="gmail_sendername">Toby Douglass
</b> &lt;<a href="mailto:toby.douglass@summerblue.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">toby.douglass@summerblue.net</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

Zhu Han wrote:<br>&gt; I'm afraid WINDOWS Overlapped IO is a critical feature for libevent because<br>&gt; some of the servers required it.&nbsp;&nbsp;I try to implement&nbsp;&nbsp;this feature with<br>&gt; Completion Port.&nbsp;&nbsp;Is anyone&nbsp;&nbsp;busing on&nbsp;&nbsp;it? If not, I will try to do it.
<br><br>I've written an IOCP library, which is here;<br><br><a href="http://www.summerblue.net/computing/libiocp/index.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.summerblue.net/computing/libiocp/index.html
</a><br><br>It's not integrated into libevent though, which is something I'm not doing.
<br><br>I've finished rewriting that IOCP library to support listen sockets, so<br>the IOCP stuff will take care of all the accept behaviour, too.&nbsp;&nbsp;Right<br>now I'm writing up test/example code for that, once it tests okay, I'll
<br>release, which I expect to do next weekend.<br><br>_______________________________________________<br>Libevent-users mailing list<br><a href="mailto:Libevent-users@monkey.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
Libevent-users@monkey.org</a><br><a href="http://monkey.org/mailman/listinfo/libevent-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://monkey.org/mailman/listinfo/libevent-users</a><br></blockquote></div><br>