lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAHp75Vd0w0P6xFH1KvGon=cTzNVPJXex33=Tv+vpmNKJXKG2sQ@mail.gmail.com>
Date: Mon, 26 Jan 2026 11:28:47 +0200
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Feng Jiang <jiangfeng@...inos.cn>
Cc: Andy Shevchenko <andriy.shevchenko@...el.com>, pjw@...nel.org, palmer@...belt.com, 
	aou@...s.berkeley.edu, alex@...ti.fr, akpm@...ux-foundation.org, 
	kees@...nel.org, andy@...nel.org, ebiggers@...nel.org, 
	martin.petersen@...cle.com, mingo@...nel.org, charlie@...osinc.com, 
	conor.dooley@...rochip.com, samuel.holland@...ive.com, 
	linus.walleij@...aro.org, nathan@...nel.org, linux-riscv@...ts.infradead.org, 
	linux-kernel@...r.kernel.org, linux-hardening@...r.kernel.org
Subject: Re: [PATCH v4 4/8] lib/string_kunit: add performance benchmark for strlen()

On Mon, Jan 26, 2026 at 8:14 AM Feng Jiang <jiangfeng@...inos.cn> wrote:
> On 2026/1/23 19:02, Andy Shevchenko wrote:
> > On Fri, Jan 23, 2026 at 04:58:37PM +0800, Feng Jiang wrote:

...

> >> +                    _bn_mbps = (u64)(buf_size) * _bn_iters * 1000;  \
> >
> > "KILO"? Or "(MEGA/KILO)"? I'm puzzled with this 1000 multiplier.
>
> The 1000 factor converts bytes/ns to MB/s:
>   (bytes/ns) * (10^9 ns/s) / (10^6 bytes/MB)
> In v5, I will replace it with (NSEC_PER_SEC / MEGA) to make the unit
> conversion explicit and avoid confusion.

Or NSEC_PER_USEC. Whatever, choose the one you think fits best.

-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ