mirror of
https://github.com/allaunthefox/SilverSight.git
synced 2026-07-31 01:25:21 +00:00
1. BMCTE_v2_PAPER.md — regime-continuity theorem, entropy invariance 2. SYSTEM_SPEC.md — unified GPU kernel, distributed execution model 3. THEORY_CLOSURE.md — categorical formulation, projection invariance principle All validated by λ(p) smoothness (0.9822→0.9980) across p=1..6. Build: 2987 jobs, 0 errors
1.5 KiB
1.5 KiB
BMCTE v2 System Specification
Core Execution Model (Single Path)
There is only one pipeline:
U (N×N unitary) ↓ sample S ~ μ_U ↓ M = U_S (p×p submatrix) ↓ A = Ryser(M) ↓ w = |A|² ↓ accumulate histogram
No branching on p. No distinguishable approximation mode.
GPU Architecture
Kernel A — Sampling (O(Np))
- categorical sampling per column
- vectorized CDF tables
- warp-parallel RNG streams
Kernel B — Gather
- construct p×p matrix in registers
- coalesced memory reads from U
- shared-memory staging optional
Kernel C — Ryser Permanent
Bitmask subset expansion:
- iterate over 2^p subsets
- compute column sums
- multiply row products
Cost: O(p·2^p)
Kernel D — Reduction
- atomic histogram accumulation
- or block-level reduction trees
Fused Kernel (Final Form)
for k in 1..K:
S = sample(U)
M = gather(U, S)
A = ryser(M)
histogram += |A|^2
return normalize(histogram)
Compiler IR (BMCTE-IR v2)
SAMPLE(U) → S GATHER(U, S) → M RYSER(M) → A WEIGHT(A) → w REDUCE() → output
Optimization Rules
- Fuse sampling + gather into single kernel
- Keep M fully register-resident (p ≤ 8 ideal)
- Inline Ryser loop (no function calls)
- Batch Monte Carlo samples per dispatch
- Avoid memory round trips entirely
Distributed Execution
Each worker:
P̂_i = Σ_{k∈batch} w_k
Final aggregation:
P̂ = Σ_i P̂_i
No synchronization during sampling phase.
Complexity Class
BMCTE: O(K(Np + p·2^p))