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


Groups > linux.kernel > #1321987

Re: [PATCH v2 3/3] x86/mm: If INVPCID is available, use it to flush global mappings

From Borislav Petkov <bp@alien8.de>
Newsgroups linux.kernel
Subject Re: [PATCH v2 3/3] x86/mm: If INVPCID is available, use it to flush global mappings
Date 2016-01-29 19:30 +0100
Message-ID <qWlY0-79P-65@gated-at.bofh.it> (permalink)
References <qUUdr-88K-5@gated-at.bofh.it> <qUUdt-88K-51@gated-at.bofh.it> <qWidJ-4pG-27@gated-at.bofh.it> <qWlbz-6xj-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Jan 29, 2016 at 09:35:22AM -0800, Andy Lutomirski wrote:
> I'll fiddle with that benchmark a little bit.  Maybe I can make it
> suck less.  If anyone knows a good non-micro benchmark for this, let
> me know.

Yeah, I don't know of a good one. The TLB and all those intermediary
walker caches modern x86 CPUs have are really good. So it is hard to
measure any improvements there. I guess in this particular case, if one
can't measure slowdowns and the code is simple enough, then we're good
enough. In theory, we are carefully killing less TLB entries and the
related cached page walker data so that should be a good thing...

> I refuse to use dbus as my benchmark :)

Ha!

> FWIW, I benchmarked cr4 vs invpcid by adding a prctl and calling it in
> a loop.

Apparently INVPCID is faster than the two CR4 writes.

-- 
Regards/Gruss,
    Boris.

ECO tip #101: Trim your mails when you reply.

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


Thread

Re: [PATCH v2 3/3] x86/mm: If INVPCID is available, use it to flush  global mappings Borislav Petkov <bp@alien8.de> - 2016-01-29 15:30 +0100
  Re: [PATCH v2 3/3] x86/mm: If INVPCID is available, use it to flush  global mappings Andy Lutomirski <luto@amacapital.net> - 2016-01-29 18:40 +0100
    Re: [PATCH v2 3/3] x86/mm: If INVPCID is available, use it to flush  global mappings Borislav Petkov <bp@alien8.de> - 2016-01-29 19:30 +0100

csiph-web