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

interpreter: (riscv) add fmv.d implementation #2571

Merged
merged 11 commits into from
May 13, 2024
Merged

Conversation

superlopuh
Copy link
Member

No description provided.

@superlopuh superlopuh added the interpreter xDSL Interpreter label May 13, 2024
@superlopuh superlopuh self-assigned this May 13, 2024
Copy link

codecov bot commented May 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

❗ No coverage uploaded for pull request base (main@9ac62d2). Click here to learn what that means.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2571   +/-   ##
=======================================
  Coverage        ?   89.65%           
=======================================
  Files           ?      357           
  Lines           ?    45173           
  Branches        ?     6791           
=======================================
  Hits            ?    40498           
  Misses          ?     3655           
  Partials        ?     1020           

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

@Moxinilian
Copy link
Contributor

Moxinilian commented May 13, 2024

Not an expert, but my understanding of this instruction is that it will cast from a float encoded as an int to a float. Is this properly handled here? (I don't know the interpreter infra)

@superlopuh
Copy link
Member Author

This just moves a float to a float, the int casting op is fcvt.w.s.

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.

Tiny nit comment, otherwise neat stuff! 🐎

args: tuple[Any, ...],
):
args = RiscvFunctions.get_reg_values(interpreter, op.operands, args)
results = args
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think you could get away without this line?

Copy link
Member Author

Choose a reason for hiding this comment

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

Defo, I'm just trying to make it explicit what's happening here, I feel like it makes it a bit clearer that it's on purpose. Maybe it could be resolved better with a comment...

Base automatically changed from sasha/riscv_scf/move-results to main May 13, 2024 18:44
@superlopuh superlopuh merged commit e3403a0 into main May 13, 2024
10 checks passed
@superlopuh superlopuh deleted the sasha/riscv/fmvd-interp branch May 13, 2024 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
interpreter xDSL Interpreter
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants