Skip to content

Add P extension#369

Open
2011eric wants to merge 1 commit intoriscv:masterfrom
2011eric:master
Open

Add P extension#369
2011eric wants to merge 1 commit intoriscv:masterfrom
2011eric:master

Conversation

@2011eric
Copy link

This commit add encodings for P Extension:
https://www.jhauser.us/RISCV/ext-P/RVP-instrEncodings-015.pdf

This commit add encodings for P Extension:
https://www.jhauser.us/RISCV/ext-P/RVP-instrEncodings-015.pdf
Signed-off-by: 2011eric <201165r1c@gmail.com>
@chihminchao
Copy link
Contributor

I can generate the encoding.out.h successfully. But there is a opcode question for rv32 and rv64. There are five instructions having same encoding but differenct name for mnemoic. There are
rv32 rv64
sslai vs psslai.w
ssha vs pssha.ws
sshar vs psshar.ws
sadd vs psadd.w
aadd vs paadd.w

Should't they be merged into one ? The decoding in implementation usally can find the first match pattern.

@2011eric
Copy link
Author

2011eric commented Sep 28, 2025

@chihminchao
Thanks for reviewing.
For now I mark them as overlapping extensions in constraint.py.
And I do think it is necessary to include them in this repo due to better alignment with the spec.
I think I can mark them as pseudo_op to prevent the emission of their masks, or I can simply comment them out.

@aswaterman
Copy link
Member

Thanks for submitting this PR. I have heard that there will be another round of renaming these instructions before the spec is submitted for architecture review. I think we should wait until that occurs, and leave this PR open in the meantime.

@chihminchao chihminchao mentioned this pull request Mar 4, 2026
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.

3 participants