diff options
author | Sylvain Munaut <tnt@246tNt.com> | 2016-01-27 12:58:50 +0100 |
---|---|---|
committer | Johnathan Corgan <johnathan@corganlabs.com> | 2016-01-27 10:31:26 -0800 |
commit | 6e482c5bb6bf49f000f6b8d35a1ca84127e38c46 (patch) | |
tree | ee9e4e3323da08dfabe91257229b970a38dff066 /gr-zeromq/include/gnuradio/zeromq/pull_source.h | |
parent | 393624c072417e0b8a74480979eeccdfb8278e77 (diff) |
gr-zeromq: Big rework for performance and correctness
- Use class hierarchy trying to maximize code re-use.
- Dont' drop samples on receive if the output buffer doesn't have
enough space.
- Don't drop tags on receive by putting tags in the future.
- Better metadata creation/parsing avoiding copying lots data.
- Always do as much work as possible in a single call to work()
to avoid scheduler overhead as long as possible.
- Allow setting the high watermark to avoid older version of
zeromq's default of buffering infinite messages and causing a
paging thrash to/from disk when the flow graph can't keep up.
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
Diffstat (limited to 'gr-zeromq/include/gnuradio/zeromq/pull_source.h')
-rw-r--r-- | gr-zeromq/include/gnuradio/zeromq/pull_source.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gr-zeromq/include/gnuradio/zeromq/pull_source.h b/gr-zeromq/include/gnuradio/zeromq/pull_source.h index ca7b40726d..07cf6af128 100644 --- a/gr-zeromq/include/gnuradio/zeromq/pull_source.h +++ b/gr-zeromq/include/gnuradio/zeromq/pull_source.h @@ -50,9 +50,10 @@ namespace gr { * \param address ZMQ socket address specifier. * \param timeout Receive timeout in seconds, default is 100ms, 1us increments. * \param pass_tags Whether source will look for and deserialize tags. + * \param hwm High Watermark to configure the socket to (-1 => zmq's default) */ static sptr make(size_t itemsize, size_t vlen, char *address, - int timeout=100, bool pass_tags=false); + int timeout=100, bool pass_tags=false, int hwm=-1); }; } // namespace zeromq |