Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp1000013rdb; Wed, 24 Jan 2024 01:26:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IGddNLDK9YYY9UlS3a/G157QyEPTYeujTI7OB9+4+l8QfjIW6jF64v1JL67J74HRptDEngj X-Received: by 2002:ac8:4e48:0:b0:42a:5d05:1964 with SMTP id e8-20020ac84e48000000b0042a5d051964mr695829qtw.89.1706088410346; Wed, 24 Jan 2024 01:26:50 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706088410; cv=pass; d=google.com; s=arc-20160816; b=ODdBfHKjBYwXbtoS6Lm0sOvGq13IsU8JwWxRRefISPK9N2BeqVVcCMmzo894za+hF/ J5Fp/JN6U8SL19QO4VljqClYec3T+InVx4kSmBaG1D74dsxjyti9PHp5toq3KMrOShn4 YWnOX9YeVG8nL+1/KYmAsp/TEyihx3LXMkFyS9NS47DjjxtI2ADDueSDP7QH9CAvansr GNt6eRPE7QqgbWsOb6KC0tz3TTOmIrCKQIO1STtsbNrxZ7DY7eiP6PBlkvQdRTOXU1BC PYho5UShCH9AF5OUwBzNsoGXvVMJBSW/nrhAT0XQ2AvTLHywkGAQUi2v16gShVRtDCDY R6mw== 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:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=E17rQ55Kkl1GF5ix0v0Fh7pozOwzbNGD2PUcFi33T54=; fh=b9B+ImQqLI0rt2mGH2o79cuMt/PpTyRCc3URkKolKoc=; b=nyzLgr8y4ep1Vfyb8MsR4yOFzncaZp0A8iuT27e8rw3Gfz8PUD9HkVAo05/3BRQwgj hDNXkKP5yA7PveyUUx+pvQcmwkEIN6PAPiSEbfUosAiumWrkWqRy8iRA6Sn4kLKRcCC7 QpSlBGWbODr0v4Ah/SE7QDx9b2gsqcaR+VzFWp0/xJ3GpxhKcnTFTRlMcPOpE+lUyPVw Qrle4T1wKzt/dRfuG2W3Li9UzvWM30XPjrS2qAQ2D8mDHGWNn3kUs5JbQwyAsM5vD8XR uccLQBGRms4MgMd9zL6OM980vMIU9/1eecxtnbwKdAdZYZI+NJdpbtZAWD82OTKaOtqA VsGw== 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-36714-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-36714-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id z16-20020a05622a061000b004297543e51bsi10035805qta.679.2024.01.24.01.26.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Jan 2024 01:26:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-36714-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; 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-36714-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-36714-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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 0D1881C20AE6 for ; Wed, 24 Jan 2024 09:26:50 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6BD7718622; Wed, 24 Jan 2024 09:24:21 +0000 (UTC) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A629418E1A; Wed, 24 Jan 2024 09:24:18 +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=1706088260; cv=none; b=VOpEUqTQR6cr1XQhZMvwrPrrGZoRyqWgN7IxH17wmFuAEx+kNbGX6FVl4Sxka6d4rtlvK64ji71cKQft+TbASkV+qFC3CcM53JOKFYf71h12Ppzh014svhhMwO9rXr3wXUfrRazNOnf55XBIqFiNyrSkrrNVcQ2k2swOMG/YqSU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706088260; c=relaxed/simple; bh=Q6a5FvIQhKrjJBTVn7WeECsxsSrv+lamt5P5SCz3wUk=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=YgEaHbxqKWxhCxDSHOc52XrRS/7nu2SIEc9xYuCYiCqP4ZryAxnnoGtGxgWjTOPkG2DMHA6UzY1R7HAxyXBWM8ZpUSQH4l3A2myceoUVVH/rx6pJ8BpdGPbNJjkTuPr1Dbnn3GJqXzjeNcBqonXn00qwRpaQo0NHPclKcv5HwSU= 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 310C0FEC; Wed, 24 Jan 2024 01:25:03 -0800 (PST) Received: from [10.57.86.221] (unknown [10.57.86.221]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 5C8963F762; Wed, 24 Jan 2024 01:24:16 -0800 (PST) Message-ID: Date: Wed, 24 Jan 2024 09:24:14 +0000 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.15.1 Subject: Re: [PATCH 2/2] perf test: Skip test_arm_callgraph_fp.sh if unwinding isn't built in Content-Language: en-US To: Ian Rogers Cc: linux-perf-users@vger.kernel.org, Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Namhyung Kim , Mark Rutland , Alexander Shishkin , Jiri Olsa , Adrian Hunter , Kajol Jain , Spoorthy S , linux-kernel@vger.kernel.org References: <20240123163903.350306-1-james.clark@arm.com> <20240123163903.350306-3-james.clark@arm.com> From: James Clark In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 23/01/2024 17:41, Ian Rogers wrote: > On Tue, Jan 23, 2024 at 8:39 AM James Clark wrote: >> >> Even though this is a frame pointer unwind test, it's testing that a >> frame pointer stack can be augmented correctly with a partial >> Dwarf unwind. So add a feature check so that this test skips instead of >> fails if Dwarf unwinding isn't present. > > Hi James, > > Is there value in testing without the partial Dwarf unwind? Presumably Yeah I think we could add a test for just --call-graph=fp, I don't think there is one. But that would be separate to this test, and would be redundant if the tests are run with a dwarf unwinder present because this test already requires the frame pointer unwinder to be correct. > that is covered by the existing dwarf unwind test? There is no overlap, this test test is for --call-graph=fp, and the dwarf test is for --call-graph=dwarf > https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git/tree/tools/perf/tests/dwarf-unwind.c?h=perf-tools-next > If the issue is inlined functions I'm surprised addr2line isn't doing > the job properly. Is there an addr2line perf script issue here? > The issue isn't inlined functions, it's when the leaf frame doesn't insert a frame pointer. In that case we use the link register to see what the parent function of the leaf frame was and insert it into the frame pointer stack. Dwarf is only used in this case to confirm if the link register was valid at that instruction. See commit b9f6fbb for more info. Long story short this test was only added for that feature and it requires a dwarf unwinder to pass despite being called test_arm_callgraph_fp > Thanks, > Ian > >> Signed-off-by: James Clark >> --- >> tools/perf/tests/shell/test_arm_callgraph_fp.sh | 6 ++++++ >> 1 file changed, 6 insertions(+) >> >> diff --git a/tools/perf/tests/shell/test_arm_callgraph_fp.sh b/tools/perf/tests/shell/test_arm_callgraph_fp.sh >> index e342e6c8aa50..83b53591b1ea 100755 >> --- a/tools/perf/tests/shell/test_arm_callgraph_fp.sh >> +++ b/tools/perf/tests/shell/test_arm_callgraph_fp.sh >> @@ -8,6 +8,12 @@ shelldir=$(dirname "$0") >> >> lscpu | grep -q "aarch64" || exit 2 >> >> +if perf version --build-options | grep HAVE_DWARF_UNWIND_SUPPORT | grep -q OFF >> +then >> + echo "Skipping, no dwarf unwind support" >> + exit 2 >> +fi >> + >> skip_test_missing_symbol leafloop >> >> PERF_DATA=$(mktemp /tmp/__perf_test.perf.data.XXXXX) >> -- >> 2.34.1 >>