From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1BB65C32772 for ; Tue, 23 Aug 2022 17:32:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232212AbiHWRcn (ORCPT ); Tue, 23 Aug 2022 13:32:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54308 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237624AbiHWRbu (ORCPT ); Tue, 23 Aug 2022 13:31:50 -0400 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 44A4C106F9C; Tue, 23 Aug 2022 08:11:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1661267468; x=1692803468; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=jjiwMuWeqdFPYRf2a09O9x3igdhPit5rsRrfCbx9zoY=; b=fmTXMMC13lK4LLM7CAZCddwLfpuL9AI9HWCFC7aPpU1NkBfM1fiwHUxj ulAVl5wbwvaDnNtQ3stSSSFLPQqpjz4X5LvVyu0woE5MUSqmJdg5UnaJq PWzPINHpd/KaCIkeGXMlMcgLoy+KpvU4zkJYa7NLisycE3YuhkGDth2+/ rZBHAnpSAqfnfqocprfLm6imwsGh9gVECNR8BKcI78dh/+mIG7BMaO8Qy vFKhRUE63aJs6jY/XHISNRdA8frzefXPXZWn2LFMxFzYztt7F9fSbt+NL 6vepOtys5A6/EA9rRPxjrvJdG/ZHxfTfWWtIbBlhMPKSASpa38zq1HUx7 Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10448"; a="294502943" X-IronPort-AV: E=Sophos;i="5.93,258,1654585200"; d="scan'208";a="294502943" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Aug 2022 08:10:56 -0700 X-IronPort-AV: E=Sophos;i="5.93,258,1654585200"; d="scan'208";a="586027125" Received: from akleen-mobl1.amr.corp.intel.com (HELO [10.212.239.19]) ([10.212.239.19]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Aug 2022 08:10:55 -0700 Message-ID: Date: Tue, 23 Aug 2022 17:10:55 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.12.0 Subject: Re: [PATCH v1 1/2] perf stat: Clear reset_group for each stat run Content-Language: en-US To: Ian Rogers , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Kan Liang , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Stephane Eranian References: <20220822213352.75721-1-irogers@google.com> From: Andi Kleen In-Reply-To: <20220822213352.75721-1-irogers@google.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-perf-users@vger.kernel.org On 8/22/2022 11:33 PM, Ian Rogers wrote: > If a weak group is broken then the reset_group flag remains set for > the next run. Having reset_group set means the counter isn't created > and ultimately a segfault. > > A simple reproduction of this is: > perf stat -r2 -e '{cycles,cycles,cycles,cycles,cycles,cycles,cycles,cycles,cycles,cycles}:W > which will be added as a test in the next patch. > > Fixes: 4804e0111662 ("perf stat: Use affinity for opening events") > Signed-off-by: Ian Rogers Makes sense Reviewed-by: Andi Kleen