]> git.openfabrics.org - ~shefty/librdmacm.git/commit
rstream: Set rsocket nonblocking if set to async operation
authorSean Hefty <sean.hefty@intel.com>
Wed, 16 May 2012 22:23:41 +0000 (15:23 -0700)
committerSean Hefty <sean.hefty@intel.com>
Wed, 16 May 2012 23:04:46 +0000 (16:04 -0700)
commit8cea41290e9c701beaa780fd2f412060916ca269
tree8f6ed845f1d4f512d6113d3b4ff5776c7e330fc4
parentd541438b83de7721c8ce91fd25c2801d99f5247a
rstream: Set rsocket nonblocking if set to async operation

If asynchronous use is specified (use of poll/select), set the
rsocket to nonblocking.  This matches the common usage case for
asynchronous sockets.

When asynchronous support is enabled, the nonblocking/blocking
test option determines whether the poll/select call will block,
or if rstream will spin on the calls.

This provides more flexibility with how the rsocket is used.
Specifically, MPI often uses nonblocking sockets, but spins on
poll/select.  However, many apps will use nonblocking sockets,
but wait on poll/select.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
examples/rstream.c