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

[Tcp] Handle int inputs in sqrt #2467

Merged
merged 1 commit into from
Sep 16, 2023
Merged

[Tcp] Handle int inputs in sqrt #2467

merged 1 commit into from
Sep 16, 2023

Conversation

navahgar
Copy link
Collaborator

This PR adds support for integer inputs in tcp.sqrt.

SameOperandsAndResultShape,
SameOperandsAndResultElementType])> {
SameOperandsAndResultShape])> {
Copy link
Member

Choose a reason for hiding this comment

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

Since all elementwise ops except tcp.sqrt adhere to the SameOperandsAndResultElementType trait, is it better to leave this as-is, and let Tcp_SqrtOp just be a Tcp_Op that uses a relaxed set of traits?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It is still useful to be able to identify all the unary elementwise ops using the common base class type.

If there are more such ops in future, we could add another base type that can be common to all of them.

Copy link
Member

@sjain-stanford sjain-stanford left a comment

Choose a reason for hiding this comment

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

LGTM. You could also drop the complex types from TcpBase.td and TcpOps.td.

@navahgar
Copy link
Collaborator Author

You could also drop the complex types from TcpBase.td and TcpOps.td.

I wanted to do that as a separate PR. Will do as a follow up.

@navahgar navahgar merged commit 0ea235e into llvm:mlir-tcp Sep 16, 2023
3 checks passed
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