Skip to content
This repository was archived by the owner on Jun 21, 2026. It is now read-only.

fix(imm): add sign-extended imm(#2) - #3

Open
chaoRIOS wants to merge 1 commit into
fintelia:mainfrom
chaoRIOS:imm_signext
Open

fix(imm): add sign-extended imm(#2)#3
chaoRIOS wants to merge 1 commit into
fintelia:mainfrom
chaoRIOS:imm_signext

Conversation

@chaoRIOS

Copy link
Copy Markdown

Signed-off-by: chaoRIOS chao.w@rioslab.org

 * add sign-extended imm to I,S,B,U,J Types
 * remove imm masks in unittest
 * add unittest for issue (fintelia#2)

Signed-off-by: chaoRIOS <chao.w@rioslab.org>
Comment thread src/types.rs
@@ -44,7 +44,11 @@ impl CsrIType {
pub struct IType(pub u32);
impl IType {
pub fn imm(&self) -> u32 {

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Could you switch this to returning an i32 now?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants