Boost logo

Boost Users :

Subject: Re: [Boost-users] [boost.asio] Concurrently Ping 1000+ Hosts
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2013-12-20 00:03:42

On 19 Dec 2013 at 20:05, reminisc3_at_[hidden] wrote:

> Nail, I am very interested in AFIO. I develop mainly for Windows and
> have recently began reading the msdn docs for completion ports, etc.
> There just doesn't seem to be many working examples and the
> documentation is weak. I posted on here a couple weeks ago trying to
> implement multithreaded io in a raid environment. I will be considering
> AFIO for sure.  

Glad you find it interesting, and I hope AFIO's unusual API design
doesn't put you off. I have some real world benchmarks for AFIO at
nc_file_io/so_what.html (bottom of page) where I compare a single
threaded iostreams vs OpenMP iostreams vs AFIO implementation.
Needless to say, AFIO whips everything else performance wise, but it
is definitely at the cost of hideous code complexity with lots of
splitting execution state across callbacks. I also threw RAM at the
problem which AFIO lets you do a bit too easily.

Be aware that AFIO has not yet passed Boost peer review. And it has a
known race condition in it, we currently suspect it's related to the
race condition in Boost.Thread's future/promise implementation.

Regarding Windows IOCP programming in general, I'd recommend you use
one of Microsoft's very good async C++ libraries which were
implemented by one of the highest calibre C++ teams in the world.
Look into Casablanca, C++ AMP and the Microsoft PPL, it might ease
your burden on Windows. Programming WinRT using C++ isn't too
terrible either actually, and it's all IOCP and async throughout.


Currently unemployed and looking for work.
Work Portfolio:

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at