Mojo function
tiled_matmul_run
tiled_matmul_run[config: KernelConfig[config.packed_shape], transpose_b: Bool, b_packed: Bool, simd_size: Int, elementwise_epilogue_enabled: Bool, kernel_id: InnerKernelID, algorithm: InnerMatmulKernel](alg: algorithm, c: NDBuffer[c.dtype, c.origin, c.shape, DimList.create_unknown[2]()], a: NDBuffer[a.dtype, a.origin, a.shape, DimList.create_unknown[2]()], b: NDBuffer[b.dtype, b.origin, b.shape, DimList.create_unknown[2]()], elementwise_epilogue_fn: def(GemmShape, GemmShape) escaping -> None, global_tile_shape: GemmShape, global_tile_offset: GemmShape)
Interface function to run tiled matmul on a given sub-tile.
Args:
- alg (
algorithm): InnerMatmulKernel algorithm for microkernel. - c (
NDBuffer): Pre-allocated buffer space for result. - a (
NDBuffer): Operand A of the matmul. - b (
NDBuffer): Operand B of the mamtul. - elementwise_epilogue_fn ([
def(GemmShape, GemmShape) escaping -> None](/mojo/kernels/linalg/matmul/cpu/impl/def(GemmShape, GemmShape) escaping -> None)): The elementwise epilogue function. - global_tile_shape (
GemmShape): Tile shape this call will process. - global_tile_offset (
GemmShape): Tile offset on the original buffer.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!