all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Aaron Jensen <aaronjensen@gmail.com>
To: YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Cc: 26397@debbugs.gnu.org, Alan Third <alan@idiocy.org>
Subject: bug#26397: [PATCH] Use vfork if possible on Darwin (bug#26397)
Date: Sun, 9 Apr 2017 17:06:21 -0700	[thread overview]
Message-ID: <CAHyO48wHFhNV0QLeuwNdExJ0w0EgV4Z0rn6quxwndCBOYTew_A@mail.gmail.com> (raw)
In-Reply-To: <wlbms5w3ej.wl%mituharu@math.s.chiba-u.ac.jp>

On Sun, Apr 9, 2017 at 4:46 PM, YAMAMOTO Mitsuharu
<mituharu@math.s.chiba-u.ac.jp> wrote:
> According to ChangeLog, setsid in callproc.c seems to be used for
> disconnecting from the controlling terminal (so as to avoid using
> /dev/tty accidentally?).
>
> 1997-06-11  Paul Eggert  <eggert@twinsun.com>
>
>         * callproc.c (Fcall_process): Use setsid to disconnect child
>         process from controlling terminal.
>
> If that is the case (i.e., if we don't have to make the child process
> a session leader), then we don't need setsid when the Emacs process
> doesn't have the controlling terminal, which is common for Mac-native
> GUI sessions.  It doesn't apply for TTY or X11 sessions, but fork is
> not that slow there.

For me, this slows down call-process in TTY emacs by 3ms (from
2.5ms->5.5ms). I typically launch a GUI emacs and connect to the
server in TTY via emacsclient, and in that scenario this patch does
not slow down call-process in the TTY, but it will affect those who
use TTY only, it seems.

Aaron





  reply	other threads:[~2017-04-10  0:06 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-08  6:25 bug#26397: 25.1; call-process slow on macOS and slower on larger frames Aaron Jensen
2017-04-08  7:37 ` YAMAMOTO Mitsuharu
2017-04-08 15:47   ` Aaron Jensen
2017-04-08 19:19     ` Alan Third
2017-04-09 13:01       ` Alan Third
2017-04-09 15:07         ` Aaron Jensen
2017-04-09 19:18           ` bug#26397: [PATCH] Use vfork if possible on Darwin (bug#26397) Alan Third
2017-04-09 20:32             ` Andreas Schwab
2017-04-09 21:34               ` Alan Third
2017-04-09 23:46             ` YAMAMOTO Mitsuharu
2017-04-10  0:06               ` Aaron Jensen [this message]
2017-04-10  1:11                 ` YAMAMOTO Mitsuharu
2017-04-10  4:13                   ` Aaron Jensen
2017-04-10 15:42                   ` bug#26397: [PATCH v2] " Alan Third
2017-04-11  7:06                     ` YAMAMOTO Mitsuharu
2017-04-18  2:29                     ` Aaron Jensen
2017-04-18 10:48                       ` Alan Third

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=CAHyO48wHFhNV0QLeuwNdExJ0w0EgV4Z0rn6quxwndCBOYTew_A@mail.gmail.com \
    --to=aaronjensen@gmail.com \
    --cc=26397@debbugs.gnu.org \
    --cc=alan@idiocy.org \
    --cc=mituharu@math.s.chiba-u.ac.jp \
    /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.