svn commit: r192676 -
user/kmacy/releng_7_2_fcs/sys/cddl/contrib/opensolaris/uts/common/fs/zfs
Kip Macy
kmacy at FreeBSD.org
Sun May 24 03:49:08 UTC 2009
Author: kmacy
Date: Sun May 24 03:49:07 2009
New Revision: 192676
URL: http://svn.freebsd.org/changeset/base/192676
Log:
try allowing the arc to grow while still permitting backpressure
Modified:
user/kmacy/releng_7_2_fcs/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c
Modified: user/kmacy/releng_7_2_fcs/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c
==============================================================================
--- user/kmacy/releng_7_2_fcs/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Sun May 24 03:22:49 2009 (r192675)
+++ user/kmacy/releng_7_2_fcs/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Sun May 24 03:49:07 2009 (r192676)
@@ -1822,14 +1822,15 @@ arc_reclaim_needed(void)
#ifdef _KERNEL
if (needfree)
return (1);
-
+ if (arc_size > arc_c_max)
+ return (1);
if (arc_size <= arc_c_min)
return (0);
/*
* If pages are needed and we're using more than half
* of kmem ... be charitable
*/
- if (vm_pages_needed && (arc_size > kmem_size()/2))
+ if (vm_pages_needed && (arc_size > (kmem_size()*2)/3))
return (1);
#if 0
@@ -3431,8 +3432,14 @@ arc_init(void)
/* Convert seconds to clock ticks */
arc_min_prefetch_lifespan = 1 * hz;
+#ifdef __amd64__
+ /* Start out with 1/8 of all memory */
+ arc_c = (physmem*PAGE_SIZE) / 8;
+
+#else
/* Start out with 1/8 of all memory */
arc_c = kmem_size() / 8;
+#endif
#if 0
#ifdef _KERNEL
/*
More information about the svn-src-user
mailing list