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

Implement SyscallOther #1419

Merged
merged 1 commit into from
Dec 6, 2023
Merged

Implement SyscallOther #1419

merged 1 commit into from
Dec 6, 2023

Conversation

mrmr1993
Copy link
Member

@mrmr1993 mrmr1993 commented Dec 5, 2023

No description provided.

Copy link
Member

@dannywillems dannywillems left a comment

Choose a reason for hiding this comment

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

LGTM, modulo comments

let is_sysbrk = {
// FIXME: Requires constraints
let pos = env.alloc_scratch();
unsafe { env.test_zero(&(syscall_num.clone() - Env::constant(4045)), pos) }
Copy link
Member

Choose a reason for hiding this comment

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

Let's add constants later.

Copy link
Member

Choose a reason for hiding this comment

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

See #1438

optimism/src/mips/interpreter.rs Show resolved Hide resolved
};
let v0 = { is_sysbrk * Env::constant(0x40000000) + is_sysclone };
let v1 = Env::constant(0);
env.write_register(&Env::constant(2), v0);
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
env.write_register(&Env::constant(2), v0);
env.write_register(&Env::constant(REGISTER_V0), v0);

optimism/src/mips/interpreter.rs Show resolved Hide resolved
Base automatically changed from feature/mips/sb to master December 6, 2023 16:47
@dannywillems dannywillems merged commit f8c060d into master Dec 6, 2023
4 checks passed
@dannywillems dannywillems deleted the feature/mips/syscall-other branch December 6, 2023 16:47
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