lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <771a5ab2c6b7347df5d7.1200592639@cinder.waste.org>
Date:	Thu, 17 Jan 2008 11:57:19 -0600
From:	Matt Mackall <mpm@...enic.com>
To:	Andrew Morton <apkm@...ux-foundation.com>
Cc:	linux-kernel@...r.kernel.org
Subject: [PATCH 1 of 3] slob: fix free block merging at head of subpage

We weren't merging freed blocks at the beginning of the free list.
Fixing this showed a 2.5% efficiency improvement in a userspace test
harness.

Signed-off-by: Matt Mackall <mpm@...enic.com>

diff -r 408d4beddb6c -r 771a5ab2c6b7 mm/slob.c
--- a/mm/slob.c	Wed Jan 16 19:00:27 2008 +0000
+++ b/mm/slob.c	Wed Jan 16 18:14:29 2008 -0600
@@ -398,6 +398,10 @@
 	sp->units += units;
 
 	if (b < sp->free) {
+		if (b + units == sp->free) {
+			units += slob_units(sp->free);
+			sp->free = slob_next(sp->free);
+		}
 		set_slob(b, units, sp->free);
 		sp->free = b;
 	} else {
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ