Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2515439imu; Tue, 6 Nov 2018 16:25:37 -0800 (PST) X-Google-Smtp-Source: AJdET5ek1WNj0+kbAVFaW7pd0gcdN8CU0xqMCRiz0V9obkID3mnW6ooIY0mZlJibPelQ0rELTQwg X-Received: by 2002:a62:8145:: with SMTP id t66-v6mr28388260pfd.246.1541550337270; Tue, 06 Nov 2018 16:25:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541550337; cv=none; d=google.com; s=arc-20160816; b=N7MgPcEeFBIrNQYQFjcRagkPYqf3F4NaASwPOPZRal2BKW6MQyCkNBcA+o6YhGDOY3 oozd+y+qidRKmPoV/HwdS8Tl+octwwyTCD7AbR4IgCFrotUOivNWt9N9weeDbJFo24OU FF5t1yQsiE/5qXGoKuMFu2FRBW5yxas9kf3rZkxVGYPV7uXEehs6rvm1nHZ4mLBQgbUQ XutH3cKcEroyEnscTnw9Rm/uqEYL9U8d3ChIY6DvQf0voM7XlmsG87PP14minLfqOg8s tQ+Tj2OcTgVWM7EYDgv1HfrMnzfMEEMqLQWMLlne0U++h7QuGikiwjZBUt4x8hhclS3T nQyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=Dls76p0eWgFvyL0Gd9YyNIfjDQgofUni5koSjPrUFqg=; b=IYhelPtetPCPL2yn+sovQvz4vyw358dGU3bRDjprnUWa5EgBko9FG/MVBEDoxqYzfe pztr5z2KsJOopFgiXPj+awMyrAbn8EqJE/vXGpI9mBbLDwWjNygxLqRBDFRpk40S0c5r eBdmTQDKNhFqL3rdDTwlSnduq7OqIXUugf2JtkaBv4yP72wp961M32mRAbkYmd8Dox04 s9HzOHVV9sha/MKwCohJJjRFhX2LfcyluKznGIBON6Kg58Nm4bicNQlcjLfEyxX67w6c HFWYD3kLDwWsCoCNI5pvrdLXk+Nty/a1i2Gwy0bqMWhqgdpMCxEmoJeUWssiPU2uRMlu ojpA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ZTPhr6CE; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i136-v6si14284328pfe.224.2018.11.06.16.25.22; Tue, 06 Nov 2018 16:25:37 -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=@gmail.com header.s=20161025 header.b=ZTPhr6CE; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388314AbeKGJvV (ORCPT + 99 others); Wed, 7 Nov 2018 04:51:21 -0500 Received: from mail-pl1-f175.google.com ([209.85.214.175]:40909 "EHLO mail-pl1-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730885AbeKGJvU (ORCPT ); Wed, 7 Nov 2018 04:51:20 -0500 Received: by mail-pl1-f175.google.com with SMTP id q19-v6so4006366pll.7; Tue, 06 Nov 2018 16:23:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=Dls76p0eWgFvyL0Gd9YyNIfjDQgofUni5koSjPrUFqg=; b=ZTPhr6CEfJffRjbE9jr3qmDQEWnMN27lHmGiB7tKpqpPHWnbBK/dM9hnndAFGzDPZT DseYtoJklsLzMptNbfTSUc6gKqAA8moLxahjAbHH6OHrLj0Sd5LpwkGm5MzGJGfTllWg pRyZdjBCUAIK7Tv0TxayGC0trwGFxd/+abjtJCQ5G3H9q3QFwwpeO7vksz+ykYOjOrAD MyNd+CAuzE6QJfWJRwWkxwbgxjZWKlCAkTKaXd6YUd3kB84IxXWhb+l5omfItKmiCENe AlFMTTCbgi/zFq6fUmbVRdk9ze1WdojsLt1mYr5LsPbBptohsubw+J1osGp+onK4/ot3 W1CA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=Dls76p0eWgFvyL0Gd9YyNIfjDQgofUni5koSjPrUFqg=; b=qUH3im8nADrTY9Gw3TavcjU/kTp7BB6pr0vjittkSVGnhkSNq2+JozfC6jn8YgPmue TDdBq3XHLYjtpNeCO+medXZ72duFfzg6Z2wSFYxHWEtSKW8SKBgqXoEP+65EEzcI3aeD JdgvUwwV5Tr6CY4RxyX838fwfcG50FRyt39UCsVpkWKMtFxFcQIG8Zhz8PX8dIg68sXc nNBweuseEJqPbUuNUg0YT2vzCQiFpIhpDRKeFRg7yjeAZaYmiyNbNu2bZwrlETU9sOqk k+dSN2yuMYctlG1nYtgZr0unSpsdLY2UUuxjOrFLnsq1X5Z20nhAnGba4aAUcELfNVoq WKhQ== X-Gm-Message-State: AGRZ1gLn1XJjj55W14zbJj9CUydkCacPgE7/OpZhdq7ikZHUc7yHDMqq jc370hZKZluiPs1tJQLmPrk= X-Received: by 2002:a17:902:5590:: with SMTP id g16-v6mr28488280pli.56.1541550208388; Tue, 06 Nov 2018 16:23:28 -0800 (PST) Received: from ?IPv6:2601:280:a:e2f8:c080:1705:befd:aeb0? ([2601:280:a:e2f8:c080:1705:befd:aeb0]) by smtp.googlemail.com with ESMTPSA id u19-v6sm77370217pfj.115.2018.11.06.16.23.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 06 Nov 2018 16:23:27 -0800 (PST) Subject: Re: [RFC perf,bpf 5/5] perf util: generate bpf_prog_info_event for short living bpf programs To: Alexei Starovoitov , David Miller Cc: Song Liu , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Kernel Team , "ast@kernel.org" , "daniel@iogearbox.net" , "peterz@infradead.org" , "acme@kernel.org" References: <6C5A9FBD-F50D-444C-9038-E9557EC850D2@fb.com> <27fc8327-3390-ba5a-6063-89c9e7165e7b@fb.com> <20181106.153647.1701013551426767213.davem@davemloft.net> <39fe6abc-5c3e-bac3-0c0b-cf68bea23ab0@fb.com> From: David Ahern Message-ID: <0a05a14c-3a79-e894-ae48-cbe1df4feb91@gmail.com> Date: Tue, 6 Nov 2018 17:23:25 -0700 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <39fe6abc-5c3e-bac3-0c0b-cf68bea23ab0@fb.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/6/18 5:13 PM, Alexei Starovoitov wrote: > On 11/6/18 3:36 PM, David Miller wrote: >> From: Alexei Starovoitov >> Date: Tue, 6 Nov 2018 23:29:07 +0000 >> >>> I think concerns with perf overhead from collecting bpf events >>> are unfounded. >>> I would prefer for this flag to be on by default. >> >> I will sit in userspace looping over bpf load/unload and see how the >> person trying to monitor something else with perf feels about that. >> >> Really, it is inappropriate to turn this on by default, I completely >> agree with David Ahern. >> >> It's hard enough, _AS IS_, for me to fight back all of the bloat that >> is in perf right now and get it back to being able to handle simple >> full workloads without dropping events.. > > It's a separate perf thread and separate event with its own epoll. > I don't see how it can affect main event collection. > Let's put it this way. If it does affect somehow, then yes, > it should not be on. If it is not, there is no downside to keep it on. > Typical user expects to type 'perf record' and see everything that > is happening on the system. Right now short lived bpf programs > will not be seen. How user suppose to even know when to use the flag? The default is profiling where perf record collects task events and periodic samples. So for the default record/report, the bpf load / unload events are not relevant. > The only option is to always pass the flag 'just in case' > which is unnecessary burden. People who care about an event enable the event collection of the event.