diff mbox series

[LOCAL] arm64: renesas: defconfig: Enable Transparent Hugepage madvise

Message ID 20201221083623.4156421-1-geert+renesas@glider.be (mailing list archive)
State Mainlined
Commit 42d146227cd58aa996eefa88aa2bb36c3ef36e4e
Delegated to: Geert Uytterhoeven
Headers show
Series [LOCAL] arm64: renesas: defconfig: Enable Transparent Hugepage madvise | expand

Commit Message

Geert Uytterhoeven Dec. 21, 2020, 8:36 a.m. UTC
Enabling Transparent Hugepage always can increase the memory footprint
of applications without a guaranteed benefit.

Documentation/admin-guide/mm/transhuge.rst says:

    Embedded systems should enable hugepages only inside madvise regions
    to eliminate any risk of wasting any precious byte of memory and to
    only run faster.

Hence enable Transparent Hugepage madvise instead, which will only
provide a performance improvement benefit to the applications using
madvise(MADV_HUGEPAGE), but it won't risk to increase the memory
footprint of applications without a guaranteed benefit.

Suggested-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
Not intended for upstream merge; to be applied to the
topic/renesas-defconfig only.

Perhaps this should be changed in arch/arm64/configs/defconfig, too?
Perhaps the default should be changed in mm/Kconfig instead?
---
 arch/arm64/configs/renesas_defconfig | 1 +
 1 file changed, 1 insertion(+)

Comments

Kuninori Morimoto Dec. 23, 2020, 11:22 p.m. UTC | #1
Hi Geert

> Enabling Transparent Hugepage always can increase the memory footprint
> of applications without a guaranteed benefit.
> 
> Documentation/admin-guide/mm/transhuge.rst says:
> 
>     Embedded systems should enable hugepages only inside madvise regions
>     to eliminate any risk of wasting any precious byte of memory and to
>     only run faster.
> 
> Hence enable Transparent Hugepage madvise instead, which will only
> provide a performance improvement benefit to the applications using
> madvise(MADV_HUGEPAGE), but it won't risk to increase the memory
> footprint of applications without a guaranteed benefit.
> 
> Suggested-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
> ---

Please add this
	Reported-by: Takanari Hayama <taki@igel.co.jp>


Thank you for your help !!

Best regards
---
Kuninori Morimoto
diff mbox series

Patch

diff --git a/arch/arm64/configs/renesas_defconfig b/arch/arm64/configs/renesas_defconfig
index 71a6cb34ca89229c..f641a2675d0a425b 100644
--- a/arch/arm64/configs/renesas_defconfig
+++ b/arch/arm64/configs/renesas_defconfig
@@ -75,6 +75,7 @@  CONFIG_BLK_DEV_INTEGRITY=y
 # CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set
 CONFIG_KSM=y
 CONFIG_TRANSPARENT_HUGEPAGE=y
+CONFIG_TRANSPARENT_HUGEPAGE_MADVISE=y
 CONFIG_CMA=y
 CONFIG_NET=y
 CONFIG_PACKET=y