Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1190348

Re: [PATCH] mm: Flush the TLB for a single address in a huge page

From Dave Hansen <dave.hansen@intel.com>
Newsgroups linux.kernel
Subject Re: [PATCH] mm: Flush the TLB for a single address in a huge page
Date 2015-07-23 01:10 +0200
Message-ID <pPbjb-5sv-5@gated-at.bofh.it> (permalink)
References <pP60d-6bF-57@gated-at.bofh.it> <pP9U7-3iz-31@gated-at.bofh.it> <pPaZP-4QP-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 07/22/2015 03:48 PM, Catalin Marinas wrote:
> You are right, on x86 the tlb_single_page_flush_ceiling seems to be
> 33, so for an HPAGE_SIZE range the code does a local_flush_tlb()
> always. I would say a single page TLB flush is more efficient than a
> whole TLB flush but I'm not familiar enough with x86.

The last time I looked, the instruction to invalidate a single page is
more expensive than the instruction to flush the entire TLB.  We also
don't bother doing ranged flushes _ever_ for hugetlbfs TLB
invalidations, but that was just because the work done around commit
e7b52ffd4 didn't see any benefit.

That said, I can't imagine this will hurt anything.  We also have TLBs
that can mix 2M and 4k pages and I don't think we did back when we put
that code in originally.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] mm: Flush the TLB for a single address in a huge page Catalin Marinas <catalin.marinas@arm.com> - 2015-07-22 19:30 +0200
  Re: [PATCH] mm: Flush the TLB for a single address in a huge page Catalin Marinas <catalin.marinas@arm.com> - 2015-07-23 00:50 +0200
    Re: [PATCH] mm: Flush the TLB for a single address in a huge page Dave Hansen <dave.hansen@intel.com> - 2015-07-23 01:10 +0200
      Re: [PATCH] mm: Flush the TLB for a single address in a huge page Andrea Arcangeli <aarcange@redhat.com> - 2015-07-23 16:20 +0200
        Re: [PATCH] mm: Flush the TLB for a single address in a huge page Andrea Arcangeli <aarcange@redhat.com> - 2015-07-23 19:20 +0200

csiph-web