Skip to content

Commit 74b9065

Browse files
committed
fix: prevent frontend load errors from leaking in triton-to-cute bridge and add optimizer benchmark baselines
1 parent 0bc8460 commit 74b9065

61 files changed

Lines changed: 18810 additions & 446 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

AGENTS.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# AGENTS.md — cppmega.mlx agent contract
2+
3+
## Tensor memory rule
4+
5+
- Wrappers/adapters must not silently allocate or copy large tensors.
6+
- If a design appears to require staging a large tensor, casting a large tensor,
7+
or copying a large tensor only to satisfy a wrapper boundary, treat that
8+
design as wrong and keep looking.
9+
- Prefer passing references to existing GPU buffers, fusion, views/broadcasts,
10+
or IR-level lowering through the TileLang/TVM/tvm-ffi pipeline.
11+
- If zero-copy/fused lowering is not currently possible, fail explicitly or
12+
fall back to the existing production path without pretending Path C handled it.
13+
- Dtype/shape mismatches must be solved at the right level:
14+
- first look higher in the graph and make the producer create the tensor in
15+
the required dtype/shape from the start;
16+
- if the current dtype/layout is the right system-level format (for example
17+
FP8 for the active config), move lower and teach the kernel to consume that
18+
format directly;
19+
- only use casts/reshapes as explicit graph decisions, not hidden adapter
20+
staging.

0 commit comments

Comments
 (0)