DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH v9 0/2] Methodology change for hugepage configuration
@ 2024-06-10 15:20 Nicholas Pratte
  2024-06-10 15:20 ` [PATCH v9 1/2] dts: Change hugepage runtime config to 2MB Exclusively Nicholas Pratte
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Nicholas Pratte @ 2024-06-10 15:20 UTC (permalink / raw)
  To: luca.vizzarro, jspewock, paul.szczepanek, Honnappa.Nagarahalli,
	yoan.picchi, juraj.linkes, probb, bruce.richardson
  Cc: dev, Nicholas Pratte

In order to prevent accidental misconfiguration of hugepages at runtime,
the following changes are made to only allow for configuration of 2MB
hugepages within the DTS config.yaml. In the previous implementation, a
default hugepage size was selected via the size listed in /proc/meminfo.
The problem with this implementation is that, assuming the end-user has
made prior modifications to the system, /proc/meminfo may default to
hugepage sizes that are not recommended to be configured at runtime
(i.e. 1GB hugepages). This can lead to two problems: overallocation of
hugepages (which may crash the remote host) configuration of hugepages
sizes that are not recommended during runtime. In this new implementation,
we stipulate that any runtime hugepage configuration size that is not 2MB
is considered an outlier. If the end-user would like to configure either
1GB hugepages or any unique hugepage size outside of 2MB, then they should
make these configurations either at startup (in the case of 1GB hugepages)
or runtime outside of DTS configuration (if a user would like hugepages
that are not 2MB). In either case, the expectation is that, if wish to
use hugepage sizes that are not 2MB, you will make these changes outside
and prior to the initialization of DTS.

The end-user has two options: remove the option for hugepage
configuration in the conf.yaml, or keep the option and specify the
amount of 2MB hugepages desired. In the case of the former, then we assume
that hugepages are already configured prior to DTS initialization. In
the latter case, the user must define the amount of 2MB hugepages to be
configured at runtime. If the amount of 2MB hugepages requested exceeds
the amount of 2MB hugepages already configured on the system, then the
system will remount hugepages to cover the difference. If the amount of
hugepages requested is either greater than or equal to the amount
already configured on the system, then nothing is done.

Nicholas Pratte (2):
  dts: Change hugepage runtime config to 2MB Exclusively
  dts: Change hugepage 'amount' to a different term

 doc/guides/tools/dts.rst                     | 14 ++++++----
 dts/conf.yaml                                |  8 +++---
 dts/framework/config/__init__.py             |  8 +++---
 dts/framework/config/conf_yaml_schema.json   | 12 ++++-----
 dts/framework/config/types.py                |  4 +--
 dts/framework/testbed_model/linux_session.py | 28 ++++++++++----------
 dts/framework/testbed_model/node.py          |  4 ++-
 dts/framework/testbed_model/os_session.py    |  9 ++++---
 8 files changed, 48 insertions(+), 39 deletions(-)

-- 
2.44.0


^ permalink raw reply	[flat|nested] 11+ messages in thread
* [PATCH v5 0/2] Methodology change for hugepage configuration
@ 2024-04-30 18:45 Nicholas Pratte
  2024-06-07 14:31 ` [PATCH v9 " Nicholas Pratte
  2024-06-07 14:59 ` Nicholas Pratte
  0 siblings, 2 replies; 11+ messages in thread
From: Nicholas Pratte @ 2024-04-30 18:45 UTC (permalink / raw)
  To: jspewock@iol.unh.edumb@smartsharesystems.combruce.richardson,
	yoan.picchi, juraj.linkes, paul.szczepanek, wathsala.vithanage,
	thomas, Honnappa.Nagarahalli, probb
  Cc: dev, Nicholas Pratte

In order to prevent accidental misconfiguration of hugepages at runtime,
the following changes are made to only allow for configuration of 2MB
hugepages within the DTS config.yaml. In the previous implementation, a
default hugepage size was selected via the size listed in /proc/meminfo.
The problem with this implementation is that, assuming the end-user has
made prior modifications to the system, /proc/meminfo may default to
hugepage sizes that are not recommended to be configured at runtime
(i.e. 1GB hugepages). This can lead to two problems: overallocation of
hugepages (which may crash the remote host) configuration of hugepages
sizes that are not recommended during runtime. In this new implementation,
we stipulate that any runtime hugepage configuration size that is not 2MB
is considered an outlier. If the end-user would like to configure either 
1GB hugepages or any unique hugepage size outside of 2MB, then they should 
make these configurations either at startup (in the case of 1GB hugepages) 
or runtime outside of DTS configuration (if a user would like hugepages
that are not 2MB). In either case, the expectation is that, if wish to
use hugepage sizes that are not 2MB, you will make these changes outside
and prior to the initialization of DTS.
    
The end-user has two options: remove the option for hugepage
configuration in the conf.yaml, or keep the option and specify the
amount of 2MB hugepages desired. In the case of the former, then we assume
that hugepages are already configured prior to DTS initialization. In
the latter case, the user must define the amount of 2MB hugepages to be
configured at runtime. If the amount of 2MB hugepages requested exceeds
the amount of 2MB hugepages already configured on the system, then the
system will remount hugepages to cover the difference. If the amount of
hugepages requested is either greater than or equal to the amount
already configured on the system, then nothing is done.

Nicholas Pratte (2):
  dts: Change hugepage runtime config to 2MB Exclusively
  dts: Change hugepage 'amount' to a different term

 doc/guides/tools/dts.rst                     |  6 ++++-
 dts/conf.yaml                                |  8 +++---
 dts/framework/config/__init__.py             |  8 +++---
 dts/framework/config/conf_yaml_schema.json   | 12 ++++-----
 dts/framework/config/types.py                |  4 +--
 dts/framework/testbed_model/linux_session.py | 28 +++++++++++---------
 dts/framework/testbed_model/node.py          |  4 ++-
 dts/framework/testbed_model/os_session.py    |  7 ++++-
 8 files changed, 45 insertions(+), 32 deletions(-)

-- 
2.44.0


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2024-06-20  2:06 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-06-10 15:20 [PATCH v9 0/2] Methodology change for hugepage configuration Nicholas Pratte
2024-06-10 15:20 ` [PATCH v9 1/2] dts: Change hugepage runtime config to 2MB Exclusively Nicholas Pratte
2024-06-10 15:26   ` Juraj Linkeš
2024-06-17 15:08   ` Luca Vizzarro
2024-06-20  1:55   ` Thomas Monjalon
2024-06-10 15:20 ` [PATCH v9 2/2] dts: Change hugepage 'amount' to a different term Nicholas Pratte
2024-06-10 15:26   ` Juraj Linkeš
2024-06-17 15:08   ` Luca Vizzarro
2024-06-20  2:06 ` [PATCH v9 0/2] Methodology change for hugepage configuration Thomas Monjalon
  -- strict thread matches above, loose matches on Subject: below --
2024-04-30 18:45 [PATCH v5 " Nicholas Pratte
2024-06-07 14:31 ` [PATCH v9 " Nicholas Pratte
2024-06-07 14:59 ` Nicholas Pratte

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).