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
Commit f8373ec
Browse filesBrowse the repository at this point in the historyBrowse files
Summary:
## Ulterior Motive
Run Whisper's log-mel front end on ggml, where `ReplaceGlobalMaxPass`
rewrites the global `max()` as `amax`.
## Rationale
**What**: Lower `aten.amax.default` over trailing dims on ggml.
**Why**: ggml has no max reduction, and the graph builder rejected
`amax`.
## Details
- ggml's `amax` reuses the `trailing_rows` helper shared with `mean` and
`sum`, and gathers each row's `ggml_argmax` element with
`ggml_get_rows`.
- Unlike `ggml_pool_1d` max, which starts from `-FLT_MAX`, this keeps an
all `-inf` row at `-inf`. NaN does not propagate, as in ggml's argmax.
- A non-trailing dim is rejected by name.
Authored with AI using Claude Code.
Reviewed By: SS-JIA
Differential Revision: D129976771
0 commit comments