functional testing for Kernel Samepage Merging (KSM)
PATCH v2 1/1 functional testing for Kernel Samepage Merging (KSM)
Basic tests were to start several programs with same and different memory contents and ensure only to merge the ones with the same contents. When changed the content of one of merged pages in a process and to the mode "unmerging", it should discard all merged pages there. Also tested it is possible to disable KSM. There are also command-line options to specify the memory allocation size, and number of processes have same memory contents so it is possible to test more advanced things like KSM + OOM etc. KSM statistics numbers look like hard to predict, so only check the ranges.
Signed-off-by CAI Qian <[email protected]>
---
v2: fixed stupid mistakes about memory content assignment.
testcases/kernel/mem/ksm/Makefile | 22 ++ testcases/kernel/mem/ksm/ksm01.c | 435 +++++++++++++++++++++++++++++++++++++ 2 files changed, 457 insertions(+), 0 deletions(-) create mode 100644 testcases/kernel/mem/ksm/Makefile create mode 100644 testcases/kernel/mem/ksm/ksm01.c
testcases/kernel/mem/ksm/Makefile new file +22 -0
@@ -0,0 +1,22 @@ +# +# Copyright (c) International Business Machines Corp., 2001 +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See +# the GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# + +top_srcdir ?= ../../../.. + +include $(top_srcdir)/include/mk/testcases.mk +include $(top_srcdir)/include/mk/generic_leaf_target.mk
testcases/kernel/mem/ksm/ksm01.c new file +435 -0
435 lines not on this page · raw message
Signature · 12 lines
1.7.1 ------------------------------------------------------------------------------ Download new Adobe(R) Flash(R) Builder(TM) 4 The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly Flex(R) Builder(TM)) enable the development of rich applications that run across multiple browsers and platforms. Download your free trials today! http://p.sf.net/sfu/adobe-dev2dev _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list