[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: try-this-for ?

From: Emanuel Berg
Subject: Re: try-this-for ?
Date: Thu, 18 Jan 2018 13:00:49 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux)

tomas wrote:

> Up to now, Emacs Lisp's model of concurrency
> seems to be explicitly cooperative.

"seems to be explicitly" :) ?

True concurrency isn't possible even for
multicore architectures IIUC.

The perceived concurrency, how does that work
if it isn't Unix-style preemptive with
priorities and a scheduler etc.?

For example, with `list-processes', is that
really all cooperative stuff handled by the
idle timer?

I thought the idle timer did font lock and such
lightweight not-really-necessary background
work whenever it got the chance, however that
must be something else as it isn't listed.

By the way, if Emacs cannot preempt, when the
idle timer does background work during
a lack-of-input respite, does that mean, when
you start typing again, the background work
isn't preempted either, only it is programmed

    (when t
      (do-something step-1)
      ; ...
      (do-something step-n) )

so despite not being preemptable, perceived
concurrency is achieved as everything is so
fast anyway?

> For one, if you want to wield more computing
> power in one process: remember, the box you
> bought has at least two cores, and each core
> not dedicated to Emacs is one core wasted.

I remember writing a post on this very list how
to dedicate one core entirely to Emacs! It must
be lost somewhere in the archives.
What I remember it made Emacs run slightly
faster :) I guess one can achieve virtually the
same with nice(1) and/or not running anything
else :))

underground experts united

reply via email to

[Prev in Thread] Current Thread [Next in Thread]