rtsc

Crates.iortsc
lib.rsrtsc
version0.2.3
sourcesrc
created_at2024-06-15 17:18:05.359997
updated_at2024-07-15 22:51:43.761024
descriptionReal-time Synchronization Components
homepage
repositoryhttps://github.com/roboplc/rtsc
max_upload_size
id1272999
size116,860
Sergiy S. (divi255)

documentation

README

RTSC - Real-time Synchronization Components crates.io page docs.rs page

Requirements for data synchronization in real-time applications differ from traditional high-load ones. The main difference is that real-time synchronization components must carefully respect and follow the traditional operating-system approach, avoid user-space spin-loops and other busy-waiting techniques (see Channels in Rust. Part 2 where such problems are clearly described).

Components

This crate provides a pack of real-time-safe synchronization components for various typical and custom use-cases.

  • Data Buffer
  • Synchronization cells
  • Sync/async channels
  • Policy-based channels
  • Semaphore
  • Time tools

Locking

On Linux the crate uses built-in priority-inheritance [pi::Mutex] implementation and re-exports this module as locking.

On other platforms, all components use Mutex/Condvar synchronization primitives from parking_lot_rt - a real-time fork of the well-known parking_lot crate. This is a relatively safe Mutex/RwLock with minimal user-space spin-waiting. The module is re-exported as locking as well.

References

RTSC is a part of RoboPLC project.

Commit count: 48

cargo fmt