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 X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 02C16C433E0 for ; Mon, 25 Jan 2021 11:11:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B6CB021744 for ; Mon, 25 Jan 2021 11:11:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727629AbhAYLLL (ORCPT ); Mon, 25 Jan 2021 06:11:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56710 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727727AbhAYLDh (ORCPT ); Mon, 25 Jan 2021 06:03:37 -0500 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E59CCC061794 for ; Mon, 25 Jan 2021 03:02:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=r+KBxMybDr1usbcaCcE0TrdbPjsSTRmFRC4Jt2BrQRs=; b=OiLH56of5BgccSMXzjF2EGN2UD /4bkt5n+QSXgGZbZtrySPl7T1ID/FYOMQ9iwE6t7w49GIAiN0rpkS1l6+MsoI+opT90Kfh3yPa0kS xIbZAx6CUQm4wxGu1W3Hinon+rXNTp6q0cTjygtg94Vjyo5w1gSkLwk8UuG+rmYf2LiFRuVbFBwrT uCNLXwgxgEBxd1QJCPtAaX31Fmc341rjxCBYWMGRnRv2NPpImQrlB++OCrrgjSJULbuHv9hAg+qzM 3xWmOWeVfSlZ+CA6VQ8iuGhxYghY/nRZ6ifBQrMF+de9HQwsMdqN83uwM0J0vEh7E0f0U68U9ql8y qjOk9Dyw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1l3zd7-0046vd-70; Mon, 25 Jan 2021 11:02:00 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 76E0C300DB4; Mon, 25 Jan 2021 12:01:56 +0100 (CET) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 3C50F207D3C61; Mon, 25 Jan 2021 12:01:56 +0100 (CET) Date: Mon, 25 Jan 2021 12:01:56 +0100 From: Peter Zijlstra To: Suzuki K Poulose Cc: Alexander Shishkin , linux-kernel@vger.kernel.org, coresight@lists.linaro.org, Ingo Molnar , will@kernel.org, mark.rutland@arm.com, mike.leach@linaro.org, al.grant@arm.com, anshuman.khandual@arm.com, mathieu.poirier@linaro.org, linux-arm-kernel@lists.infradead.org, jolsa@redhat.com, acme@kernel.org Subject: Re: [RFC PATCH] perf: Handle multiple formatted AUX records Message-ID: References: <20210122151829.2890484-1-suzuki.poulose@arm.com> <20210122151829.2890484-2-suzuki.poulose@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jan 25, 2021 at 10:45:06AM +0000, Suzuki K Poulose wrote: > On 1/25/21 10:25 AM, Peter Zijlstra wrote: > > Since we have a whole u64, do we want to reserve a whole nibble (or > > maybe even a byte) for a format type? Because with a single bit like > > this, we'll kick ourselves when we end up with the need for a 3rd format > > type. > > > > Sure, makes sense. We could do: > > #define PERF_AUX_FLAG_PMU_FORMAT_TYPE_MASK 0xff00 > > Additionally, the values could be allocated by individual PMUs and > interpreted by the corresponding counterpart. That way we don't > have to worry about centralized allocation of the "TYPE" fields. > > e,g: > > #define PERF_AUX_FLAG_CORESIGHT_FORMAT_CORESIGHT 0x0000 > #define PERF_AUX_FLAG_CORESIGHT_FORMAT_RAW 0x0100 > > #define PERF_AUX_FLAG_RANDOM_PMU_FORMAT_FMT1 0x0000 > #define PERF_AUX_FLAG_RANDOM_PMU_FORMAT_FMT2 0x0100 > > > What do you think ? Sounds good to me. 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 X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1378DC433DB for ; Mon, 25 Jan 2021 11:03:49 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9C51722582 for ; Mon, 25 Jan 2021 11:03:48 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9C51722582 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=0KpdIxa2FABn5maasAWht/HLJ+2Z+4+r0CgPBv+Xo8A=; b=u9HEccwQFjMcQu3Fiv9n2Vf3H kVEFdgwkIsq/DZw/ukvBZ2l68fvBzugd+o8JqsAi7POr0u/XbvH37avyTScRvHvUghZEim6P2YHLt EB/JIDrCx5KsuU+DYw7R+ytnhc2CKQpZRoDR1c3NY8UKQsdY4vGj6dBfIyUenOaNVlOJ2tJUiX1bV 4+ZeVZ4ATO3A1mfCwnvP820lgXXhdKaHiksKWgffJOtpMzK63dFBe/dJMEu/8z63M69iXsII3DZax 0E8illULH2saDcrtXkbZf2mYHN+bhXElFGpayKgtmhC8mFYHmS8dEwBfsQh6PSfDmo6Ov8SkkPDtL YVOQv0K/g==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l3zdK-0005YE-HW; Mon, 25 Jan 2021 11:02:10 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1l3zdH-0005Xz-Ic for linux-arm-kernel@merlin.infradead.org; Mon, 25 Jan 2021 11:02:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=r+KBxMybDr1usbcaCcE0TrdbPjsSTRmFRC4Jt2BrQRs=; b=OiLH56of5BgccSMXzjF2EGN2UD /4bkt5n+QSXgGZbZtrySPl7T1ID/FYOMQ9iwE6t7w49GIAiN0rpkS1l6+MsoI+opT90Kfh3yPa0kS xIbZAx6CUQm4wxGu1W3Hinon+rXNTp6q0cTjygtg94Vjyo5w1gSkLwk8UuG+rmYf2LiFRuVbFBwrT uCNLXwgxgEBxd1QJCPtAaX31Fmc341rjxCBYWMGRnRv2NPpImQrlB++OCrrgjSJULbuHv9hAg+qzM 3xWmOWeVfSlZ+CA6VQ8iuGhxYghY/nRZ6ifBQrMF+de9HQwsMdqN83uwM0J0vEh7E0f0U68U9ql8y qjOk9Dyw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1l3zd7-0046vd-70; Mon, 25 Jan 2021 11:02:00 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 76E0C300DB4; Mon, 25 Jan 2021 12:01:56 +0100 (CET) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 3C50F207D3C61; Mon, 25 Jan 2021 12:01:56 +0100 (CET) Date: Mon, 25 Jan 2021 12:01:56 +0100 From: Peter Zijlstra To: Suzuki K Poulose Subject: Re: [RFC PATCH] perf: Handle multiple formatted AUX records Message-ID: References: <20210122151829.2890484-1-suzuki.poulose@arm.com> <20210122151829.2890484-2-suzuki.poulose@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, al.grant@arm.com, mathieu.poirier@linaro.org, anshuman.khandual@arm.com, Alexander Shishkin , jolsa@redhat.com, coresight@lists.linaro.org, linux-kernel@vger.kernel.org, acme@kernel.org, Ingo Molnar , will@kernel.org, linux-arm-kernel@lists.infradead.org, mike.leach@linaro.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Jan 25, 2021 at 10:45:06AM +0000, Suzuki K Poulose wrote: > On 1/25/21 10:25 AM, Peter Zijlstra wrote: > > Since we have a whole u64, do we want to reserve a whole nibble (or > > maybe even a byte) for a format type? Because with a single bit like > > this, we'll kick ourselves when we end up with the need for a 3rd format > > type. > > > > Sure, makes sense. We could do: > > #define PERF_AUX_FLAG_PMU_FORMAT_TYPE_MASK 0xff00 > > Additionally, the values could be allocated by individual PMUs and > interpreted by the corresponding counterpart. That way we don't > have to worry about centralized allocation of the "TYPE" fields. > > e,g: > > #define PERF_AUX_FLAG_CORESIGHT_FORMAT_CORESIGHT 0x0000 > #define PERF_AUX_FLAG_CORESIGHT_FORMAT_RAW 0x0100 > > #define PERF_AUX_FLAG_RANDOM_PMU_FORMAT_FMT1 0x0000 > #define PERF_AUX_FLAG_RANDOM_PMU_FORMAT_FMT2 0x0100 > > > What do you think ? Sounds good to me. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel