stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Willy Tarreau <w@1wt.eu>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Yves-Alexis Perez <corsac@debian.org>
Subject: Re: Feedback on 4.9 performance after PTI fixes
Date: Tue, 9 Jan 2018 08:09:41 +0100	[thread overview]
Message-ID: <20180109070941.GA11835@1wt.eu> (raw)
In-Reply-To: <20180107101856.GA9590@1wt.eu>

Hi again,

updating the table after Yves-Alexis' comment on PCID. Rerunning the test
with -cpu=Haswell to enable PCID gave me much better numbers :

On Sun, Jan 07, 2018 at 11:18:56AM +0100, Willy Tarreau wrote:
> Hi,
> 
> I managed to take a bit of time to run some more tests on PTI both
> native and hosted in KVM, on stable versions built with
> CONFIG_PAGE_TABLE_ISOLATION=y. Here it's 4.9.75, used both on the
> host and the VM. I could compare pti=on/off both in the host and the
> VM. A single CPU was exposed in the VM.
> 
> It was running on my laptop (core i7 3320M at 2.6 GHz, 3.3 GHz single
> core turbo).
> 
> The test was run on haproxy's ability to forward connections. The
> results are below :
> 
>    Host  |  Guest  | conn/s  | ratio_to_host |  ratio_to_VM | Notes
> ---------+---------+---------+---------------+--------------+----------------
>  pti=off |   -     |  27400  |     100.0%    |      -       | host reference
>  pti=off | pti=off |  24200  |      88.3%    |    100.0%    | VM reference 
>  pti=off | pti=on  |  13300  |      48.5%    |     55.0%    |
>  pti=on  |   -     |  23800  |      86.9%    |      -	      | protected host
>  pti=on  | pti=off |  23100  |      84.3%    |     95.5%    |
>  pti=on  | pti=on  |  13300  |      48.5%    |     55.0%    |

New run :

    Host  |  Guest  | conn/s  | ratio  | Notes
 ---------+---------+---------+--------+----------------
  pti=off | pti=off |  23100  | 100.0% | VM reference without PTI
  pti=off | pti=on  |  19700  |  85.2% | VM with PTI and PCID
  pti=off | pti=on  |  12700  |  55.0% | VM with PTI without PCID

So the performance cut in half was indeed caused by the lack of PCID
here. With it the impact is much less, though still important.

Willy

      parent reply	other threads:[~2018-01-09  7:09 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-07 10:18 Feedback on 4.9 performance after PTI fixes Willy Tarreau
2018-01-08 17:07 ` Yves-Alexis Perez
2018-01-08 17:21   ` Yves-Alexis Perez
2018-01-08 18:26   ` Willy Tarreau
2018-01-08 20:26     ` Yves-Alexis Perez
2018-01-08 20:39       ` Willy Tarreau
2018-01-08 22:45         ` Pavlos Parissis
2018-01-08 17:26 ` David Laight
2018-01-09  7:09 ` Willy Tarreau [this message]

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=20180109070941.GA11835@1wt.eu \
    --to=w@1wt.eu \
    --cc=corsac@debian.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=stable@vger.kernel.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: link
Be 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).