[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1525238492.23321.1709812267495.JavaMail.zimbra@nod.at>
Date: Thu, 7 Mar 2024 12:51:07 +0100 (CET)
From: Richard Weinberger <richard@....at>
To: David Hildenbrand <david@...hat.com>
Cc: linux-mm <linux-mm@...ck.org>, linux-fsdevel <linux-fsdevel@...r.kernel.org>,
linux-kernel <linux-kernel@...r.kernel.org>,
Linux Doc Mailing List <linux-doc@...r.kernel.org>,
upstream+pagemap <upstream+pagemap@...ma-star.at>,
adobriyan <adobriyan@...il.com>,
wangkefeng wang <wangkefeng.wang@...wei.com>,
ryan roberts <ryan.roberts@....com>, hughd <hughd@...gle.com>,
peterx <peterx@...hat.com>, avagin <avagin@...gle.com>,
lstoakes <lstoakes@...il.com>, vbabka <vbabka@...e.cz>,
Andrew Morton <akpm@...ux-foundation.org>,
usama anjum <usama.anjum@...labora.com>,
Jonathan Corbet <corbet@....net>
Subject: Re: [PATCH 1/2] [RFC] proc: pagemap: Expose whether a PTE is
writable
----- Ursprüngliche Mail -----
> Von: "David Hildenbrand" <david@...hat.com>
>> I'm currently investigating why a real-time application faces unexpected
>> page faults. Page faults are usually fatal for real-time work loads because
>> the latency constraints are no longer met.
>
> Are you concerned about any type of page fault, or are things like a
> simple remapping of the same page from "read-only to writable"
> acceptable? ("very minor fault")
Any page fault has to be avoided.
To give you more background, the real time application runs on Xenomai,
a real time extension for Linux.
Xenomai applies already many tweaks to the kernel to trigger pre-faulting of
memory areas. But sometimes the application does not use the Xenomai API
correctly or there is an bug in Xenomai it self.
Currently I'm suspecting the latter.
>>
>> So, I wrote a small tool to inspect the memory mappings of a process to find
>> areas which are not correctly pre-faulted. While doing so I noticed that
>> there is currently no way to detect CoW mappings.
>> Exposing the writable property of a PTE seemed like a good start to me.
>
> Is it just about "detection" for debugging purposes or about "fixup" in
> running applications?
It's only about debugging. If an application fails a test I want to have
a tool which tells me what memory mappings are wonky or could cause a fault
at runtime.
I fully understand that my use case is a corner case and anything but mainline.
While developing my debug tool I thought that improving the pagemap interface
might help others too.
Thanks,
//richard
Powered by blists - more mailing lists