Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/cddl/osnet/dist/uts/common/fs/zfs use pool_cache fo...
details: https://anonhg.NetBSD.org/src/rev/acef1efa2984
branches: trunk
changeset: 934795:acef1efa2984
user: jdolecek <jdolecek%NetBSD.org@localhost>
date: Fri Jun 19 14:13:23 2020 +0000
description:
use pool_cache for (meta)data buffers also on NetBSD
this should generally slightly improve performance on MP systems, and
specifically for xbd(4) storage avoids slow unaligned I/O buffer handling
this change requires updated kernel, to allow up to SPA_MAXBLOCKSHIFT item
size for pools
fixes PR kern/55397 by Frank Kardel
diffstat:
external/cddl/osnet/dist/uts/common/fs/zfs/zio.c | 6 +-----
1 files changed, 1 insertions(+), 5 deletions(-)
diffs (44 lines):
diff -r dbf04bc44460 -r acef1efa2984 external/cddl/osnet/dist/uts/common/fs/zfs/zio.c
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/zio.c Fri Jun 19 13:52:40 2020 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/zio.c Fri Jun 19 14:13:23 2020 +0000
@@ -46,7 +46,7 @@
SYSCTL_DECL(_vfs_zfs);
SYSCTL_NODE(_vfs_zfs, OID_AUTO, zio, CTLFLAG_RW, 0, "ZFS ZIO");
#ifdef __NetBSD__
-const int zio_use_uma = 0;
+const int zio_use_uma = 1;
#else
#if defined(__amd64__)
static int zio_use_uma = 1;
@@ -156,7 +156,6 @@
zio_link_cache = kmem_cache_create("zio_link_cache",
sizeof (zio_link_t), 0, NULL, NULL, NULL, NULL, NULL, 0);
-#ifndef __NetBSD__
if (!zio_use_uma)
goto out;
@@ -220,7 +219,6 @@
zio_data_buf_cache[c - 1] = zio_data_buf_cache[c];
}
out:
-#endif /* __NetBSD__ */
zio_inject_init();
@@ -242,7 +240,6 @@
kmem_cache_t *last_cache = NULL;
kmem_cache_t *last_data_cache = NULL;
-#ifndef __NetBSD__
for (c = 0; c < SPA_MAXBLOCKSIZE >> SPA_MINBLOCKSHIFT; c++) {
if (zio_buf_cache[c] != last_cache) {
last_cache = zio_buf_cache[c];
@@ -256,7 +253,6 @@
}
zio_data_buf_cache[c] = NULL;
}
-#endif /* __NetBSD__ */
kmem_cache_destroy(zio_link_cache);
kmem_cache_destroy(zio_cache);
Home |
Main Index |
Thread Index |
Old Index