From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Adrian Robert Newsgroups: gmane.emacs.devel Subject: Re: Serious performance problem with process output on Mac OSX Date: Sun, 28 Mar 2010 17:41:46 +0300 Message-ID: References: <83634jglab.fsf@gnu.org> <831vf7ge57.fsf@gnu.org> <83y6hfeyzw.fsf@gnu.org> <83vdcig87f.fsf@gnu.org> <87k4sywpvv.fsf@stupidchicken.com> <83tys2fbxs.fsf@gnu.org> <87hbo1iubm.fsf@home.jasonrumney.net> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1077) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1269787325 3107 80.91.229.12 (28 Mar 2010 14:42:05 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 28 Mar 2010 14:42:05 +0000 (UTC) Cc: emacs-devel@gnu.org To: Christian Lynbech Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Mar 28 16:42:01 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Nvtge-0003y3-Vb for ged-emacs-devel@m.gmane.org; Sun, 28 Mar 2010 16:42:01 +0200 Original-Received: from localhost ([127.0.0.1]:49907 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nvtge-0000dY-KQ for ged-emacs-devel@m.gmane.org; Sun, 28 Mar 2010 10:42:00 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NvtgZ-0000dM-24 for emacs-devel@gnu.org; Sun, 28 Mar 2010 10:41:55 -0400 Original-Received: from [140.186.70.92] (port=42940 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NvtgW-0000dE-OG for emacs-devel@gnu.org; Sun, 28 Mar 2010 10:41:53 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NvtgU-00024v-UG for emacs-devel@gnu.org; Sun, 28 Mar 2010 10:41:52 -0400 Original-Received: from ey-out-1920.google.com ([74.125.78.147]:33303) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NvtgU-00024i-Pe for emacs-devel@gnu.org; Sun, 28 Mar 2010 10:41:50 -0400 Original-Received: by ey-out-1920.google.com with SMTP id 4so940414eyg.34 for ; Sun, 28 Mar 2010 07:41:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=TukCRtPosryKAyyVXci7PU3r5o+mZM8hrDIuxTzVbdU=; b=O/V6cwMnJz2uvJa6cLyI9DY2Fp7ow0VLTqdJRZvV3SIL5gMvE+vWo8z9+/iU5bslIF 6W66e+aHdXFbr2ho6syMqacsQPT8VPpXnQAGaRM1a+uIaJIgCTEqP938Ti3X3T/xO1w8 /dzIcuyDQj3YKvm5MKn1qacY9FzHjQ1uXNJ+0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=stYTPMI+Xllk9JKxdOtv0j6X6gcvgtfKsXx/of06ukSlJYvWGlCztjheZDhxsU4Id+ rzkQYf4gEhAfhWJYoFzzHf1j4TsqPgs6YQKU6JdY6W9nPLJ7GDuESaflInYptmb3YTlH iYBQIARX9+Dzp5PZUkay6P3PE22P997+R9VzQ= Original-Received: by 10.213.55.8 with SMTP id s8mr1509149ebg.57.1269787309457; Sun, 28 Mar 2010 07:41:49 -0700 (PDT) Original-Received: from [10.0.1.2] (dsl-hkibrasgw2-ff6ec300-110.dhcp.inet.fi [88.195.110.110]) by mx.google.com with ESMTPS id 14sm1759665ewy.2.2010.03.28.07.41.47 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 28 Mar 2010 07:41:48 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1077) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:122792 Archived-At: > When emacs is processing such output, there is a kind of lock up where > it literally can take many seconds to switch desktops or to switch > between applications (Cmd-TAB). Hi, I was able to reproduce this also on a 10.6.2 system, simply by = executing the "ls -lR /System" command in a shell buffer and minimizing = it. What I noticed was that app switching through clicking on other app = windows is as fast as normal when a disk-intensive background process is = going on, but that Cmd-tab or clicking on the dock was slow. Under = Activity Monitor or top, the "Dock" process is taking up a lot of CPU. = This seems to have something to do with the updates Dock wants to do for = the icon based on whatever methods Emacs is calling periodically. I = don't think it has to do with external processes -- but I couldn't = figure out a way to get a growing buffer redisplayed while iconified = purely from lisp code to test for sure. Nor does it have to do purely with output -- the high Dock CPU usage = occurs whether or not emacs is actually displaying the buffer doing the = ls or not, and running the same ls -lR in Terminal and minimizing does = not cause it. I suspect unneeded calls to one of the icon/icon_type methods in nsfns.m = or the miniwindowimage methods in nsterm.m are causing this. Someone = could try shortcircuiting these in the source and seeing if the problem = still obtains. It would also be interesting to know if this occurs under Leopard or = Tiger, if anyone has access to those systems. thanks, Adrian