all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Phil Hagelberg <phil@hagelb.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: Kickstarter for Emacs
Date: Wed, 25 Apr 2012 16:33:52 +0000	[thread overview]
Message-ID: <8762cnahzj.fsf@hagelb.org> (raw)
In-Reply-To: <jwvd36xnb8g.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Mon, 23 Apr 2012 22:01:13 -0400")

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>>> The problem still remains: what would be the benefit?
>> I must confess this is difficult for me to express, simply because
>> it's something I've taken for granted for so long; it's like being
>> asked why I like garbage collection. Anyhow, the most obvious benefit
>> would be that you have a chance at writing code that you know will
>> function correctly while run concurrently. =)
>
> I'm an academic working in functional programming and type systems, so
> you don't have to convince me of the general virtues of
> side-effect-free code.
>
> So my question is specifically in the context of Emacs where you need to
> balance the theoretical benefits against the downsides (mostly
> incompatibilities and efforts that could be spent elsewhere).

I guess the main specific benefit (beyond the general "easier to write
functions you know are correct") is that once you introduce concurrency,
you will need a way to share data between different threads. Shared
mutable state is very very difficult to get right; in order to avoid
race conditions you must construct complex, error-prone, and
non-composable locking strategies and adhere to them rigidly.

Another option of course would be to force all cross-thread
communication to go through channels that cause data to be copied, but
this would probably feel unnatural and would be difficult to enforce in
addition to being more expensive.

The benefit in Emacs as it is today might not be too clear, but I
believe this to be an important step to take as we move into the
concurrent world.

-Phil



  reply	other threads:[~2012-04-25 16:33 UTC|newest]

Thread overview: 58+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-18  7:08 Kickstarter for Emacs Tom
2012-04-18  7:50 ` Tom
2012-04-18  8:59   ` Chong Yidong
2012-04-18  9:25     ` Tom
2012-04-18  9:38       ` Vyacheslav Gonakhchyan
2012-04-18  9:43         ` Tom
2012-04-18 10:14           ` Vyacheslav Gonakhchyan
2012-04-18 10:34             ` Tom
2012-04-18 11:00               ` Jambunathan K
2012-04-18 11:20                 ` Tom
2012-04-18 11:39                   ` Jambunathan K
2012-04-18 13:10               ` Tassilo Horn
2012-04-18 13:47                 ` Tom
2012-04-18 14:19                   ` Nikodemus Siivola
2012-04-18 14:57                     ` Tom
2012-04-18 22:09                       ` Phil Hagelberg
2012-04-19 21:02                         ` Stefan Monnier
2012-04-21  0:10                           ` Phil Hagelberg
2012-04-21  2:46                             ` Stefan Monnier
2012-04-23  5:17                               ` Phil Hagelberg
2012-04-23  8:17                                 ` Guile based Elisp faster? (was Re: Kickstarter for Emacs) Thorsten
2012-04-24 11:35                                   ` Guile based Elisp faster? Andy Wingo
2012-04-24 17:46                                     ` Thorsten Jolitz
2012-04-24  2:01                                 ` Kickstarter for Emacs Stefan Monnier
2012-04-25 16:33                                   ` Phil Hagelberg [this message]
2012-04-19  0:45                     ` Richard Stallman
2012-04-19  6:23                       ` [PROPOSAL] GSoC-like campaingn for FSF/GNU projects Jambunathan K
2012-04-19 17:54                         ` Bastien
2012-04-19 18:38                         ` Richard Stallman
2012-04-19 11:58                       ` Kickstarter for Emacs Nikodemus Siivola
2012-04-19 18:38                         ` Richard Stallman
2012-04-18 14:27                   ` Tassilo Horn
2012-04-18 14:50                     ` Tom
2012-04-23  9:23                     ` Steinar Bang
2012-04-23  9:20                       ` Tassilo Horn
2012-04-19 12:47                   ` Richard Riley
2012-04-18 22:39               ` Bastien
2012-04-18 14:33       ` Eric Schulte
2012-04-19  0:45         ` Richard Stallman
2012-04-19  5:28         ` Tom
2012-04-19  6:05           ` Jambunathan K
2012-04-19 18:38           ` Richard Stallman
2012-04-19 19:04             ` Tom
2012-04-25 19:56     ` Jordi Gutiérrez Hermoso
2012-04-18 18:25   ` Richard Stallman
2012-04-18 11:25 ` Jambunathan K
2012-04-18 13:34   ` Tom
2012-04-18 16:08 ` Ivan Andrus
2012-04-18 16:24   ` Drew Adams
2012-04-18 18:49   ` Andreas Röhler
2012-04-18 19:04   ` aaditya sood
2012-04-18 19:44     ` Andreas Röhler
2012-04-19  1:50   ` Chong Yidong
2012-04-19  5:13     ` Andreas Röhler
2012-04-19 15:22     ` Rasmus
2012-04-19 16:10     ` Ivan Andrus
2012-04-19 22:07       ` Stefan Monnier
2012-04-20  7:33         ` Ivan Andrus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8762cnahzj.fsf@hagelb.org \
    --to=phil@hagelb.org \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.