Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TorchToLinalg] Use linalg.broadcast instead of generic for conv bias #3661

Merged
merged 1 commit into from
Aug 26, 2024

Conversation

ubfx
Copy link
Member

@ubfx ubfx commented Aug 22, 2024

The current implementation uses a linalg.generic to broadcast the bias tensor for the lowering of convolutions. This is suboptimal for later pattern matching. This patch changes it to use the respective named op, linalg.broadcast, instead.

The current implementation uses a `linalg.generic` to broadcast the bias
tensor for the lowering of convolutions. This is suboptimal for later
pattern matching. This patch changes it to use the respective named op,
`linalg.broadcast`, instead.
@ubfx ubfx requested review from rsuderman and silvasean August 22, 2024 19:27
@ubfx ubfx changed the title [TorchToLinalg] Use linalg.broadcast for conv bias [TorchToLinalg] Use linalg.broadcast instead of generic for conv bias Aug 23, 2024
@ubfx ubfx requested a review from zjgarvey August 26, 2024 17:55
Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice. LGTM.

@ubfx ubfx merged commit 638ef14 into llvm:main Aug 26, 2024
3 checks passed
@ubfx ubfx deleted the broadcast-bias-tensor branch August 26, 2024 18:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants