texmacs-dev
[Top][All Lists]
Advanced

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

Re: [Texmacs-dev] disk caches and startup time


From: Joris van der Hoeven
Subject: Re: [Texmacs-dev] disk caches and startup time
Date: Wed, 26 May 2004 15:16:50 +0200 (CEST)

On Wed, 26 May 2004, Joris van der Hoeven wrote:
> Thanks for the program. I have added some timing code in file.cpp.
> I obtain the following result after flushing the memory (this does
> not take into account loading scheme files):
>
> address@hidden src]$ texmacs --debug-bench
> Bench  ] Initialized plug-ins in 6267 ms
> TeXmacs] loading ecrm11 at 300 dpi
> TeXmacs] With linked TrueType support
> Evaluating user init-texmacs.scm
> Bench  ] Initialized scheme in 3040 ms
> TeXmacs] Loading hyphen.us
> TeXmacs] loading ecrm10 at 600 dpi
> Evaluating user init-buffer.scm
> Bench  ] Loaded 90 files in 197 ms
> Bench  ] Loaded 393 directories in 3778 ms
> Bench  ] Issued 8242 stat commands in 3245 ms
>
> When launching a second time, one obtains
>
> address@hidden src]$ texmacs --debug-bench
> Bench  ] Initialized plug-ins in 506 ms
> TeXmacs] loading ecrm11 at 300 dpi
> TeXmacs] With linked TrueType support
> Evaluating user init-texmacs.scm
> Bench  ] Initialized scheme in 1809 ms
> TeXmacs] Loading hyphen.us
> TeXmacs] loading ecrm10 at 600 dpi
> Evaluating user init-buffer.scm
> Bench  ] Loaded 90 files in 25 ms
> Bench  ] Loaded 393 directories in 8 ms
> Bench  ] Issued 8242 stat commands in 220 ms

I checked in more detail all load/stat/dir commands and found that
I search in the standard TeX directories even though kpsewhich works.
I corrected this and now obtain:

address@hidden src]$ texmacs --debug-bench
Bench  ] Initialized plug-ins in 122 ms
TeXmacs] loading ecrm11 at 300 dpi
TeXmacs] With linked TrueType support
Evaluating user init-texmacs.scm
Bench  ] Initialized scheme in 2855 ms
TeXmacs] Loading hyphen.us
TeXmacs] loading ecrm10 at 600 dpi
Evaluating user init-buffer.scm
Bench  ] Loaded 88 files in 163 ms
Bench  ] Loaded 201 directories in 820 ms
Bench  ] Issued 2196 stat commands in 2724 ms

and

address@hidden src]$ texmacs --debug-bench
Bench  ] Initialized plug-ins in 52 ms
TeXmacs] loading ecrm11 at 300 dpi
TeXmacs] With linked TrueType support
Evaluating user init-texmacs.scm
Bench  ] Initialized scheme in 1598 ms
TeXmacs] Loading hyphen.us
TeXmacs] loading ecrm10 at 600 dpi
Evaluating user init-buffer.scm
Bench  ] Loaded 88 files in 20 ms
Bench  ] Loaded 201 directories in 4 ms
Bench  ] Issued 2196 stat commands in 96 ms

That is already much better, but it should be possible
to remove most of the remaining stat/dir commands.
In fact, they mainly localize files in the plug-ins and
style files/packages.

Notice that the load/stat/dir commands do not seem to
be the only responsables for the longer start-up time.
Indeed, I observe a first startup time of approximately 13secs
and a second startup time of approximately 3secs on my computer.
The above timings show that approximately 4secs are due to
load/stat/dir commands and probably a bit more to the loading of
scheme files ((2855-1598)ms ~ 1.3sec) and loading the TeXmacs
binary itself (~1sec). That leaves us with 4 unexplained seconds.





reply via email to

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