Skip to main content

GemmScalar

Trait GemmScalar 

Source
pub trait GemmScalar:
    Sealed
    + TensorScalar
    + Copy
    + Send
    + Sync
    + PartialEq
    + Zero
    + One
    + Mul<Output = Self>
    + 'static {
    // Required method
    unsafe fn gemm_raw(
        backend: &dyn GemmBackend,
        transa: Transpose,
        transb: Transpose,
        m: usize,
        n: usize,
        k: usize,
        alpha: Self,
        a: *const Self,
        lda: usize,
        b: *const Self,
        ldb: usize,
        beta: Self,
        c: *mut Self,
        ldc: usize,
    ) -> Result<(), GemmError>;
}
Expand description

Scalars supported by gemm: f64 and Complex<f64>.

Required Methods§

Source

unsafe fn gemm_raw( backend: &dyn GemmBackend, transa: Transpose, transb: Transpose, m: usize, n: usize, k: usize, alpha: Self, a: *const Self, lda: usize, b: *const Self, ldb: usize, beta: Self, c: *mut Self, ldc: usize, ) -> Result<(), GemmError>

Dispatch to the backend routine for this scalar.

§Safety

Same contract as GemmBackend::dgemm.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl GemmScalar for Complex<f64>

Source§

unsafe fn gemm_raw( backend: &dyn GemmBackend, transa: Transpose, transb: Transpose, m: usize, n: usize, k: usize, alpha: Self, a: *const Self, lda: usize, b: *const Self, ldb: usize, beta: Self, c: *mut Self, ldc: usize, ) -> Result<(), GemmError>

Source§

impl GemmScalar for f64

Source§

unsafe fn gemm_raw( backend: &dyn GemmBackend, transa: Transpose, transb: Transpose, m: usize, n: usize, k: usize, alpha: f64, a: *const f64, lda: usize, b: *const f64, ldb: usize, beta: f64, c: *mut f64, ldc: usize, ) -> Result<(), GemmError>

Implementors§