mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-24 06:31:02 +00:00
79e145a970
Before executing the gnuplot executable the environment variable `GDFONTPATH` is populated with a list of font directories, which is obtained from `fc-list`. In that process we iterated over each line and called `dirname` on it, which introduces a performance hit for loading and executing the external executable `dirname` every time. The new version avoids the loop. The author of this patch measured a 42 fold performance improvement: old version: $ time ./gnuplot_old/bin/gnuplot -e '' real 0m3.828s user 0m0.392s sys 0m0.465s new version: $ time ./gnuplot_new2/bin/gnuplot -e '' real 0m0.091s user 0m0.112s sys 0m0.014s The correctness of the value of `GDFONTPATH` was confirmed with the following command and comparing its output between versions: $ gnuplot -e 'print system("echo $GDFONTPATH")' |
||
---|---|---|
.. | ||
argyllcms | ||
asymptote | ||
barcode | ||
briss | ||
cfdg | ||
cuneiform | ||
dcraw | ||
diagrams-builder | ||
ditaa | ||
dmtx-utils | ||
editres | ||
enblend-enfuse | ||
eplot | ||
exif | ||
exiftags | ||
fgallery | ||
ggobi | ||
gifsicle | ||
glmark2 | ||
glxinfo | ||
gmic | ||
gnuplot | ||
graphviz | ||
icoutils | ||
imgur-screenshot | ||
imgurbash | ||
jbig2enc | ||
jhead | ||
kst | ||
leela | ||
logstalgia | ||
lprof | ||
maim | ||
mscgen | ||
netpbm | ||
nifskope | ||
nip2 | ||
optipng | ||
panomatic | ||
pdf2svg | ||
pdfread | ||
pfstools | ||
pgf | ||
ploticus | ||
plotutils | ||
pngcheck | ||
pngcrush | ||
pngnq | ||
pngout | ||
pngquant | ||
pngtoico | ||
povray | ||
pstoedit | ||
qrcode | ||
qrencode | ||
quirc | ||
scrot | ||
sng | ||
transfig | ||
unpaper | ||
vips | ||
welkin | ||
wkhtmltopdf | ||
zbar | ||
zxing |