Received: by 10.223.185.116 with SMTP id b49csp1408688wrg; Sun, 11 Feb 2018 11:14:42 -0800 (PST) X-Google-Smtp-Source: AH8x225c/fQbU6nN8J5UEiCtrJS9Y7JWqAyhd94WxaZXh9Wgdu6i/BM2MK1o8hsLzwnC/k+Ybwe1 X-Received: by 10.99.67.66 with SMTP id q63mr7485426pga.175.1518376482818; Sun, 11 Feb 2018 11:14:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518376482; cv=none; d=google.com; s=arc-20160816; b=VredHV23KGX0sY+BPTznBosm/ZQF7KwfEvC4Znhm8pBCE1y04v6jxUe9ZUyrh7FOxd HTdVXnD3Q0GQw13GeulMFDmxtKhL5yvQMNLeKsP7n33bKZTiWRoFoBVUWgSza6J1oE+1 CrIv5Z9mg6ygUcQ/KWrafcnOSJjAWSe67Mqh3F2XcduXSoyoQB3554FUlIzzk9PFBSXf ckMKDpqS1RVV1S60ODK7Q57UShvQcaVgrxFiFPVTg/2PeUG1TgtnwK0oPPla5rn+BgAH FVdFr68ENUKvDjD/8cUfZY+5qn+vPcCShPOReg6+BJdsDpO2EkjbQs5Bgjgjcy/lIuBQ 4WHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=Sb7D/e+myKUPxA0fmAFwq4qF2XlDjLhyP8QV6vk16WM=; b=hoqnebvzC38l4G7k0RAUF1qVH0MZjSXu402ybCBaamM44+ccHHauhyoWvGz49dJ87p OT6LoJu++7KBhzWjEUpBF8gNUq9MJp5xYLSSl2wBwKn4eCJF0GViX8thN0uj8Xb1VjKC a6zKF29rc50OoaN/TOPeWioSmGn5bSTPWrM4q9UHZPMpC0+tJK5pr2XY+N4c7/Jr5K/f W+vQwSWxJ/r8q1P8rLQ0uEZV1XuYPY3DsRcjt5x3uXxNGz3JtaushhgEaueN3NoNOKk8 JrESopkgMADIBofvpemNzuIpkKZjqdRoxd4MmzfNy9ACx16JliAhWL0IoJ/JD33oTUme pk6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=X+YZdKyL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t6-v6si2958173plr.777.2018.02.11.11.14.17; Sun, 11 Feb 2018 11:14:42 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=X+YZdKyL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753669AbeBKTNS (ORCPT + 99 others); Sun, 11 Feb 2018 14:13:18 -0500 Received: from mail-wr0-f196.google.com ([209.85.128.196]:46350 "EHLO mail-wr0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753602AbeBKTNR (ORCPT ); Sun, 11 Feb 2018 14:13:17 -0500 Received: by mail-wr0-f196.google.com with SMTP id 34so2869893wre.13 for ; Sun, 11 Feb 2018 11:13:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=Sb7D/e+myKUPxA0fmAFwq4qF2XlDjLhyP8QV6vk16WM=; b=X+YZdKyLPZoSaynOnWaRCuf2I+IDuvqv9kSsswmTGaqIHtE2CpGvYRE+4f2SYDz69G RL1A7pFSTHDxc+Vrw0t0jILTNv0hcE4BlkF2+oso96YvV7hrZwiv3D+T0zivv+N3jdnW NP+8D61FOasDiUYuBKZqJ7xqTdOUsssYAGQvHR6aSHSWS4MI2if3mXcDsayonfXmHbY7 DME6krlCfGxVl36kSMbocfa1GZ01fwT78vFX3KGq27XBAfyhYAcsZtN+FLyLTNqKZRtH E1RrgPFkJz+Ezb/DRTVQ0JVlAMjHNrJOhHhSgHqvPS39N3R1G5t+wMxI/qOdW8ON+KSz DaSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=Sb7D/e+myKUPxA0fmAFwq4qF2XlDjLhyP8QV6vk16WM=; b=aYsLkPOGPzOS1KW3OCwQ0l6S8t4XQpY2+B+NJsEhUdH/t6I8PKFIHQSsVUSOxfuGDm xOBwlMDl2EA6+Bfz8NS1pSuNfPnA3Mu1hhp1TYxlotFRdodeKB4dEUIbApGQGVy0L2dm EzUZRnPlie1De/AKojEJPcUuoVpPXqYExMP8YIEPxQqLQAG0XI3OTmsOcQzORUw9b87v N+Kur7IaMH8gh6yhjCHjsgNdyNkt9mjttk2dbmo8fQwCA43L2upIb+6axQ0WtAKYiGdk MqRtQJ8Nb/RqrLbMqFLZ2wyouXmBragnkYBnI4TkXa75cJ4FWW8RNPVdAnYND9mFncj6 zxww== X-Gm-Message-State: APf1xPChg9UY5Cnoseh1cQkxoVkc/8Z+O+/EZywgNHb0gJWqNLHx7c+n QytoZoqBhCVWkGXmrOQ7Jdg= X-Received: by 10.223.138.132 with SMTP id y4mr6260795wry.242.1518376396257; Sun, 11 Feb 2018 11:13:16 -0800 (PST) Received: from gmail.com (2E8B0CD5.catv.pool.telekom.hu. [46.139.12.213]) by smtp.gmail.com with ESMTPSA id h194sm5625384wma.8.2018.02.11.11.13.14 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 11 Feb 2018 11:13:15 -0800 (PST) Date: Sun, 11 Feb 2018 20:13:12 +0100 From: Ingo Molnar To: Joerg Roedel Cc: Andy Lutomirski , Joerg Roedel , Thomas Gleixner , "H . Peter Anvin" , X86 ML , LKML , Linux-MM , Linus Torvalds , Dave Hansen , Josh Poimboeuf , Juergen Gross , Peter Zijlstra , Borislav Petkov , Jiri Kosina , Boris Ostrovsky , Brian Gerst , David Laight , Denys Vlasenko , Eduardo Valentin , Greg KH , Will Deacon , "Liguori, Anthony" , Daniel Gruss , Hugh Dickins , Kees Cook , Andrea Arcangeli , Waiman Long , Pavel Machek Subject: Re: [PATCH 00/31 v2] PTI support for x86_32 Message-ID: <20180211191312.54apu5edk3olsfz3@gmail.com> References: <1518168340-9392-1-git-send-email-joro@8bytes.org> <20180209191112.55zyjf4njum75brd@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180209191112.55zyjf4njum75brd@suse.de> User-Agent: NeoMutt/20170609 (1.8.3) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Joerg Roedel wrote: > Hi Andy, > > On Fri, Feb 09, 2018 at 05:47:43PM +0000, Andy Lutomirski wrote: > > One thing worth noting is that performance of this whole series is > > going to be abysmal due to the complete lack of 32-bit PCID. Maybe > > any kernel built with this option set that runs on a CPU that has the > > PCID bit set in CPUID should print a big fat warning like "WARNING: > > you are using 32-bit PTI on a 64-bit PCID-capable CPU. Your > > performance will increase dramatically if you switch to a 64-bit > > kernel." > > Thanks for your review. I can add this warning, but I just hope that not > a lot of people will actually see it :) Could you please measure the PTI kernel vs. vanilla kernel? Nothing complex, just perf's built-in scheduler and syscall benchmark should be enough: perf stat --null --sync --repeat 10 perf bench sched messaging -g 20 this should give us a pretty good worst-case overhead figure for process workloads. Add '-t' to test threaded workloads as well: perf stat --null --sync --repeat 10 perf bench sched messaging -g 20 -t The 10 runs used should be enough to reach good stability in practice: Performance counter stats for 'perf bench sched messaging -g 20 -t' (10 runs): 0.380742219 seconds time elapsed ( +- 0.73% ) Maybe do the same on the 64-bit kernel as well, so that we have 4 good data points on the same hardware? Thanks, Ingo