From: Andrea Arcangeli <aarcange@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: [PATCH] register MADV_HUGEPAGE
Date: Sat, 16 Jan 2010 19:46:42 +0100 [thread overview]
Message-ID: <20100116184642.GA5687@random.random> (raw)
From: Andrea Arcangeli <aarcange@redhat.com>
In order to allow early shipping transparent hugepage feature enabled
only inside MADV_HUGEPAGE and not globally to diminish the risk of
unexpected performance regressions on non-hypervisor related usages
I'd need this little define registered. This is also to avoid things
like this:
#define MADV_DOFORK 11 /* do inherit across fork */
#define MADV_HWPOISON 100 /* poison a page for testing */
Picking random number not so nice... and with my proof of concept
patch posted working and boosting performance equally to hugetlbfs but
without its limitations, I think it is a given that eventually KVM
will run inside MADV_HUGEPAGE madvise regions only, so I see a
negligeable risk to pollute the kernel in including this as first bit
of the full patchset.
Signed-off-by: Andrea Arcangeli <aarcange@redhat.com>
---
The rest of the transparent hugepage patchset is very ready for
inclusion too with all cleanups requested and after full handling of
all review on linux-mm so far, with the only exception of khugepaged
that is about to be finished, expect a new submit on linux-mm in a few
days. Then we'll have to plug Mel memory compaction on top of it.
(in addition to the below, /sys/kernel/mm/transparent_hugepage also
has been moved to some other distro specific location to avoid any
possible risk of clashes or confusion with future mainline behavior)
Thanks,
Andrea
diff --git a/include/asm-generic/mman-common.h b/include/asm-generic/mman-common.h
--- a/include/asm-generic/mman-common.h
+++ b/include/asm-generic/mman-common.h
@@ -45,6 +45,8 @@
#define MADV_MERGEABLE 12 /* KSM may merge identical pages */
#define MADV_UNMERGEABLE 13 /* KSM may not merge identical pages */
+#define MADV_HUGEPAGE 14 /* Worth backing with hugepages */
+
/* compatibility flags */
#define MAP_FILE 0
WARNING: multiple messages have this Message-ID (diff)
From: Andrea Arcangeli <aarcange@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: [PATCH] register MADV_HUGEPAGE
Date: Sat, 16 Jan 2010 19:46:42 +0100 [thread overview]
Message-ID: <20100116184642.GA5687@random.random> (raw)
From: Andrea Arcangeli <aarcange@redhat.com>
In order to allow early shipping transparent hugepage feature enabled
only inside MADV_HUGEPAGE and not globally to diminish the risk of
unexpected performance regressions on non-hypervisor related usages
I'd need this little define registered. This is also to avoid things
like this:
#define MADV_DOFORK 11 /* do inherit across fork */
#define MADV_HWPOISON 100 /* poison a page for testing */
Picking random number not so nice... and with my proof of concept
patch posted working and boosting performance equally to hugetlbfs but
without its limitations, I think it is a given that eventually KVM
will run inside MADV_HUGEPAGE madvise regions only, so I see a
negligeable risk to pollute the kernel in including this as first bit
of the full patchset.
Signed-off-by: Andrea Arcangeli <aarcange@redhat.com>
---
The rest of the transparent hugepage patchset is very ready for
inclusion too with all cleanups requested and after full handling of
all review on linux-mm so far, with the only exception of khugepaged
that is about to be finished, expect a new submit on linux-mm in a few
days. Then we'll have to plug Mel memory compaction on top of it.
(in addition to the below, /sys/kernel/mm/transparent_hugepage also
has been moved to some other distro specific location to avoid any
possible risk of clashes or confusion with future mainline behavior)
Thanks,
Andrea
diff --git a/include/asm-generic/mman-common.h b/include/asm-generic/mman-common.h
--- a/include/asm-generic/mman-common.h
+++ b/include/asm-generic/mman-common.h
@@ -45,6 +45,8 @@
#define MADV_MERGEABLE 12 /* KSM may merge identical pages */
#define MADV_UNMERGEABLE 13 /* KSM may not merge identical pages */
+#define MADV_HUGEPAGE 14 /* Worth backing with hugepages */
+
/* compatibility flags */
#define MAP_FILE 0
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next reply other threads:[~2010-01-16 18:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-16 18:46 Andrea Arcangeli [this message]
2010-01-16 18:46 ` [PATCH] register MADV_HUGEPAGE Andrea Arcangeli
2010-01-17 11:08 ` Christoph Hellwig
2010-01-17 11:08 ` Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100116184642.GA5687@random.random \
--to=aarcange@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.