From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Pip Cet via "Emacs development discussions." Newsgroups: gmane.emacs.devel Subject: Re: Merging MPS a.k.a. scratch/igc, yet again Date: Tue, 10 Dec 2024 15:10:44 +0000 Message-ID: References: <871pyijctd.fsf@protonmail.com> <8634iyf257.fsf@gnu.org> <8634iwex8q.fsf@gnu.org> <87plm0msrq.fsf@telefonica.net> <87zfl4npcd.fsf@debian-hx90.lan> <87ldwnn0ny.fsf@telefonica.net> Reply-To: Pip Cet Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17126"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: =?utf-8?Q?=C3=93scar_Fuentes?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Dec 10 17:35:00 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1tL3CO-0004ET-7T for ged-emacs-devel@m.gmane-mx.org; Tue, 10 Dec 2024 17:35:00 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tL3BS-0007Kv-7e; Tue, 10 Dec 2024 11:34:02 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tL1t2-00020H-Bs for emacs-devel@gnu.org; Tue, 10 Dec 2024 10:10:58 -0500 Original-Received: from mail-40133.protonmail.ch ([185.70.40.133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tL1sx-00071C-Ev for emacs-devel@gnu.org; Tue, 10 Dec 2024 10:10:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1733843448; x=1734102648; bh=F91xXlt7s53H/SB/aa2ttyect/DkvI/KnGBg7m/4CaM=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=ylXTDBljO1W788lI6U/6MSxfW+D6A86san55PiOVsKKizKBKn/KMZeM470Wr6/VN5 38ZVfrFvI9APaqsh4QiRlh7bfTFinSvTJ8D0TkmDl7vPepj0rZoKBZA72vUXEN9BhC iQ8dxePF5LjHZjtaSXL2B2UZk12GVVXOWFjJwrPFgOMSzsMsSa0qVRV7auCXjxya8B lnp5x6BgXUX+/M5guiSkWvsbtX0pS+TWSfvqhhOT51fMjf/o10UYH+PmUtiH9bKIsq BNKYJZ7ly7Ii4gGw1/VewMlQThS+0fpMzANLP2g8IvoMZRJuI4pXtSdsLYOHJTd8FX 2f/DodSFijQCw== In-Reply-To: <87ldwnn0ny.fsf@telefonica.net> Feedback-ID: 112775352:user:proton X-Pm-Message-ID: d7e3bdc7bbcdaf1578c183e927fef54c9d10054c Received-SPF: pass client-ip=185.70.40.133; envelope-from=pipcet@protonmail.com; helo=mail-40133.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Tue, 10 Dec 2024 11:33:59 -0500 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:326299 Archived-At: On Tuesday, December 10th, 2024 at 13:10, =C3=93scar Fuentes wrote: > Xiyue Deng manphiz@gmail.com writes: > * It is very likely that we end doing some patching to the MPS sources > to adapt to our specific needs (if those patches end upstream or not, > that's another question.) If that ends up being the case, we'll have to make sure not to use shared l= ibraries which may contain the upstream code. But that's true of all librar= ies; in the particular case of a Debian package, both the APT versioning sc= hemes and ELF versioning are available for that. > * MPS does a performance-critical job. Using it as a shared object might > incur in a performance penalty. Having it in source form alongside the > Emacs sources will result in opportunities for optimizations (LTO, > PGO, ...) that may bring better performance. ...and more problems. MPS has made the decision not to work with gcc -O3, o= nly with -O2 or less, and LTO in particular is something MPS cannot reliabl= y support, IIUC. > * MPS does a correctness-critical job. Depending on multiple external > sources for such core component is a recipe for problems (future > changes by the MPS maintainers, patching by packagers, buggy > compilers, etc.) We need to keep a close watch on what MPS incarnation > we use. Better yet, total control. I think the correctness argument goes both ways: shared linking means bugs = may be fixed for you automatically, as is routinely the case with libc. > For those reasons, incorporating MPS into the Emacs sources is the right > thing to do. I don't think that's an option, because Emacs should remain capable of swit= ching to GPLv4 if and when that is released, and we don't know whether the = MPS license is compatible with such a future document. So it's either static or dynamic linking; static links have these disadvant= ages: * shared libraries on GNU/Linux have versioning, static libs don't, AFAIK * legally, statically-linked binaries are quite different from dynamically-= linked ones * someone might enable LTO and break MPS (this may be done automatically by= the compiler rather than a user error) * with dynamic linking, there is some hope we could switch from libmps.so t= o libmps-debug.so without having to recompile Emacs, which would help us di= agnose crashes in their actual environment Pip