all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Ergus <spacibba@aol.com>
Cc: emacs-devel@gnu.org
Subject: Re: Multithread or multiprocess in emacs??
Date: Mon, 17 Apr 2023 05:26:33 +0300	[thread overview]
Message-ID: <83r0sj9rc6.fsf@gnu.org> (raw)
In-Reply-To: <7w4yjuxtu6rm325oeddtl3fu4oe64fsarru3s4fnh7on5m7udl@wzxqo5pm6es7> (message from Ergus on Sun, 16 Apr 2023 22:50:24 +0200)

> Date: Sun, 16 Apr 2023 22:50:24 +0200
> From: Ergus <spacibba@aol.com>
> 
> Hi:
> 
> Very recently I have seen a code in an elpa package that starts async
> subprocesses; but instead of using make-process the package uses
> make-thread + process-file. This was to reduce the latency and some
> lagging (not evident in my system, but apparently it annoyed the
> package's author).
> 
> So, my question is now: Has anyone measured the overhead created by
> make-process in critical parts of the code like flymake checkers, or
> ispell? and compared with creating new threads?
> 
> If this is somehow significant maybe we may consider adding a helper
> thread or thread-pool for some purposes as now the C11 standard has the
> threads.h header.
> 
> Is there any work already in this direction? How does Elisp handles
> multithreading?

Lisp threads in Emacs don't support parallel processing, whereas async
subprocesses do.  So these two features are not two different
implementations of parallelism.



  reply	other threads:[~2023-04-17  2:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <7w4yjuxtu6rm325oeddtl3fu4oe64fsarru3s4fnh7on5m7udl.ref@wzxqo5pm6es7>
2023-04-16 20:50 ` Multithread or multiprocess in emacs?? Ergus
2023-04-17  2:26   ` Eli Zaretskii [this message]
2023-04-17 13:37   ` Philip Kaludercic
2023-04-17 13:58     ` Po Lu

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=83r0sj9rc6.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=spacibba@aol.com \
    /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.