linkedin / eyeglass

NPM Modules for Sass
741 stars 60 forks source link

[broccoli-eyeglass] Optimize Sass concurrency. #233

Closed chriseppstein closed 5 years ago

chriseppstein commented 5 years ago

Empirical testing shows that Sass compilation performance is optimal when the number of physical cores is used for concurrent compilation. In this patch, I use systeminformation to get access to the number of physical cores because node only exposes the number of cores which includes virtual (hypervisor) cores.

Environment Variables:

The number of Sass jobs requested is overridden or ignored when it is clearly going to just cause jobs to spend longer in the uv queue and inflate the compilation times or result in obviously worse performance.