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

Support custom encode/decode of exponent+IE #25

Merged
merged 1 commit into from
Nov 20, 2024
Merged

Conversation

arichardson
Copy link
Member

Instead of performing a "fake" xor part way through the decode.
This will also be helpful to support the https://riscv.github.io/riscv-cheri/ encoding.

Instead follow what the sail model does and invert the exponent and IE
values when reading them as part of the decode. This will also be useful
for supporting the RISC-V standard encoding which also avoids the XOR
on load and instead deals with the inversion during decode.
Introduce new _CC_N({ENCODE,EXTRACT}_{IE,EXPONENT}) macros to deal with
the differences in formats instead of reading the raw field values.

This also includes various Morello test changes since the input PESBT
values now need to be passed without the previous mask applied.
Copy link
Contributor

@LawrenceEsswood LawrenceEsswood left a comment

Choose a reason for hiding this comment

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

LGTM

@arichardson arichardson merged commit 7eec45b into master Nov 20, 2024
2 checks passed
@arichardson arichardson deleted the morello-avoid-xor branch November 20, 2024 22:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants