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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D1D20C433F5 for ; Sun, 27 Feb 2022 13:55:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229812AbiB0Nzf (ORCPT ); Sun, 27 Feb 2022 08:55:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48154 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229608AbiB0Nzb (ORCPT ); Sun, 27 Feb 2022 08:55:31 -0500 Received: from mail-pg1-x535.google.com (mail-pg1-x535.google.com [IPv6:2607:f8b0:4864:20::535]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 506831BE85 for ; Sun, 27 Feb 2022 05:54:55 -0800 (PST) Received: by mail-pg1-x535.google.com with SMTP id 12so9244113pgd.0 for ; Sun, 27 Feb 2022 05:54:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=R5/L3FvnnktNyA34E6kruOzfisqAyzhCs9ooPGmemyU=; b=uuLL8S0E+zI20jKmcmApZ8T7BLy1ekrigcJchDezUrX58/hAEEwRWtQ8ixFg6WwbZF 9Vfe4zkxPKtl6nk75f0qx6s/j4iSpeEI1ioAlj894Gh9jhhSfIwSMw/nYiZz5FpK3mK8 yDqfKHXZuAV686mDbZNgIlvd2AaCcUgsyuwTbyPHLrRORL5h7yaCtg0M5cf+aon/8Yi2 Ho29Y3QLIBQMpe5QW2akghgcYyDEwaubjGYraXpVw+qH+UnYondbitbR0ltIkaAhlDHZ 6VwTPUxe15KRvxs+sPtwHLiGLBPLIMLxxe8indN6XxMJ8sYHw8ZA7HKBU57VUGRnQpso 0j+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=R5/L3FvnnktNyA34E6kruOzfisqAyzhCs9ooPGmemyU=; b=fO6tppWJdW9L4T3tg6tSCkopDmx1qOzTo7LJTJ0loF6ZcnkXSRxKFO4bp1hT9Vjlte NZZn2E5xS9zKtpsf/XLn8dtxb45/2GBjOqdalS+B9mWSR8/BUnmhUV6w8n1Z1FxB4hQp 6V8/tXJlMXELU2uCcDB8YgYZET9hmBOx6bWStpTt4ICxsW/AMz6yFmEky4hCrzTxFQI+ uOGG32MEm5g7SIypd+nzS3FYX6atkHDKuU2ptJ8oqJHhoHtx4hFlXFu2x0EZdaiR30pT HNLpAkm8ttMBkiFurBSD6AaYd4Q8sIIBxzkxARt0T6i67UcX8BE/YUj+HjauU52izWqb WHCg== X-Gm-Message-State: AOAM530HKRF9mlWtXgAkJQRm40qGfLAehUsqLfTWnAQOzmp7j6N23wcL KBO7EMW/4KHXtMqdlBHgGI7CyA== X-Google-Smtp-Source: ABdhPJw1trEejf2Gp3RfzHniQF58pqnIWCn0DG0TdWVAUuroABa8H5/f51okcOdZQvFbGHfkKnpNhw== X-Received: by 2002:a63:3111:0:b0:373:a1fa:8998 with SMTP id x17-20020a633111000000b00373a1fa8998mr13312669pgx.415.1645970094678; Sun, 27 Feb 2022 05:54:54 -0800 (PST) Received: from leoy-ThinkPad-X240s ([204.124.180.219]) by smtp.gmail.com with ESMTPSA id v14-20020a056a00148e00b004e1cee6f6b4sm10221833pfu.47.2022.02.27.05.54.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Feb 2022 05:54:54 -0800 (PST) Date: Sun, 27 Feb 2022 21:54:44 +0800 From: Leo Yan To: Ali Saidi Cc: german.gomez@arm.com, acme@kernel.org, alexander.shishkin@linux.intel.com, andrew.kilroy@arm.com, benh@kernel.crashing.org, james.clark@arm.com, john.garry@huawei.com, jolsa@redhat.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, mark.rutland@arm.com, mathieu.poirier@linaro.org, mingo@redhat.com, namhyung@kernel.org, peterz@infradead.org, will@kernel.org Subject: Re: [PATCH 2/2] perf arm-spe: Parse more SPE fields and store source Message-ID: <20220227135444.GB107053@leoy-ThinkPad-X240s> References: <9266bfb6-341c-1d9c-e96f-c9f856a5ffb6@arm.com> <20220222192943.20137-1-alisaidi@amazon.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220222192943.20137-1-alisaidi@amazon.com> Precedence: bulk List-ID: X-Mailing-List: linux-perf-users@vger.kernel.org On Tue, Feb 22, 2022 at 07:29:43PM +0000, Ali Saidi wrote: [...] > >So I am just wandering if we can set the field > >sample::data_src::mem_lock for atomic operations, like: > > > > data_src.mem_op = PERF_MEM_OP_LOAD; > > data_src.mem_lock = PERF_MEM_LOCK_ATOMIC; > > > >The field "mem_lock" is only two bits, we can consider to extend the > >structure with an extra filed "mem_lock_ext" if it cannot meet our > >requirement. > > These are for the LOCK instruction on x86. I don't know that we want to > overload the meaning here. Minimally there is value in differentiating > exclusives vs atomics. Good point. Can we consider to add new filed data_src.atomic with below types? PERF_MEM_ATOMIC_INST -> Atomic operations PERF_MEM_ATOMIC_EXCL -> Load-Exclusive/Store-Exclusive PERF_MEM_ATOMIC_ACQUIRE_RELEASE ->Load-Acquire/Store-Release Thanks, Leo