Skip to content

Update Sail pseudo code #10

Description

The Sail (pseudo)code needs to be updated. The code looks mostly fine, but there are a few things that are incorrect. I know this is pseudocode, but since the actual implementation is quite similar, I think it would be better to use the actual code wherever possible and keep the pseudocode as close to the implementation as possible.

For example:

  • sext_or_truncate_to_sew does not exist. The model uses get_scalar(rs1, SEW), see model/extensions/V/vext_utils_insts.sail.
  • match suffix { "vv" => ..., "vx" => ... } uses a suffix variable that is never defined.
  • let (result, mask) = init_masked_result(...) followed by result[i] = ... does not work because let bindings are immutable.
  • ...

Here is the latest code:

https://github.com/riscv/sail-riscv/pull/1886/changes

Any thoughts on this Andrew Waterman (@aswaterman) Prashanth Mundkur (@pmundkur)?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions