[NTG-context] luaotfload

Hans Hagen j.hagen at xs4all.nl
Fri Apr 12 17:34:40 CEST 2019


On 4/12/2019 3:17 PM, Herbert Voss wrote:
> Hello all,
> 
> If I run the following document on a 8 GByte RAM Linux machine.
> It takes more than 30 minutes until luaotfload has build
> the cache for Sparks-Dotline-Medium.otf. If I run another
> Program in the background that it never ends (too less memory).
> On my Mac the first run with context (upcoming TL2019) needs 9.5 Gbyte
> memory and nearly 100% CPU load to scan the Sparks-Dotline font.
> This one is, of course, 400 kB big, but why do we need
> more than 8 GByte Ram??

- the cpu load is puzzling: assuming that you have multiple cores, 
luatex will only use one core

- the 30 min on linux is probably due to swapping

- the 8 gig in general is a side effect of the way this font is using 
pair positioning (half a billion pairs due to classes where most pairs 
are dummies)

> The font files are here:
> 
> http://tug.org/~hvoss/Sparks-Bar-Medium.otf
> http://tug.org/~hvoss/Sparks-Dotline-Medium.otf

i hacked a faster solution for such fonts (now I need some 25 sec for 
the initial caching so probably less on your machine and < 0.1 sec for 
loading the cached font)

> -rw-r--r-- 1 voss voss  34412 Apr 11 18:54 Sparks-Bar-Medium.otf
> -rw-r--r-- 1 voss voss 403776 Apr 11 18:54 Sparks-Dotline-Medium.otf

These make a pretty good case for using proper drawing package,

> \definefont[sparkBarMedium][file:Sparks-Bar-Medium.otf:mode=node;+calt]
> \definefont[sparkDotlineMedium][file:Sparks-Dotline-Medium.otf:mode=node;+calt] 
> 
> 
> \starttext
> Text 
> {\sparkBarMedium{14,95,68,9,19,41,91,1,81,97,79,45,96,76,17,65,8,92}} Text
> 
> Text 
> {\sparkDotlineMedium{14,95,68,9,19,41,91,1,81,97,79,45,96,76,17,65,8,92}} Text 
> 
> \stoptext
> 
> 
> Herbert
> ___________________________________________________________________________________ 
> 
> If your question is of interest to others as well, please add an entry 
> to the Wiki!
> 
> maillist : ntg-context at ntg.nl / 
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________ 
> 


-- 

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------


More information about the ntg-context mailing list