emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] another example of org being slow, with some analysis


From: Daniel Bausch
Subject: Re: [O] another example of org being slow, with some analysis
Date: Fri, 19 Jun 2015 10:28:41 +0200
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.4 (gnu/linux)

Eric S Fraga <address@hidden> writes:

> On Friday, 19 Jun 2015 at 08:19, Daniel Bausch wrote:
>
> [...]
>
>> Line 6000 is indeed quite "lame".  I have similar problems like Eric.  A
>> table recalculation at line 43868 takes about a minute at my quite fast
>> machine.  I also tracked that down to org-current-line.  One interesting
>> detail is that this depends on the buffer encoding.  With ASCII the
>> recalculation takes less than a second, with utf-8 about a minute.
>
> Adding some data: my table is at line 8438 in the buffer but character
> position 398345 (I have very long lines as I use visual-line-mode in org
> exclusively with org-indent).  I do use utf-8 encoding.
>
> I have just tried updating the table on a different laptop (i7-2760, 8
> cores, 8 GB RAM, Ubuntu) and it was very fast.  
>
> The two laptops are running different versions of emacs (tracking latest
> emacs developments on Ubuntu and Debian testing lead to different
> versions unfortunately) so my gut feeling is that there is an emacs
> issue here and possibly one related to utf-8 as Daniel suggests.

Maybe it is related (and maybe not - just some thoughts): Since some
months I keep having a problem with my preferred encoding.  Gentoo
changed some things how the LC_... variables are set during boot.  Now
emacs daemon starts with "no encoding".  I tried to fix that by
inserting (prefer-coding-system 'utf-8) into mit ~/.emacs file, but that
does not help.  I still need to manually execute prefer-coding-system by
hand and revert my org-file (which is automatically opened during login)
with C-x RET r utf-8 every day.  But if I remember correctly, I started
observing the slowness of the table recalculation long before that
change in Gentoo.  Maybe it got worse since then but that might also be
just because the file grew further.  If anyone could give me a hint how
to reliably set the preferred (or internal) encoding I could check
wether it might have something to do with the system locale.  (I can
imagine that in some constellations there could be some otherwise
unnecessary conversion happening.  E.g. maybe utf-8 support is faster if
the system locale is also utf-8.)  Is there anything like an internal
encoding in emacs at all?  As far as I know I can type any character in
any buffer regardless of the buffer encoding.  I just cannot save the
buffer if the encoding does not support a character.  How is then a
utf-8 *buffer* different from a buffer with no encoding (until being
saved).  Does goto-char work on bytes or really on characters?  How does
it maybe deal different with characters made up of multiple bytes in the
on-disk encoding of the buffer?

Regards,
Daniel
-- 
MSc. Daniel Bausch
Research Assistant (Computer Science)
Technische Universität Darmstadt
http://www.dvs.tu-darmstadt.de/staff/dbausch



reply via email to

[Prev in Thread] Current Thread [Next in Thread]