Expand description
Dispatch table — calibration-aware kernel selection (plan #2).
Two layers:
- Defaults from
kernel_config(compile-time, per-arch). - Overrides filled at runtime by autotune / calibration when a measured number disagrees with the default.
Borrowed from MAX’s dispatch_table_a100_gpu.mojo /
dispatch_table_amd.mojo pattern: kernel-variant selection is a
data lookup, not scattered match arms in dispatch sites.
Today the table is consulted by the cost model and (when an
override is set) used to override a kernel_config default.
Future work wires fusion patterns through the same table so
schedule decisions are uniformly data-driven.
Enums§
- Override
- One-line override for a default
KernelConfigfield. Add cases as autotune learns more.
Functions§
- resolve
- Resolve a
KernelConfigfor(arch, op), applying any overrides on top of the const-time defaults. - resolve_
current - Convenience: resolve for the running target.
- set_
override - Set an override for
(arch, op). Idempotent — re-set replaces.