pub struct BackendConfig {
pub cuda_device: i32,
pub cuda_unified_memory: bool,
pub memory_limit_bytes: u64,
pub memory_pooling: bool,
pub pool_initial_bytes: u64,
pub pool_growth_factor: f32,
pub async_memory: bool,
pub kernel_fusion: bool,
pub max_batch_size: usize,
}Expand description
Backend-specific configuration
Fields§
§cuda_device: i32CUDA device index (for cuda backend)
cuda_unified_memory: boolEnable CUDA unified memory
memory_limit_bytes: u64GPU memory limit in bytes (0 = unlimited)
memory_pooling: boolEnable memory pooling
pool_initial_bytes: u64Memory pool initial size in bytes
pool_growth_factor: f32Memory pool growth factor
async_memory: boolEnable async memory operations
kernel_fusion: boolEnable kernel fusion optimizations
max_batch_size: usizeMaximum batch size for batched execution
Implementations§
Source§impl BackendConfig
impl BackendConfig
Sourcepub fn production() -> Self
pub fn production() -> Self
Production backend configuration
Sourcepub fn high_performance() -> Self
pub fn high_performance() -> Self
High-performance backend configuration
Trait Implementations§
Source§impl Clone for BackendConfig
impl Clone for BackendConfig
Source§fn clone(&self) -> BackendConfig
fn clone(&self) -> BackendConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BackendConfig
impl Debug for BackendConfig
Source§impl Default for BackendConfig
impl Default for BackendConfig
Source§impl<'de> Deserialize<'de> for BackendConfig
impl<'de> Deserialize<'de> for BackendConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for BackendConfig
impl RefUnwindSafe for BackendConfig
impl Send for BackendConfig
impl Sync for BackendConfig
impl Unpin for BackendConfig
impl UnwindSafe for BackendConfig
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.