From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.4 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6172FC432C0 for ; Tue, 3 Dec 2019 10:44:52 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 1177520659 for ; Tue, 3 Dec 2019 10:44:51 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="XIgg8xKf" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1177520659 Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 9B67E6B0393; Tue, 3 Dec 2019 05:44:51 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 9674B6B0394; Tue, 3 Dec 2019 05:44:51 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 87CAF6B0395; Tue, 3 Dec 2019 05:44:51 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0254.hostedemail.com [216.40.44.254]) by kanga.kvack.org (Postfix) with ESMTP id 731796B0393 for ; Tue, 3 Dec 2019 05:44:51 -0500 (EST) Received: from smtpin21.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with SMTP id 34857442C for ; Tue, 3 Dec 2019 10:44:51 +0000 (UTC) X-FDA: 76223497182.21.fuel65_81995440e370d X-HE-Tag: fuel65_81995440e370d X-Filterd-Recvd-Size: 7759 Received: from mail-wm1-f46.google.com (mail-wm1-f46.google.com [209.85.128.46]) by imf20.hostedemail.com (Postfix) with ESMTP for ; Tue, 3 Dec 2019 10:44:50 +0000 (UTC) Received: by mail-wm1-f46.google.com with SMTP id p9so2447555wmg.0 for ; Tue, 03 Dec 2019 02:44:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=yf8eK6nn/l8FBqy5zy+AQkQtE/1bo2oQ0xqOSWkZCR8=; b=XIgg8xKfAuwhAndLQtjdTcfLlVqUk24xPrpU17I7MmFjt5p66hMSn932pL1MRxVi+j o4vYyl/TunwgBp0WiFl1U7s5Jj36jwcgYfm5rO4EYTMQsEnD/9GfJIBNshS9EROAcGQF Stgsc0p+lG9UrmSRY0x7i7uPaSPpRM0+KSOhh1BnFly7MqhqASi3ZYpqHNWg+YcLeqJL DiVI5n99SMaAe89wnsfwRK+isI6dUdcyuY6mEStYZHVoGI8sl435l2dQ73dc75x68FR/ OKFrtnxJA/88SstUjKUim9i0UneX1SvppClLzH9RHc897yNyGP5D2dTwXtoANMBhAAAy 8JfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=yf8eK6nn/l8FBqy5zy+AQkQtE/1bo2oQ0xqOSWkZCR8=; b=POO87yRvqC++prl2Go19d3LlqVWz1Y+JzsgdANe+Rh4iH/qXaDU5a+L6UivU/mgzmr rUgd+E9y/2rEpgu/iQHLVVDU5alkcTzD6hmQj99LG4tFwXBf/4h8sCS2A3+STSn5R5De lVeG3BH3hNr5CZ3EKJyTHPTm5m1ycaU7DBVMY8/f10kd+P8avTVEWqqM+pE1V1d2N3W8 sLgprFFm+mtwp2XlRvtVVonwtO9EhwC8SKmKPjkuQBs4FA06Ii32jcHKYZga6HbyhF02 jJIySTbXC1g3+SBri4fbTR4OsUwoP0/54XvXQdiGgqHBNzAM9Bzzt8OvIzHhmJ2T6ILD 8poQ== X-Gm-Message-State: APjAAAUi7qqcd1WKDh4srpZEKijso77dfr+N3xhIJITM/d+/f+4aLLwl djZrDJ1jBfDnPMCWlgGOg5OskqaUB/LCAPAg9VHBLA== X-Google-Smtp-Source: APXvYqx55B035A8gsWC2BlpEgHZF47qcDE5HlVUK/fW05iM+0q/Aj6R7VeptDOdyVXlB9pf2o0SG+eWgyfT0ZwxC4wY= X-Received: by 2002:a1c:1dc9:: with SMTP id d192mr26120779wmd.92.1575369888674; Tue, 03 Dec 2019 02:44:48 -0800 (PST) MIME-Version: 1.0 References: <20191201015030.MR-ux4mV1%akpm@linux-foundation.org> <20191202121415.1e64a461@gandalf.local.home> <20191202211345.GE17234@google.com> <20191202165601.42366c21@gandalf.local.home> <20191202234514.GR17234@google.com> <20191202185324.30b502bb@gandalf.local.home> <2084584347.3560.1575351504972.JavaMail.zimbra@efficios.com> In-Reply-To: <2084584347.3560.1575351504972.JavaMail.zimbra@efficios.com> From: Primiano Tucci Date: Tue, 3 Dec 2019 10:44:36 +0000 Message-ID: Subject: Re: [patch 026/158] mm: emit tracepoint when RSS changes To: Mathieu Desnoyers Cc: rostedt , "Joel Fernandes, Google" , Andrew Morton , aneesh kumar , Carmen Jackson , Dan Williams , Daniel Colascione , jglisse@redhat.com, linux-mm , Mayank Gupta , Michal Hocko , Minchan Kim , mm-commits@vger.kernel.org, rcampbell@nvidia.com, Tim Murray , Linus Torvalds , Vlastimil Babka , Matthew Wilcox Content-Type: text/plain; charset="UTF-8" X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue, Dec 3, 2019 at 5:38 AM Mathieu Desnoyers wrote: > > ----- On Dec 2, 2019, at 9:48 PM, Primiano Tucci primiano@google.com wrote: > > > On Mon, Dec 2, 2019 at 11:53 PM Steven Rostedt wrote: > > On Mon, 2 Dec 2019 18:45:14 -0500 > > Joel Fernandes wrote: > > > >> > >> I would love for that to happen but I don't develop Perfetto much. If I am > >> writing a tool I will definitely give it a go from my side. CC'ing Perfetto's > >> lead developer Primiano -- I believe you have already met Primiano at a > >> conference before as he mentioned it to me that you guys met. I also believe > >> this topic of using a common library was discussed before, but something > >> about licensing came up. > > > > Oh hello again! > > > >> libtraceevent is under LGPL, is that an issue? > > > > Unfortunately yes, it is :/ > > Our process for incorporating GPL or LGPL code makes Perfetto [1] (which is > > Apache-2 licensed) problematic for us and recursively for other projects that > > depend on us. > > > > For context, Perfetto is a cross-platform tracing project based on shmem and > > protobuf, shipped on production devices and used by other app-developer-facing > > tools (e.g. [6, 7]). It deals with both: > > (1) pure userspace-to-userspace tracing (on all major OSs). > > (2) kernel tracing via ftrace/tracefs (only on Linux/Android). > > https://docs.perfetto.dev/ explains it a bit more. > > > > Today Perfetto is embedded and used both by Chrome [2] and Android platform [3]. > > For both projects, pulling LGPL-licensed code is cumbersome process-wise: It > > would require us to put mechanism in place to guarantee that the relevant LGPL > > dependencies don't get accidentally linked in any production binary but only > > used for the standalone offline tools to analyze traces. > > Such process is unfortunately very expensive to setup and maintain for us and > > for the projects that depend on us. > > I don't want to start an ideological battle about licensing. To be clear, I > > don't have any issues with LGPL, nor I think there's anything inherently > > wrong with it. Just, it makes things too complicated when a smaller sub-project > > like ours is embedded in larger projects. > > Just to clarify: my understanding is that a constraint that requires no dynamic > linking of proprietary code on LGPL libraries does not seem to originate from > restrictions based on the wording of the LGPL text. So it appears to be self-imposed > either by your employer's (or your own) additional requirements, so not to bother > dealing with the legal side of compliance, am I correct ? Essentially adding a LGPL dep for us is the moral equivalent of putting a sticker on the project that says "This needs to be handled with care now". Any new user of the project would need to go through the process of putting build-time scripts/checks in place to ensure that the dynamic linking requirements are not accidentally violated. In large projects with hundreds of build targets (like the aforementioned ones which embed Perfetto today), refactorings happens every single day. The risk of somebody pulling unwanted deps by accident is non-zero. Licensing is not something that one can risk to accidentally get wrong, hence we are required to do our best to avoid those mistakes. Furthermore, from a pure technical viewpoint, dynamic linking is a major pain for many cross-platform projects because has different subtleties on each platform. Most projects just ship big statically linked monoliths. Having a LGPL dependency in Perfetto means telling them "if you want to use this tracing project you need to change your build rules / packaging strategy and start dealing with dynamic linking on four different platforms (Linux, Android, Mac, Windows)". This would be a show-stopper for our project. Primiano > > Thanks, > > Mathieu > > -- > Mathieu Desnoyers > EfficiOS Inc. > http://www.efficios.com -- Primiano Tucci Software Engineer Google UK Limited Registered Office: Belgrave House, 76 Buckingham Palace Road, London SW1W 9TQ