Received: by 2002:ab2:7041:0:b0:1f4:bcc8:f211 with SMTP id x1csp1717lql; Fri, 12 Apr 2024 01:23:14 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUPmUNsFe18zqNSk/EIxLtDmiqaMy2H6jYObSNQI9O5yz4ffsqnSWCFLXFWGrs5PW0035x+7zvJOUVXm8GRTBOyH7EQhywl1xwsFBmsEg== X-Google-Smtp-Source: AGHT+IFc3JzKs7EvdBpwiMj9N77EjBFi2FjxyX+bQRv/pdEWZ0u0NG8W0GxzolD9LcyZyP9aQCmE X-Received: by 2002:a17:902:d481:b0:1e3:cfc5:589c with SMTP id c1-20020a170902d48100b001e3cfc5589cmr2053424plg.28.1712910194022; Fri, 12 Apr 2024 01:23:14 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712910194; cv=pass; d=google.com; s=arc-20160816; b=OGAKgOo7etk3VppH9scftIo4X5BMJkyz6OjrzbEWpXrbiAf5L9Fm1o67pLqB4fecUM kAKqyhA4GGCYAkXBIam4cpdUWCs1eClXYLYHJTfxYDEBEoXFPQp0qHX1NT8/bVUlGY+y FKFplFCVJK8TZU7U4i5X+bQKDowfzBYCi0nj1+NiWVUxxe89w0/7BHBfiReBNXpcH0rm s1KHElICP+s+LCUPxZcjVSu1l7JKJJ0qw6J+OlH4Q7RMOmQTyQRipitcC5DESlRYlIUJ tdDDpBL8Eebcu5Wql6JZPg2hPzSiOO2fx08uBqV/OwYlqK2PmY2WcFpjs5X85YvShIkG E+Bw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=IlP1+4PddepzPXhEMUuofK14LjnPxuooMWIpNnOvRkk=; fh=nUreRhHgsJMASWdTZMTCFYUXUWUeVxv/8IoaJ1DUKpk=; b=U80gbTl6+qu+9DFdqRSh3ilgoOl42cmkfJtxrICxa01Y0Ud56EtnBwbHEinO7FfYcT Q/hsZVNUKPmW83zasb70sS0Wf/CeCrOKVxsj3HH1CEncMRiAbRIN2Yt3Msupp3kTGPbE Z/LbpWfAYK1qJdFqZdtJefwrOYXOp8pbckCiXUiO8Qxv+DT8I3EdCEkGKinj4wazwlAZ 6iFkWGIM4ZkLsgVrFxFc68RQnx9n54RsGsM0fvoNX//pQbi4RViYyrcq6QZu/v5AMc1f iApsG9LfFWWCK3es8BBBmWhzDV3sBr/bqlsWXvjEf1ak9mDalP3o5b8/ZKuX29cKOe3d BkpA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-142229-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-142229-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id b17-20020a170902e95100b001e20290828fsi2728630pll.637.2024.04.12.01.23.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 01:23:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-142229-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-142229-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-142229-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 861D7282D1C for ; Fri, 12 Apr 2024 08:22:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C8C5A5027F; Fri, 12 Apr 2024 08:22:32 +0000 (UTC) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 87964502B2; Fri, 12 Apr 2024 08:22:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712910152; cv=none; b=kSBsiAb43wNcm5OxH24qu9hDz4rC5x87QsEHxiVB9h2gRPjLc/vNNyD4S2AoFDLjaLEfLBPnkSQVJi6IEjdTHHQwPwpxB70SvTpQfDUaaaOt0ziaLDHG8fkjfXXdv8yE7fvaVxzg5Ol7vysRTIpS90PaWy2AwTJjuieNlLpbA84= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712910152; c=relaxed/simple; bh=peYTgt9uBIcWrdPc00owGJXHu/yjGHl8jXUFuJL+vS4=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=flWnQfM8oNMNuQ9u3K/o5XT3Jq6Iq0cX92ktP6Irgbb1RU/ygnveF9aQsEb9TEZDQqqMtR/0rvfFsUYU9ORqx/8jzzwgj4danT6svOasXeTJK38MnPM8kph9wVc0NBuL8zKb8//jLLZBM/bSe004BPgQuoA19YSGWiKYM9kRZzk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 16402339; Fri, 12 Apr 2024 01:22:58 -0700 (PDT) Received: from [192.168.1.100] (usa-sjc-mx-foss1.foss.arm.com [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 069173F6C4; Fri, 12 Apr 2024 01:22:26 -0700 (PDT) Message-ID: <7f5c32dd-edc6-4b53-9cdd-780756f5536c@arm.com> Date: Fri, 12 Apr 2024 09:22:25 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] perf test: Increase buffer size for Coresight basic tests To: Anshuman Khandual , linux-perf-users@vger.kernel.org Cc: Mike Leach , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Namhyung Kim , Mark Rutland , Alexander Shishkin , Jiri Olsa , Ian Rogers , Adrian Hunter , coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <20240326113749.257250-1-james.clark@arm.com> <5a4023aa-af9b-48d2-84f3-a0b9b30dc54e@arm.com> Content-Language: en-US From: James Clark In-Reply-To: <5a4023aa-af9b-48d2-84f3-a0b9b30dc54e@arm.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 12/04/2024 08:04, Anshuman Khandual wrote: > > > On 3/26/24 17:07, James Clark wrote: >> These tests record in a mode that includes kernel trace but look for >> samples of a userspace process. This makes them sensitive to any kernel >> compilation options that increase the amount of time spent in the >> kernel. If the trace buffer is completely filled before userspace is >> reached then the test will fail. Double the buffer size to fix this. > > This is a valid concern to address, but just wondering how did we arrive > at the conclusion that doubling the buffer size i.e making that 8M will > solve the problem positively for vast number of kerne build scenarios ? > Nobody else has reported anything yet, if it happens again we can always increase it again if that is what the issue is. I had most of the kernel debugging stuff turned on like memory debugging etc, which is probably why I ran into it and 8MB fixed it for me. So I'm not sure if there is much more that could be added. >> >> The other tests in the same file aren't sensitive to this for various >> reasons, for example the iterate devices test filters by userspace >> trace only. But in order to keep coverage of all the modes, increase the >> buffer size rather than filtering by userspace for the basic tests. >> >> Fixes: d1efa4a0a696 ("perf cs-etm: Add separate decode paths for timeless and per-thread modes") >> Signed-off-by: James Clark >> --- >> tools/perf/tests/shell/test_arm_coresight.sh | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/tools/perf/tests/shell/test_arm_coresight.sh b/tools/perf/tests/shell/test_arm_coresight.sh >> index 65dd85207125..3302ea0b9672 100755 >> --- a/tools/perf/tests/shell/test_arm_coresight.sh >> +++ b/tools/perf/tests/shell/test_arm_coresight.sh >> @@ -188,7 +188,7 @@ arm_cs_etm_snapshot_test() { >> >> arm_cs_etm_basic_test() { >> echo "Recording trace with '$*'" >> - perf record -o ${perfdata} "$@" -- ls > /dev/null 2>&1 >> + perf record -o ${perfdata} "$@" -m,8M -- ls > /dev/null 2>&1 >> >> perf_script_branch_samples ls && >> perf_report_branch_samples ls &&