From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo de Moraes Serpa Subject: Re: Re: Org file rendering/manipulation too slow Date: Sun, 5 Sep 2010 22:37:28 -0500 Message-ID: References: <871vak112n.fsf@altern.org> <87iq3o86s4.fsf@gnu.org> <19549.21434.7688.225279@gazelle-32.local> <87zkwamkn9.fsf@norang.ca> <19578.37551.295920.461789@gazelle-32.local> <25942.1283221918@gamaville.dokosmarshall.org> <7013.1283738842@gamaville.dokosmarshall.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=60960 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OsSWU-0003vI-15 for emacs-orgmode@gnu.org; Sun, 05 Sep 2010 23:37:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OsSWP-0004fP-SD for emacs-orgmode@gnu.org; Sun, 05 Sep 2010 23:37:33 -0400 Received: from mail-pv0-f169.google.com ([74.125.83.169]:60957) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OsSWP-0004f2-HW for emacs-orgmode@gnu.org; Sun, 05 Sep 2010 23:37:29 -0400 Received: by pvc30 with SMTP id 30so2597742pvc.0 for ; Sun, 05 Sep 2010 20:37:28 -0700 (PDT) In-Reply-To: <7013.1283738842@gamaville.dokosmarshall.org> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: nicholas.dokos@hp.com Cc: Bernt Hansen , Org Mode , Bastien HI Nicholas, thanks for the reply, >How long does it take for emacs to show >you the file? >From the moment I press on the minibuffer to the moment the whole file is rendered, it takes about 3 seconds. So, it does take longer than I would expect. I have a 10-months old Macbook, and its specs are quite recent, check out (from System Profiler): Model Name: MacBook Model Identifier: MacBook6,1 Processor Name: Intel Core 2 Duo Processor Speed: 2.26 GHz Number Of Processors: 1 Total Number Of Cores: 2 L2 Cache: 3 MB Memory: 4 GB Bus Speed: 1.07 GHz Boot ROM Version: MB61.00C8.B00 SMC Version (system): 1.51f53 Serial Number (system): W89483Q78PX Hardware UUID: 413C6EF2-12B3-5C38-A3CA-5A1F924867D7 Sudden Motion Sensor: State: Enabled So, the system is quite capable and is definetly should not be the bottlene= ck. What I note though is that when I open this big org file and try to naviagate around, the Emacs.app CPU usage goes up to 100% and then gradually goes down to 0 as I stop giving any other commands. Check out the screenshot below: http://i56.tinypic.com/123sbcj.png When I run "ps awlx | grep emacs", I get the following output: >501 5733 5578 0 31 0 2425520 168 - R+ s000 0:00.00 grep emacs Some additional information: Emacs version string: >GNU Emacs 23.2.1 (x86_64-apple-darwin, NS apple-appkit-1038.29) of 2010-05= -08 on black.local Org-mode version string: >Org-mode version 7.01trans (release_7.01g.20.gdd484.dirty) It is really unfortunate that org-mode runs like this on OSX. I can't really think of anything else I could use to manage my personal information and todo lists, but handling big orgfiles, as of now, is really starting to be a blocker :-( Thanks for the help, Marcelo. On Sun, Sep 5, 2010 at 9:07 PM, Nick Dokos wrote: > Marcelo de Moraes Serpa wrote: > >> Hi Nick, >> >> The output of elp-results is attached. I have opened a big org file I >> have, and navigated through the items a bit. >> >> Thanks, >> >> Marcelo. >> >> On Mon, Aug 30, 2010 at 9:31 PM, Nick Dokos wrot= e: >> > Marcelo de Moraes Serpa wrote: >> > >> >> Yeah, thanks. It is really a shame that emacs will run orgmode this >> >> slow on OSX. OSX is now my platform of choice, and emacs my editor of >> >> choice. I keep a big reference org file with tons of tons of notes, >> >> but, even with the settings you suggested (thanks for that!) it is >> >> still very slow. I'm considering switching my notes to evernote, >> >> although I would really like to just stay with emacs+orgmode, but it'= s >> >> just too slow as of now :( >> >> >> > >> > Please take a profile: Just do >> > >> > =A0 =A0 =A0 M-x elp-instrument-package org >> > >> > then run the slow command, then M-x elp-results and post the output to >> > the list. It might not be enough to solve your problem but it would at >> > least provide *some* information. >> > >> > Thanks, >> > Nick >> > > > OK - thanks for doing that. Given the stats: > > ,---- > | org-cycle =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 3 =A0 =A0 =A0 =A0 =A0 0.050032 = =A0 =A0 =A00.0166773333 > | org-cycle-internal-local =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A03 =A0 =A0 =A0 =A0 =A0 0.04951 =A0 =A0 =A0 0.= 0165033333 > | org-optimize-window-after-visibility-change =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 2 =A0 =A0 =A0 =A0 =A0 0.0380670000 =A00.0190335000 > | ... > `---- > > it seems clear that org-mode is not the culprit and, at 0.05s, any > improvements made there are going to be completely swamped by the real > time sink (maybe the display code if I understand things correctly.) > Also, presumably you are not complaining about the 50ms delay: that > would be almost unnoticeable. How long does it take for emacs to show > you the file? > > Some questions: > > How much memory do you have on your system? How much memory does emacs > consume? Is your disk active when emacs is taking forever? > > On linux, I get the first with > > =A0 =A0 =A0 =A0 sed 1q /proc/meminfo > > and the second with > > =A0 =A0 =A0 =A0 ps awlx | grep emacs > > and look at the RSS field (field 8 in the output); e.g. > > ,---- > | $ ps awlx | grep emacs > | 0 =A09772 11777 =A0 =A0 1 =A020 =A0 0 =A051284 32660 - =A0 =A0 =A0R =A0= =A0? =A0 =A0 =A0 =A0 =A01:02 /usr/local/bin/emacs > `---- > > shows me that emacs is consuming roughly 32Mb. I have 1Gb of memory on > the machine, so that's a comfortable fit (about 1/30 of available > memory: leaves just enough space for X and firefox :-) ). If your > numbers are closer, then maybe that's a problem: in particular, if your > disk goes wild while emacs is trying to do its thing, you are probably > swapping heavily and your performance will *really* be in the > toilet. The only solution is to buy more memory (assuming your machine > can handle it.) > > I should say that I know very little about Darwin, so all of the above > is pure speculation. Parts of it may be applicable: you'd need to check > with an OSX expert for more details. > > If there are no problems of the sort described above, I would ask in an > emacs forum about the performance of the display engine on Darwin: do > other people see the slowness? It would show up even without org > (although org make the situation marginally worse to be sure.) =A0Given > the font-lock setting that Bernt dug up, it seems likely that if memory > is not the problem, the display engine is. > > HTH, > Nick > > >