ArchX Sovereign v3.0 — Fluent Performance Runtime
Adaptive Intelligence. Sovereign Ergonomics.
ArchX v3.0 is a high-performance, adaptive runtime library designed for systems programming in Rust. It introduces the Sovereign Fluent API, a unified, chainable interface for CPU, GPU, and Hybrid compute.
🚀 Quick Start
Add ArchX to your Cargo.toml:
[]
= "3.0"
Basic Vector Addition
use ;
🛠️ Core API & Execution Modes
ArchX supports multiple execution modes through a single entry point:
- CPU/SIMD: Parallel execution using host threads and SIMD instructions (AVX2, AVX-512).
- GPU (Adaptive): Offloads heavy computation to GPU backends (Vulkan/CUDA).
- Hybrid: Cooperative scheduling that splits workloads between CPU and GPU.
- Async: Non-blocking background execution.
GPU Configuration
use ;
archx
.with_gpu // Force GPU execution
.sum?;
📊 Hybrid Execution & Profiling
ArchX intelligently splits workloads based on hardware state and workload size.
Collecting Metrics
use ;
let metrics = archx
.profile
.with_policy
.run;
// Use the built-in profiler visualization
get_profiler.print_summary;
🧮 Mathematical Operations
The Fluent API provides high-level math primitives:
| Method | Operation | Description |
|---|---|---|
add |
out = a + b |
Vectorized element-wise addition |
sub |
out = a - b |
Vectorized element-wise subtraction |
mul |
out = a * b |
Vectorized element-wise multiplication |
dot |
sum(a * b) |
Scalar dot product |
sum |
sum(a) |
Parallel reduction sum |
Safety Modes
use ;
archx
.with_mode // Enable overflow checking
.mul?;
⚡ Advanced Usage
Asynchronous Operations
Avoid blocking the main thread for massive datasets:
use ;
async
⚠️ Error Handling
All ArchX operations return ArchXResult<T>. Handle errors gracefully:
use ArchXError;
match archx.add
🧪 Verification
Run flagship demo:
Designed with ❤️ by AkramStation. MIT / Apache-2.0 © 2026 AkramStation