all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Anders Lindgren <andlind@gmail.com>
To: David Reitter <david.reitter@gmail.com>
Cc: Eli Zaretskii <eliz@gnu.org>, Alan Third <alan@idiocy.org>,
	emacs-devel <emacs-devel@gnu.org>
Subject: Re: Redisplay: NS port, high CPU load
Date: Mon, 13 Jun 2016 20:44:15 +0200	[thread overview]
Message-ID: <CABr8ebYiF7Ac+w_26+6Nc9M5+6t62Yw8tpWv5gUhB6MamzYr0A@mail.gmail.com> (raw)
In-Reply-To: <62E0B0C4-4D9B-4E1C-ACE5-06E674C8A342@gmail.com>

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

Hi!

Unfortunately, I can't reproduce this either, but I have a theory on what
is going on.

`with-temp-buffer' calls `generate-new-buffer'. This, in turn calls
`get-buffer-create', which run `buffer-list-update-hook'. In theory, if a
function on this hook would trigger a tool-bar redisplay,
`(with-temp-buffer (insert "XXX"))' will too.

If this is the cause of the problem David is seeing, one solution would be
to temporarily bind `buffer-list-update-hook' to nil in `with-temp-buffer'.
(This might be a good idea anyway, since we don't want `with-temp-buffer'
to be slowed down by slow hooks, unless is it more important to ensure that
the buffer list is up to date?)

When it comes to the HFS coding rewrite, I still think it is valid. The
documentation of `define-coding-system' indicated that it expects the
pre-write function to convert the current buffer and that the two
parameters are only there for backward compatibility. The function, before
the rewrite, was clearly written for an older version of
`define-coding-system'.

    -- Anders


On Fri, Jun 10, 2016 at 12:36 PM, David Reitter <david.reitter@gmail.com>
wrote:

> On Jun 10, 2016, at 8:22 PM, Eli Zaretskii <eliz@gnu.org> wrote:
>
> > To be sure this triggers redisplay of the tool bar, you need:
> >
> >  . emacs -Q
> >  . disable blink-cursor-mode
> >  . disable global-eldoc-mode
> >  . define an interactive function that does the above insertion, and
> >    then bind that function to a key (I used F8)
> >  . press F8 and see if update_frame_tool_bar is called
>
>
> Well, turns out this happens with -q, but not with -Q.
>
> If I clear tool-bar-map, the update goes away, but running populating it
> with a standard toolbar as per (tool-bar-setup), the updates come back.
> So, I’m not sure what exactly makes this happen - I’m obviously loading a
> whole lot of settings with -q.
>
> I’m assuming I’ll have to give you something more reproducible then, so
> please stand by.
>
>
>

[-- Attachment #2: Type: text/html, Size: 2616 bytes --]

  reply	other threads:[~2016-06-13 18:44 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-08  6:04 Redisplay: NS port, high CPU load David Reitter
2016-06-08  7:50 ` Anders Lindgren
2016-06-08 10:44   ` David Reitter
2016-06-08 19:55     ` Alan Third
2016-06-08 20:12       ` David Reitter
2016-06-09  1:03         ` David Reitter
2016-06-09  8:22           ` David Reitter
2016-06-09  9:25             ` Anders Lindgren
2016-06-09 13:04               ` David Reitter
2016-06-09 14:11                 ` Anders Lindgren
2016-06-09 18:03                   ` David Reitter
2016-06-09 18:52                     ` Anders Lindgren
2016-06-09 23:03                       ` David Reitter
2016-06-10  6:02                         ` Anders Lindgren
2016-06-10  8:16                           ` David Reitter
2016-06-10  9:34                             ` Eli Zaretskii
2016-06-10  9:46                               ` David Reitter
2016-06-10 10:22                                 ` Eli Zaretskii
2016-06-10 10:36                                   ` David Reitter
2016-06-13 18:44                                     ` Anders Lindgren [this message]
2016-06-13 19:16                                       ` Eli Zaretskii
2016-06-14 12:07                                         ` David Reitter
2016-06-14 17:02                                           ` Eli Zaretskii
2016-06-15  3:55                                           ` Stefan Monnier
2016-06-14 11:50                                       ` David Reitter

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=CABr8ebYiF7Ac+w_26+6Nc9M5+6t62Yw8tpWv5gUhB6MamzYr0A@mail.gmail.com \
    --to=andlind@gmail.com \
    --cc=alan@idiocy.org \
    --cc=david.reitter@gmail.com \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.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.