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 61C9BC4332F for ; Mon, 14 Nov 2022 01:25:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235630AbiKNBZu (ORCPT ); Sun, 13 Nov 2022 20:25:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48386 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230525AbiKNBZr (ORCPT ); Sun, 13 Nov 2022 20:25:47 -0500 Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B96B610067; Sun, 13 Nov 2022 17:25:46 -0800 (PST) Received: from dggpemm500020.china.huawei.com (unknown [172.30.72.53]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4N9WpG41Jkz15Mbf; Mon, 14 Nov 2022 09:25:26 +0800 (CST) Received: from dggpemm500006.china.huawei.com (7.185.36.236) by dggpemm500020.china.huawei.com (7.185.36.49) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Mon, 14 Nov 2022 09:25:44 +0800 Received: from [10.174.178.55] (10.174.178.55) by dggpemm500006.china.huawei.com (7.185.36.236) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Mon, 14 Nov 2022 09:25:44 +0800 Subject: Re: [PATCH v8 0/9] kallsyms: Optimizes the performance of lookup symbols To: Luis Chamberlain , Nick Alcock , CC: Josh Poimboeuf , Jiri Kosina , Miroslav Benes , Petr Mladek , Joe Lawrence , , , Masahiro Yamada , Alexei Starovoitov , Jiri Olsa , Kees Cook , Andrew Morton , , Ingo Molnar , David Laight References: <20221102084921.1615-1-thunder.leizhen@huawei.com> From: "Leizhen (ThunderTown)" Message-ID: <61daf7e0-049c-0338-03a6-472694def181@huawei.com> Date: Mon, 14 Nov 2022 09:25:43 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.178.55] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To dggpemm500006.china.huawei.com (7.185.36.236) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2022/11/13 10:55, Luis Chamberlain wrote: > On Sat, Nov 12, 2022 at 06:44:26PM -0800, Luis Chamberlain wrote: >> On Wed, Nov 02, 2022 at 04:49:12PM +0800, Zhen Lei wrote: >>> v7 --> v8: >>> Sort the symbols by name and implement kallsyms_lookup_name() using a binary >>> search. The performance is more than 20 times higher than that of v7. Of course, >>> the memory overhead is also extended to (3 * kallsyms_num_syms) bytes. Discard >>> all implementations of compression and then comparison in v7. >>> >>> In addition, all sparse warnings about kallsyms_selftest.c are cleared. >> >> Awesome work, I can't find a single thing I hate about this, but my >> biggest conern is the lack of testing so I'm going to merge this to > > Sorry finished the email too fast, I just wanted to add Nick to the > thread as his work does tons of changes on scripts/kallsyms.c. > > I was saying -- I'm just concern with the lack of testing so I have merged > this to modules-next and see what explodes over the next few weeks. > I'm also happy to drop this from modules-next and have it go through > the livepatching tree instead, but given Nick's work is dedicated > towards modules and it also touches on scripts/kallsyms.c a lot, to > avoid conflicts it felt best to merge that to modules for now in case > his changes get merged during the next merge window. > > Let me know what folks prefer. > > Obviously, if testing blows up we can drop the series. > > Zhen, wouldn't ftrace benefit from the same > s/kallsyms_on_each_symbol/kallsyms_on_each_match_symbol ? ftrace uses regular matching, so it cannot be replaced. > > Luis > . > -- Regards, Zhen Lei