cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-library Mailing List Archives

Re: Project hiper - High Performance libcurl

From: Cory Nelson <phrosty_at_gmail.com>
Date: Mon, 7 Nov 2005 01:53:25 -0800

Sorry for the late reply, been busy...

Here is a small sample that should give you the idea. Unfortunately I
don't know *nix APIs very well, so I'm unable to guess the best API
that would work for the both of them.

I'd make something like:

// called on completion, error, etc..
typedef void (*hiper_callback)(int status, CURL *easy);

// creates the handler.
hiper_handle hiper_create(hiper_callback);
void hiper_destroy(hiper_handle);

// pushes an easy handle onto the hyper handle.
void hiper_push(hiper_handle, CURL *easy);

// blocks until all easy handles are done processing.
void hiper_wait(hiper_handle);

The big change is making the wait function optional- blocking doesn't
belong in a high perf app. I'm assuming that function currently
processes all the sockets- I believe that should all be done in the
background for the user so CURL can make proper use of SMP if it's
available. And maybe add another function to pull the current status
of an easy handle.

What are your thoughts?

On 11/4/05, Daniel Stenberg <daniel_at_haxx.se> wrote:
> On Fri, 4 Nov 2005, Cory Nelson wrote:
>
> > I don't think this maps very well to your API... perhaps we can discuss this
> > further to make sure both platforms perform efficiently. I'll be gone today
> > but will write up some basic code for you to get the idea of how IOCP
> > handles sockets.
>
> I'd appreciate it and I certainly am open for suggestions and discussions
> around how to do the API so that we can get the best performance on Windows as
> well.
>
> --
> Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
>

--
Cory Nelson
http://www.int64.org

  • application/octet-stream attachment: iocp.c
Received on 2005-11-07

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET