libzmq
src
config.hpp
Go to the documentation of this file.
1
/* SPDX-License-Identifier: MPL-2.0 */
2
3
#ifndef __ZMQ_CONFIG_HPP_INCLUDED__
4
#define __ZMQ_CONFIG_HPP_INCLUDED__
5
6
namespace
zmq
7
{
8
// Compile-time settings.
9
10
enum
11
{
12
// Number of new messages in message pipe needed to trigger new memory
13
// allocation. Setting this parameter to 256 decreases the impact of
14
// memory allocation by approximately 99.6%
15
message_pipe_granularity
= 256,
16
17
// Commands in pipe per allocation event.
18
command_pipe_granularity
= 16,
19
20
// Determines how often does socket poll for new commands when it
21
// still has unprocessed messages to handle. Thus, if it is set to 100,
22
// socket will process 100 inbound messages before doing the poll.
23
// If there are no unprocessed messages available, poll is done
24
// immediately. Decreasing the value trades overall latency for more
25
// real-time behaviour (less latency peaks).
26
inbound_poll_rate
= 100,
27
28
// Maximal delta between high and low watermark.
29
max_wm_delta
= 1024,
30
31
// Maximum number of events the I/O thread can process in one go.
32
max_io_events
= 256,
33
34
// Maximal batch size of packets forwarded by a ZMQ proxy.
35
// Increasing this value improves throughput at the expense of
36
// latency and fairness.
37
proxy_burst_size
= 1000,
38
39
// Maximal delay to process command in API thread (in CPU ticks).
40
// 3,000,000 ticks equals to 1 - 2 milliseconds on current CPUs.
41
// Note that delay is only applied when there is continuous stream of
42
// messages to process. If not so, commands are processed immediately.
43
max_command_delay
= 3000000,
44
45
// Low-precision clock precision in CPU ticks. 1ms. Value of 1000000
46
// should be OK for CPU frequencies above 1GHz. If should work
47
// reasonably well for CPU frequencies above 500MHz. For lower CPU
48
// frequencies you may consider lowering this value to get best
49
// possible latencies.
50
clock_precision
= 1000000,
51
52
// On some OSes the signaler has to be emulated using a TCP
53
// connection. In such cases following port is used.
54
// If 0, it lets the OS choose a free port without requiring use of a
55
// global mutex. The original implementation of a Windows signaler
56
// socket used port 5905 instead of letting the OS choose a free port.
57
// https://github.com/zeromq/libzmq/issues/1542
58
signaler_port
= 0
59
};
60
}
61
62
#endif
zmq::clock_precision
@ clock_precision
Definition:
config.hpp:50
zmq::max_wm_delta
@ max_wm_delta
Definition:
config.hpp:29
zmq::message_pipe_granularity
@ message_pipe_granularity
Definition:
config.hpp:15
zmq
Definition:
zmq.hpp:229
zmq::command_pipe_granularity
@ command_pipe_granularity
Definition:
config.hpp:18
zmq::inbound_poll_rate
@ inbound_poll_rate
Definition:
config.hpp:26
zmq::proxy_burst_size
@ proxy_burst_size
Definition:
config.hpp:37
zmq::max_command_delay
@ max_command_delay
Definition:
config.hpp:43
zmq::signaler_port
@ signaler_port
Definition:
config.hpp:58
zmq::max_io_events
@ max_io_events
Definition:
config.hpp:32
libaditof
Author(s):
autogenerated on Wed May 21 2025 02:06:48