Received: by 2002:a89:413:0:b0:1fd:dba5:e537 with SMTP id m19csp563110lqs; Thu, 13 Jun 2024 20:48:42 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXfjIzy2/pjdxdFIDCVKZL4hhwigy6cQkQkifHMmRvz3G+H304ptxJ00pimKgnjiTarR+ul03rIwNWaZI5lz5BvJKwFkzRPzi5ItBTSgw== X-Google-Smtp-Source: AGHT+IF9PXSz0HZCQEB7JUIqdhUCx4Nexybaz1zBhJGKtZPJ4oq+zGyXeScZAG99fw7+tMiD+k8B X-Received: by 2002:aa7:8058:0:b0:704:1932:5607 with SMTP id d2e1a72fcca58-705d717de59mr1467330b3a.20.1718336922105; Thu, 13 Jun 2024 20:48:42 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718336922; cv=pass; d=google.com; s=arc-20160816; b=vGnroFUEdlsnsndeBRC6KV1eiJobqBEKhS9nSVJy+X9nczxc5MhxrAioe2r0FYdUFV w4kH3314UUN35ZV53ZT7MU4OAyd+w6lRNna1yM756wkczMIVmiRr3xRe7mgLl2uusm91 GRl8ezfCiVNfFiXtExhp6UQoDZkYUCrNtvtgOEodPNoSiolhiL/a4Dbb3hLxyT3XT+B+ 6LCoKiwysWbXUYsw5NSJdQTQ6i0/D8u/iWBGK8J4u9DhZkv2cMSuViRpak5i6hjteBg2 89iClse5CKjCfS2X/RPQbVMt7WP9BpwMFxNf+P6BTfu6yTwyoUNx0vRxT7aHhC2FXF3X cntA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :content-transfer-encoding:content-id:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from; bh=gq0rjch+4nK4ym+BydXC6CoeYJFHy0HJisnLlat2VDk=; fh=8Ourhkr0tvK0vG9IHJ9QgfFJx8o+EsOFvYXMeRYLVuM=; b=NPLAgUP1dG4OIbjy8ESLB86TNgAAOjJoyag3YvNERQOOqJbmCXJdXS1R7GDzBrVnY9 H9rS6CCzPIKJ0LthaoxCWcW0U0H1HIGGqk/Blbl0UdSdmksH1G+x6/w8FkThFgImiOB6 5xkrg3AyFai1CVWF82ccxTcXuhH342OeSS3q2qz08mXUjlwDRJtyo8HjK+eFkld1Ewpa NFCHfUKN1yeDZ7RBI7HiIOYa1NjeMWEpdvpL4S7INunUD6TdHHWhJy1loopjLgM8YrvR wd2u4f+nhCYtBGTcS62bx9c2K9xKCj5yTuauDJuyKYEdFGNjm5A+DeHJk1zN9H4SIFCV yTaw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-214310-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-214310-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id 41be03b00d2f7-6fee453ef53si2617827a12.581.2024.06.13.20.48.41 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Jun 2024 20:48:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-214310-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-214310-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-214310-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 33789B2297E for ; Fri, 14 Jun 2024 03:48:39 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DE8F7146D43; Fri, 14 Jun 2024 03:48:29 +0000 (UTC) Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F3353146582; Fri, 14 Jun 2024 03:48:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.188 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718336909; cv=none; b=XfAGUtWrOCxyn4nsvCcgPXJULywCwS/dBxiXFJ0RPeWKX/4PgLg9tZsvBWUawV8anWD4tJrXLjglGDzG+k9Nerw5mjJ+zV7JhChEzvkFr4YXrLA7IX9eRIAsg14HRXD2+wU+uyCEFS4O2VuRyBk0ii+rZS3sryL+Cmq5MLOB11k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718336909; c=relaxed/simple; bh=tOdcNuf2kRMwiFSwcr6k9xuklL/HpB+Iw5uNR7FPc44=; h=From:To:CC:Subject:Date:Message-ID:References:In-Reply-To: Content-Type:MIME-Version; b=ruJNm9QnpKNWJnK6biH+ETb2QEupoSaqIU7i0bE2btlzzFl23SVZkQAc0aIQNyIcPe2bHnldDpiYeeTBc0qXKozuWu4YKoDgnm/h9T6jzFPZcptZPBCw9PD8aY0HbVkdkgxfBcoJe51jo660i1N+I1gz9FHLfZt3m9P5BW0s6a8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.188 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.163.48]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4W0lVx4w1pzmYsS; Fri, 14 Jun 2024 11:43:37 +0800 (CST) Received: from kwepemd100011.china.huawei.com (unknown [7.221.188.204]) by mail.maildlp.com (Postfix) with ESMTPS id 1BAD318007C; Fri, 14 Jun 2024 11:48:24 +0800 (CST) Received: from kwepemd100011.china.huawei.com (7.221.188.204) by kwepemd100011.china.huawei.com (7.221.188.204) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1258.34; Fri, 14 Jun 2024 11:48:23 +0800 Received: from kwepemd100011.china.huawei.com ([7.221.188.204]) by kwepemd100011.china.huawei.com ([7.221.188.204]) with mapi id 15.02.1258.034; Fri, 14 Jun 2024 11:48:23 +0800 From: duchangbin To: Adrian Hunter CC: duchangbin , Peter Zijlstra , Ingo Molnar , "Arnaldo Carvalho de Melo" , Namhyung Kim , Nathan Chancellor , Mark Rutland , Alexander Shishkin , Jiri Olsa , "Ian Rogers" , "Liang, Kan" , "Nick Desaulniers" , Bill Wendling , Justin Stitt , "linux-perf-users@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "llvm@lists.linux.dev" Subject: Re: [PATCH 2/2] perf: disasm: prefer symsrc_filename for filename Thread-Topic: [PATCH 2/2] perf: disasm: prefer symsrc_filename for filename Thread-Index: AQHavVvh9tYwOTcSHEG6bdTlEhoGM7HE0t8AgACesgD//4X1gIABqREA Date: Fri, 14 Jun 2024 03:48:23 +0000 Message-ID: <4b420b265a6d4c298315807725734a31@huawei.com> References: <20240613063510.348692-1-changbin.du@huawei.com> <20240613063510.348692-3-changbin.du@huawei.com> <395cfff7-9692-4123-96b6-353752007f46@intel.com> <39be46d6a5194b6390ed31be67689c6c@huawei.com> <6abf540f-5f11-4b2b-b8c1-69783a71277b@intel.com> In-Reply-To: <6abf540f-5f11-4b2b-b8c1-69783a71277b@intel.com> Accept-Language: en-US Content-Language: zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-imapappendstamp: kwepemd100011.china.huawei.com (15.02.1258.034) x-ms-exchange-messagesentrepresentingtype: 1 Content-Type: text/plain; charset="us-ascii" Content-ID: Content-Transfer-Encoding: quoted-printable Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 On Thu, Jun 13, 2024 at 01:26:39PM +0300, Adrian Hunter wrote: > On 13/06/24 12:43, duchangbin wrote: > > On Thu, Jun 13, 2024 at 11:15:28AM +0300, Adrian Hunter wrote: > >> On 13/06/24 09:35, Changbin Du wrote: > >>> If we already found a debugging version when loading symbols for that= dso, > >>> then use the same file for disasm instead of looking up in buildid-ca= che. > >> > >> In the past, there have been cases where the debugging version has not > >> worked for reading object code. I don't remember the details, but the > >> symbols and debugging information was OK while the object code was not= . > >> > >> In general, using anything other than the file that was actually execu= ted > >> for reading object code seems like a bad idea. > >> > > Is this a platform specific issue? AFAIK, the binary code in debugging = and > > non-debugging version should be identical.=20 >=20 > "should be" !=3D "guaranteed to be". Simpler to avoid the issue and > stick with the file that was actually executed. We already support > having separate symbol sources, so there should not really be a > problem. > ok, so for vdso I think we can flow the kernel part in dso__disassemble_fil= ename. I'll add vdso processing here. >=20 --=20 Cheers, Changbin Du