cubecl_common/
lib.rs

1#![cfg_attr(not(feature = "std"), no_std)]
2#![warn(missing_docs)]
3
4//! # CubeCL Common Library
5//!
6//! This library contains common types used by other crates that must be shared.
7
8#[macro_use]
9extern crate derive_new;
10
11/// Rand module contains types for random number generation for non-std environments and for
12/// std environments.
13pub mod rand;
14
15/// Backtrace module to build error reports.
16pub mod backtrace;
17
18/// Device module.
19pub mod device;
20
21/// Map utilities and implementations.
22pub mod map;
23
24/// Utilities module to manipulate bytes.
25#[cfg(feature = "serde")]
26pub mod bytes;
27
28/// Stub module contains types for stubs for non-std environments and for std environments.
29pub mod stub;
30
31/// Stream id related utilities.
32pub mod stream_id;
33
34/// Cache module for an efficient in-memory and persistent database.
35#[cfg(feature = "cache")]
36pub mod cache;
37
38#[cfg(feature = "cache")]
39pub(crate) mod cache_file;
40
41/// Module for benchmark timings
42pub mod benchmark;
43
44/// Module for profiling any executable part
45pub mod profile;
46
47/// Useful when you need to read async data without having to decorate each function with async
48/// notation.
49pub mod reader;
50
51/// Future utils with a compatible API for native, non-std and wasm environments.
52pub mod future;
53
54/// Quantization primitives required outside of `cubecl-quant`
55pub mod quant;
56
57/// Format utilities.
58pub mod format;
59
60/// Various utilities to create ID's.
61extern crate alloc;
62
63/// Custom float implementations
64mod float;
65/// Common kernel types
66mod kernel;
67
68pub use float::*;
69pub use kernel::*;