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

core: add argument and result types getters to CallableOpInterface #2535

Merged
merged 6 commits into from
May 6, 2024

Conversation

superlopuh
Copy link
Member

@superlopuh superlopuh commented May 4, 2024

This adds some more of the capabilities of the MLIR equivalent.

Note stacked PR

@superlopuh superlopuh added the core xDSL core (ir, textual format, ...) label May 4, 2024
@superlopuh superlopuh self-assigned this May 4, 2024
Copy link

codecov bot commented May 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.82%. Comparing base (c366844) to head (312308e).

Additional details and impacted files
@@                    Coverage Diff                     @@
##           sasha/memref/malloc-riscv    #2535   +/-   ##
==========================================================
  Coverage                      89.82%   89.82%           
==========================================================
  Files                            351      352    +1     
  Lines                          44116    44169   +53     
  Branches                        6593     6593           
==========================================================
+ Hits                           39625    39674   +49     
- Misses                          3531     3535    +4     
  Partials                         960      960           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Moxinilian
Copy link
Contributor

Moxinilian commented May 5, 2024

Codecov Report

This pull request has no tests Mr Lopoukhine.

Project coverage is actually pretty good. Comparing base (c366844) to head (525ddda).

Additional details and impacted files

actually no thanks

☔ View full report in Codecov by Théo
📢 Have feedback on the report? Yeah that makes sense.

@superlopuh
Copy link
Member Author

Weird indeed, I was aware that there were no tests but the fact that CodeCov doesn't bring this up is somewhat surprising. I'll add some

Copy link
Collaborator

@AntonLydike AntonLydike left a comment

Choose a reason for hiding this comment

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

Really nice! I like it! Thanks! 🚀

Copy link
Collaborator

@JosseVanDelm JosseVanDelm left a comment

Choose a reason for hiding this comment

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

Looks good, I just noticed that I don't understand a single thing about MLIR interfaces defined in tablegen

Comment on lines +421 to +431
raise NotImplementedError()

@classmethod
@abc.abstractmethod
def get_argument_types(cls, op: Operation) -> tuple[Attribute, ...]:
raise NotImplementedError()

@classmethod
@abc.abstractmethod
def get_result_types(cls, op: Operation) -> tuple[Attribute, ...]:
raise NotImplementedError()
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is there a reference you can give to the MLIR equivalent?

Copy link
Member Author

Choose a reason for hiding this comment

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

I tried to hunt for this, but the best one I found was at the link in the docstring for the whole trait. I also found it quite difficult to navigate the tablegen.

Base automatically changed from sasha/memref/malloc-riscv to main May 6, 2024 09:08
@superlopuh superlopuh merged commit 849987d into main May 6, 2024
9 checks passed
@superlopuh superlopuh deleted the sasha/core/callable-types branch May 6, 2024 09:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core xDSL core (ir, textual format, ...)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants