pub enum Accelerator {
Cuda,
Rocm,
Vulkan,
Metal,
Cpu,
}Expand description
A hardware accelerator that can be used to compute any target metrics.
Variants§
Cuda
Available on crate feature
cuda only.Run kernels using the Nvidia CUDA backend.
Nvidia GPUs only (duh.)
Rocm
Available on crate feature
rocm only.Run kernels using the AMD ROCm backend.
AMD GPUs only (duh.)
Vulkan
Available on crate feature
vulkan only.Run kernels using the WGPU Vulkan backend.
This is the most lightweight and portable accelerator because it supports all platforms and GPUs that support basic compute shaders.
Metal
Available on crate feature
metal only.Run kernels using the WGPU Metal backend.
This is the only accelerator available for Apple Silicon.
Cpu
Available on crate feature
cpu only.Run kernels using the CPU JIT compiler.
Trait Implementations§
Source§impl Clone for Accelerator
impl Clone for Accelerator
Source§fn clone(&self) -> Accelerator
fn clone(&self) -> Accelerator
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for Accelerator
Source§impl Debug for Accelerator
impl Debug for Accelerator
Source§impl Display for Accelerator
impl Display for Accelerator
impl Eq for Accelerator
Source§impl<'_derivative_strum> From<&'_derivative_strum Accelerator> for &'static str
impl<'_derivative_strum> From<&'_derivative_strum Accelerator> for &'static str
Source§fn from(x: &'_derivative_strum Accelerator) -> &'static str
fn from(x: &'_derivative_strum Accelerator) -> &'static str
Converts to this type from the input type.
Source§impl From<Accelerator> for &'static str
impl From<Accelerator> for &'static str
Source§fn from(x: Accelerator) -> &'static str
fn from(x: Accelerator) -> &'static str
Converts to this type from the input type.
Source§impl FromStr for Accelerator
impl FromStr for Accelerator
Source§impl IntoEnumIterator for Accelerator
impl IntoEnumIterator for Accelerator
type Iterator = AcceleratorIter
fn iter() -> AcceleratorIter ⓘ
Source§impl PartialEq for Accelerator
impl PartialEq for Accelerator
impl StructuralPartialEq for Accelerator
Auto Trait Implementations§
impl Freeze for Accelerator
impl RefUnwindSafe for Accelerator
impl Send for Accelerator
impl Sync for Accelerator
impl Unpin for Accelerator
impl UnsafeUnpin for Accelerator
impl UnwindSafe for Accelerator
Blanket Implementations§
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<C> CloneExpand for Cwhere
C: Clone,
impl<C> CloneExpand for Cwhere
C: Clone,
fn __expand_clone_method(&self, _scope: &mut Scope) -> C
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.