Original GGML ops have no explicit integer assignments. The mainline
ggml/include/ggml.h enum ggml_op enumerates positionally (no explicit
values) and ends in GGML_OP_COUNT. New ops append immediately before
GGML_OP_COUNT.
Per Phase 0.5 constraint C1.3, added ops are listed here so the
intent and ordering are explicit and audit-able. The "slot" column is the
position-index in enum ggml_op after each op is inserted (counting from 0).
Mainline-side reordering will shift slot numbers — the contract is
positional, not numeric.
| Op | First landed | Phase | Purpose |
|---|---|---|---|
GGML_OP_TURBO_WHT |
feature/phase-1-turboquant-kv Step 3 | Phase 1 | TurboQuant Walsh-Hadamard Transform: O(d log d) rotation for KV-cache compression. Replaces dense ggml_mul_mat(128x128, ...). Sourced from TheTom 012faec26 (introducing commit). |
When adding an original GGML_OP_*:
- Append the op to
enum ggml_opimmediately beforeGGML_OP_COUNTinggml/include/ggml.h. - Append a matching entry to
GGML_OP_NAME[]andGGML_OP_SYMBOL[]inggml/src/ggml.c(and bump bothstatic_assert(GGML_OP_COUNT == N, ...)counters). - Wire CPU dispatch in
ggml/src/ggml-cpu/ggml-cpu.cggml_compute_forwardandggml_get_n_tasksandggml_graph_plan. - Add CPU impl in
ggml/src/ggml-cpu/ops.cpp+ declaration inops.h. - Add backend supports_op gates: ROCm (
ggml-cuda.cu), Vulkan (ggml-vulkan.cpp), CPU (auto via dispatch). - Append a row to this table with the first-landed branch/phase and a one-sentence purpose.