Stream: git-wasmtime

Topic: wasmtime / PR #6099 riscv64: Add instruction helpers


view this post on Zulip Wasmtime GitHub notifications bot (Mar 24 2023 at 17:01):

afonso360 opened PR #6099 from riscv-inst-helpers to main:

:wave: Hey,

This change is something we discussed recently. It refactors the RISC-V ISLE files so that all instructions are emitted via helpers, similar to what we have in the x64 backend.

It also unifies them under a common syntax. We currently use 4 different ways of emitting instructions:

(alu_rrr (AluOPRRR. ...) ...)
(emit_... )
(alu_... )
(gen_... )

These were all different ways of doing the same thing. Sometimes we even used multiple variations of the above for the same instruction.

With this PR, single instructions are now emitted using rv_.... Larger patterns are still emitted using one of gen_... or lower_....

This is a pretty large refactor. I'm not sure if it helps reviewing but I've tried to restrict changes to one instruction per commit. It also doesn't change any of the golden output tests, so that helps making sure I haven't messed up anywhere.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 24 2023 at 18:00):

fitzgen submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 24 2023 at 18:34):

fitzgen merged PR #6099.


Last updated: Dec 23 2024 at 13:07 UTC