Commit Graph

64 Commits

Author SHA1 Message Date
David Greenman a83c285c7e Fixed return status from pagers. Ahem...the previous method would manufacture
data when it couldn't get it legitimately. :-(

Submitted by:	John Dyson
1994-11-06 09:55:31 +00:00
David Greenman 2fe6e4d71e Added support for starting the experimental "vmdaemon" system process.
Enabled via REL2_1.

Added support for doing object collapses "on the fly". Enabled via REL2_1a.

Improved object collapses so that they can happen in more cases. Improved
sensing of modified pages to fix an apparant race condition and improve
clustered pageout opportunities. Fixed an "oops" with not restarting page
scan after a potential block in vm_pageout_clean() (not doing this can result
in strange behavior in some cases).

Submitted by:	John Dyson & David Greenman
1994-11-06 05:07:53 +00:00
David Greenman 1b119d9d17 Improved I/O error reporting. 1994-10-25 07:06:20 +00:00
David Greenman 191ee5b300 #if 0'd out the object cache trimming code - there are multiple ways
that the pageout daemon can deadlock otherwise.

Submitted by:	John Dyson
1994-10-25 05:35:44 +00:00
David Greenman e8fbe458e4 Fixed object cache trimming policy so it actually works.
Submitted by:	John Dyson
1994-10-23 21:03:09 +00:00
David Greenman 389918ee95 Adjusted reserved levels to fix a deadlock condition.
Submitted by:	John Dyson
1994-10-23 20:53:33 +00:00
David Greenman 47c9acfdeb Changed a thread_sleep into an spl protected tsleep. A deadlock can occur
otherwise. Minor efficiency improvement in vm_page_free().

Submitted by:	John Dyson
1994-10-23 06:15:04 +00:00
Poul-Henning Kamp 2fc59d0032 Contrary to my last commit here: NFS-swap is enabled automatically. 1994-10-22 17:53:35 +00:00
David Greenman 36df951444 Fixed a comment from the previous commit. 1994-10-22 02:41:19 +00:00
David Greenman 5663e6de1c Various changes to allow operation without any swapspace configured. Note
that this is intended for use only in floppy situations and is done at
the sacrifice of performance in that case (in ther words, this is not the
best solution, but works okay for this exceptional situation).

Submitted by:	John Dyson
1994-10-22 02:18:03 +00:00
Poul-Henning Kamp 2a054bc060 ATTENTION!
From now on, >all< swapdevices must be activated with "swapon".

If you havn't got it, add this line to /etc/fstab:
	/dev/wd0b	none	swap	sw	0 0
ne sec

Reason:
We want our GENERIC* kernels to have a large selection of swap-devices, but
on the other hand, we don't want to use a wd0b as swap when we boot of a
floppy.  This way, we will never use a unexpected swapdevice.  Nothing else
has changed.
1994-10-21 03:17:11 +00:00
Garrett Wollman 091b0456f4 Make my ALLDEVS kernel compile (basically, LINT minus a lot of options).
This involves fixing a few things I broke last time.
1994-10-21 01:19:28 +00:00
David Greenman a58d1fa15d Fix the remaining vmmeter counters. They all now work correctly. 1994-10-18 14:59:20 +00:00
David Greenman 27de4e40b8 Put sanity check for negative hold count into #ifdef DIAGNOSTIC so that
it doesn't consume an extra 3k of kernel text because of gcc's bogus
inlining code.
1994-10-17 10:43:56 +00:00
David Greenman 976e77fc9c 1) Some of the counters in the vmmeter struct don't fit well into the Mach VM
scheme of things, so I've changed them to be more appropriate. page in/ous
   are now associated with the pager that did them. Nuked v_fault as the
   only fault of interest that wouldn't be already counted in v_trap is a VM
   fault, and this is counted seperately.
2) Implemented most of the remaining counters and corrected the counting of
   some that were done wrong. They are all almost correct now...just a few
   minor ones left to fix.
1994-10-15 13:33:09 +00:00
David Greenman b8d95f1624 Count vm faults as v_vm_fault, not v_fault. 1994-10-15 10:33:47 +00:00
David Greenman a08a17a3ce Properly count object lookups and hits. 1994-10-15 10:28:47 +00:00
David Greenman b73f3b1da2 Got rid of redundant declaration warnings. 1994-10-14 12:26:18 +00:00
Jordan K. Hubbard 0a99546c0a Add missing )'s to previous midnight changes. :-) 1994-10-14 08:57:25 +00:00
David Greenman 2e1e24dd28 Fixed bug where page modifications would be lost when swap space was
almost depleted.

Reviewed by:	John Dyson
1994-10-14 01:58:52 +00:00
David Greenman defb6744ba Changed I/O error messages to be somewhat less cryptic. Removed a piece
of unused code.
1994-10-14 00:57:19 +00:00
David Greenman 28e12d63f3 Fixed an object reference count problem that was caused by a call to
vm_object_lookup() being outside of some parens. The bug was introduced
via some recently added code.

Reviewed by:	John Dyson
1994-10-13 21:01:39 +00:00
David Greenman 35c10d2239 Got rid of map.h. It's a leftover from the rmap code, and we use rlists.
Changed swapmap into swaplist.
1994-10-09 07:35:18 +00:00
Poul-Henning Kamp 05f0fdd26a Cosmetics: unused vars, ()'s, #include's &c &c to silence gcc.
Reviewed by:	davidg
1994-10-09 01:52:19 +00:00
David Greenman da8b3304fb Call resetpriority, not setpriority() ...oops.
Submitted by:	John Dyson
1994-10-09 00:18:22 +00:00
Poul-Henning Kamp 4e39a515d4 Cosmetics. Unused vars and other warnings. 1994-10-07 07:23:04 +00:00
David Greenman 8e58bf6875 Stuff object into v_vmdata rather than pager. Not important which at
the moment, but will be in the future. Other changes mostly cosmetic,
but are made for future VMIO considerations.

Submitted by:	John Dyson
1994-10-05 09:48:45 +00:00
David Greenman 5cedf6806b Fixed minor bug caused by some missing parens that can result in slightly
reduced paging performance by missing a clustering opportunity. Found
by Poul-Henning Kamp with gcc -Wall.
1994-10-05 09:02:53 +00:00
David Greenman 8baf4dac64 John Dyson's work in progress. Not currently used. 1994-10-04 07:32:08 +00:00
David Greenman edaaafdb0f Fixed bug related to proper sensing of page modification that we
inadvertantly introduced in pre-1.1.5. This could cause page modifications
to go unnoticed during certain extreme low memory/high paging rate conditions.

Submitted by:	John Dyson and David Greenman
1994-10-04 03:05:09 +00:00
Poul-Henning Kamp 623ae52e4e GCC cleanup.
Reviewed by:
Submitted by:
Obtained from:
1994-10-02 17:48:58 +00:00
David Greenman 1ffd2a2cbd Previous commit should have read ...in vm_page_alloc_contig().
...(this commit): moved initialization of 'start' to make it more clear
that it is initialized properly (also in vm_page_alloc_contig).
Reviewed by:
Submitted by:
Obtained from:
1994-09-27 20:49:02 +00:00
David Greenman 5992708aea Fixed another bug, and cleaned up the code. 1994-09-27 20:45:24 +00:00
David Greenman 0d040c7eae Fixed multiple bugs in previous version of vm_page_alloc_contig. 1994-09-27 19:34:16 +00:00
David Greenman d3c2cf7a80 1) New "vm_page_alloc_contig" routine by me.
2) Created a new vm_page flag "PG_FREE" to help track free pages.
3) Use PG_FREE flag to detect inconsistencies in a few places.
1994-09-27 18:00:29 +00:00
David Greenman c770b47d56 Removed unimplemented subr_rmap.c and unused references to it. 1994-09-25 22:31:11 +00:00
David Greenman 426de76026 Disabled swap anti-fragmentation code. It reduces swap paging performance
by 20% in my tests, and it appears to be the cause of a swap leak.

Submitted by:	John Dyson
1994-09-25 04:02:10 +00:00
David Greenman 11b224dca2 Fixed a bug I introduced when fixing the rss limit code. Changed swapout
policy to be a bit more selective about what processes get swapped out.

Reviewed by:	John Dyson
1994-09-12 15:06:14 +00:00
David Greenman cde7257454 Eliminated a whole pile of ancient (we're taking 4.3BSD) VM system
related #define constants. Corrected incorrect VM_MAX_KERNEL_ADDRESS.

Reviewed by:	John Dyson
1994-09-12 11:38:31 +00:00
David Greenman ed74321b1a Don't deactivate pages in 0-refcount objects. Added a couple of missing
paging stats. Fixed problem with free_reserved becoming depleted during
certain swap_pager operations.

Submitted by:	John Dyson, with a little help from me
1994-09-12 11:31:36 +00:00
David Greenman 55e8e4749f Fixed problem with no swap on boot device, but there is some on an
alternate device (as specified via kernel config file)...that casues
the machine to panic.
1994-09-11 03:55:39 +00:00
David Greenman db141545dc Disabled a debugging printf. 1994-09-06 17:53:24 +00:00
David Greenman a647a30954 Simple changes to paging algorithms...but boy do they make a difference.
FreeBSD's paging performance has never been better. Wow.

Submitted by:	John Dyson
1994-09-06 11:28:46 +00:00
David Greenman 90324b078e Whoops, accidently left out some pieces of the munmapfd patch. 1994-09-02 15:06:51 +00:00
David Greenman 2c7a40c7ca Removed all vestiges of tlbflush(). Replaced them with calls to pmap_update().
Made pmap_update an inline assembly function.
1994-09-02 04:12:26 +00:00
David Greenman a6ca859eb1 Fixed bug caused by change of rlimit variables to quad_t's. The bug was in
using min() to calculate the minimum of rss_cur,rss_max - since these
are now quad_t's and min() takes u_ints...the comparison later for exceeding
the rss limit was always true - resulting in rather serious page thrashing.
Now using new qmin() function for this purpose.

Fixed another bug where PG_BUSY pages would sometimes be paged out (bad!).
This was caused by the PG_BUSY flag not being included in a comparison.
1994-08-30 18:27:44 +00:00
David Greenman fff93ab600 Patches from John Dyson to improve swap code efficiency.
Religiously add back pmap_clear_modify() in vnode_pager_input until we figure
out why system performance isn't what we expect.

Submitted by:	John Dyson (swap_pager) & David Greenman (vnode_pager)
1994-08-29 06:23:19 +00:00
David Greenman 8a129caed5 1) Changed ddb into a option rather than a pseudo-device (use options DDB
in your kernel config now).
2) Added ps ddb function from 1.1.5. Cleaned it up a bit and moved into its
   own file.
3) Added \r handing in db_printf.
4) Added missing memory usage stats to statclock().
5) Added dummy function to pseudo_set so it will be emitted if there
   are no other pseudo declarations.
1994-08-27 16:14:39 +00:00
Paul Richards 3301cc3c0a Made idempotent
Reviewed by:
Submitted by:
1994-08-21 07:19:45 +00:00
Garrett Wollman f23b4c91c4 Fix up some sloppy coding practices:
- Delete redundant declarations.
- Add -Wredundant-declarations to Makefile.i386 so they don't come back.
- Delete sloppy COMMON-style declarations of uninitialized data in
  header files.
- Add a few prototypes.
- Clean up warnings resulting from the above.

NB: ioconf.c will still generate a redundant-declaration warning, which
is unavoidable unless somebody volunteers to make `config' smarter.
1994-08-18 22:36:09 +00:00