WSL vs Dual Boot speed test

By Dillon Smart · · · 0 Comments

In this experiment, I will be using WSL2 running Ubuntu 20.04 and Ubuntu 20.04 dual-booted on the same Dell XPS. Is there a noticeable difference? Follow along for the results of the WSL vs Dual Boot speed test.

If you are like me and use different development environments a lot, you may find the results of the tests interesting.

PHP Speed Test

In the PHP Speed Test, I will be using PHP 8.1. which is the latest version of PHP as of writing this post. I will be cloning a repository and installing the dependencies with Composer 2 and comparing the results.

PHP Composer CLI Output

Composer speed test on WSL vs Dual-boot

WSL downloaded all dependencies in 6.61 seconds. Dual-boot Ubuntu downloaded all dependencies in 4.38 seconds.

The difference here may not seem that big, however, for large projects with many dependencies the difference in time can become more noticeable.

NPM Speed Test

In the NPM Speed Test, I will be using NPM 8.9.0 (The latest stable release at the time of writing this). I will be installing the Angular CLI and comparing the results.

Angular CLI Output

On WSL, the Angular CLI was installed in 7.21 seconds. Dual-boot Ubuntu downloaded the Angular CLI in 3.28 seconds.

This is a far bigger difference in time and can become extremely noticeable when installing packages using NPM.

Conclusion

WSL is slower, that’s undeniable. However, for many developers, running WSL is a better choice than a Virtual Machine. Staying within the Windows environment is a must in some organizations, and WSL provides a great, convenient way to run Linux applications and command-line tools natively on Windows. It will just take a little longer to get stuff done.

Learn how to set up a LAMP stack on WSL

AngularComposerPHPUbuntuWindows Subsystem for Linux

0 Comment

Was this helpful? Leave a comment!

This site uses Akismet to reduce spam. Learn how your comment data is processed.

How to check Composer version – Install and use Composer for PHP

Updated 11th January 2024

Composer is a dependency manager for PHP. First released in 2012, Composer, and its adoption by popular frameworks such as Laravel has single-handedly driven the rise in PHP adoption in recent years. In this post, I will show you how to install and use Composer. How to install Composer To get started, download Composer from

2022 PHP Usage Statistics

Updated 16th August 2022

PHP: Hypertext Preprocessor is the most popular language used on the web. Around 77.6% of all websites run PHP in some way as of April 2022. PHP has been the driving force behind the growth of the web, but is it slowly dying? Let’s look at some PHP usage statistics. Why is PHP so popular?

What is the Lexing stage in PHP

Updated 10th December 2023

Lexing is a phase the PHP interpreter undergoes while interpreting the source code written. Lexing, is the first of four overall steps performed by the PHP interpreter. Steps in the PHP Interpreter The PHP interpreter undergoes a total of four steps before executing the code written. What is Lexing in PHP Lexical analysis, also known