# Comparison of Windows 10 and Linux Julia

**URL:** <https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227>\
**Category:** General Usage\
**Created:** [June 11, 2020, 8:01pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227 "2020-06-11T20:01:38Z")\
**Posts on this page:** 16\
**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:** [June 11, 2020, 8:01pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/1 "2020-06-11T20:01:38Z")

</div>

I was curious about some recent observations I made concerning the speed of sparse-matrix solve.  
Here are some measurements comparing Windows 10, WSL2, and Ubuntu 20.4, all running on the same laptop(HP Spectre 360 i7 at 3.1 GHz, 16 GB of memory). Serial execution with default number of threads.

Assembly of the left-hand side matrix and the right hand side vector [(source).](https://github.com/PetrKryslUCSD/Elfel.jl/blob/master/examples/heat/heat_poisson_q4_alt_wgradN.jl). 4.2 million degrees of freedom.

![image](https://global.discourse-cdn.com/julialang/original/3X/3/7/37bb8006f463378d90fa1172973baa98896762f3.png)

Solution of 4.2 million coupled linear algebraic equations. Default sparse matrix storage, and default solution method (\).

 ![image](https://global.discourse-cdn.com/julialang/original/3X/7/a/7a361f91caef8ecc451bdf206c9458f4d9c06b19.png)

---

<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:** [June 11, 2020, 11:53pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/2 "2020-06-11T23:53:55Z")

</div>

I forgot to post my conclusion re WSL2. It seems it leaves some performance on the table. That is fine for development, but not so good for running real simulations.

---

<div class="post-metadata">

**Author:** ![paolol](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/paolol/32/14624_2.png) [@paolol](https://discourse.julialang.org/u/paolol)\
**Post date:** [June 12, 2020, 8:07am UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/3 "2020-06-12T08:07:51Z")

</div>

I agree , but is normal for a Virtual Machine to be less performant . It will be cool to see the Linux performance using a more performant Distro like Arch or Manjaro with a real time Kernel.  
But thanks for your work 🙂

---

<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:** [June 12, 2020, 8:19pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/4 "2020-06-12T20:19:26Z")

</div>

Update with Manjaro 18.0  
Data as in the OP. First the assembly:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/3/2/321d53e6bd550a46776457d523c66be29eaf690f.png)  
Sparse matrix solve:  
 ![image](https://global.discourse-cdn.com/julialang/original/3X/2/4/241ff28a0447b03dcf6e12ee108b41e714daa37c.png)  
EDIT: Sorry, Manjaro is mislabeled. It was 20.0.3.

---

<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:** [June 12, 2020, 8:20pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/5 "2020-06-12T20:20:09Z")

</div>

By the way, the WSL2 was running Ubuntu 20.4.

---

<div class="post-metadata">

**Author:** ![affans](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/affans/32/11911_2.png) [@affans](https://discourse.julialang.org/u/affans)\
**Post date:** [June 12, 2020, 8:24pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/6 "2020-06-12T20:24:26Z")

</div>

Thanks for this. The last few days I am switching my dev over to WSL2. For small codes and data analysis, I am okay with the performance hit. But that being said, in your simulations you are not reading/writing from `/mnt/` correct? It’s been established that the cross filesystem read/write is horrendous right now. If you stay purely within the Linux file system, things should be on par with running natively on Windows.

---

<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:** [June 12, 2020, 8:26pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/7 "2020-06-12T20:26:26Z")

</div>

No reading/writing. Pure computation.

---

<div class="post-metadata">

**Author:** ![jebej](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jebej/32/1784_2.png) [@jebej](https://discourse.julialang.org/u/jebej)\
**Post date:** [June 12, 2020, 8:48pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/8 "2020-06-12T20:48:10Z")

</div>

Would WSL1 be faster for pure computation?

---

<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:** [June 12, 2020, 9:02pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/9 "2020-06-12T21:02:08Z")

</div>

I don’t know at the moment, I only have WSL2 installed. Sorry.

---

<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:** [June 12, 2020, 9:46pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/10 "2020-06-12T21:46:02Z")

</div>

I know from past experience that Linux excels when handling threaded Julia computations. Much better scaling than Windows. But frankly I expected more from Linux even on serial execution. I’ve heard of “high-performance” distros (Manjaro). I did not see that in the data above.

Has anyone made some experiences that bear on this?

---

<div class="post-metadata">

**Author:** ![cschubert](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/cschubert/32/13467_2.png) [@cschubert](https://discourse.julialang.org/u/cschubert)\
**Post date:** [June 13, 2020, 12:48pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/11 "2020-06-13T12:48:59Z")

</div>

Its just a guess but maybe this behavior is related to some intel security mitigations. Many of these are integrated in the recent linux kernels.  
Was/is your Windows 10 Installation up to date and are all vendors drivers/firmeware/bios up to date?

---

<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:** [June 13, 2020, 1:58pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/12 "2020-06-13T13:58:37Z")

</div>

Yes. I had the Win 10 updated to 2004 so that I could install WSL2. Which was going to be much better than WSL1.

---

<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:** [June 13, 2020, 6:22pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/13 "2020-06-13T18:22:28Z")

</div>

Found out that 1.4.2 is on LLVM 8 whereas 1.5 and nightly are on LLVM 9. Could that be the reason for the speedup?

---

<div class="post-metadata">

**Author:** ![paolol](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/paolol/32/14624_2.png) [@paolol](https://discourse.julialang.org/u/paolol)\
**Post date:** [June 14, 2020, 9:16am UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/14 "2020-06-14T09:16:10Z")

</div>

First thanks for all your effort.  
I will like to know what kernel did you use on Manjaro,a s the latest ISO is 20 and we just got the 5.7.0.x few days ago and current installed LLVM-libs is 10.0.0.2

---

<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:** [June 14, 2020, 2:16pm UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/15 "2020-06-14T14:16:10Z")

</div>

Sorry, my plotting got the Manjaro Linux mislabeled. I’ve actually booted manjaro-xfce-20.0.3-200606-linux56.iso.

---

<div class="post-metadata">

**Author:** ![paolol](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/paolol/32/14624_2.png) [@paolol](https://discourse.julialang.org/u/paolol)\
**Post date:** [June 15, 2020, 8:37am UTC](https://discourse.julialang.org/t/comparison-of-windows-10-and-linux-julia/41227/16 "2020-06-15T08:37:11Z")

</div>

Thanks a lot for your work.  
🙂
