lewissbaker / disruptorplus Goto Github PK
View Code? Open in Web Editor NEWA disruptor thread-synchronisation data structure for C++11.
License: MIT License
A disruptor thread-synchronisation data structure for C++11.
License: MIT License
The constructor of class disruptorplus::spin_wait
has the call to std::thread::hardware_concurrency()
. It affects latency of all
disruptorplus::spin_wait_strategy::wait_until_published()
methods:
disruptorplus/include/disruptorplus/spin_wait.hpp
Lines 40 to 50 in 748e354
disruptorplus/include/disruptorplus/spin_wait_strategy.hpp
Lines 51 to 65 in 748e354
disruptorplus/include/disruptorplus/spin_wait_strategy.hpp
Lines 142 to 163 in 748e354
Also, there are some redundant code which trying to hide negative impact of this defect:
disruptorplus/include/disruptorplus/sequence_barrier_group.hpp
Lines 164 to 170 in 748e354
disruptorplus/include/disruptorplus/sequence_barrier_group.hpp
Lines 204 to 210 in 748e354
Possible fix is to save the result of std::thread::hardware_concurrency()
in some static variable and reuse it in spin_wait
ctor.
disruptorplus/sequence_barrier_group.hpp:202:67: error: ‘count’ was not declared in this scope
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.