LKML Archive on lore.kernel.org help / color / mirror / Atom feed
From: Mingwei Zhang <firstname.lastname@example.org> To: Peter Xu <email@example.com> Cc: Jim Mattson <firstname.lastname@example.org>, Paolo Bonzini <email@example.com>, Sean Christopherson <firstname.lastname@example.org>, Vitaly Kuznetsov <email@example.com>, Wanpeng Li <firstname.lastname@example.org>, Joerg Roedel <email@example.com>, kvm <firstname.lastname@example.org>, LKML <email@example.com>, Ben Gardon <firstname.lastname@example.org>, David Matlack <email@example.com>, Jing Zhang <firstname.lastname@example.org> Subject: Re: [PATCH v4 3/3] KVM: x86/mmu: Add detailed page size stats Date: Thu, 12 Aug 2021 10:44:26 -0700 [thread overview] Message-ID: <CAL715WK+uSx3MjRH7NcMsBELz9-2jmWhJs0c3+_atto0iv8UOg@mail.gmail.com> (raw) In-Reply-To: <YRPMxLdL5vsZRyux@t490s> Hi Peter, On Wed, Aug 11, 2021 at 6:12 AM Peter Xu <email@example.com> wrote: > > On Tue, Aug 10, 2021 at 06:06:51PM -0700, Mingwei Zhang wrote: > > Regarding the pursuit for accuracy, I think there might be several > > reasons. One of the most critical reasons that I know is that we need > > to ensure dirty logging works correctly, i.e., when dirty logging is > > enabled, all huge pages (both 2MB and 1GB) _are_ gone. Hope that > > clarifies a little bit? > > It's just for statistics, right? I mean dirty log should be working even > without this change. That's true. What I meant was that the accurate stats might be able to help verifying a property of dirty logging as a side benefit. Sorry for the confusion. > > But I didn't read closely last night, so we want to have "how many huge pages > we're mapping", not "how many we've mapped in the history". Yes that makes > sense to be accurate. I should have looked more carefully, sorry. > > PS: it turns out atomic is not that expensive as I thought even on a 200 core > system, which takes 7ns (but for sure it's still expensive than normal memory > ops, and bus locking); I thought it'll be bigger as on a 40 core system I got > 15ns which is 2x of my laptop of 8 cores, but it didn't really grow but shrink. Thanks for the information about atomic access! > > Thanks, > > -- > Peter Xu >
next prev parent reply other threads:[~2021-08-12 17:44 UTC|newest] Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-08-03 4:46 [PATCH v4 0/3] Add detailed page size stats in KVM stats Mingwei Zhang 2021-08-03 4:46 ` [PATCH v4 1/3] KVM: x86/mmu: Remove redundant spte present check in mmu_set_spte Mingwei Zhang 2021-08-03 4:46 ` [PATCH v4 2/3] KVM: x86/mmu: Avoid collision with !PRESENT SPTEs in TDP MMU lpage stats Mingwei Zhang 2021-08-03 4:46 ` [PATCH v4 3/3] KVM: x86/mmu: Add detailed page size stats Mingwei Zhang 2021-08-09 22:26 ` Jim Mattson 2021-08-09 23:39 ` Mingwei Zhang 2021-08-10 0:01 ` Mingwei Zhang 2021-08-10 23:22 ` Peter Xu 2021-08-11 1:06 ` Mingwei Zhang 2021-08-11 13:12 ` Peter Xu 2021-08-12 17:44 ` Mingwei Zhang [this message] 2021-08-11 11:36 ` Paolo Bonzini
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=CAL715WK+uSx3MjRH7NcMsBELz9-2jmWhJs0c3+_atto0iv8UOg@mail.gmail.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).