From patchwork Thu May 25 08:29:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adrian Hunter X-Patchwork-Id: 9828 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp213098vqr; Thu, 25 May 2023 01:51:34 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ44V7vqxDxAUHfCoOBfowHTFcCLxWm938IuV6axXK5CTFpM5tjo4ywicyJoTjIi+KOMqbZ+ X-Received: by 2002:a05:6a20:72a8:b0:10c:1047:68ba with SMTP id o40-20020a056a2072a800b0010c104768bamr11991550pzk.35.1685004694646; Thu, 25 May 2023 01:51:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685004694; cv=none; d=google.com; s=arc-20160816; b=HNrqFKNAtgPIw2Z2ZOQzWHoY2/akhGnMu6YhhlR4QW1sJPl+68IdPWS1FhTl/F5qln Ajdjt+piCM5+BiOmXANCQplT2ijiMhJ56sqM3u0/25Flgjn+tVvfrMW8NoOC0rVYNdj9 1R0BdPa/Zf7OYgewIH3Dyy2S2zmFin8VU96NiAu9NAKhWlAYzVX/QFz6FbQ/GuCke5yQ c8G8EOpW+/xBQ8v7kPJDQceTNjjPwRRvjTqySSnOUMLSDZGGv31UlLzQYt3GIh/7Z3y9 hGgPNNjre7Zq0vU58s+EGXJxQ26km9e5tUZ5KDnkodUYn4W4qAzsY4Lcptv38alx8D4V vXcw== 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:message-id:date:subject:cc:to:from:dkim-signature; bh=iaTYQtSF03KNQVpVMZs3WFBKCm5AWi/cLNPETAY+A1o=; b=JqDDjRT7QXQ54ljL/PXUEJlcZa3PqfAG8nmKiCwY+5HsoPwEiukpeDrAhMvgLpyJQl JgX+8Vw5FYb6pCc8Y1gjbovk1DQ7b8W2dJ8ed3yx4X/EIfffYNcr407r5++5EHaRtJcE /Z4ExGAtDubF2bZ7abWQC0IEWmy2pFxvwGxvE4jaEmYwRiBjvoRJ+RF8r+eryxRFPJ6J THQ5DONe2oig7GASc3cNQ1/d6GEHSClxXy4VCBNDI/lh4V3Kr2hh3+u7QzM+caI/6AmP j/sHRbS40ZeJr3Ea9wVTXr6z7iXBYvG3aqALcmQt58kuy909rtX3SQekTrl6+oHi82U5 6CGA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="Oa/X3pAI"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w20-20020a637b14000000b005347e036056si661961pgc.633.2023.05.25.01.51.20; Thu, 25 May 2023 01:51:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="Oa/X3pAI"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239832AbjEYI3V (ORCPT + 99 others); Thu, 25 May 2023 04:29:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54434 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239793AbjEYI3R (ORCPT ); Thu, 25 May 2023 04:29:17 -0400 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C4C3186; Thu, 25 May 2023 01:29:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1685003356; x=1716539356; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=QHA0PUM2kozuFhevzuFcZbE8+0O6nv9jDPUSc6oHy+0=; b=Oa/X3pAI5cc/rRPJSSM1MKyWZ2WWWogCuk8mwtwS6mHLGtfyfb2cqvUh xOXZnEnjS/rx4AcOOD5yBnsSci8AWSHs7uHlyrgUrd9CweWYH8oc4zPjz yc4eKOUeXiKtq6OLcIyhwHfPGzu5v4GUG0j/HIRcO8EVooQjXzEV4VY53 0AzQFZZMcGgm6P3fyqXITxCFLLeDky37/9v8bwmGhbt7E4q/lk1y16J6e d/osCyYRcpaNVnSsM3YxyxJ/xqu1SAYJKGE/Kh2dFhS6EN3xaFruyIt1j UBUQySyii+c8iQ0EXt35smTv/uVYN64+FmAulk3COfMFhL+Wr9YqOa71O w==; X-IronPort-AV: E=McAfee;i="6600,9927,10720"; a="338400398" X-IronPort-AV: E=Sophos;i="6.00,190,1681196400"; d="scan'208";a="338400398" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 May 2023 01:29:15 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10720"; a="707914632" X-IronPort-AV: E=Sophos;i="6.00,190,1681196400"; d="scan'208";a="707914632" Received: from ahunter6-mobl1.ger.corp.intel.com (HELO ahunter-VirtualBox.home\044ger.corp.intel.com) ([10.251.208.63]) by fmsmga007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 May 2023 01:29:12 -0700 From: Adrian Hunter To: Arnaldo Carvalho de Melo Cc: Jiri Olsa , Namhyung Kim , Ian Rogers , linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org Subject: [PATCH V3 0/1] perf tools: Allow config terms with breakpoints Date: Thu, 25 May 2023 11:29:01 +0300 Message-Id: <20230525082902.25332-1-adrian.hunter@intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Organization: Intel Finland Oy, Registered Address: PL 281, 00181 Helsinki, Business Identity Code: 0357606 - 4, Domiciled in Helsinki X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766855122546125064?= X-GMAIL-MSGID: =?utf-8?q?1766855482996960258?= Hi Here is a patch (V3) to the event parser for breakpoint events. I am not that familiar with flex / bison, but it seemed to need trailing context to stop the mem event colon and slash delimiters from getting mixed up with delimiters for config terms or event modifiers. Please look closely at that. Changes in V3: Add Ian's Reviewed-by Re-base Changes in V2: Add comments to tools/perf/util/parse-events.l Add a test for 2 mem events back to back with config terms Adrian Hunter (1): perf tools: Allow config terms with breakpoints tools/perf/tests/parse-events.c | 157 ++++++++++++++++++++++++++++++++++++++++ tools/perf/util/parse-events.c | 23 +++++- tools/perf/util/parse-events.h | 6 +- tools/perf/util/parse-events.l | 23 +++++- tools/perf/util/parse-events.y | 42 ++++++----- 5 files changed, 224 insertions(+), 27 deletions(-) Regards Adrian Signed-off-by: Adrian Hunter