Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 31 Aug 1995 09:24:22 -0500
From:      Mark Tinguely <tinguely@plains.nodak.edu>
To:        gurney_j@efn.org, hackers@freebsd.org
Subject:   Re: problems with programs being swaped out!!
Message-ID:  <199508311424.JAA28099@plains.nodak.edu>

next in thread | raw e-mail | index | archive | help
>  right now I am having a regular problem with programs getting swapped out 
>  but never getting back in... right now Netscape just died on me wand it 
>  has the ps flags of: IW  Right now netscape just stop responding...  I 
>  have a 486/33DX (running at 40mhz), w/ 8megs ram and swap:

in pre 4.4 days, BSD VM copied the entire text to backstore and user and
sbrk pages were shoved into backstore when needed and they stayed there
until the program ended.

since 386BSD days, it is normal operation for single page put into backstored
or a entire process is swap put into backstore, to remains in backstore until
the process died. The backstore acts like a cache.

Back in late 386BSD or early FreeBSD, I modified the VM code to do exactly
like you wished happened, when a page(s) is brought back into RAM, the page
is removed from backstore. I kept counters to count the pages in/out of
backstore and the number of pages that were/were not modified before being
put on backstore after being brought back in. By the way, re-writes to
backstore without modification of the page was rare, so my changes did
not introduce much new overhead. At the time the disks and RAM were
smaller, swap backstore space was a premium. Logic says that a swapping machine
most like will not choose the same file to push out in low memory conditions
and this could lead to then common "full VM lockup error". My change did
help significantly my lowly 25 MHz 386 with 8 MB RAM and 80 MB running X.

Just after my changes, the VM was rewritten. I am under the impression
(****** DISCLAIMER -- I HAVE NOT HAD TIME TO STUDY THE VM FOR SOME TIME,
I COULD BE MISTAKEN *****) that larger chunks of backstore are read into the
system to improve speed. At times, some pages are discarded which is okay 
because they are on the backstore.

I would like to take the time to restudy the VM, count the cost of putting
that code back in the VM, and also put look at a features for a laptop to
automatically power down without losing currently running processes.

--mark [reply almost as long as a Terry reply :), but then I did not go into
	the plans of replacing the EBUSY mistake that is in our VM (yep, I was
	partly to blame that it is there, but I have been converted), but say
	boo and it can start a 30-40 line sermonette]



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199508311424.JAA28099>