-
Notifications
You must be signed in to change notification settings - Fork 85
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
dialects: (riscv) split out the base classes for custom format and assembly printing #3436
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3436 +/- ##
=======================================
Coverage 90.19% 90.19%
=======================================
Files 458 458
Lines 57716 57717 +1
Branches 5564 5564
=======================================
+ Hits 52059 52060 +1
Misses 4194 4194
Partials 1463 1463 ☔ View full report in Codecov by Sentry. |
xdsl/dialects/riscv.py
Outdated
@@ -361,6 +361,12 @@ def get_register_constraints(self) -> RegisterConstraints: | |||
def assembly_line(self) -> str | None: | |||
raise NotImplementedError() | |||
|
|||
|
|||
class RISCVCustomFormatOperation(RISCVAsmOperation, ABC): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it intentional that this inherits from RISCVAsmOperation
? Your description makes it sound like these should be disjoint
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yes I'll remove this, thank you
…sembly printing (xdslproject#3436) We currently have a single base class for two kinds of shared functionality: printing the assembly for the target, and printing the custom format. I'd like to decouple them to migrate some RISC-V operations to custom format, which cannot be provided at the same time as custom printing and parsing functions.
We currently have a single base class for two kinds of shared functionality: printing the assembly for the target, and printing the custom format. I'd like to decouple them to migrate some RISC-V operations to custom format, which cannot be provided at the same time as custom printing and parsing functions.