From f24aa01f9d0b03a6650deffd7bd31cb68bfd0172 Mon Sep 17 00:00:00 2001 From: Mateusz Guzik Date: Thu, 5 Nov 2020 11:24:45 +0000 Subject: [PATCH] tmpfs: reorder struct tmpfs_node to shrink it by 8 bytes The reduction (232 -> 224 bytes) allows UMA to fit one more item (17 -> 18) per slab as reported in vm.uma.TMPFS_node.keg.ipers. --- sys/fs/tmpfs/tmpfs.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/sys/fs/tmpfs/tmpfs.h b/sys/fs/tmpfs/tmpfs.h index 8c6e51e62fe5..beded9cd5455 100644 --- a/sys/fs/tmpfs/tmpfs.h +++ b/sys/fs/tmpfs/tmpfs.h @@ -156,7 +156,9 @@ struct tmpfs_node { * when the node is removed from list and unlocked. */ LIST_ENTRY(tmpfs_node) tn_entries; /* (m) */ - bool tn_attached; /* (m) */ + + /* Node identifier. */ + ino_t tn_id; /* (c) */ /* * The node's type. Any of 'VBLK', 'VCHR', 'VDIR', 'VFIFO', @@ -166,8 +168,10 @@ struct tmpfs_node { */ enum vtype tn_type; /* (c) */ - /* Node identifier. */ - ino_t tn_id; /* (c) */ + /* + * See the top comment. Reordered here to fill LP64 hole. + */ + bool tn_attached; /* (m) */ /* * Node's internal status. This is used by several file system