Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp5013249rdb; Tue, 12 Dec 2023 16:49:30 -0800 (PST) X-Google-Smtp-Source: AGHT+IHT3ow2NIfEcU0YJA2PmAUXYjdN2BjykvXjPHNEW0o5eZWctOTvpUWk7IJxMSO+HnWY6jyV X-Received: by 2002:a17:90b:1058:b0:286:c7af:b68e with SMTP id gq24-20020a17090b105800b00286c7afb68emr5182539pjb.72.1702428570197; Tue, 12 Dec 2023 16:49:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702428570; cv=none; d=google.com; s=arc-20160816; b=pMVRObDsXplZ08qpeNhQfw2q4TfUsSRmZp+9CtI6kLNvygJeVDp+JqoB1vgWWtvxTD OKjNGwE+O+JJhr0JlvMmZISRmz12jq8b1LI9tZn6PiCl4EA+cIrwA0dZUtgguSb48RK4 6rqK4NaiNG1A/AMLOu47RxF1+vH9Xq+SEIkA36bUUCrUo+J3dkSLqy++Pzd8OfzzJ8BU ineMDZU1yhEcnQB6PPBJe05lMA8/EGiGjmMbC095PwUWPFsZZEXOCtoS4RlFQH3bC02Y iTewU8Z3b3QWpEh4tUOqi4Ml3Pi/IGy6JukZnfnWvWhK9PIA0h2vZHnNVlpm57qgVClI sEsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=pGb9rhg1aE3uF41EQgn+hZ1cAYCUE8wg0HR5jXQis4A=; fh=/hhORBAM0lb7M1gVyvX/fEu96XaRvUs0WH6EpZMFYIk=; b=pbbaO8UxznWSnLLxbYZw/TNJnKzl61pHuddsjL5/HztGCh+nGaau5A3ikfsbSqEkOu cKTlLWXN8Tc8RXEY+IKEuZvZ/lXN8uwWPgVQHZp5bvuTetS9yN5zBV3Qg1M+6OOHeWLk vyhViUqfJ5204L2ldXlO/RGFEtgYRwnShHN/f+1UHrChUkiwxb85bNt6ir4DIXS9DJFB lkkHw1wdEYPNDJ/6LVSWwP4RcYsK0sbffo+2ZY1E+Kvl3/Gj/jMGeOXjJzZqZ2TVPA/Z VaQlJseK522XmBaZTxapFLGIn6F9I65jLjq2rq8oZPHO2XWchton9YnFgijfK2EpqMvF MwBQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id x24-20020a17090abc9800b0028a0244d5d9si8711614pjr.164.2023.12.12.16.49.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Dec 2023 16:49:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 9B42980A9AB7; Tue, 12 Dec 2023 16:49:27 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377896AbjLMAtI (ORCPT + 99 others); Tue, 12 Dec 2023 19:49:08 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44312 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232683AbjLMAtH (ORCPT ); Tue, 12 Dec 2023 19:49:07 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B4D49CA for ; Tue, 12 Dec 2023 16:49:12 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 864EEC433C8; Wed, 13 Dec 2023 00:49:09 +0000 (UTC) Date: Tue, 12 Dec 2023 19:49:52 -0500 From: Steven Rostedt To: Alexander Graf Cc: , , , , , , , , Eric Biederman , "H. Peter Anvin" , Andy Lutomirski , Peter Zijlstra , "Rob Herring" , "Andrew Morton" , Mark Rutland , "Tom Lendacky" , Ashish Kalra , James Gowans , Stanislav Kinsburskii , , , , Anthony Yznaga , Usama Arif , David Woodhouse , Benjamin Herrenschmidt Subject: Re: [PATCH 09/15] tracing: Introduce names for events Message-ID: <20231212194952.5f6d599b@gandalf.local.home> In-Reply-To: <20231213000452.88295-10-graf@amazon.com> References: <20231213000452.88295-1-graf@amazon.com> <20231213000452.88295-10-graf@amazon.com> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.8 required=5.0 tests=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 fry.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 (fry.vger.email [0.0.0.0]); Tue, 12 Dec 2023 16:49:27 -0800 (PST) On Wed, 13 Dec 2023 00:04:46 +0000 Alexander Graf wrote: > With KHO (Kexec HandOver), we want to preserve trace buffers. To parse > them, we need to ensure that all trace events that exist in the logs are > identical to the ones we parse as. That means we need to match the > events before and after kexec. > > As a first step towards that, let's give every event a unique name. That > way we can clearly identify the event before and after kexec and restore > its ID post-kexec. > > Signed-off-by: Alexander Graf > --- > include/linux/trace_events.h | 1 + > include/trace/trace_events.h | 2 ++ > kernel/trace/blktrace.c | 1 + > kernel/trace/trace_branch.c | 1 + > kernel/trace/trace_events.c | 3 +++ > kernel/trace/trace_functions_graph.c | 4 +++- > kernel/trace/trace_output.c | 13 +++++++++++++ > kernel/trace/trace_probe.c | 3 +++ > kernel/trace/trace_syscalls.c | 29 ++++++++++++++++++++++++++++ > 9 files changed, 56 insertions(+), 1 deletion(-) > > diff --git a/include/linux/trace_events.h b/include/linux/trace_events.h > index d68ff9b1247f..7670224aa92d 100644 > --- a/include/linux/trace_events.h > +++ b/include/linux/trace_events.h > @@ -149,6 +149,7 @@ struct trace_event { > struct hlist_node node; > int type; > struct trace_event_functions *funcs; > + const char *name; > }; OK, this is a hard no. We definitely need to find a different way to do this. I'm trying hard to lower the footprint of tracing, and this just added 8 bytes to every event on a 64 bit machine. On my box I have 1953 events, and they are constantly growing. This just added 15,624 bytes of tracing overhead to that machine. That may not sound like much, but as this is only for this feature, it just added 15K to the overhead for the majority of users. I'm not sure how easy it is to make this a config option that takes away that field when not set. But I would need that at a minimum. -- Steve