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

Add decomposition for aten.roll #1170

Merged
merged 4 commits into from
Aug 24, 2022
Merged

Conversation

tanyokwok
Copy link
Collaborator

@tanyokwok tanyokwok commented Aug 8, 2022

  1. Add aten.roll to torch_ods_gen.py
  2. Add decomposition for aten.roll
  3. Add decomposition filecheck for aten.roll
  4. Add a e2e unit test

@pashu123
Copy link
Member

pashu123 commented Aug 8, 2022

@fortianyou Please add an e2e example.

@silvasean
Copy link
Contributor

Hey MHLO folks, before you add too many new ops, can you please plug in the MHLO backend into the end-to-end tests in our CI? More info here: #1025 (comment)

I'm really worried about adding many new ops without our e2e tests.

@tanyokwok
Copy link
Collaborator Author

can you please plug in the MHLO backend into the end-to-end tests in our CI

Thanks for reminding me @silvasean. I will try to figure out how to add the e2e tests for MHLO in Torch-MLIR CI.

But the PR only added codes to decomposition, and I tried to add e2e UT in the lowering pass of linalg-on-tensors

@tanyokwok
Copy link
Collaborator Author

@pashu123 Can you have a glance at my code? Why is the data type of torch.roll output unknown in the e2e test?
image

@tanyokwok tanyokwok requested a review from pashu123 August 9, 2022 05:53
@pashu123
Copy link
Member

pashu123 commented Aug 9, 2022

@pashu123 Can you have a glance at my code? Why is the data type of torch.roll output unknown in the e2e test? image

You will have to add the out type in refine types pass.

PrimAbsScalarOp, AtenNumpyTOp, AtenTriuOp>(op)) {

@tanyokwok
Copy link
Collaborator Author

@pashu123 @silvasean After rebasing the latest main branch codes, all the tests are passed. Do you have any other comments?

@silvasean
Copy link
Contributor

LGTM! Please make sure to squash all your commits before merging.

@tanyokwok tanyokwok merged commit 3d0e18b into llvm:main Aug 24, 2022
@tanyokwok tanyokwok deleted the tanyo/aten_roll branch August 24, 2022 00:36
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.

3 participants