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
{{ message }}
Repository navigation
[BUG] Crash on ellipsis indexing with too many trailing indices #4398
Indexing an array with an ellipsis followed by more non-None indices than the array has dimensions crashes instead of raising a ValueError. mlx_expand_ellipsis in python/src/indexing.cpp computes the ellipsis-expansion loop bound as shape.size() - non_none_indices_after, where shape.size() is unsigned. When non_none_indices_after > shape.size(), this underflows, producing a huge loop bound and an out-of-bounds read / crash.
Activity