Re: [RFC 0/2] Introduce a page_fault ioengine for MM workflows

Jens Axboe <[email protected]> Sat, 31 Jan 2026 06:59:37 -0700
Newsgroups org.kernel.vger.fio
Message-ID <[email protected]>
On 1/29/26 11:42 AM, Nico Pache wrote:
> This series introduces a new page_fault ioengine and a follow?up option
> to make khugepaged behavior more deterministic for page fault testing.
> 
> The first patch adds an mmap?backed ioengine that allocates anonymous
> memory and copies data on read/write to intentionally trigger faults.
> This enables using fio?s existing framework and job files for memory
> management style workloads without relying on a filesystem. An example
> job file is included to demonstrate usage.
> 
> The second patch adds a hugepage_delay option to the new engine. It
> initially maps memory with MADV_NOHUGEPAGE, then (after a configurable
> delay) switches to MADV_HUGEPAGE via a helper thread. This makes
> khugepaged candidates reproducible, allows for easier khugepaged testing
> and improves repeatability for page_fault tests.

Looks pretty clean - echo what Vincent added on the option that should
be an engine specific option, but outside of that, the formatting of
the code is all wrong. Please follow the style of the code that's in the
repo already, which means:

1) Placement of braces
2) Tabs are... tabs, not 4 spaces. The code is a mix and match of this.
3) Appropriate empty lines after variable declarations
4) Style of switch case (indentation and braces)

etc. It's a good start to just use the clang format from the kernel,
that should get you basically to where you need to be.

-- 
Jens Axboe