Skip to main content

Module kernels

Module kernels 

Source
Expand description

Built-in SoftGPU Functional IR kernels (Rust builders + JSON twins).

Functions§

atomic_inc_reduce
SoftGPU Phase 7: each lane atomic_add(counter, 1); write previous value to out[i].
cross_workgroup_store_zero
SoftGPU Phase 8 (negative): every workgroup stores to the same global cell.
group_exchange
SoftGPU Phase 7: group[lid]=lid; barrier; out[gid]=group[(lid+1)%wg].
group_exchange_missing_barrier
SoftGPU Phase 8 (negative): group exchange without barrier (MissingBarrier).
infinite_loop_watchdog
SoftGPU Phase 7: busy loop until step budget trips (watchdog).
kernarg_one_ptr
kernarg_two_ptrs
Pack two u64 pointers into a 16-byte kernarg.
oob_store_past_end
SoftGPU Phase 8 (negative): store at base + (n * 4) — one past last element.
predicated_inc
SoftGPU Phase 7: even lanes add 1 to buf[i]; odd lanes leave value unchanged.
race_all_store_global_zero
SoftGPU Phase 8 (negative): every workitem stores to global offset 0 (race).
sanitize_clean_index
SoftGPU Phase 8 (positive): private per-lane global store (no race).
tiny_add
b[i] = a[i] + 1 for i = global_id_x. Pointers in kernarg at 0 and 8.
tiny_copy
b[i] = a[i] copy.
tiny_index
out[i] = global_id_x (index write).
uninit_group_read
SoftGPU Phase 8 (negative): read group memory before any store (uninit).
wave_lane_ids
SoftGPU Phase 7: write (wave_id * 16) + lane_id to out[global_id].