Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2396946imu; Tue, 6 Nov 2018 13:56:54 -0800 (PST) X-Google-Smtp-Source: AJdET5fCWj6g3nTLzPwPYyBnxTDLVqzjpNnEjooBxCi+U6G8kznngCLoPFdSdXhz4XSg5b/APhaC X-Received: by 2002:a63:c70a:: with SMTP id n10-v6mr24835746pgg.431.1541541413992; Tue, 06 Nov 2018 13:56:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541541413; cv=none; d=google.com; s=arc-20160816; b=uZT1DRViuZJEivsFGzDx0fPn2dknM8sF174WxyNYlm51/xKDGmLtKWH2fujoe0xAX4 D9SPxFTnsxDM5PU8+MwYpJPqRtnH1u+diRGIw2hloQlPOeOHdDNTTALZwC21hKE/fJo6 yG126pK8vEMaJmuSY3R3ouAhXJUyKlpQaDIbxTGXVN+RDKnNG4vcityuSkmCZutuMekQ XE9kBpzbtKlzDe+NROG4FZSldAkmiWgp0Z533DY7MRMPX5MXMIaTrJZE3w/FzARXC91L 4G/wZOdB6FEK3S1QKuLPYQ021y4URmVGQRMxiAh0XPvhgeYdN4otpUKk1zEMau3z26eg M89w== 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=L7mT2wYXMecMbAvmjrJxTahyoUEFJDhWpI7hoacznyM=; b=krChGoiiZpmrfKekidpJNYKBTtli2EhnNjwhL8088U6TS0fEHR6R+ommtd9CI/4T8z dzkdp063P+GgJa8efUV6nKryWeORpuRbvuW/xuwy9ioW60HjU1XjxJFjMr2AoGlGPeKC eACAeWEuYQj3xsG6asiNcxwg/gTeCHuTHkItus/3K35Kq7OWVgfsQcdiZEp31J0X4ysg svH7zXM5T7i0NXjbt9Sfr5e37Q2KFHF3i9IZBxWesbpsQYON1IEN6tpbBTYlFBPg9zBJ 27bmYznCldQ29WDPOPsNvEx6LZ3kzqzUmTBCC4hRdodfkBqOEMDO3jt6VahSatXDiMWc Rf8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=g+ZfPtCx; 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 i13si5943553pgj.199.2018.11.06.13.56.38; Tue, 06 Nov 2018 13:56:53 -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=g+ZfPtCx; 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 S1730884AbeKGHVb (ORCPT + 99 others); Wed, 7 Nov 2018 02:21:31 -0500 Received: from mail-pf1-f177.google.com ([209.85.210.177]:32944 "EHLO mail-pf1-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726069AbeKGHVa (ORCPT ); Wed, 7 Nov 2018 02:21:30 -0500 Received: by mail-pf1-f177.google.com with SMTP id v68-v6so3143379pfk.0; Tue, 06 Nov 2018 13:54:12 -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=L7mT2wYXMecMbAvmjrJxTahyoUEFJDhWpI7hoacznyM=; b=g+ZfPtCxdIA/hxX7eK9yMAY4bXAxoUS/b9PV3cUdrjXKGDIR4bVb71/zXlw0RB0E6X gDLTJr1EUr/lFy+IF6tgdkUup7Kx/YqI3rroMldlfXRznfzJT8yJonJe7e+EU7LaxPbO PAB58Nlf18gt5WhGaJypfc0PBnxkQIPbHqI4Bnh94hrbGzPYei2/B110HKHb8lVlsTiQ THydeEWCxCIM9PJKChvqWpVSfeQX4Pvu83o6u8gXb0Ok+U6TUwwbUCvRUQaB7sPDTybq 9Z7OALtx2YgQ049jBZYXphxUzggEAqmWPzMusbFnjbB5/mJG6J8VyTgFJojQmoF1bxuN srdA== 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=L7mT2wYXMecMbAvmjrJxTahyoUEFJDhWpI7hoacznyM=; b=jr6KVCOXhrzOYJiOxVNE2JQMoe1XM5Oop7TiKcqRYiCFZ/InsCw2j72RZNJwoZ1Jkf STcvWGh642o6btrmxwQYpWl/HiBuJ/Yv9aeYQ2yP8+iID/MsqRabRGIH20jZc4a9KWUg SUSN9fvbCih0l9dI7ArmtaooRh4kGoaID7EanHqTbJ9DHwtgThZ5+7r0R1NLLkjIIi5+ ND80C7ukMsesZRuzOCxbS5oISReX2eWHRQj7RwRiLLEooD8jDnQ6dHOf+YQtgLAlnHtX jgNOAo2LyCcHO0aa+udJdYVcOMn9Hk0FT3x0Ckig64Wi+qF65t4Bostk0ZmPsDLAIkPU dN0w== X-Gm-Message-State: AGRZ1gKXcL150MK6FwQ8zKnAHQ4R/Y/14HiBMUs7fv502c5MkpkXNi17 CkPug1zjHxkh93Gu6gpBmVc= X-Received: by 2002:a63:f710:: with SMTP id x16mr25415819pgh.322.1541541251698; Tue, 06 Nov 2018 13:54:11 -0800 (PST) Received: from ?IPv6:2601:282:800:fd80:30c7:3851:bc7d:ba41? ([2601:282:800:fd80:30c7:3851:bc7d:ba41]) by smtp.googlemail.com with ESMTPSA id r137-v6sm14130467pfc.105.2018.11.06.13.54.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 06 Nov 2018 13:54:10 -0800 (PST) Subject: Re: [RFC perf,bpf 5/5] perf util: generate bpf_prog_info_event for short living bpf programs To: Song Liu , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: kernel-team@fb.com, ast@kernel.org, daniel@iogearbox.net, peterz@infradead.org, acme@kernel.org References: <20181106205246.567448-1-songliubraving@fb.com> <20181106205246.567448-6-songliubraving@fb.com> From: David Ahern Message-ID: Date: Tue, 6 Nov 2018 14:54:09 -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: <20181106205246.567448-6-songliubraving@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 1:52 PM, Song Liu wrote: > + > static int record__mmap_read_all(struct record *rec) > { > int err; > > + err = record__mmap_process_vip_events(rec); > + if (err) > + return err; > + > err = record__mmap_read_evlist(rec, rec->evlist, false); > if (err) > return err; Seems to me that is going to increase the overhead of perf on any system doing BPF updates. The BPF events cause a wakeup every load and unload, and perf processes not only the VIP events but then walks all of the other maps. > @@ -1686,6 +1734,8 @@ static struct option __record_options[] = { > "signal"), > OPT_BOOLEAN(0, "dry-run", &dry_run, > "Parse options then exit"), > + OPT_BOOLEAN(0, "no-bpf-event", &record.no_bpf_event, > + "do not record event on bpf program load/unload"), Why should this default on? If am recording FIB events, I don't care about BPF events.