Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp173691rdh; Thu, 23 Nov 2023 00:02:47 -0800 (PST) X-Google-Smtp-Source: AGHT+IFYoEeGyIT4SOTvcer+ggZ2OFRwE/BWGnsiHFW5onM2NZYqV15TcnoktR5k21flEt4+E2OE X-Received: by 2002:a17:903:1252:b0:1cc:6078:52ff with SMTP id u18-20020a170903125200b001cc607852ffmr2882876plh.26.1700726566977; Thu, 23 Nov 2023 00:02:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700726566; cv=none; d=google.com; s=arc-20160816; b=0R4gYXBuumD+U7K5/vvXlZeSO69OwgvMAf1yd5D2Pj+Q0WnJgQUNs+J1O2e5Ohhs6q eZvS1aWHpawf95CpC6neHWzEGOeREg6Mw7Qfny8K/qS20pefrDuWRau8CKFX5J36330j iqpqLJmPnYHh3ax1c7ErVpzj0yz0wywaT1OeFA3dS5Sf1pCdcDvUspeuJ2wBXBuNBOgR qkmKgFWp3au5RPcjx9+A+M3I4SgI+r/fxe02+K5HfHO1qS00LWAMLJWZguquKyci1Jd2 1yRUqF8Zw7oHPQYeOnc8O0egOZbSCr41IIyiMcXx4af4f90oxWknHdPQSsoGKWof/G7S D5Kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:organization :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=vBa2/HGdh85N9TZifW3P5OEtKiycFqOTEXumW1wXnYc=; fh=TPQr4nff5QO7OKSg4AL08iZb9B1RwOBx3bV3jWC0cDE=; b=fDDJS2We4O1ITCFMwqnTW4CL9Ivz39+oIYf55D/pMiWr82YuZQKWNfBJQki74OFotI lXju05/D0lvAdZNcmmSRbNeHDuRruqMhbZ08cMk21YMwYRilbvjmFIn95MS/HaDDp60t EACYaQ8F5kvtYvfuPAThRDcMEfJeV82PgigPjOXDRVa3EQhtd+W37kh9y6GazpUGxaXM eFzVEvzxBkQ0KiBnq4S5vBhTbgTLiQaV4vXlKf9Xb6SGx+fsCbZ0/ZEEYJ5gUA0XZ/Qa HgEWppLNYx6ZotvoNYGdhyW+wfSKC+erjkupo9AHl5jjJkN7h+Bvs6P7yRWF/9WSw1/4 Xzvg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="YE3/DL8f"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id f15-20020a170902ab8f00b001cf75ba66e6si618443plr.580.2023.11.23.00.02.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 00:02:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="YE3/DL8f"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 507AC8087FF0; Thu, 23 Nov 2023 00:00:34 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235027AbjKWH7i (ORCPT + 99 others); Thu, 23 Nov 2023 02:59:38 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39830 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234509AbjKWH7Y (ORCPT ); Thu, 23 Nov 2023 02:59:24 -0500 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 12E9B1B3; Wed, 22 Nov 2023 23:59:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1700726371; x=1732262371; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=nk3gCy6p2GL7PvwIZ2K6eYMQde7iUIS5gU74LC1oz/E=; b=YE3/DL8f4MkfppPNYFWCg3tS1Vbf4/cYmAHuV/acTtsthUhh2uOn8cr7 3u6vWLQ3qS97VPkUpuc08I/9fZP0qsBQ94gM9qy3oGFnEBPe3lgIbSLBd si70Vmdo3/AhqimHPx4uOZq600cwKEJl3gtj0yMaq06fgACDO7SwEe35U P1WzkCWQUVdcjieGVmN8WL+uLj4/K1yGsj/Ffj6uSlajZw/7Tw9n57rmR pIHuLUMFtUdvL/NkwP0gDccIN3vmqPg1Tzc1VoC1q3H4aPeXkl2uKyME8 eLLVKJUYtrUGarTV+OXHqaylu0acOWKTr+DZt3jHfoORtRfD47LMR0lTB A==; X-IronPort-AV: E=McAfee;i="6600,9927,10902"; a="396126427" X-IronPort-AV: E=Sophos;i="6.04,221,1695711600"; d="scan'208";a="396126427" Received: from fmviesa002.fm.intel.com ([10.60.135.142]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Nov 2023 23:59:29 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.04,221,1695711600"; d="scan'208";a="8764987" Received: from ahunter6-mobl1.ger.corp.intel.com (HELO ahunter-VirtualBox.home\044ger.corp.intel.com) ([10.252.41.107]) by fmviesa002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Nov 2023 23:59:11 -0800 From: Adrian Hunter To: Arnaldo Carvalho de Melo Cc: Jiri Olsa , Namhyung Kim , Ian Rogers , James Clark , German Gomez , Leo Yan , linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org Subject: [PATCH 3/8] perf tests: Skip pipe test if noploop symbol is missing Date: Thu, 23 Nov 2023 09:58:43 +0200 Message-Id: <20231123075848.9652-4-adrian.hunter@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231123075848.9652-1-adrian.hunter@intel.com> References: <20231123075848.9652-1-adrian.hunter@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy, Registered Address: PL 281, 00181 Helsinki, Business Identity Code: 0357606 - 4, Domiciled in Helsinki Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Thu, 23 Nov 2023 00:00:34 -0800 (PST) perf pipe recording and injection test depends on finding symbol noploop in perf, and fails if perf has been stripped and no debug object is available. In that case, skip the test instead. Example: Before: $ strip tools/perf/perf $ tools/perf/perf buildid-cache -p `realpath tools/perf/perf` $ tools/perf/perf test -v pipe 86: perf pipe recording and injection test : --- start --- test child forked, pid 47734 [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.000 MB - ] 47741 47741 -1 |perf [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.000 MB - ] cannot find noploop function in pipe #1 test child finished with -1 ---- end ---- perf pipe recording and injection test: FAILED! After: $ tools/perf/perf test -v pipe 86: perf pipe recording and injection test : --- start --- test child forked, pid 48996 perf does not have symbol 'noploop' perf is missing symbols - skipping test test child finished with -2 ---- end ---- perf pipe recording and injection test: Skip Signed-off-by: Adrian Hunter --- tools/perf/tests/shell/pipe_test.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tools/perf/tests/shell/pipe_test.sh b/tools/perf/tests/shell/pipe_test.sh index 8dd115dd35a7..a78d35d2cff0 100755 --- a/tools/perf/tests/shell/pipe_test.sh +++ b/tools/perf/tests/shell/pipe_test.sh @@ -2,10 +2,17 @@ # perf pipe recording and injection test # SPDX-License-Identifier: GPL-2.0 +shelldir=$(dirname "$0") +# shellcheck source=lib/perf_has_symbol.sh +. "${shelldir}"/lib/perf_has_symbol.sh + +sym="noploop" + +skip_test_missing_symbol ${sym} + data=$(mktemp /tmp/perf.data.XXXXXX) prog="perf test -w noploop" task="perf" -sym="noploop" if ! perf record -e task-clock:u -o - ${prog} | perf report -i - --task | grep ${task}; then echo "cannot find the test file in the perf report" -- 2.34.1