Expand description
CPU Backend for RingKernel
This crate provides a CPU-based implementation of the RingKernel runtime, primarily used for testing and as a fallback when no GPU is available.
ยงFeatures
- Full implementation of the RingKernelRuntime trait
- Simulates GPU execution using async tasks
- Supports all kernel lifecycle operations
- Useful for unit testing and development
ยงExample
โ
use ringkernel_cpu::CpuRuntime;
use ringkernel_core::runtime::{RuntimeBuilder, Backend};
#[tokio::main]
async fn main() {
let runtime = CpuRuntime::new().await.unwrap();
let kernel = runtime.launch("my_kernel", Default::default()).await.unwrap();
kernel.activate().await.unwrap();
}Modulesยง
- kernel ๐
- CPU kernel implementation.
- memory ๐
- CPU memory buffer implementation.
- prelude
- Prelude for convenient imports.
- runtime ๐
- CPU runtime implementation.
Structsยง
- CpuBuffer
- CPU-based buffer that simulates GPU memory.
- CpuKernel
- CPU-based kernel implementation.
- CpuRuntime
- CPU-based implementation of RingKernelRuntime.