modeS
SetBitsSstatus(SstatusReg{.ie = 1 << modeS}.val);
SstatusReg oldStatus{.val = GetAndClearBitsSstatus(SstatusReg{.ie = 1 << modeS}.val)};
return ((1 << modeS) & oldStatus.ie) != 0;
return ((1 << modeS) & status.ie) != 0;
causeSEcall = causeECall + modeS,
sSoftInt = softInt + modeS,
sTimerInt = timerInt + modeS,
sExternInt = externInt + modeS,
case modeS: dprintf("s"); break;
case 0 + modeS: dprintf("sSoft"); break;
case 4 + modeS: dprintf("sTimer"); break;
case 8 + modeS: dprintf("sExtern"); break;
status.mpp = modeS;
case modeS: kprintf("s"); break;
case 0 + modeS: kprintf("sSoft"); break;
case 4 + modeS: kprintf("sTimer"); break;
case 8 + modeS: kprintf("sExtern"); break;
status.pie = (1 << modeS); // enable interrupts when enter userspace
status.pie = (1 << modeS); // enable interrupts when enter userspace