Expand description
This crate provides some useful utilities.
- The
hints moduleprovides hints to the compiler that affects how code should be emitted or optimized. - The
backoff moduleprovides theBackoffstructure. - The
cache_padded moduleprovides cache-padded atomics types and the [CachePadded] wrapper. - The
light_arc moduleprovides theLightArctype. - The
OrengineInstantthat is a monotone clock that weights 8 bytes on Unix-like systems. - The
ArrayQueuethat is an array-based queue implementation. - The
VecQueuethat is a vector-based queue implementation. - The
numa moduleprovides sufficient utilities for working with NUMA nodes. - The
treap moduleprovides theTreap— a randomized BST with subtree-augmented filtering for efficient filtered min/max queries. - The
cheap_random moduleprovides fast non-cryptographic xorshift PRNGs foru32andu64, both stateful and thread-local. - Configuration macros that are used to right compile the program based on the target platform
such as
config_target_pointer_width_64,config_target_pointer_width_32, andconfig_target_pointer_width_16.
Modules§
- backoff
- This module provides a
Backoffthat can be used to busy-wait with preemptive yield when it is necessary. - cache_
padded - Provides cache-padded atomic types.
- cheap_
random - Fast non-cryptographic pseudo-random number generators.
- hints
- Hints to the compiler that affects how code should be emitted or optimized.
- light_
arc - This module provides
LightArc. - numa
- Provides utilities for working with NUMA (Non-Uniform Memory Access) nodes.
- rw_
serde - treap
- A randomized binary search tree with subtree-augmented filtering.
- varint
- Variable-length integer (varint) encoding and decoding.
Macros§
- config_
target_ pointer_ width_ 16 - Generates code only compiled when the target pointer width is 16 bits.
- config_
target_ pointer_ width_ 32 - Generates code only compiled when the target pointer width is 32 bits.
- config_
target_ pointer_ width_ 64 - Generates code only compiled when the target pointer width is 64 bits.
Structs§
- Array
Buffer ArrayBufferis a fixed-sized array-based buffer.- Array
Queue ArrayQueueis a queue, but it uses an array on a stack and can’t be resized.- Orengine
Instant - A monotone clock. It can be converted to/from
std::time::Instant. - Small
String - A UTF-8 string with configurable inline storage.
- VecQueue
- A queue that uses a vector to store the elements.
Functions§
- clear_
with - This function is like
drainfor the wholeVec, but faster.