cpu loop R85: plain conv2d activations (346→350)#81
Merged
chenxingqiang merged 2 commits intoJun 30, 2026
Conversation
Co-authored-by: Johnson.Chen <joy6677@outlook.com>
Co-authored-by: Johnson.Chen <joy6677@outlook.com>
Reviewer's GuideAdds new plain conv2d+activation CPU kernel graph builders, wires them into the customized op builder/parity inventory, and bumps planned value-verify counts from 346 to 350 across certification and inventory tests and documentation. Sequence diagram for new conv2d_relu CPU parity workflowsequenceDiagram
participant cpu_parity_test
participant CUSTOMIZED_OP_BUILDERS
participant conv2d_relu
participant pytorch_reference
cpu_parity_test->>CUSTOMIZED_OP_BUILDERS: conv2d_relu
CUSTOMIZED_OP_BUILDERS-->>cpu_parity_test: conv2d_relu
cpu_parity_test->>conv2d_relu: conv2d_relu
conv2d_relu-->>cpu_parity_test: [cpu_graph]
cpu_parity_test->>pytorch_reference: conv2d_relu
pytorch_reference-->>cpu_parity_test: [reference_output]
cpu_parity_test-->>cpu_parity_test: [compare_outputs]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
de28a15
into
cursor/cpu-loop-r84-rms-matmul-conv2d-78f5
6 of 13 checks passed
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- The
build_conv2d_reluandbuild_conv2d_relu_batch1builders are currently identical (both use batch size 1); consider either differentiating the batch1 case (e.g., shapes/contract) or deduplicating via a shared helper to avoid confusion. - The new
conv2d_*activation builders share the same graph and reference setup with only the activation differing; you may want to factor out a small helper to reduce repetition and make future activations easier to add.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The `build_conv2d_relu` and `build_conv2d_relu_batch1` builders are currently identical (both use batch size 1); consider either differentiating the batch1 case (e.g., shapes/contract) or deduplicating via a shared helper to avoid confusion.
- The new `conv2d_*` activation builders share the same graph and reference setup with only the activation differing; you may want to factor out a small helper to reduce repetition and make future activations easier to add.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
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
conv2d_relu,conv2d_gelu,conv2d_silu,conv2d_relu_batch1g.conv2d+ unary activation vs PyTorch referenceCUSTOMIZED_OP_BUILDERS+ parity patternsVerification
make test-cpu-value-verify→ 350 passed, 1 skippedStack
Based on
cursor/cpu-loop-r84-rms-matmul-conv2d-78f5(#80)Summary by Sourcery
Add CPU conv2d + activation test builders and update certification inventory counts accordingly.
New Features:
Enhancements:
Tests: