Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp800142ybx; Wed, 6 Nov 2019 08:36:31 -0800 (PST) X-Google-Smtp-Source: APXvYqx/q5YhFJrjEU6V2MFZnXC5zDcRySy46KaWAK8zEuicq56wdP1QZjnEfv1vKbr6zIpHTtTg X-Received: by 2002:a17:906:1dc4:: with SMTP id v4mr34923715ejh.248.1573058191249; Wed, 06 Nov 2019 08:36:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573058191; cv=none; d=google.com; s=arc-20160816; b=MpS6Z0GEUMSe3Rlpu1iPtY6lW213h7MHKUbEd0SCRwafmA4e2ZqHddLBvQcsItB0GW SCCxsxL877UrotSurHlwbnjAWu02otnQpl0B3A9p6kWoOZqe/0CFIKji8v0zzVKcprel wlyAf9fCJKZzNg7LmvwNn284/EmxEtUfuKJ0ZqL8ocPpzCR8EmP/T83uNlFhXcx8oO51 HzovYen9DKT7I710YKQIGJTXOGF4OyUoyPM3Xi4jsakdDuULUUyALoqSmCoPcW9Hj4YR sxzmJufMDEwvpkWs3hnoItOqpu/8B4L7LHPUFx5DCcmvoRiJ4L0ijiI66ZUXFbgLEw9w RydQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:user-agent:in-reply-to:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=BQP7afY4/MZ7S29LaklU0C/wM1CnsMUrSv6g4R9XuMk=; b=rmwBUoHWBGMFXIg0zPFh217Y7jprGioHiCZU1vz41RwHJlY1NyTBqYwES1tCF8N9dc 524UncFlqHzTPkOAOnqsY8zU3fFvurO8fFUeAcUM9lVhGwetyacD7g4VvwUC1DoVbK9i FvXzo1qMrqk8n4/93ZAdp+kBBrQFReUwZXa4dy7zn+5y0/DQMjhjYMhXfTH2sF8kgtf2 jAa23VPvVyLK95Hue3Z+I9PD3nNcXbFpN+Uj65GoziYyhJVcHM6Q4SzY3kwFGSJrQKfj kmlLXcI00pBGE/dB87WMmtd3W8B9mp0EFbALH6M9v4vOC0a9cnC5bdHoRUMj7EREQD3Y 8aYQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZBYof4Ot; 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=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e11si15509012ejq.437.2019.11.06.08.36.07; Wed, 06 Nov 2019 08:36:31 -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=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZBYof4Ot; 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=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728490AbfKFQeb (ORCPT + 99 others); Wed, 6 Nov 2019 11:34:31 -0500 Received: from us-smtp-2.mimecast.com ([205.139.110.61]:29173 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727570AbfKFQeb (ORCPT ); Wed, 6 Nov 2019 11:34:31 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1573058070; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=BQP7afY4/MZ7S29LaklU0C/wM1CnsMUrSv6g4R9XuMk=; b=ZBYof4OtXJDFD6DweJouqUJiEuHiGviNBOF89SbYzj7KJXYQV2xaBbYXY12JAKncLxKwTq Dxa+ZhvKpO8FEDKPSwWzA3YW/aTHqThqecF/wepDR4MoWlN9S1PRlNbmLpjSwpp+N+EN/J dll1BflTk9X1JgUhvWydJqt3JYeCdYc= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-60-BY5XieEJPmmFXSIGprnm5g-1; Wed, 06 Nov 2019 11:34:27 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 806F71800D53; Wed, 6 Nov 2019 16:34:26 +0000 (UTC) Received: from krava (ovpn-204-115.brq.redhat.com [10.40.204.115]) by smtp.corp.redhat.com (Postfix) with SMTP id 1FFDB5D726; Wed, 6 Nov 2019 16:34:24 +0000 (UTC) Date: Wed, 6 Nov 2019 17:34:24 +0100 From: Jiri Olsa To: Andi Kleen Cc: acme@kernel.org, jolsa@kernel.org, linux-kernel@vger.kernel.org, Andi Kleen Subject: Re: [PATCH v4 7/9] perf stat: Use affinity for opening events Message-ID: <20191106163424.GP30214@krava> References: <20191105002522.83803-1-andi@firstfloor.org> <20191105002522.83803-8-andi@firstfloor.org> MIME-Version: 1.0 In-Reply-To: <20191105002522.83803-8-andi@firstfloor.org> User-Agent: Mutt/1.12.1 (2019-06-15) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-MC-Unique: BY5XieEJPmmFXSIGprnm5g-1 X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Nov 04, 2019 at 04:25:20PM -0800, Andi Kleen wrote: SNIP > +} > + > void evsel__close(struct evsel *evsel) > { > =09perf_evsel__close(&evsel->core); > @@ -1832,9 +1839,10 @@ void evsel__close(struct evsel *evsel) > } > =20 > int perf_evsel__open_per_cpu(struct evsel *evsel, > -=09=09=09 struct perf_cpu_map *cpus) > +=09=09=09 struct perf_cpu_map *cpus, > +=09=09=09 int cpu) > { > -=09return evsel__open(evsel, cpus, NULL); > +=09return evsel__open_cpu(evsel, cpus, NULL, cpu, cpu + 1); > } > =20 > int perf_evsel__open_per_thread(struct evsel *evsel, > diff --git a/tools/perf/util/evsel.h b/tools/perf/util/evsel.h > index 2e3b011ed09e..d5440a928745 100644 > --- a/tools/perf/util/evsel.h > +++ b/tools/perf/util/evsel.h > @@ -94,6 +94,8 @@ struct evsel { > =09struct evsel=09=09*metric_leader; > =09bool=09=09=09collect_stat; > =09bool=09=09=09weak_group; > +=09bool=09=09=09reset_group; > +=09bool=09=09=09errored; would be great to move some of the changes into separate patches, it seems all related to new code, but would ease up the review like these 2 bools above or adding cpu to create_perf_stat_counter and adding evsel__open_cpu funtion and related changes thanks, jirka