Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2378951imu; Thu, 10 Jan 2019 13:08:59 -0800 (PST) X-Google-Smtp-Source: ALg8bN7XaIhD/NaDMpY/d4gWxJ42EmLMcSTWxht5sM5Kkh2mcznXD5UkEOaaX3Vrs/g9rNj2Z1yV X-Received: by 2002:a63:f552:: with SMTP id e18mr10916175pgk.239.1547154539346; Thu, 10 Jan 2019 13:08:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547154539; cv=none; d=google.com; s=arc-20160816; b=gaA3W2M0g35+9WawMrk2mhcqm47cTwMhu9DQdNyOuESouLAJuRgXTAKNZH23Jl1uSb TyrJ/AqYw9I3SqQttWnG8Yt6LKEBTSXT1PeiWZ2SMGIJkVLsix0t/kTnr2w39tCKzeZH 1DDzMN+kFnrFSa5dqLkzPfB2tt74bK2oS7ZdT8Lf8bdM9ALDym2nQc9/VR7he8ymKRz4 Gl3C4BpS2ler/HUP6dZAmH7+hYzohxZraA3xisJ7UQYe0zHG3A9ICfw7kzNq3rBKsBmZ XmsAJx2s+5JpSlXuG/fxCtqPdogHsFglhJDatL8CsqgIBKl26X4Uv2s9Xj8VeqJ/RjID WXfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:spamdiagnosticmetadata:spamdiagnosticoutput :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature :dkim-signature; bh=WSCok1Io1IC4ErUHEfo+foA4JH6ZNS1qLKu1JsDH9kM=; b=vFZQtK/yv7fs1brfNzzd4JDlRTRNKXizYIOoV9Kvs/RAL09/evskK+mIlnx0UhN3oM qcLEuh2kyAYBuFuqKxxP/oH2VLBpPm65QOlGdCGqSmmtDulr6aC4nXu5GQXESEgC0mY1 Hbxp2lw5B6NANQMruihiwKDMDpQ8qKrhWDViN+PgoxqI7L76zpmsDFmXmjvG2F9JtsVT HjxITaCKaUUtYuArlPWQsPeEhgOOLu+EMcdn9lnDqs10saQ3swJLNeHEFT5IdFVltuj8 BJGVUV/Ckl6v2IdeQD9zLQDfJx1ylm6UI+vffJga3ntZ7ktkSvzWIpfU3wKOLHn0uRK2 ZC4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=cJYf85YE; dkim=pass header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b="k7miB/5V"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cb2si10999836plb.298.2019.01.10.13.08.43; Thu, 10 Jan 2019 13:08:59 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=cJYf85YE; dkim=pass header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b="k7miB/5V"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729554AbfAJTau (ORCPT + 99 others); Thu, 10 Jan 2019 14:30:50 -0500 Received: from mx0b-00082601.pphosted.com ([67.231.153.30]:35142 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728572AbfAJTau (ORCPT ); Thu, 10 Jan 2019 14:30:50 -0500 Received: from pps.filterd (m0001303.ppops.net [127.0.0.1]) by m0001303.ppops.net (8.16.0.27/8.16.0.27) with SMTP id x0AJRr0b028593; Thu, 10 Jan 2019 11:30:26 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-id : content-transfer-encoding : mime-version; s=facebook; bh=WSCok1Io1IC4ErUHEfo+foA4JH6ZNS1qLKu1JsDH9kM=; b=cJYf85YEv++uncu+Z02ilKqehcb5Rai3svez4zE08cGYTDgXElCfYE+oZCDiuDKP3+dE RV5So4HVlMAMwgKyohCvGmzdwZ84FEeanJsi8xZQejqbMmC3FIfD2xnhshrf7RM8P1nI Qz8jP+z5azegJ0fsiiMm+5rUY+mTBSzrUBc= Received: from mail.thefacebook.com ([199.201.64.23]) by m0001303.ppops.net with ESMTP id 2pxb7sg87y-6 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Thu, 10 Jan 2019 11:30:26 -0800 Received: from prn-hub02.TheFacebook.com (2620:10d:c081:35::126) by prn-hub02.TheFacebook.com (2620:10d:c081:35::126) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.1.1531.3; Thu, 10 Jan 2019 11:30:24 -0800 Received: from NAM01-SN1-obe.outbound.protection.outlook.com (192.168.54.28) by o365-in.thefacebook.com (192.168.16.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.1.1531.3 via Frontend Transport; Thu, 10 Jan 2019 11:30:24 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.onmicrosoft.com; s=selector1-fb-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WSCok1Io1IC4ErUHEfo+foA4JH6ZNS1qLKu1JsDH9kM=; b=k7miB/5V2CvRwEmySFRoF8iYcnUf/KMdW/rU3t0Wa3nSNmLekJtGmiSFim22to38aCIO9d+zAX5J6SxMMuJt1Q0l0qVUc1Bq9Zn5YM5yUoG1l8JzXGnKQbLDZTPF2RdlyXXoMpXWAvO/MOMhRJS8SkCbnOypv10XSgpbVU0RC4M= Received: from DM5PR15MB1163.namprd15.prod.outlook.com (10.173.208.149) by DM5PR15MB1161.namprd15.prod.outlook.com (10.173.208.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1516.13; Thu, 10 Jan 2019 19:30:22 +0000 Received: from DM5PR15MB1163.namprd15.prod.outlook.com ([fe80::1909:9d4c:715b:faa0]) by DM5PR15MB1163.namprd15.prod.outlook.com ([fe80::1909:9d4c:715b:faa0%5]) with mapi id 15.20.1516.015; Thu, 10 Jan 2019 19:30:22 +0000 From: Song Liu To: Arnaldo Carvalho de Melo CC: lkml , "netdev@vger.kernel.org" , "peterz@infradead.org" , "ast@kernel.org" , "daniel@iogearbox.net" , Kernel Team Subject: Re: [PATCH v6 perf, bpf-next 1/7] perf, bpf: Introduce PERF_RECORD_KSYMBOL Thread-Topic: [PATCH v6 perf, bpf-next 1/7] perf, bpf: Introduce PERF_RECORD_KSYMBOL Thread-Index: AQHUqFCaPbT+UGXQnkaaX1wm9KrpVKWo0rKAgAAEoACAAAQiAIAACcSA Date: Thu, 10 Jan 2019 19:30:22 +0000 Message-ID: References: <20190109192111.130995-1-songliubraving@fb.com> <20190109192111.130995-2-songliubraving@fb.com> <20190110182403.GN22483@kernel.org> <064FBBA4-A0D0-4335-BCE7-902724CE2988@fb.com> <20190110185524.GO22483@kernel.org> In-Reply-To: <20190110185524.GO22483@kernel.org> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-mailer: Apple Mail (2.3445.102.3) x-originating-ip: [2620:10d:c090:200::6:3651] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM5PR15MB1161;20:pkM3RHfpYgenymV0Tc19MiDShO3RRiYTMv0/RQjIxeI63oGyFm/5WqxT4us/vqPiDuvlVfdL3IYjN2tvp557vPkfWfH6OBY3EopiEsMSGEcGIgbZdhn3RH9MCuQuVbgfeRmSTSEeQUcVFQCTolnpW8y8W+jsZdEP8moPbYHei/c= x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-correlation-id: 303a2e92-baa6-4224-2d4d-08d67732102f x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600109)(711020)(2017052603328)(7153060)(7193020);SRVR:DM5PR15MB1161; x-ms-traffictypediagnostic: DM5PR15MB1161: x-microsoft-antispam-prvs: x-forefront-prvs: 0913EA1D60 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(136003)(396003)(39860400002)(366004)(346002)(376002)(199004)(189003)(81166006)(81156014)(316002)(476003)(54906003)(478600001)(8676002)(97736004)(46003)(93886005)(106356001)(71190400001)(71200400001)(486006)(82746002)(83716004)(68736007)(229853002)(86362001)(6436002)(57306001)(186003)(11346002)(2616005)(446003)(6916009)(256004)(6486002)(5660300001)(6116002)(8936002)(102836004)(50226002)(76176011)(53546011)(6506007)(53936002)(36756003)(4326008)(2906002)(25786009)(14454004)(33656002)(6246003)(7736002)(6512007)(305945005)(99286004)(105586002);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR15MB1161;H:DM5PR15MB1163.namprd15.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: fb.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: 5TGq4+XutidWC1BW9vYNOy+rLL0HPJ2AmP6bEna6W+se4uCHznjk2iqGP8lhgJ3KTT+bFXrYlVgTmof2Ou43pY0g6/SwgTR1DrT4i1vL/jdPSVMOy7nkRWQE7nbI/L+zYyOWmgR54DlkfcMhkZEvylvB7q/9lM+BzQk3ZzSc/ZW6fyHi1mtV4fyqXw8XxFFoXwXovoUyFOtcxDh5SCyHTUvNdeAyu7qlpy1LYly7PPV7FES8O9edNPNcsElBz2p8Qw8D1AzyuTZrpglquiPXr98LC7LPCa6P2T+jugZaPdo4ij1sWGL8WtMFtyU6iPl2 spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-ID: <58DC48A9088BDE4E84A4126563AF9BB0@namprd15.prod.outlook.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 303a2e92-baa6-4224-2d4d-08d67732102f X-MS-Exchange-CrossTenant-originalarrivaltime: 10 Jan 2019 19:30:22.2476 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 8ae927fe-1255-47a7-a2af-5f3a069daaa2 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR15MB1161 X-OriginatorOrg: fb.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-01-10_07:,, signatures=0 X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Jan 10, 2019, at 10:55 AM, Arnaldo Carvalho de Melo = wrote: >=20 > Em Thu, Jan 10, 2019 at 06:40:37PM +0000, Song Liu escreveu: >>=20 >>=20 >>> On Jan 10, 2019, at 10:24 AM, Arnaldo Carvalho de Melo wrote: >>>=20 >>> Em Wed, Jan 09, 2019 at 11:21:05AM -0800, Song Liu escreveu: >>>> For better performance analysis of dynamically JITed and loaded kernel >>>> functions, such as BPF programs, this patch introduces >>>> PERF_RECORD_KSYMBOL, a new perf_event_type that exposes kernel symbol >>>> register/unregister information to user space. >>>>=20 >>>> The following data structure is used for PERF_RECORD_KSYMBOL. >>>>=20 >>>> /* >>>> * struct { >>>> * struct perf_event_header header; >>>> * u64 addr; >>>> * u32 len; >>>> * u16 ksym_type; >>>> * u16 flags; >>>> * char name[]; >>>> * struct sample_id sample_id; >>>> * }; >>>> */ >>>=20 >>> So, I couldn't find where this gets used, the intention here is just to >>> add the interfaces and afterwards is that you will wire this up? I woul= d >>> like to test the whole shebang to see it working. >>=20 >> I guess you meant PERF_RECORD_BPF_EVENT not being used?=20 >>=20 >> PERF_RECORD_KSYMBOL is used by BPF in 3/7 and 5/7. I tested=20 >=20 > Oops, I didn't look at 3/7, just read its cset summary line and as it > says: >=20 > Subject: [PATCH v6 perf, bpf-next 3/7] perf, bpf: introduce PERF_RECORD_B= PF_EVENT >=20 > I didn't thought it was related, perhaps break it down into one that > states that it is wiring up PERF_RECORD_KSYMBOL, and at that point we > could just test it, getting the notifications for new kallsyms related > to BPF? Good idea! I will split it into two patches as: [3/8] perf, bpf: generate PERF_RECORD_KSYMBOL for BPF program=20 [4/8] perf, bpf: introduce PERF_RECORD_BPF_EVENT >=20 >> PERF_RECORD_BPF_EVENT with dump_trace. As we separate RECORD_KSYMBOL fro= m >> RECORD_BPF_EVENT, user space won't use BPF_EVENT until annotation suppor= t. =20 >=20 > Right, so why not just introduce PERF_RECORD_KSYMBOL, make it be used by > tooling, etc, then move on to PERF_RECORD_BPF_EVENT? I'd like to make sure we all agree on the new ABI for RECORD_KSYMBOL and=20 RECORD_BPF_EVENT. Multiple user space tools dependent on RECORD_BPF_EVENT, for example, bcc and auditing. Finalizing RECORD_BPF_EVENT will unblock the= =20 development of these tools. On perf side, it will take us quite some time=20 to finish annotation. Ideally, I don't want to block the development of=20 other tools for so long.=20 Thanks, Song