Print this page
remove whole-process swapping
Long before Unix supported paging, it used process swapping to reclaim
memory. The code is there and in theory it runs when we get *extremely* low
on memory. In practice, it never runs since the definition of low-on-memory
is antiquated. (XXX: define what antiquated means)
You can check the number of swapout/swapin events with kstats:
$ kstat -p ::vm:swapin ::vm:swapout
*** 1108,1125 ****
sysdc_globpri(kthread_t *t)
{
return (t->t_epri);
}
- /*ARGSUSED*/
- static pri_t
- sysdc_no_swap(kthread_t *t, int flags)
- {
- /* SDC threads cannot be swapped. */
- return (-1);
- }
-
/*
* Get maximum and minimum priorities enjoyed by SDC threads.
*/
static int
sysdc_getclpri(pcpri_t *pcprip)
--- 1108,1117 ----
*** 1200,1211 ****
sysdc_enosys, /* parmsset */
sysdc_nullsys, /* stop */
sysdc_exit,
sysdc_nullsys, /* active */
sysdc_nullsys, /* inactive */
- sysdc_no_swap, /* swapin */
- sysdc_no_swap, /* swapout */
sysdc_nullsys, /* trapret */
sysdc_preempt,
sysdc_setrun,
sysdc_sleep,
sysdc_tick,
--- 1192,1201 ----