[tex-live] Request for performance check of legacy darwin (luatex)

jfbu jfbu at free.fr
Fri Mar 9 10:10:09 CET 2018


Hi Mojca

Le 9 mars 2018 à 09:40, Mojca Miklavec <mojca.miklavec.lists at gmail.com> a écrit :

> On 8 March 2018 at 14:38, jfbu wrote:
>> 
>> Here is with luatex on the same test file
>> 
>> $ time luatex temptest.tex
>> This is LuaTeX, Version 0.95.0 (TeX Live 2016)
>> restricted system commands enabled.
>> (./temptest.tex . . . . . . . . . .)
>> warning  (pdf backend): no pages of output.
>> Transcript written on temptest.log.
>> 
>> real    0m1.585s
>> user    0m1.561s
>> sys     0m0.018s
>> 
>> $ time luatex temptest.tex
>> This is LuaTeX, Version 1.0.4 (TeX Live 2017/MacPorts 2017_1)
>> restricted system commands enabled.
>> (./temptest.tex . . . . . . . . . .)
>> warning  (pdf backend): no pages of output.
>> Transcript written on temptest.log.
>> 
>> real    0m1.745s
>> user    0m1.716s
>> sys     0m0.025s
>> 
>> $ time luatex temptest.tex
>> This is LuaTeX, Version 1.07.0 (TeX Live 2018)
>> restricted system commands enabled.
>> (./temptest.tex . . . . . . . . . .)
>> warning  (pdf backend): no pages of output.
>> Transcript written on temptest.log.
>> 
>> real    0m2.618s
>> user    0m2.593s
>> sys     0m0.020s
> 
> Thank you very much. There's evidently something "wrong" with
> efficiency of the binaries generated with the latest clang compiler,
> but it's not exactly clear to me why this would be the case. 75%
> slowdown is very significant.
> 
> I'll try to use your testcase and prepare a few more variants of
> binaries to test (using different compilers and compiler options).
> 
> This got me thinking. I'm always setting up some CXXFLAGS. I wonder if
> the results would be any faster if I omit CXXFLAGS as setting the
> flags might override some optimisation that would otherwise be set.
> 
> I don't find your question any longer, but no, MacTeX won't work on 10.9.


Thanks for looking into this. I think the slowdown is 50% from number above.

I have done a test which takes 10 times more time  (with the idea to reduce the
relative importance of file access operations, as initialization represents
less in proportion):

\def\A{\B\B\B\B\B\B\B\B\B\B}% 10
\def\B{\C\C\C\C\C\C\C\C\C\C}% 100
\def\C{\noexpand\A\noexpand\A\noexpand\A\noexpand\A
      \noexpand\A\noexpand\A\noexpand\A\noexpand\A
      \noexpand\A\noexpand\A}% 1000
\edef\D{\A}% 1000
% \edef\E{\D}% 1000000
\edef\E{\D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D\noexpand\message{.}%
        \D%
        }% 10000000

\def\A{\edef\z{666}}

\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\E\message{.}
\bye

I got these typical timings:

$ time luatex temptest2.tex
This is LuaTeX, Version 1.07.0 (TeX Live 2018) 
 restricted system commands enabled.
(./temptest2.tex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .)
warning  (pdf backend): no pages of output.
Transcript written on temptest2.log.

real	0m24.099s
user	0m24.045s
sys	0m0.054s

versus

$ time luatex temptest2.tex
This is LuaTeX, Version 1.0.4 (TeX Live 2017/MacPorts 2017_1) 
 restricted system commands enabled.
(./temptest2.tex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .)
warning  (pdf backend): no pages of output.
Transcript written on temptest2.log.

real	0m16.138s
user	0m16.062s
sys	0m0.075s

Best,

Jean-François


More information about the tex-live mailing list