32 comments

[ 3.1 ms ] story [ 47.2 ms ] thread
No, generally Linux is at least 3x faster than OpenBSD, because they don't care much for optimizations.
"It depends"

Faster is all relative. What are you doing? Is it networking? Then BSD is probably faster than Linux. Is it something Linux is optimized for? Then probably Linux.

A general benchmark? Who knows, but does it really matter?

At the end of the day, you should benchmark your own workload, but also it's important to realize that in this day and age, it's almost never the OS that is the bottleneck. It's almost always a remote network call.

In my mind faster = the same game with the same graphics settings have more FPS

(I don’t even know you could actually start mainstream games on BSD or not)

Interesting. I tried to follow the discussion in the linked thread, and the only takeaway I got was "something to do with RCU". What id the simplified explanation?
So ... essentially testing file descriptor allocation overhead
My guess is it has something to do with the file descriptor table having a lot of empty entries (the dup2(0, 666) line.)

Now time to read the actual linked discussion.

Yea, well, I had to modify your website to make it readable. Why do people do this?
A better title: a pathological test program meant for Linux does not trigger pathological behavior on OpenBSD
Not sure if that’s relevant, but when I do micro-benchmarks like that measuring time intervals way smaller than 1 second, I use __rdtsc() compiler intrinsic instead of standard library functions.

On all modern processors, that instruction measures wallclock time with a counter which increments at the base frequency of the CPU unaffected by dynamic frequency scaling.

Apart from the great resolution, that time measuring method has an upside of being very cheap, couple orders of magnitude faster than an OS kernel call.

While __rdtsc() is fast, be cautious with multi-core benchmarks as TSC synchronization between cores isn't guaranteed on all hardware, especially older systems. Modern Intel/AMD CPUs have "invariant TSC" which helps, but it's worth checking CPU flags first.
I don't think it is (guaranteed to be) synchronized across cores. I might be wrong about that though.
the first step in benchmarking software is to use the same hardware.

the author failed the first step.

everything that follows is then garbage.

By leaving my finger on the screen, I accidentally triggered an easter egg of two "cannons" shooting squares. Did anyone else notice it?
the bsd people seem to enjoy measuring and logging a lot.
OpenBSD is many things, but 'fast' is not a word that comes to mind.

Lightweight? Yes.

Minimalist? Definitely.

Compact? Sure.

But fast? No.

Would I host a database or fileserver on OpenBSD? Hell no.

Boot times seem to take as long as they did 20 years ago. They are also advocates for every schizo security mitigation they can dream up that sacrifices speed and that's ok too.

But let's not pretend it's something it's not.

Gotta disagree with you on your minimalist verdict, out of the box openbsd tends to have everything and the kitchen sink, I am not complaining, it is good solid well written software. but I have never found a base linux distro that was as well stocked as a base openbsd install.

    a c compiler
    a web server
    3 routing daemons(bgpd, ospfd, ripd)
    a mail server(smtpd, spamd)
    a sound server(sndiod)
    a reverse proxy(relayd)
    2 desktop environments(fvwm, cwm)
    plus many many more
Openbsd is not some minimalist highly focused operating system, I mean what on earth is it actually for? based on the included features, A desktop development system that is also the router and office web and mail server?

Personally I love it, after a fresh install I always feel like I could rebuild the internet from scratch using only what is found in front of me if I needed to.

OpenBSD runs much faster than 20 years ago thanks to sending locks to /dev/null.
I think OpenBSD has gotten quite a bit faster in the last 4 - 5 releases. Unfortunately we will need to wait for another round of benchmarks by phoronix as it seems to have problems every time benchmarks are ran.

Somewhere along the line may be it will become fast enough and certain applications may use it for different sets of reasons.

This is kind of a stupid "benchmark" but if we're going to walk down this road:

linux: elapsed: 0.019895s

nanos (running on said linux): elapsed: 0.000886s

What about this on FreeBSD? It's possible to reach the same results?
A better way to do that (sorry) is to increase the loading instead of modifying the test. I'm happy to hear reasons why their way could be a better benchmark.
(comment deleted)