1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
[]
= "aprender-gpu"
= true
= "2021"
= ["Pragmatic AI Labs"]
= "MIT"
= "Pure Rust PTX generation for NVIDIA CUDA - no LLVM, no nvcc"
= "https://github.com/paiml/trueno"
= "README.md"
= ["cuda", "ptx", "gpu", "simd", "nvidia"]
= ["algorithms", "mathematics", "science"]
[]
# NOTE: trueno-gpu does NOT depend on trueno (would create cycle)
# ComputeBrick is available from trueno crate directly
# Users: `use trueno::brick::{ComputeBrick, ComputeBackend};`
= "2.0"
= { = true }
# Dynamic library loading for libcuda.so/nvcuda.dll
# OWN THE STACK: We write our own CUDA FFI in driver/sys.rs (~400 lines)
# Citation: RustBelt [1] proves Rust's type system safely encapsulates unsafe FFI
= { = "0.8", = true }
# WASM support
= { = "0.2", = true }
# Sovereign Stack - visual testing (optional to avoid version conflicts)
# NOTE: trueno-viz (=aprender-viz) removed (APR-MONO self-containment): aprender-viz
# depends on trueno, so gpu→viz→trueno closed a compute→gpu→viz→compute cycle. The `viz`
# feature's unused-in-tree GPU visual-testing (gpu_renderer.rs + wasm.rs, 835 LOC) is
# dropped here; re-home as a top-level visual-test crate above both gpu and viz if needed.
# Simular for deterministic RNG and TUI monitoring (Sovereign Stack)
= { = true, = true }
# NOTE: renacer (=aprender-profile) removed as a normal dep (APR-MONO self-containment):
# aprender-profile depends on trueno, so gpu→renacer→trueno would close a
# compute→gpu→profile→compute cycle. renacer was unused in gpu src; it remains a
# dev-dependency (dev-dep cycles are legal) for stress-test benches only.
# NOTE: presentar-core/-terminal removed (APR-MONO self-containment): the GPU backend
# crate must not depend on the terminal-UI layer (present-core → trueno would close a
# compute→gpu→present-core→compute cycle). No gpu src consumed them — TUI/monitoring
# lives in higher-level tools (apr-cli, cbtop), not the gpu backend.
= { = "0.28", = true }
# WGPU for cross-platform WebGPU compute (Vulkan/Metal/DX12/WebGPU)
= { = "24", = true }
# Apple Metal backend via manzana (macOS only)
[]
= { = "0.2.0", = true }
[]
= "1.9"
= { = true }
= { = "../aprender-simulate", = "aprender-simulate" }
= "0.4"
= { = "1.21", = ["derive"] }
# NOTE: renacer (=aprender-profile) dev-dep removed — unused (0 references) and its
# ^0.50.0 version pin closed a crates.io publish cycle
# (aprender-compute → aprender-gpu → aprender-profile → aprender-core → aprender-compute).
[]
# GPU pixel testing with TUI visualization (Sovereign Stack)
= { = "0.4.0", = true }
[]
= []
# Enable CUDA driver FFI for actual GPU execution (requires NVIDIA driver)
# Uses our own driver/sys.rs FFI layer, not external bindings
= ["dep:libloading"]
# WASM visual testing
= ["dep:wasm-bindgen"]
# Stress testing with randomized inputs (native only)
= ["dep:simular"]
# TUI monitoring mode for stress tests
= ["stress-test", "dep:crossterm"]
# GPU pixel testing with probar TUI visualization
= ["dep:jugar-probar", "dep:crossterm"]
# WGPU backend for cross-platform GPU compute (WebGPU via wgpu crate)
= ["dep:wgpu"]
# Apple Metal backend via manzana (macOS only)
= ["dep:manzana"]
[]
= false
# Inherit workspace lints
[]
= "allow"
[]
= "trueno_gpu"
= "src/lib.rs"
= ["cdylib", "rlib"]
[[]]
= "ptx_gen"
= false
# cuBLAS benchmark: cargo test -p trueno-gpu --features cuda --lib -- cublas_bench --no-capture --release