Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp970041ybh; Tue, 21 Jul 2020 12:22:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxuyI+Iu4jc79IZGe39dDjxach0JjxRKWpyHHc+CqNVzLY6FuB8PRkJ5TOxD0I0cR2Xuo2f X-Received: by 2002:a17:907:41dc:: with SMTP id og20mr27802344ejb.183.1595359366450; Tue, 21 Jul 2020 12:22:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595359366; cv=none; d=google.com; s=arc-20160816; b=NLRrs2QidEInZN++AYBKbfDtg4I9pIJeMs9C8p01HpgScv5/OCRkpyZBvU0wfFQicW jXUt7MGNK/+W5CrzPtmfazqP26iilQ7S9+dyGUolHQqnY/HV4Y3sOp7RTSlxahvcIfrh ScPLXAHqppb23S9zrDTk4yVGJ4yCYLUf/jQJprSu8SO9If1COrBXT6ZG1LbWyQ1n7ALJ Ietu3w1LXroA3q7QQ25BM0Z1q2hSDpVIgQhEhjNVs0nYg0f1YCseBZZS+wqBcvnPSoF4 YAIjagt6XmujIjPjkW5c2Ho08F98NzTo5Ct/rGI3zcuK8ny2rFYqLPYxiGqgKxCoryCv l61w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=VhiQA6qev8PWeov/hSb1BErF1Q8azhYHkTiZfTrt8pE=; b=y4JUcUac1LHjWxYnxFQ/d4vsbwrvLcTwRcheOcTNxFsr5ijoEe8i/VLrF0Wugc3lBu AH1MNseRkDWPOZS7s0GDUywF3YOzlqZufaRtuR1Sm5PVECkAJ275o467CkHo22i9YSzH LYVtezOiBTmdcLBbuYRYEjnvttHDTqx4H8Wdzoof/c/CvDEMLa+h25XiTbAqCcDVAQfh 3M/nbCcDZAE4Zfg+GHHlYPmRyS29/TCW5qhWFSarKA/v1VsbT/Elnv58yA8C+N5iXnl6 9/rW8Q4UOUyDIotSJqFI4B0jsmnLXog3xZCuqiFm/VkbXae8RzPQDpdqpwgbi7m6EwEP d64A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=leGPhWIG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i26si12694733ejk.576.2020.07.21.12.22.23; Tue, 21 Jul 2020 12:22:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=leGPhWIG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729215AbgGUTUK (ORCPT + 99 others); Tue, 21 Jul 2020 15:20:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43346 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727801AbgGUTUJ (ORCPT ); Tue, 21 Jul 2020 15:20:09 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A427DC061794 for ; Tue, 21 Jul 2020 12:20:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=VhiQA6qev8PWeov/hSb1BErF1Q8azhYHkTiZfTrt8pE=; b=leGPhWIGaMSDBw2JNEVNvsOkGe nB4QK89Tr1IHLRgdVJ0wqikAmCEA5yXVgWKMmx8I0vK9X24cnML/gjmaXgtgNUQw9384WjA+4Or4h L4QMRYGhbMOr7Py2ejR+ezbA2lavO5T9rTwQercFCsNThT42ZvqWOjB4cTgpvcd+IWrwUwmRVIzSp 4KDxwcAXQdml67PpXqT1S9QFE0qf8GT102f9l41tcsqiHzCOrdJNMkY63yeU9YE+XPElWceyPm8P5 gYP/DbdqUSzpGDw81M8Me7V0l5Ff1Re5WvepqvidwOceJOyaArpUSrzapEY/V0CArMQAwXZKCmF7V Hhbq9C3A==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1jxxo3-0008Ve-02; Tue, 21 Jul 2020 19:20:03 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 8A385304D28; Tue, 21 Jul 2020 21:20:02 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 76F4C20140AC3; Tue, 21 Jul 2020 21:20:02 +0200 (CEST) Date: Tue, 21 Jul 2020 21:20:02 +0200 From: Peter Zijlstra To: Andi Kleen Cc: kan.liang@linux.intel.com, acme@redhat.com, mingo@kernel.org, linux-kernel@vger.kernel.org, jolsa@kernel.org, eranian@google.com, alexander.shishkin@linux.intel.com Subject: Re: [PATCH V6 09/14] perf/x86/intel: Support TopDown metrics on Ice Lake Message-ID: <20200721192002.GI10769@hirez.programming.kicks-ass.net> References: <20200717140554.22863-1-kan.liang@linux.intel.com> <20200717140554.22863-10-kan.liang@linux.intel.com> <20200721124042.GX10769@hirez.programming.kicks-ass.net> <20200721173859.GG1180481@tassilo.jf.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200721173859.GG1180481@tassilo.jf.intel.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 21, 2020 at 10:38:59AM -0700, Andi Kleen wrote: > > Also, that for_each_set_bit() loop, trying to find the events to > > update... > > > > Can't we, instead, make the SLOTS update advance 5 running counters in > > cpuc and feed the events off of that? > > The original patches implemented this through a perf transaction and a > cache. I think what you're suggesting is similar to the old cache. I can't remember :-) Anyway, the TXN_READ thing Kan pointed out should work fine, I just missed it when reading through the code.