# Windows 11 versus WSL2: Need for Speed

**URL:** https://discourse.julialang.org/t/windows-11-versus-wsl2-need-for-speed/99086
**Category:** General Usage
**Tags:** package
**Created:** [May 18, 2023, 9:48pm UTC](https://discourse.julialang.org/t/windows-11-versus-wsl2-need-for-speed/99086 "2023-05-18T21:48:07Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![PetrKryslUCSD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/petrkryslucsd/32/215825_2.png) [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)
#### Post date: [May 18, 2023, 9:48pm UTC](https://discourse.julialang.org/t/windows-11-versus-wsl2-need-for-speed/99086/1 "2023-05-18T21:48:07Z")

</div>

Could one gain a significant advantage using Julia in Linux running within WSL2 compared to the Windows version?

Package instantiation. 239 dependencies, always starting from blank slate (no depot).

```julia
Julia Version 1.9.0
Commit 8e63055292 (2023-05-07 11:25 UTC)
Platform Info:
  OS: Windows (x86_64-w64-mingw32)
  CPU: 8 × Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-14.0.6 (ORCJIT, icelake-client)
  Threads: 1 on 8 virtual cores
Environment:
  JULIA_IMAGE_THREADS = 1

```

```julia
Julia Version 1.9.0
Commit 8e630552924 (2023-05-07 11:25 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 8 × Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-14.0.6 (ORCJIT, icelake-client)
  Threads: 1 on 8 virtual cores
Environment:
  JULIA_IMAGE_THREADS = 1

```

Windows 11 measurements: 452, 521, 505 seconds, mean 492 seconds.  
WSL2 measurements: 411, 392, 424 seconds, mean 409 seconds.

Conclusion: It is possible to reduce the instantiation time around 20% with WSL2.

---

<div class="post-metadata">

### Author: ![joa-quim](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/joa-quim/32/227_2.png) [@joa-quim](https://discourse.julialang.org/u/joa-quim)
#### Post date: [May 18, 2023, 10:17pm UTC](https://discourse.julialang.org/t/windows-11-versus-wsl2-need-for-speed/99086/2 "2023-05-18T22:17:45Z")

</div>

This guy takes a while to compile. Differences in precompilation are small, but favorable to Windows

```julia
# Win
julia> @time using GMT
[Info: Precompiling GMT [5752ebe1-31b9-557e-87aa-f909b540aa54]
 80.867677 seconds (3.08 M allocations: 151.455 MiB, 0.07% gc time, 0.06% compilation time)

```

```julia
# WSL
julia> @time using GMT
[Info: Precompiling GMT [5752ebe1-31b9-557e-87aa-f909b540aa54]
 82.835008 seconds (3.12 M allocations: 158.919 MiB, 0.11% gc time, 0.06% compilation time)

```
