Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp176426rdg; Thu, 12 Oct 2023 02:17:38 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF13M6suKRgKCtqWL7zQKter5i4yl+KH0uP6zz9QPUYJ3cJ6zmdQFcvMMmH9sVRD/QEVS9/ X-Received: by 2002:a05:6808:211d:b0:3af:5aa2:a3d with SMTP id r29-20020a056808211d00b003af5aa20a3dmr30551944oiw.40.1697102257980; Thu, 12 Oct 2023 02:17:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697102257; cv=none; d=google.com; s=arc-20160816; b=c8oBgHhKgxv2CV/Yk65mwhBoamttB5qsmIKUbSjrPOPOYoTg9G2B5hI85jHuEaQLbq L7NfshzUlMpO5r/MsX3ZwQip/gZfRVZ3yp3xbAF9+dGrID6q0OR3+Moo/qZMOFatv/Vz gpEVizMLaMBNj1N3LcNRNV7l7CENRsnQ0dY+j7gH0233Q8Qe5ZEyUXCIy2pO3CXE6Yvp its/hvryQw73mvmc2Eg6tfJ4uy4kgUP2O4PijUPSCAn5iFLKh9wAUBwW1zo06y800+QU 6jfTqivFbz3UGMbOaCGVbLpN75zHQ1gAHLpd7R51+wvJOHDnX1ZrthbY3IJ+Y2qzrTG/ nOGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=SY5yqmx7UFQ27nMH5z2Z6G4quyyShMn+b9u4K2hwCUk=; fh=Ytnn8ffAvS1E+UaEcf+ga2qRcaASnzKZc62Kc7EKWpo=; b=nTZM9ww1oPiY6foYzvw0yTIboogNxk774ZUge8qdTXYyOo7omEGPOmra88794wjevL dbTWeNZ9qsWrnnZ3VLr83RykgDUWcqZH+Z7610oo3aTIJcsMMXLQjRAfgcp6UGTrLvJ9 F7TUNb3YvOw4RzmWXoht6hoIeZ5fKwSEBgYsF79eiAWNazW9I1sRkzHAg+hr+veiyg73 MaAc04HDBEPuT7xPwRnCmP0R0BBkQAFaWtPZQ11rSeds+78zcmIM9IAIqiLtvjynkuyg X+LwLtnLeFI8pkeekpub2Ti8FqASe3FNzrTVNgTPTz/9MdEJzCaPSpHcvq7ZrrX8wGcP Y2tQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=Kuw8PvSm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id s23-20020a632c17000000b00578b6e2f462si1769369pgs.351.2023.10.12.02.17.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Oct 2023 02:17:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=Kuw8PvSm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (Postfix) with ESMTP id A6A478217072; Thu, 12 Oct 2023 02:17:36 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235422AbjJLJRe (ORCPT + 99 others); Thu, 12 Oct 2023 05:17:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57850 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234155AbjJLJRd (ORCPT ); Thu, 12 Oct 2023 05:17:33 -0400 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BF0A6CA; Thu, 12 Oct 2023 02:17:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; 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=SY5yqmx7UFQ27nMH5z2Z6G4quyyShMn+b9u4K2hwCUk=; b=Kuw8PvSmEOCGiEh1bcE5c93zOf UfMqN9elE915IiKRRyJatxJw8k66yVw8f6StP7tcTqF8Gxk957xNQ+xH9QRVvlkjW6PEkTf5/+/7b Oq0aeMRXXwlo1UoyY8qUo5kTQniVMMjjBKB9dmKVt6Ro7dADusdPGIoTBvvdu5pcli2Ij6KZbv/jH AYkZHhJtd8sDKci0/Kj9OwuLH2kYm0ltifRtcPkzAIeJ5PxAox8Zvbfm3xhh9A9HlqkX1I6qcdGkN wBS2lnFMKio5saaCjl0JbBdZifa31gUptVONJxMgyMeoHmqUKyEencbuaSS6ZhzFlI+Iw+D1jV2aZ ja5cOr/w==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1qqrn6-001hMl-2e; Thu, 12 Oct 2023 09:17:12 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id E353830036C; Thu, 12 Oct 2023 11:15:37 +0200 (CEST) Date: Thu, 12 Oct 2023 11:15:37 +0200 From: Peter Zijlstra To: Namhyung Kim Cc: Arnaldo Carvalho de Melo , Jiri Olsa , Ian Rogers , Adrian Hunter , Ingo Molnar , LKML , linux-perf-users@vger.kernel.org, Linus Torvalds , Stephane Eranian , Masami Hiramatsu , linux-toolchains@vger.kernel.org, linux-trace-devel@vger.kernel.org, Ben Woodard , Joe Mario , Kees Cook , David Blaikie , Xu Liu , Kan Liang , Ravi Bangoria Subject: Re: [RFC 00/48] perf tools: Introduce data type profiling (v1) Message-ID: <20231012091537.GM6307@noisy.programming.kicks-ass.net> References: <20231012035111.676789-1-namhyung@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231012035111.676789-1-namhyung@kernel.org> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_NONE 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-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Thu, 12 Oct 2023 02:17:37 -0700 (PDT) On Wed, Oct 11, 2023 at 08:50:23PM -0700, Namhyung Kim wrote: > Actually there's a performance issue about getting disassembly from the > objdump for kernel. On my system, GNU objdump was really slower than the > one from LLVM for some reason so I had to pass the following option for > each perf report and perf annotate. > > $ sudo perf report --objdump=llvm-objdump ... > > # To save it in the config file and drop the command line option > $ sudo perf config annotate.objdump=llvm-objdump > > Even with this change, still the most processing time was spent on the > objdump to get the disassembly. It'd be nice if we can get the result > without using objdump at all. So the kernel has an instruction decoder, all we need is something that can pretty print the result. IIRC Masami had an early version of that somewhere. With those bits, and some basic ELF parsing (find in objtool for instance) you can implement most of objdump yourself.