You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Summary
Adds an MLX delegate handler for `aten.roll`, mapping `torch.roll` onto
`mlx::core::roll` via a new `RollNode` in the schema. Replaces the
default decomposition (`index_select + arange + cat`) with a single
native kernel — needed by Swin Transformer's shift-window attention.
Flat roll (`dims=[]`) raises `NotImplementedError` for now; no known
consumer needs it yet.
Generated files (`MLXLoader.*`, `schema_generated.h`,
`mlx_graph_schema.py`, `_generated_serializers.py`,
`_generated_inspector.py`, `_generated/`) are regenerated from
`schema.fbs` by `backends/mlx/CMakeLists.txt` at build time and are
deliberately not committed.
Fixes#18919.
## Test plan
- `python backends/mlx/serialization/generate.py` — regenerates cleanly
with `RollNode` in all expected outputs.
- `lintrunner --skip MYPY --paths-cmd 'git diff --name-only
upstream/main'` — no issues.
- End-to-end `run_all_tests -k roll` not run locally (no executorch
build on this machine); relying on CI. Happy to push fixes if it finds
anything.
cc @metascroy
Co-authored-by: Ishan Godawatta <ishan.godawatta@arm.com>
0 commit comments