fix(hip): unify broadcast and reduction shape contracts - #641
Draft
fhanuman wants to merge 1 commit into
Draft
Conversation
|
Thanks for opening a PR! This project follows LLVM's incremental-development and AI-tool-use Before requesting review, please check that:
Reviewers are assigned through |
L2 Accuracy Results (EP vs CPU)
Threshold: 0.01 | Run: 3952 - Commit: |
MorphiZen EP Performance Results
EPContext Export Performance
EPContext Import Performance
OGA Benchmark Results
OGA Wheel Smoke (Python benchmark_e2e.py)
Run: 3952 - Commit: |
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 5, 2026 21:56
8f61689 to
0fb9bd6
Compare
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 6, 2026 21:00
0fb9bd6 to
c09cd39
Compare
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 7, 2026 19:51
c09cd39 to
ce462bb
Compare
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 7, 2026 20:25
ce462bb to
f57da78
Compare
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 10, 2026 21:59
f57da78 to
b71eb35
Compare
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
2 times, most recently
from
August 10, 2026 23:33
b3a8260 to
6146cf0
Compare
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 11, 2026 00:42
6146cf0 to
ba534eb
Compare
Share NumPy broadcast and reduction dimension rules across converter destinations, dialect reification, and generated verification while rejecting unsupported runtime and non-contiguous reduction axes before lowering. Co-Authored-By: GPT-5.6 Sol <noreply@openai.com> Made-with: Cursor
fhanuman
force-pushed
the
pr/shape-stack-03-broadcast-reduction
branch
from
August 11, 2026 16:25
ba534eb to
354c3f0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Unify NumPy broadcast and ONNX reduction result-shape rules across converter destination construction, HIP reification, and static verification.
select(lhs == 1, rhs, lhs)rather than integer maximum;keepdims, andnoop_with_empty_axeshandling across all six reducers, including ReduceL2;keepdims = 0preserves the correct surviving dimensions;Stack
This is PR 5 of 12 and depends on PR 4:
AI assistance
AI tools assisted with the shape-rule consolidation and stack reconstruction. The broadcast and reduction layer was checked with the authoritative local build and focused rank-zero, keepdims, noop, converter, reification, and verifier tests.
Made with Cursor