Received: by 2002:ac0:a679:0:0:0:0:0 with SMTP id p54csp709161imp; Wed, 20 Feb 2019 07:41:18 -0800 (PST) X-Google-Smtp-Source: AHgI3IaYN1lJAnADz8IH8ioIu1WTbskX3cTPy800LK7Y9COZCk90DN02/l+1WADuGOEnBEgDBDj6 X-Received: by 2002:a65:6149:: with SMTP id o9mr29674573pgv.315.1550677278369; Wed, 20 Feb 2019 07:41:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550677278; cv=none; d=google.com; s=arc-20160816; b=AIaEjbbXSL8BH+nH7gz5viX9ZY4XzRj9lILlDI1v7xSMAjkFPEMGuyaBPK5/OiOaAA OTEIBzb3pIbCjYHVredIMT+m4VU84NxTnkIt+Sr+smwlWajHNFGh9gf13sav8b9BQ/lG XcbwrMkeRPMes0GhXobMUhHQcrmNt59bLFWmVTveXcK/e63IqF4/oEdetkAWWNIQN623 GEbRYHOi6KAliVNm4A8S/6EBzyUS0iHnVAGPjU2J571f3b9C4LnzqxOBnzZ69Bs/kEaB ppFFEVfMmt02HZ/CEutU57vPITglLrYYjIlEsjloh9RWpvvBtDVSNBXlLMilPV42d5b7 JYVQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=hrVVdJfI9yi2YE6QtCzWNO3roOLoQpuBDAVp9INzooY=; b=nWT5vUuj7DgbHN2pBgZVsEKyjnbo9xhpnkcJrRQ2DcQHfgslnVmyvf3aXOk83j3cZY Z8cWw2NM+BxYR49b2AP3D+i1r4jGRXDDB13OP4bPuQVVy8ZByxrcnrSIO+rwyO7XmNrv 2pR2pzX8U3pqFn0I/CmKhrGY/2hlO8tiNYhb+1bud6IVRrex/RPPNwVOkoYuCb1vLZeS LtmsF4W38af+T/lVmIkvyF06BROy9iWd/uKS+vyHqcAmPvOo4Bh+VUTYljn5/cghnMmf fk2UIPVdxPLdYdi3TEGKUhKqC8omed468WmuaCuyD7gorAQ7cHPmfkrASGMk1cwXYKZs /2AQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u84si9518313pfa.134.2019.02.20.07.41.03; Wed, 20 Feb 2019 07:41:18 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726900AbfBTPi6 (ORCPT + 99 others); Wed, 20 Feb 2019 10:38:58 -0500 Received: from mga05.intel.com ([192.55.52.43]:35279 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725822AbfBTPi5 (ORCPT ); Wed, 20 Feb 2019 10:38:57 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 20 Feb 2019 07:38:57 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.58,391,1544515200"; d="scan'208";a="135782951" Received: from avandeve-mobl.amr.corp.intel.com (HELO [10.254.102.211]) ([10.254.102.211]) by orsmga002.jf.intel.com with ESMTP; 20 Feb 2019 07:38:55 -0800 Subject: Re: [PATCH v11 2/3] x86,/proc/pid/status: Add AVX-512 usage elapsed time To: David Laight , 'Thomas Gleixner' , "Li, Aubrey" Cc: "mingo@redhat.com" , "peterz@infradead.org" , "hpa@zytor.com" , "ak@linux.intel.com" , "tim.c.chen@linux.intel.com" , "dave.hansen@intel.com" , "aubrey.li@intel.com" , "linux-kernel@vger.kernel.org" References: <20190213023748.6614-1-aubrey.li@linux.intel.com> <20190213023748.6614-2-aubrey.li@linux.intel.com> <85b22e16-fffc-7ebe-2ab1-3b6fe7e036ab@linux.intel.com> <5c6ed8168eb34e0e84245fe01ba477ef@AcuMS.aculab.com> From: Arjan van de Ven Message-ID: Date: Wed, 20 Feb 2019 07:38:54 -0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1 MIME-Version: 1.0 In-Reply-To: <5c6ed8168eb34e0e84245fe01ba477ef@AcuMS.aculab.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2/20/2019 7:35 AM, David Laight wrote: > From: Sent: 16 February 2019 12:56 >> To: Li, Aubrey > ... >> The above experiment just confirms what I said: The numbers are inaccurate >> and potentially misleading to a large extent when the AVX using task is not >> scheduled out for a longer time. > > Not only that, they won't detect programs that use AVX-512 but never > context switch with live AVX-512 registers. you are completely correct in stating that this approach is basically sampling at a relatively course level and such sampling will give false negatives the alternative is not sampling, and not knowing anything at all, unless you have a better suggestion on how to help find tasks that use avx512 in a low overhead way (the typical use case is trying to find workloads that use avx512 to help scheduling those workloads in the future in the cloud orchestrator, for example to help them favor machines that support avx512 over machines that don't)