We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
As noted by @KotorinMinami the getPendingSet() function can be simplified quite a lot now that N is gone:
getPendingSet()
function getPendingSet(priv : Privilege) -> option((xlenbits, Privilege)) = { assert(extensionEnabled(Ext_S) | mideleg == zeros()); let pending_m = mip.bits & mie.bits & ~(mideleg); let pending_s = mip.bits & mie.bits & mideleg; let mIE = (priv == Machine & mstatus[MIE] == 0b1) | priv == User | priv == Supervisor; let sIE = (priv == Supervisor & mstatus[SIE] == 0b1)) | priv == User; if mIE & (pending_m != zeros()) then Some((pending_m, Machine)) else if sIE & (pending_s != zeros()) then Some((pending_s, Supervisor)) else None() }
(not tested!)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
As noted by @KotorinMinami the
getPendingSet()
function can be simplified quite a lot now that N is gone:(not tested!)
The text was updated successfully, but these errors were encountered: