Cargo Features
gix-features has no features set by default.
[dependencies]
gix-features = { version = "0.45.2", features = ["progress", "progress-unit-human-numbers", "progress-unit-bytes", "fs-read-dir", "tracing", "tracing-detail", "parallel", "once_cell", "walkdir", "io-pipe", "crc32", "zlib", "cache-efficiency-debug", "document-features"] }
- progress = prodash
-
Provide traits and utilities for providing progress information. These can then be rendered using facilities of the
prodashcrate.Affects
gix-features::progress… - progress-unit-human-numbers
-
Provide human-readable numbers as well as easier to read byte units for progress bars.
Enables unit-human of optional prodash ^30.0.1
progress
Affects
progress::count_with_decimals… - progress-unit-bytes
-
Provide human readable byte units for progress bars.
Enables bytesize, unit-bytes of optional prodash ^30.0.1
Affects
progress::bytes… - fs-read-dir
-
Provide utilities suitable for working with the
std::fs::read_dir().Enables gix-utils
- tracing
-
Implement
tracingwithtracing-core, which provides applications with valuable performance details if they opt-in to it.Note that this may have overhead as well, thus instrumentations should be used stategically, only providing coarse tracing by default and adding details only where needed while marking them with the appropriate level.
- tracing-detail
-
If enabled, detailed tracing is also emitted, which can greatly increase insights but at a cost.
Enables tracing-detail of gix-trace
- parallel
-
Use scoped threads and channels to parallelize common workloads on multiple objects. If enabled, it is used everywhere where it makes sense. As caches are likely to be used and instantiated per thread, more memory will be used on top of the costs for threads. The
threadingmodule will contain thread-safe primitives for shared ownership and mutation, otherwise these will be their single threaded counterparts. This way, single-threaded applications don't have to pay for threaded primitives.Enables crossbeam-channel and parking_lot
crossbeam-channel:
'parallel' feature
Affects
parallel::optimize_chunk_size_and_thread_limit,parallel::num_threads,parallel::in_parallel_if… - once_cell
-
If enabled, OnceCell will be made available for interior mutability either in sync or unsync forms.
Note: This still uses once_cell because std::sync::OnceLock::get_or_try_init() is not yet stable.Enables once_cell
Note: once_cell is kept for OnceCell type because std::sync::OnceLock::get_or_try_init() is not yet stable.
Once it's stabilized (tracking issue #109737), we can remove this dependency. - walkdir
-
Makes facilities of the
walkdircrate partially available. In conjunction with the parallel feature, directory walking will be parallel instead behind a compatible interface.Enables walkdir
used when parallel is off
gix-path:
for walkdir
Affects
fs::walkdir… - io-pipe
-
- an in-memory unidirectional pipe using
bytesas efficient transfer mechanism.
Enables bytes
pipe
Affects
io::pipe,gix-features::io… - an in-memory unidirectional pipe using
- crc32
-
provide a proven and fast
crc32implementation.Enables crc32fast
hashing
Affects
hash::crc32_update,hash::crc32… - zlib
-
Enable the usage of zlib-related utilities to compress or decompress data. This enables and uses the high-performance
zlib-rsbackend.zlib-rs:
zlib module
Affects
gix-features::zlib… - cache-efficiency-debug
-
Other
Count cache hits and misses and print that debug information on drop. Caches implement this by default, which costs nothing unless this feature is enabled
Features from optional dependencies
In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.
- prodash progress?
-
Enables prodash ^30.0.1
- document-features implicit feature
-
Enables document-features
document-features:
Extract documentation for the feature flags from comments in Cargo.toml