From nobody Sat Dec 11 10:38:00 2021 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 0AF7B18D7791 for ; Sat, 11 Dec 2021 10:38:03 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JB43t6ByKz4bPD; Sat, 11 Dec 2021 10:38:02 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from smtp.theravensnest.org (smtp.theravensnest.org [45.77.103.195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: theraven) by smtp.freebsd.org (Postfix) with ESMTPSA id AEE392DE68; Sat, 11 Dec 2021 10:38:02 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from [192.168.1.64] (unknown [81.141.223.100]) by smtp.theravensnest.org (Postfix) with ESMTPSA id 0116F2E214; Sat, 11 Dec 2021 10:38:01 +0000 (GMT) Content-Type: text/plain; charset=utf-8 List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.7\)) Subject: Re: Benchmarks: FreeBSD 13 vs. NetBSD 9.2 vs. OpenBSD 7 vs. DragonFlyBSD 6 vs. Linux From: David Chisnall In-Reply-To: Date: Sat, 11 Dec 2021 10:38:00 +0000 Cc: "beepc.ch" , FreeBSD Current Content-Transfer-Encoding: quoted-printable Message-Id: References: To: "dmilith ." X-Mailer: Apple Mail (2.3608.120.23.2.7) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1639219082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=GqpEvDuwBoothqJC8b8jOxSJb5unbOooU3RrT0K8HZg=; b=HrWq0N959TAXbNQ+QX31Vh1GBWDeghLMCDgEz+/O0YxYs7KJkakt2Fp54wKzLnOndhcIxb CH9gdKQFrCHO2/JZKRqUBdD0vYjadooMzRs2TbsFNEquenqq/OYMWJ/FveoUlKCSMc8ypF LLpnR4Q8phKidR2GNFTKbAjWEJgQ8EhWXYVmQUTur4lXgPmG1DxdALM7quaOKV8u/zw9q1 u49iQC9zQxJ3kLIKwZ9p+6mjfzabzTLs8e8jfHRmMxE4whLQ52QefR/96cHekw1/kUV23E yparb8z+Iz/rmXACFmvkxbE1d1yHN/JQ39k9XnyvKuge3Ozt3cMJpbVkaysA8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1639219082; a=rsa-sha256; cv=none; b=Yczxmm0ADOONtf+9J38/cHLH3+506IZUOOSkXMNqiBbMSRbJjOqaF9/bPKEMWa0Wdkcsmq MqSCCzmjod/91Vt6KC3nPEHaXhvXRyEfivqUWf2bz6NYY3Y6RsVifNlBsGASAZSYT4CQog SsBDj+95nLf3+XGjsCM+p35rPucejIVZ6YG3t55VwQxCVjibd8oQz+mVAJOiT2jpmWY0J9 GJ5AocnVGqX/aD2a0FPpGItQxIurKPkIZOPUFiwWHn06J/MjUhq2wVG/AktsjCvmujogoD OsNhwtks+aoQPHalzLUsSEX/U+eOyMkb+APU19xS8/FHQrec5yn01ArByBAUEQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N While I agree on most of your points, the value of Phoronix is that it = tests the default install. As an end user, I don=E2=80=99t care that a particular program is twice = as fast on a particular Linux distro as it is on FreeBSD because of = kernel features, compiler options, or dependency choices. I would love to see the base system include the ThinLTO (LLVM IR) .a = files so that I can do inlining from libc into my program. I would love = for ports to default to ThinLTO unless they break with it. Apple = flipped that switch a few years ago, so a lot of things that broke with = ThinLTO are now fixed. The FreeBSD memcpy / memset implementations look like they=E2=80=99re = slower than the latest ones, which can give a 5-10% perf boost on some = workloads. LLVM just landed the automemcpy framework, which is designed = by some Google folks to synthesises efficient memcpy implementations = tailored to different workloads. FreeBSD often wins versus glibc-based distros because jemalloc is faster = than dlmalloc (the default malloc implementations in FreeBSD libc and = glibc, respectively). I=E2=80=99ve been using snmalloc in my libc for a = while and it generally gives me a few percent more perf. Unfortunately, = FreeBSD decided to expose all of the jemalloc non-standard functions = from libc, which means I can=E2=80=99t contribute it to upstream without = implementing all of those on top of snmalloc or it would be an ABI = break. It would be great if someone could pick up the Phronix benchmark suite = and do some profiling: where is FreeBSD spending more time than Linux? = Are there Linux-specific code paths that hit slow paths on FreeBSD and = fast paths on Linux that could have FreeBSD-specific fast paths added = (e.g. futex vs _umtx_op)? David > On 11 Dec 2021, at 10:17, dmilith . wrote: >=20 > 1. Where are compiler options for BSDs? > 2. Why they compare -O2 to -O3 code in some benchmarks? Why they = enable > fast math in some, and disable it for others? > 3. Why they don't mention powerd setup for FreeBSD? By default it may = use > slowest CPU mode. Did they even load cpufreq kernel module? > 4. Did they even care about default FreeBSD mitigations (via sysctl) > enabled, or it's only valid for Linuxes? ;) > 5. What happened to security and environment details of BSDs? >=20 > It's kinda known that guys from Phroenix lack basic knowledge of how = to do > proper performance testing and lack basic knowledge about BSD systems. > Nothing new. Would take these results with a grain of salt. >=20 > On Sat, 11 Dec 2021 at 10:53, beepc.ch wrote: >=20 >>> I am surprised to see that the BSD cluster today has much worse >> performance >>> than Linux. >>> What do you think of this? >>=20 >> "Default" FreeBSD install setting are quite conservative. >> The Linux common distros are high tuned, those benchmark is in my >> opinion comparison of apples and oranges. >>=20 >> Comparing "default" FreeBSD install with "default" Slackware install >> would be more interesting, because Slackware builds are at most = vanilla. >>=20 >>=20 >=20 > --=20 > Daniel Dettlaff > Versatile Knowledge Systems > verknowsys.com