lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOUHufZhcJh8PdVtFuoOPWBWw_fWNAB61GndXoWjekYaubXTAQ@mail.gmail.com>
Date:   Thu, 22 Dec 2022 14:37:00 -0700
From:   Yu Zhao <yuzhao@...gle.com>
To:     Yuanchu Xie <yuanchu@...gle.com>
Cc:     Ivan Babrou <ivan@...udflare.com>,
        Johannes Weiner <hannes@...xchg.org>,
        Alexander Viro <viro@...iv.linux.org.uk>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Steven Barrett <steven@...uorix.net>,
        Brian Geffon <bgeffon@...gle.com>,
        Oleksandr Natalenko <oleksandr@...alenko.name>,
        Suren Baghdasaryan <surenb@...gle.com>,
        Arnd Bergmann <arnd@...db.de>, Peter Xu <peterx@...hat.com>,
        Hugh Dickins <hughd@...gle.com>,
        Gaosheng Cui <cuigaosheng1@...wei.com>,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-mm@...ck.org, Jens Axboe <axboe@...nel.dk>,
        Michael Larabel <michael@...haellarabel.com>
Subject: Re: [PATCH 2/2] mm: support POSIX_FADV_NOREUSE for generic fadvise handler

On Wed, Dec 21, 2022 at 11:13 PM Yuanchu Xie <yuanchu@...gle.com> wrote:

Thanks for following up on this.

> POSIX_FADV_NOREUSE allows an application to specify that accesses to
> file data does not follow LRU and is used only once. Since 2.6.18 this
> is a no-op. We add FMODE_NOREUSE, checked in vma_has_locality to prevent
> LRU activation.

This needs to include what you plan to write on the man page.

A few questions to answer:
1. Does this flag work with accesses via FDs?
2. If there is a random or sequential file VMA, should the user choose
this flag or the VMA flag or both? Consider a) how those flags affect
readahead; b) their scopes, i.e., per VMA or per file.

Please also follow up with Jens to add this flag to fio.

Micheal reported that SVT-AV1 regressed with MGLRU, which is the only
real one [1]. The following not only fixes the regression but also
improves the baseline. Please follow up on that as well.

--- a/Source/App/EncApp/EbAppMain.c
+++ b/Source/App/EncApp/EbAppMain.c
@@ -115,6 +115,7 @@ void init_memory_file_map(EbConfig* config) {
             fseeko(config->input_file, curr_loc, SEEK_SET); // seek
back to that location
 #ifndef _WIN32
             config->mmap.fd = fileno(config->input_file);
+            posix_fadvise(config->mmap.fd, 0, 0, POSIX_FADV_NOREUSE);
 #endif
         }
         config->mmap.file_frame_it = 0;

[1] https://openbenchmarking.org/result/2209259-PTS-MGLRU8GB57

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ