From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?B?U8O4cmVuIFBpbGfDpXJk?= Newsgroups: gmane.emacs.devel Subject: Re: Emacs Lisp's future Date: Sun, 9 Oct 2016 14:43:36 +0200 Message-ID: References: <87wq97i78i.fsf@earlgrey.lan> <86k2dk77w6.fsf@molnjunk.nocrew.org> <9D64B8EA-DB52-413D-AE6A-264416C391F3@iotcl.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: blaine.gmane.org 1476017042 11010 195.159.176.226 (9 Oct 2016 12:44:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 9 Oct 2016 12:44:02 +0000 (UTC) Cc: John Wiegley , emacs-devel@gnu.org, Lars Brinkhoff To: Toon Claes Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Oct 09 14:43:57 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1btDSG-0001Cw-Ix for ged-emacs-devel@m.gmane.org; Sun, 09 Oct 2016 14:43:48 +0200 Original-Received: from localhost ([::1]:44385 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1btDSF-0000n8-4e for ged-emacs-devel@m.gmane.org; Sun, 09 Oct 2016 08:43:47 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41719) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1btDS8-0000n1-7K for emacs-devel@gnu.org; Sun, 09 Oct 2016 08:43:41 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1btDS5-0004Sn-S4 for emacs-devel@gnu.org; Sun, 09 Oct 2016 08:43:39 -0400 Original-Received: from mail-io0-x22f.google.com ([2607:f8b0:4001:c06::22f]:36169) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1btDS5-0004Se-Mu for emacs-devel@gnu.org; Sun, 09 Oct 2016 08:43:37 -0400 Original-Received: by mail-io0-x22f.google.com with SMTP id j37so87462029ioo.3 for ; Sun, 09 Oct 2016 05:43:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=PRYo2si5JbBl3iIBULA8bf4OOFpCeSy7BveFX3/nqkc=; b=GpxDVlBBw9tImST3zGJZN9A20xa9WZPk4Mkp4IsHvijNAhP9N03mw+d8TQW0nGBzor Zv0Q52iTh00L5hrBjPzCUidKbkLEldpCuGAEyOdnPyTuEUN2bWpUXiMArmTS0wFJulZs rupA5z5Z+nKdJbgLv+aJnFdz3wN3smQVQ3dGwIGJB9ZibXwZ1Cj9NPuATRfu/eMFiGky j0xUd2Utti2J7cTRD1/iYmiVH3DDEIEW4U8ckrOEJN9q30/iFu0sKTqaXOpSmEDNAwfi EBmyVf5Dsjye04OklFN5vsmUOlGs3ovMEzMhdZorYWtoXzRsoWI2qYx5fkrFbm8rWadR IB+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=PRYo2si5JbBl3iIBULA8bf4OOFpCeSy7BveFX3/nqkc=; b=aU2tkIcYstSG6D+We5t0HAgSTeJ8kMakyK/yuXGyfev57B7vq2YqY+zLf9v4dz+HP7 bvSiK1UVeelfVOsdN0fDS5xEI71Donv3hIWLEWLA2rRiyyxsMZPpe3m114D8COl90T28 /QAUhuWbvp6vYinaN4rtvJHUKVQ6+tgX0iwoLyM72Lgdz4dRQYm28xr0PlEdv+BIYJRR V2XQxmkcIbJwBsykyFgh18IGVJGU5+6ordShifE/vbam/B6k141jfG/M2epmLgRX9VEl VpAgs7E7EIkgktPASMnwvKS2iX3Kg2vpLdNzWPiVcF2YCx3Y/Wl8C3Xa+nUw/YepV2+1 omHg== X-Gm-Message-State: AA6/9RlNDigJGe/PAd7rK85JgfWJ646t4o1WOTC+NW2L8TFhzMBQJsHejCifsjSRll1i+crZMtUuXv/U/u/xFA== X-Received: by 10.107.26.79 with SMTP id a76mr27709023ioa.54.1476017016858; Sun, 09 Oct 2016 05:43:36 -0700 (PDT) Original-Received: by 10.36.238.202 with HTTP; Sun, 9 Oct 2016 05:43:36 -0700 (PDT) In-Reply-To: <9D64B8EA-DB52-413D-AE6A-264416C391F3@iotcl.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2607:f8b0:4001:c06::22f X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:208116 Archived-At: On Sun, Oct 9, 2016 at 2:03 PM, Toon Claes wrote: > On 7 Oct 2016, at 19:07, John Wiegley wrote: > > It would be nice to have real compilation > of Emacs Lisp after the manner of Common Lisp, and maybe the concurrency > support; > > > Oh yes, please add concurrency support! > Would it help if we would start a crowdfunding campaign for this? Because I > know a few fellow emacs user who would definitely back it. > > Regards, > Toon Claes The thing about concurrency is that it is very hard to integrate meaningfully and robustly into Emacs. All Emacs lisp code has the basic assumption, that when it is running, it is the only code running. Introducing concurrency would either break that assumption or have to make it explicit somehow, potentially breaking tons of existing code. As an example, lets say you have a plugin that count occurrences of a word, and another that corrects spelling mistakes. As it is now, the counting plugin can assume no other code runs when it counts and it can thus simply scan the buffer. But if we let both run simultaneously the spelling correcter could modify the buffer resulting in the wrong count as some were done before and some after the modification. Oh, but couldn't we then just let each buffer have its own "world" where everything is sequential? Well we would lose the ability for the spelling correcter to run while we were working negating the benefit. And further, what if the plugin counting occurrences gave the total count for all buffers? Then it would have to lock all buffers somehow, so no other code could modify them simultaneously. As you can see, introducing concurrency has wide implications for Emacs. Finding a way to go about it that will still allow old "naive" code to function correctly is what makes it so tough. Hopefully we will someday have that, but it requires a lot of hard work. Maybe we could start out with something like javascripts webworkers. A function running in its own world without access to buffers or other shared state, and then we could communicate by message passing. But as the keen eye would observe that is very similar to simply spawning an external process. And it wouldn't benefit much for problems that rely on buffers or global state. This problem will clearly not be solved just by switching the underlying platform.