all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Alan Third <alan@idiocy.org>
To: Bob Halley <halley@play-bow.org>
Cc: emacs-devel@gnu.org
Subject: Re: UI Unresponsive Again on macOS
Date: Fri, 10 Mar 2017 14:51:42 +0000	[thread overview]
Message-ID: <20170310145142.GB76673@breton.holly.idiocy.org> (raw)
In-Reply-To: <BC3C399F-E8D6-4519-AEC4-0A5A570FC40B@play-bow.org>

[-- Attachment #1: Type: text/plain, Size: 1063 bytes --]

On Fri, Mar 10, 2017 at 06:40:00AM -0800, Bob Halley wrote:
> I build from the master branch about once a week. I had no problem
> with last week's build made early in the morning California time on
> Sunday the 6th, but the build I just made this morning becomes
> completely unresponsive after a short time. I don't have an exact
> recipe to reproduce -- I was just typing, and then stopped for a
> bit, and then it became completely unresponsive. This happens every
> time I try to use it.
> 
> I suspect one or both of these changes:
> 
> a65236214d9202fb69a6ba5169d4ac1a4bcb0b0d
> 3bd2e9e975ed29daaf03ca7559e4664aade0674f
> 
> as they are new since my last working build and seem to be relevant.
> 
> I obtained backtraces of all the threads. I did two snapshots of
> thread 1 as it seemed to be spinning a bit.

Thanks for that, Bob. I noticed these hangs too, but I haven’t
actually managed to catch one in the debugger yet.

Can you please try the attached patch? I’m not at all sure it’ll fix
it, but it’ll be good to rule it out.
-- 
Alan Third

[-- Attachment #2: Disable SIGIO --]
[-- Type: text/plain, Size: 1375 bytes --]

From 6b4787023b247b68ae0598d03dce50a6fce44ab1 Mon Sep 17 00:00:00 2001
From: Alan Third <alan@idiocy.org>
Date: Fri, 10 Mar 2017 14:21:14 +0000
Subject: [PATCH] Disable SIGIO processing on NS port

* src/conf_post.h: undef USABLE_SIGIO and INTERRUPT_INPUT.
* src/nsterm.m (hold_event, ns_select): Remove unneeded calls to raise
SIGIO.
---
 src/conf_post.h | 6 ++++++
 src/nsterm.m    | 3 ---
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/conf_post.h b/src/conf_post.h
index e146b9bbe8..3b6b9aff8d 100644
--- a/src/conf_post.h
+++ b/src/conf_post.h
@@ -355,3 +355,9 @@ extern int emacs_setenv_TZ (char const *);
 #else
 # define UNINIT /* empty */
 #endif
+
+/* The NS port doesn't use SIGIO for input. */
+#ifdef HAVE_NS
+# undef USABLE_SIGIO
+# undef INTERRUPT_INPUT
+#endif
diff --git a/src/nsterm.m b/src/nsterm.m
index f985786e19..d61d357811 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -454,8 +454,6 @@ - (NSColor *)colorUsingDefaultColorSpace
     }
 
   hold_event_q.q[hold_event_q.nr++] = *event;
-  /* Make sure ns_read_socket is called, i.e. we have input.  */
-  raise (SIGIO);
   send_appdefined = YES;
 }
 
@@ -4120,7 +4118,6 @@ in certain situations (rapid incoming events).
   if (hold_event_q.nr > 0)
     {
       /* We already have events pending. */
-      raise (SIGIO);
       errno = EINTR;
       return -1;
     }
-- 
2.12.0


  reply	other threads:[~2017-03-10 14:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-10 14:40 UI Unresponsive Again on macOS Bob Halley
2017-03-10 14:51 ` Alan Third [this message]
2017-03-10 15:04   ` Bob Halley
2017-03-13  6:23   ` Herbert J. Skuhra
2017-03-13 11:42     ` Alan Third
2017-03-14 14:52     ` Alan Third
2017-03-13 18:13   ` Bob Halley

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=20170310145142.GB76673@breton.holly.idiocy.org \
    --to=alan@idiocy.org \
    --cc=emacs-devel@gnu.org \
    --cc=halley@play-bow.org \
    /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.