unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: "Stephen Berman" <stephen.berman@gmx.net>,
	"Jan Djärv" <jan.h.d@swipnet.se>
Cc: 14838@debbugs.gnu.org
Subject: bug#14838: 24.3.50; repeating next-line or previous-line is broken
Date: Thu, 11 Jul 2013 18:59:14 +0300	[thread overview]
Message-ID: <838v1dulyl.fsf@gnu.org> (raw)
In-Reply-To: <8761whxvjc.fsf@rosalinde.fritz.box>

> From: Stephen Berman <stephen.berman@gmx.net>
> Cc: 14838@debbugs.gnu.org
> Date: Thu, 11 Jul 2013 12:04:07 +0200
> 
> Yes.  First, I found out that the problems I observed do not happen when
> I repeat exactly the above recipe after having removed my ~/.Xresources
> file and logged in again.  That file contains this:
> 
> Emacs.FontBackend: xft
> Emacs.Font: DejaVu Sans Mono-9
> 
> ! ---------[ xft ] ---------
> Xft*antialias:          true
> Xft*autohint:           true
> 
> Without this, when I start Emacs with -Q, the font is still the one I
> reported above, but now holding down C-n in NEWS works fine.  I don't
> understand why, since I thought -Q means no X resources are read.

It should.  Is inhibit-x-resources set when you invoke with -Q?

Maybe the fact that X resources matter is a GTK thing?  Just
guessing.  Jan, could you please comment on this?

> When I start Emacs with my init file but without the .Xresources file, I
> also don't observe the problem with C-n.  In my initializations, I have
> the font DejaVu Sans Mono-9 set as default in a custom theme loaded from
> my init file (I've been using the .Xresources file since long before
> creating the them, and didn't try removing till now).  So without the
> .Xresources file, I have no problem using C-n with this font, but with
> the above .Xresources, the problem occurs with this font.  

FWIW, I tried such a font as well (but without anti-aliasing), and
didn't see any problem.

> I started Emacs like this:
> 
> emacs -Q -l ~/bzr/emacs/quickfixes/lisp/simple.el
> 
> switched the default font to Adobe Courier as described above and then
> followed your instructions; here is the report:
> 
> + call-interactively                                             6758  29%
> + next-line                                                      6059  26%
> + if                                                             5176  22%
> + line-move                                                      3875  16%
> + command-execute                                                 522   2%
>   Automatic GC                                                    445   1%
> + let                                                              86   0%
> + redisplay_internal (C function)                                  35   0%
> + prog1                                                            26   0%
> + read-from-minibuffer                                             24   0%
> + find-file-noselect                                               19   0%
> + run-hooks                                                        18   0%
> + condition-case                                                   16   0%
> + cond                                                             12   0%
> + view-file                                                         8   0%
> + mapc                                                              4   0%
> + list                                                              4   0%
> + read-extended-command                                             4   0%
> + vc-mode-line                                                      3   0%
> + line-move-visual                                                  3   0%
> + file-truename                                                     2   0%
> + vc-find-file-hook                                                 2   0%
> + vc-backend                                                        2   0%
> + after-find-file                                                   2   0%
> + completing-read                                                   2   0%
> + let*                                                              1   0%
> + view-emacs-news                                                   1   0%
> + find-file-noselect-1                                              1   0%
> + vc-call-backend                                                   1   0%
>   internal-timer-start-idle                                         1   0%
> + and                                                               1   0%

What do you see if you completely expand the profile?  Do you see
line-move-partial anywhere in the profile?  That's the only function
where I made significant changes in the offending revisions, so if
it's not high in the profile, I don't know what to think.

> followed by exactly 175 repetitions of these two lines (I used `M-x
> occur' to make sure they were all identical):
> 
> vs 0 dlh 14 this nil rowh 13 rbot 1 py 0 vpos 32 last 31.0
> 2
> 
> and nothing else.

The "py 0" part is very strange.  "py" is the vertical coordinate of
point in screen line units.  Since this was with C-n, I expect py
never to be less than half the screen height, which is 16.  How come
it is zero, i.e. point is in the first line?  Can you step through
line-move-partial in Edebug and see what is going on there?

> > I also asked to try reducing the keyboard auto-repeat rate, and see if
> > that makes any difference.
> 
> The default rate in my setup is 25 repeats/s.  I lowered it to 15 and
> repeated the above experiment, and the problem again occurs, but starts
> later, around line 300.  Then I lowered the repeat rate to 10, which is
> annoyingly slow, and here too the problem occurs, starting around line
> 500.

This is consistent with the high CPU load you see.  But I'd be damned
if I understand what is causing that CPU load, or why it happens with
some fonts, but not others.

Btw, do you have any local changes in your builds?





  reply	other threads:[~2013-07-11 15:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-10 21:29 bug#14838: 24.3.50; repeating next-line or previous-line is broken Stephen Berman
2013-07-11  2:51 ` Eli Zaretskii
2013-07-11 10:04   ` Stephen Berman
2013-07-11 15:59     ` Eli Zaretskii [this message]
2013-07-11 18:51       ` Stephen Berman
2013-07-11 19:16         ` Eli Zaretskii
2013-07-11 20:04           ` Stephen Berman
2013-07-11 20:25             ` Eli Zaretskii
2013-07-12  9:48               ` Eli Zaretskii
2013-07-12 10:19                 ` Stephen Berman
2013-07-12 10:35                   ` Eli Zaretskii
2013-07-13  7:29                   ` Eli Zaretskii
2013-07-13 13:15                     ` Stephen Berman

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=838v1dulyl.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=14838@debbugs.gnu.org \
    --cc=jan.h.d@swipnet.se \
    --cc=stephen.berman@gmx.net \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).