Windows Subsystem for Linux (Ubuntu Bash on Windows) Benchmarked Against Native Ubuntu 14.04 and 16.04

Orange Pi Development Boards

Microsoft recently announced that they brought Ubuntu userspace to Windows, and that this features will be officially released in Windows 10’s Anniversary Update and called Windows Subsystem for Linux. But people part of the company’s insider program can already try the beta version of “Bash on Windows”, and Phoronix ran some benchmarks in bash in Windows 10, and repeated the tests in Ubuntu 16.04, Ubuntu 14.04, and Clear Linux. The test machine was based on an Intel Xeon E3-1280 v5 Skylake CPUwith 16GB of RAM and 120GB Samsung 850 EVO SSD.

Many of the results show Windows Subsystem for Linux (I’ll just call it Windows 10 in the rest of the post) just performing a little slower than on the Linux distributions, but there are also some outliers, which I’m going to cover here.

The most surprising results is when Windows 10 clearly outperforms Linux at its own game which should not be happening.

Windows_10_Bash_vs_Linux_Bash_Stream_Triad
Click to Enlarge
Click to Enlarge
Click to Enlarge

That’s the case for Stream 1.2 triad and add benchmarks. Stream is supposed to benchmark the system memory (RAM) performance. The copy operation from the same benchmark is still faster in Linux however, except in Ubuntu 14.04.

Click to Enlarge
Click to Enlarge

The table below summarize the operation for the 4 stream tests:


I don’t have any explanation for the issue, but maybe some people can provide some clues in the comments.

There were also benchmarks where bash on Windows 10 is  much slower, likely due to the use of NTFS instead of EXT-4.

Click to Enlarge
Click to Enlarge

The Compile bench “tries to age a filesystem by simulating some of the disk IO common in creating, compiling, patching, stating and reading kernel trees. It indirectly measures how well file systems can maintain directory locality as the disk fills up and directories age. This current test is setup to use the makej mode with 10 initial directories”. Since Ubuntu bash on Windows is designed for developers this may actually matter. The poor performance is confirmed with Timed PHP compilation benchmark.

Click to Enlarge
Click to Enlarge

So it may pay off to try some other file systems if possible in Windows 10.

SciMarks v2.0 Fast Fourier Transform is another benchmark that’s quite faster in bash in Windows 10.

Click to Enlarge
Click to Enlarge

That one is also odd, so there must be some operations that the Windows kernel does faster than the Linux kernel, even after the overhead of converting Linux calls to Windows calls.

Windows 10 got back to struggling with Redis open-source data structure server benchmark that’s likely reliant on storage I/Os.

Click to Enlarge
Click to Enlarge

The other benchmark results where more or less in line with expectations, although there were some regressions between Ubuntu 16.04 and Ubuntu 14.04.

Support CNX Software - Donate via PayPal or become a Patron on Patreon

8
Leave a Reply

avatar
8 Comment threads
0 Thread replies
0 Followers
 
Most reacted comment
Hottest comment thread
6 Comment authors
HuitzianonymoustkaisercnxsoftFransM Recent comment authors
  Subscribe  
newest oldest most voted
Notify of
notzed
Guest
notzed

“ubuntu userland” i.e. GNU? GNU/M$, who’d have thunk that’d be the next thing they’d want to EEE is GNU Bash.

All tests would depend on the compiler somewhat which might explain the 14.04 differences in the memory tests. Since CPU bound things should only depend on the hardware, the main OS contributors would be the page table setup or context switching rate, or power throttling/burst modes.

Those NTFS times mirror my experience with it (native) – it’s total junk.

FransM
Guest
FransM

I feel Ubuntu Bash is a misnomer. Bash is a GNU project not something Ubuntu created.

tkaiser
Guest
tkaiser

So he messed up storage configuration in Windows, tested different compilers and obviously syscalls (according to the screenshots the Linux subsystem reports a kernel 3.4.0). And the most interesting thing (huuuuuge standard deviation, see the Stream values above) is not even commented. Another round of useless passive benchmarking as usual 🙂

It might be interesting how results differ if PTS would start to use optimised settings and not nonsense ‘defaults’ and demanding tests like cpuminer.

BTW: I don’t get why bash is mentioned at all since it’s about the performance of this “Windows Subsystem for Linux” and neither bash nor Ubuntu (I would assume you can replace the whole Ubuntu userland with something else)

tkaiser
Guest
tkaiser

@cnxsoft
You start C:\Windows\System32\bash.exe (could also be called C:\Windows\System32\enter_hell.exe 😉 ) and then you get a root shell that is bash by default (I would suspect it could also be zsh or sh later), the userland will be downloaded the first time you start WSL and is a stripped down Ubuntu 14.04 LTS (x86-64) and most importantly there is no interconnection to the Windows world apart from sockets and filesystem access (/mnt/c/ — OMG). It’s a nice feature for developers that want to quickly try out things or are more familiar with Unix tools but there is no real interaction with Windows applications possible.

Therefore the whole benchmarking approach is even more questionable than as usual with the Phoronix stuff. And when you’re talking about performance both bash/Ubuntu aren’t relevant but WSL’s syscall implementation. And even in this early stage it already seems quite performant and we might even see Linux stuff being executed faster using the Windows kernel 😉

I had some hope there would be more integration between Linux and Windows possible with WSL. Like on OS X for example where I have full access to application objects from BSD using osascript and the like or am able to interact between Cocoa apps and BSD stuff through Automator.

anonymous
Guest
anonymous

The storage benchmarks being bad probably reflects that the abstraction layer needs to do a lot of work for every filesystem access, emulating what the Linux expects from its filesystems, directory structure, acess rights. Benchmarks that are only bottlenecked by RAM usage or CPU power should have it easier.

Huitzi
Guest
Huitzi

The differences in math performance might be due to different compilers used for making the kernels of Windows10 and Ubuntu, using different features of the CPU. Just guessin’… Otherwise it makes absolutely no sense that such simple calls yield such different results.