Supervisor Scratch Register (sscratch): 0x140

The sscratch register is a 32-bit read/write register dedicated for use by machine mode. Typically, sscratch is used to hold a pointer to the hart-local supervisor context while the hart is executing user code. At the beginning of a trap handler, sscratch is swapped with a user register to provide an initial working register.

31 0
sscratch
Bits Field Description Single/Multi-Core w/FPU w/MMU
0-31 sscratch A temporary scratch space that can be used by supervisor mode software. N/A N/A Read/Write