aboutsummaryrefslogtreecommitdiff
path: root/src/tools
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2024-12-19 13:05:23 -0800
committerGarrett D'Amore <garrett@damore.org>2024-12-19 13:05:23 -0800
commit60f63557d87528497fe1392fa6a676b2a51efb16 (patch)
tree36efdb0fa027594b2e293c21f1a8115cd359eb0f /src/tools
parent5e18eb4f18af570abf84a615db5235e2e9415c75 (diff)
downloadnng-60f63557d87528497fe1392fa6a676b2a51efb16.tar.gz
nng-60f63557d87528497fe1392fa6a676b2a51efb16.tar.bz2
nng-60f63557d87528497fe1392fa6a676b2a51efb16.zip
poll: performance improvements, simplifications
We preallocate the arrays used for pollfds, based on what the system can tolerate (tunable with NNG_MAX_OPEN), and we change the code for inserting and removing pollfds from the list so that it can run without acquiring the locks during the main loop, only when adding or removing files. The poll() implementation is very nearly lock free in the hot code path, and soon will be.
Diffstat (limited to 'src/tools')
0 files changed, 0 insertions, 0 deletions