View Issue Details

IDProjectCategoryView StatusLast Update
0001018luatexluatex limitationpublic2020-02-03 21:32
ReporterdbitouzeAssigned ToHans Hagen 
Status closedResolutionno change required 
PlatformLinuxOSMageiaOS Version7
Product Version1.0.0 
Target VersionFixed in Version 
Summary0001018: LuaLaTeX extremely slow if libertine package is loaded
DescriptionWhen Libertine is loaded, I noticed LuaLaTeX takes a very, very long pause (AFACIS, after fontspec.cfg loading). As a result, lualatex is almost 10 times slower than pdflatex.
Steps To ReproduceCompile the following MWE:

--8<---------------cut here---------------start------------->8---
--8<---------------cut here---------------end--------------->8---

with both lualatex and with pdflatex.
Additional InformationHere is a bench test shows lualatex is almost 10 times slower than pdflatex :

  $ time lualatex -interaction batchmode test
  This is LuaTeX, Version 1.10.0 (TeX Live 2019)
   restricted system commands enabled.
  luaotfload | main : initialization completed in 0.370 seconds
  lualatex -interaction batchmode test 2,04s user 3,12s system 99% cpu 5,185 total


  $ time pdflatex -interaction batchmode test
  This is pdfTeX, Version 3.14159265-2.6-1.40.20 (TeX Live 2019)
  (preloaded format=pdflatex)
   restricted \write18 enabled.
  entering extended mode
  pdflatex -interaction batchmode test 0,30s user 0,34s system 97% cpu 0,662 total

And note the result is not that rude for lualatex if libertine isn't loaded: lualatex is then only about 3 times slower.
TagsNo tags attached.


Hans Hagen

2020-02-03 21:32

manager   ~0001727

This is not really a test. Luatex is a wide font engine and pdftex isn't. I don't know the latex specifics for pdftex and luatex but I assume that startup time for luatex is longer than for pdftex so you need to subtract the overhead. Then there is often more involved than just fonts, so who knows what overhead after startup comes from where. Finally font inclusion (embedding ) is different for t1 fonts and opentype. Also, when processing the text, it can be that where pdftex simply has no features for fonts, luatex can have them which has some overhead. How many page are we talking about.

I can't speak for latex but for context, for simple documents, pdftex is always faster, but luatex comes close, while xetex lags a bit behind. In the end it all depends on the complexity of the document and dealing with fonts is just one aspect of it.

Anyway, because it's a latex specific question and not really engine related, you can best ask on a latex list (maybe there are tuning options).

Issue History

Date Modified Username Field Change
2020-02-03 21:10 dbitouze New Issue
2020-02-03 21:32 Hans Hagen Note Added: 0001727
2020-02-03 21:32 Hans Hagen Assigned To => Hans Hagen
2020-02-03 21:32 Hans Hagen Status new => closed
2020-02-03 21:32 Hans Hagen Resolution open => no change required