All of lore.kernel.org
 help / color / mirror / Atom feed
* Adding a new cpu mode for the cpu engine
@ 2021-01-07 23:07 Erwan Velu
  0 siblings, 0 replies; only message in thread
From: Erwan Velu @ 2021-01-07 23:07 UTC (permalink / raw)
  To: fio

Hey list,
I've been sending a pull request to improve the cpu engine 
:https://github.com/axboe/fio/pull/1161 
<https://github.com/axboe/fio/pull/1161>

fio is featuring a cpu engine which makes noop to load the cpu cores.
This makes the core busy but doesn't really consume energy and doesn't 
generate heat.

When benchmarking systems, it could be useful putting the processor 
under a realistic load to see how the whole system behave.
The idea is to get a more realistic cpu workload generator so IO 
benchmarks can be done under a defined cpu load.

This commit adds cpumode option into the cpuio engine.
By default, cpumode=noop to keep the current behavior.


If cpumode is set to qsort, fio will use a qsort algorithm instead of 
the noop instructions to load the processor.

This mode will consume more cpu power and will be useful to increase the 
pressure on the thermal and electrical components.

The expected cpu load is selected as per noop via the cpuload option.
qsort() consumes a lot of energy so the duration of every loop will vary 
over time as the power management & cpu clock changes.

To ensure a proper calibration, the thinktime is adjusted after every 
qsort() computation to be as precise as possible.


To give an order of magnitude, on an AMD 7502P (TDP=180W) :
cpuload=30, numjobs=64: packagewatt = 134W
cpuload=50, numjobs=64: packagewatt = 167W

cpuload=70, numjobs=64: packagewatt = 180W


The example file is updated to reflect this new capabilities.


The qsort code is coming from stress-qsort.c from stress-ng tool.
This software is also GPLv2 but author was informed and agreed with this 
usage


Erwan,


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-01-07 23:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-07 23:07 Adding a new cpu mode for the cpu engine Erwan Velu

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.