Message ID | 20211230072030.302559-2-irogers@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 36BFEC433F5 for <linux-arm-kernel@archiver.kernel.org>; Thu, 30 Dec 2021 07:22:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:From:Subject:References: Mime-Version:Message-Id:In-Reply-To:Date:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=+OqKgMjIkcEvUMHFugtpSS9oqL4vj2H742g6rKaezSc=; b=ChMrGmMro7WyEZHwVatdomuNMi 6NgPO/1FqYLi2d07CLUfBI79SX3xGwy3DCdskQcf+PsMKHqDMbs2ewKMD/EsgXvQLxjasCvy7RaL0 419i8l4x/ah9jt0HUxni+lhdwbOx14dHQy84TLdrZ8QaVSW4oFjM4rFEx45WHN8LK5WeyEFHBGUkT yUNO9C+iLJL8Uf4m45E7vCMSoD39l2Had0uv8N1+0F1gH/4SDoM9LNgap6aS+CxD+t0J3jy13AJHi wGtIRXHcSk2/Jroj4IPAO5tkhhBLyLXIRxIf6j/vjJSJoR8LoTmQg95RIUySOdOMXv7eL5SywQKw9 b0moUesw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1n2pk4-003jTb-8f; Thu, 30 Dec 2021 07:20:52 +0000 Received: from mail-yb1-xb4a.google.com ([2607:f8b0:4864:20::b4a]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1n2pjs-003jPH-I6 for linux-arm-kernel@lists.infradead.org; Thu, 30 Dec 2021 07:20:41 +0000 Received: by mail-yb1-xb4a.google.com with SMTP id c5-20020a25f305000000b0060bbdf755f7so25223110ybs.14 for <linux-arm-kernel@lists.infradead.org>; Wed, 29 Dec 2021 23:20:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=date:in-reply-to:message-id:mime-version:references:subject:from:to :cc; bh=R/ciplz7o8MJIByj4LFS+saOMsnt5V7JtjWFtjIV8fs=; b=hOnDJwZL1uLASJfxt16LE8RbyfAliT6lWhtat21Tok3eL5nEi56QviZgxbrBWkjbvH XcDTOXrfk8KXWSKd/gcxHMDBj8SDtjaQmSDkLF9iI1VtzccOrmo7SKYvF6BdZlEwhkjQ G52a+98JImuc8mE1Iu2+xNB5BY/m2ySBaJFm2e+nI+qUeCpD/NiVam89g+z03DkHfQWr kBkGfTlR3zL8pyYjAmdMbgLdMwagtqYMwfpD/bHcS9dibJZ6T0GjuIaKJP1TdvTHEZUt NCr4gAa47x5rn1N5jy478QfHJXvdXM61fjflTU+q5UEdUTdq+BaOzMnmqs0t8N5+FP67 HCkA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=R/ciplz7o8MJIByj4LFS+saOMsnt5V7JtjWFtjIV8fs=; b=gceR3UiAzqCjfRPA7yD4eITW3bMsmTDIYiiMcx/vTeskxhM42LB390KDomcFBMNwmI hzN+eSHliR3szXuqV2LPHWqfLfbTiXzbL9U3MWAYWTo8n788W47WfpK0+qokuEicCsCr vmS3e+rA1aHVrbCOsr1FbELLGSsOgzqfWUqX11iOBlXfVtGhZuCIEzbkZ7jH6Yz17I79 8e3MYYh2e8L//pF971jti8YQF5c/Avs7tiubNvQ8ZmF9EV7MCD7fEkM6JTQlRZdQ9LLg wuV8D0vYGqc7bwv6tDuRhx5vDz/1/ZIv907sdsMhV+wAo8t5Vtt1r1xAoZH3DZ1MHdOf snQQ== X-Gm-Message-State: AOAM531/fbBlAl8hqDYbUonUy3N01ee4UnYx0OUSVhC4h5xq5goIsrt5 BiZN0/r9YvMekS1RQlN7azkrKjUSe4fl X-Google-Smtp-Source: ABdhPJz0suG/e7yZrpxzUx3hVM4B9b7DWdq9+GCwNAbOY3zjXSahtZ9HZi+mnDCm0FVN8zGn882k7ziDe8sp X-Received: from irogers.svl.corp.google.com ([2620:15c:2cd:202:31c4:9539:dba1:a82b]) (user=irogers job=sendgmr) by 2002:a5b:c01:: with SMTP id f1mr38085796ybq.47.1640848838463; Wed, 29 Dec 2021 23:20:38 -0800 (PST) Date: Wed, 29 Dec 2021 23:19:42 -0800 In-Reply-To: <20211230072030.302559-1-irogers@google.com> Message-Id: <20211230072030.302559-2-irogers@google.com> Mime-Version: 1.0 References: <20211230072030.302559-1-irogers@google.com> X-Mailer: git-send-email 2.34.1.448.ga2b2bfdf31-goog Subject: [PATCH v3 01/48] libperf: Add comments to perf_cpu_map. From: Ian Rogers <irogers@google.com> To: Andi Kleen <ak@linux.intel.com>, Jiri Olsa <jolsa@redhat.com>, Namhyung Kim <namhyung@kernel.org>, John Garry <john.garry@huawei.com>, Kajol Jain <kjain@linux.ibm.com>, "Paul A . Clarke" <pc@us.ibm.com>, Arnaldo Carvalho de Melo <acme@kernel.org>, Riccardo Mancini <rickyman7@gmail.com>, Kan Liang <kan.liang@linux.intel.com>, Peter Zijlstra <peterz@infradead.org>, Ingo Molnar <mingo@redhat.com>, Mark Rutland <mark.rutland@arm.com>, Alexander Shishkin <alexander.shishkin@linux.intel.com>, linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, Vineet Singh <vineet.singh@intel.com>, James Clark <james.clark@arm.com>, Mathieu Poirier <mathieu.poirier@linaro.org>, Suzuki K Poulose <suzuki.poulose@arm.com>, Mike Leach <mike.leach@linaro.org>, Leo Yan <leo.yan@linaro.org>, coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, zhengjun.xing@intel.com Cc: eranian@google.com, Ian Rogers <irogers@google.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211229_232040_618079_BCFE248A X-CRM114-Status: GOOD ( 12.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
Refactor perf cpumap
|
expand
|
diff --git a/tools/lib/perf/include/internal/cpumap.h b/tools/lib/perf/include/internal/cpumap.h index 840d4032587b..4054169c12c5 100644 --- a/tools/lib/perf/include/internal/cpumap.h +++ b/tools/lib/perf/include/internal/cpumap.h @@ -4,9 +4,18 @@ #include <linux/refcount.h> +/** + * A sized, reference counted, sorted array of integers representing CPU + * numbers. This is commonly used to capture which CPUs a PMU is associated + * with. The indices into the cpumap are frequently used as they avoid having + * gaps if CPU numbers were used. For events associated with a pid, rather than + * a CPU, a single dummy map with an entry of -1 is used. + */ struct perf_cpu_map { refcount_t refcnt; + /** Length of the map array. */ int nr; + /** The CPU values. */ int map[]; };