jnk0le / Ring Buffer
Licence: cc0-1.0
simple C++11 ring buffer implementation, allocated and evaluated at compile time
Stars: ✭ 80
Projects that are alternatives of or similar to Ring Buffer
Confluo
Real-time Monitoring and Analysis of Data Streams
Stars: ✭ 1,428 (+1685%)
Mutual labels: lock-free, atomic
Onering
A collection of concurrent ring buffers
Stars: ✭ 114 (+42.5%)
Mutual labels: lock-free, atomic
Xorstr
heavily vectorized c++17 compile time string encryption.
Stars: ✭ 435 (+443.75%)
Mutual labels: compile-time, template
Orm Lite
Header-Only, Strong-Typed, Compile-time Object Relation Mapping (ORM) in Modern C++ :-)
Stars: ✭ 164 (+105%)
Mutual labels: compile-time, template
Swiftcoroutine
Swift coroutines for iOS, macOS and Linux.
Stars: ✭ 690 (+762.5%)
Mutual labels: lock-free, atomic
Template.js
A javascript template engine, simple, easy & extras, support webpack, rollup, parcel, browserify, fis and gulp
Stars: ✭ 1,201 (+1401.25%)
Mutual labels: template
Vue Demo
Vue.js 示例项目 · 简易留言板。本项目拥有完善的文档说明与注释,让您快速上手 Vue.js 开发 SPA。Webpack / ES6 + Babel / Vue Router / (Vue Resource?) / (Vue Validator?) / (Vuex?) —— An Excellent Vue Starter with Best Practice / 最佳实践
Stars: ✭ 1,225 (+1431.25%)
Mutual labels: template
Pytorch Project Template
Deep Learning project template for PyTorch (Distributed Learning is supported)
Stars: ✭ 76 (-5%)
Mutual labels: template
Sming
Sming - Open Source framework for high efficiency native ESP8266 development
Stars: ✭ 1,197 (+1396.25%)
Mutual labels: embedded
Deveeldb
DeveelDB is a complete SQL database system, primarly developed for .NET/Mono frameworks
Stars: ✭ 80 (+0%)
Mutual labels: embedded
Devextreme Angular Template
Responsive Application Layout Templates based on DevExtreme Angular Components
Stars: ✭ 80 (+0%)
Mutual labels: template
Expo Three Demo
🍎👩🏫 Collection of Demos for THREE.js in Expo!
Stars: ✭ 76 (-5%)
Mutual labels: template
Wasm Template Rust
A wasm template for Rust to publish to gh-pages without npm-deploy
Stars: ✭ 76 (-5%)
Mutual labels: template
Ring Buffer
- pure C++11, no OS dependency
- no exceptions, RTTI, virtual functions and dynamic memory allocation
- designed for compile time (static) allocation and type evaluation
- no wasted slots (in powers of 2 granularity)
- lock and wait free SPSC operation
- underrun and overrun checks in insert/remove functions
- highly efficient on most microcontroller architectures (nearly equal performance as in 'wasted-slot' implemetation)
notes
- index_t of size less than architecture reg size (size_t) might not be most efficient (known gcc bug)
- Only lamda expressions or functor callbacks can be inlined into
buffWrite
/buffRead
functions - 8 bit architectures are not supported in master branch at the moment. Broken code is likely to be generated
- relaxed atomic stores on RISC-V gcc port may be inefficient
- the DEC Alpha ultra-weak memory model is not supported
example
Ringbuffer<const char*, 256> message;
int main()
{
//...
while(1)
{
const char* tmp = nullptr;
while(!message.remove(tmp));
printf("%s fired\n", tmp);
//...
}
}
extern "C" void SysTick_Handler(void)
{
message.insert("SysTick_Handler");
}
// if multiple contexts are writing/reading buffer they shall not be interrupting each other
// in this case, those interrupts have to be of the same priority (nesting not allowed)
extern "C" void USART2_IRQHandler(void)
{
message.insert("USART2_IRQHandler");
//...
}
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].