[Tex/LaTex] How to build with multiple cores in Ubuntu 16.04 and TexStudio


I would like to speed up the building of my latex documents, and I'm curious if it's possible to use all four of my processor cores when building documents.

There are instructions for windows users, but I haven't found any for linux users.

Best Answer

TeX engines are one-threaded, so they cannot distribute the load to multiple cores. TeX processing often require running external programs (biber, bibtex, makeindex), but since they need files produced by TeX and send their results to TeX as files, you cannot do much here either.

Still, there is an advantage of having a multicore machine: if your editor (or TeXStudio) runs on one core, and a TeX engine on another one, this will speed things up. However, this is usually automatically done by your OS, and is transparent to you.

Another situation is processing rnw documents with knitr or Sweave. While R is also one-threaded, it can parallelize computations using multicore package. This can speed R parts considerably.

Related Question