unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Jan Djärv" <jan.h.d@swipnet.se>
To: Lars Hamren <hamren@sdu.se>
Cc: 7069@debbugs.gnu.org
Subject: bug#7069: Compilation from within emacs becomes slower and slower until Emacs is restarted
Date: Wed, 22 Sep 2010 08:43:50 +0200	[thread overview]
Message-ID: <4C99A5A6.8090004@swipnet.se> (raw)
In-Reply-To: <4C955B68.6000701@sdu.se>

I can't repeat this.  The "Much waiting here" you mark below is Emacs waiting 
for your X server to send something, so it doesn't say anything.
As there is only one fd in the select, the compilation must have finished 
before this.

For an strace to be useful, you need to see what emacs reads from the 
compilation and when and compare this to the "real" output.  If there is a 
notable delay for when Emacs reads from the compilation process, there might 
be a problem.  For now it just looks like your X server has some bug or is 
busy doing something else, so it doesn't have time to update Emacs windows.

You also failed to say if this happens with emacs -Q.  Is Emacs stuck when 
this happens or can you edit in other buffers?

Please use M-x report-emacs-bug next time to include relevant information 
about your Emacs.

	Jan D.

2010-09-19 02:38, Lars Hamren skrev:
> The first few compiles, using "compile" to invode  GNU make,
> from within Emacs, run at "command-line speed" but then the overall
> time increases. The first 10 compiles are OK, but after about 20 compiles,
> a compilation that "time make -k" reports as taking
>
> real 0m0.127s
> user 0m0.100s
> sys 0m0.016s
>
> takes more than five seconds. Then I give up and restart Emacs, and
> everything is fine for another 10 compiles. And so on.
>
> Here is some output from "strace emacs"
>
> socket(PF_FILE, SOCK_STREAM, 0) = 3 <0.000016>
> connect(3, {sa_family=AF_FILE, path=@"/tmp/.X11-unix/X0"}, 20) = 0
> <0.000015>
>
> Here I attach strace to a running emacs just before i start compilation
> and detach as soon as the compilation is done. The first few selects are
> probably from before the time I press enter to execute the compile command.
>
> select(4, [3], NULL, NULL, {0, 297904}) = 0 (Timeout) <0.298232>
> select(4, [3], NULL, NULL, {0, 498307}) = 0 (Timeout) <0.498832>
> select(4, [3], NULL, NULL, {0, 498294}) = 0 (Timeout) <0.498820>
> select(4, [3], NULL, NULL, {0, 498292}) = 0 (Timeout) <0.498818>
> select(4, [3], NULL, NULL, {0, 498250}) = 0 (Timeout) <0.498776>
> select(4, [3], NULL, NULL, {0, 498299}) = 1 (in [3], left {0, 444141})
> <0.054181>
> select(4, [3], NULL, NULL, {0, 441524}) = 1 (in [3], left {0, 320780})
> <0.120760>
> select(4, [3], NULL, NULL, {0, 312270}) = 1 (in [3], left {0, 311270})
> <0.001084>
> select(4, [3], NULL, NULL, {0, 282200}) = 0 (Timeout) <0.282507>
> select(4, [3], NULL, NULL, {0, 498525}) = 1 (in [3], left {0, 21105})
> <0.477438>
> select(4, [3], NULL, NULL, {0, 499408}) = 0 (Timeout) <0.499936>
> select(4, [3], NULL, NULL, {0, 498927}) = 1 (in [3], left {0, 272045})
> <0.226897>
> select(5, [3 4], NULL, NULL, {0, 499323}) = 1 (in [4], left {0, 479747})
> <0.019591>
> select(5, [3], NULL, NULL, {0, 20000}) = 0 (Timeout) <0.020070>
> select(5, [3 4], NULL, NULL, {0, 442695}) = 1 (in [4], left {0, 442690})
> <0.000016>
> select(5, [3], NULL, NULL, {0, 0}) = 0 (Timeout) <0.000008>
> select(4, [3], NULL, NULL, {0, 494042}) = 0 (Timeout) <0.494564> <----
> Much waiting here
> select(4, [3], NULL, NULL, {0, 498322}) = 0 (Timeout) <0.498847>
> select(4, [3], NULL, NULL, {0, 498336}) = 0 (Timeout) <0.498862>
> select(4, [3], NULL, NULL, {0, 498261}) = 0 (Timeout) <0.498784>
> select(4, [3], NULL, NULL, {0, 498320}) = 0 (Timeout) <0.498847>
> select(4, [3], NULL, NULL, {0, 498260}) = 0 (Timeout) <0.498786>
> select(4, [3], NULL, NULL, {0, 498325}) = 0 (Timeout) <0.498853>
> select(4, [3], NULL, NULL, {0, 498215}) = 0 (Timeout) <0.498737>
> select(4, [3], NULL, NULL, {0, 498057}) = 1 (in [3], left {0, 445670})
> <0.052400>
> select(4, [3], NULL, NULL, {0, 445001}) = 1 (in [3], left {0, 349721})
> <0.095295>
> select(4, [3], NULL, NULL, {0, 347501}) = 1 (in [3], left {0, 345858})
> <0.001656>
> select(4, [3], NULL, NULL, {0, 345151}) = 1 (in [3], left {0, 342229})
> <0.002978>
> select(4, [3], NULL, NULL, {0, 340611}) = 1 (in [3], left {0, 268540})
> <0.072088>
> select(4, [3], NULL, NULL, {0, 259972}) = 1 (in [3], left {0, 259075})
> <0.000975>
> select(4, [3], NULL, NULL, {0, 228314}) = 0 (Timeout) <0.228570>
> select(4, [3], NULL, NULL, {0, 498550} <unfinished ...>
>
> Environment
>
> Ubuntu 10.04 (and earlier, on 9.04)
> Linux: 2.6.32-24-generic
> Emacs 23.1.2 (my own emacs build)
> Emacs 22.2.1 (Ubuntu package)
>
> Googling, I can find nothing about this problem.
>
> /Lars
> -------------------------------------------------------------------
> Lars Hamrén Tel...: +46(46)189090
> Svensk Datorutveckling e-post: hamren@sdu.se
> Vadmöllan 211 WWW...: www.sdu.se
> S-225 94 Lund
> Sweden
>
>






  parent reply	other threads:[~2010-09-22  6:43 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-19  0:38 bug#7069: Compilation from within emacs becomes slower and slower until Emacs is restarted Lars Hamren
2010-09-19 18:14 ` bug#7069: Problem only with "compile", not with "shell-command" Lars Hamren
2010-09-19 18:32 ` bug#7069: Clarification Lars Hamren
2010-09-22  6:43 ` Jan Djärv [this message]
2010-10-28  2:42 ` bug#7069: Compilation from within emacs becomes slower and slower until Emacs is restarted Stefan Monnier
2011-04-20 10:04 ` Lars Hamren
2011-04-20 13:10   ` Stefan Monnier
2011-04-25  1:16     ` Daniel Colascione
2011-04-25 12:28       ` Stefan Monnier
2011-04-25 13:05         ` Lars Hamren

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=4C99A5A6.8090004@swipnet.se \
    --to=jan.h.d@swipnet.se \
    --cc=7069@debbugs.gnu.org \
    --cc=hamren@sdu.se \
    /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).