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: <1500902885.12695.0.camel@edumazet-glaptop3.roam.corp.google.com>
Date:   Mon, 24 Jul 2017 06:28:05 -0700
From:   Eric Dumazet <eric.dumazet@...il.com>
To:     Peter Zijlstra <peterz@...radead.org>
Cc:     Rasmus Villemoes <linux@...musvillemoes.dk>,
        Andi Kleen <ak@...ux.intel.com>,
        Andi Kleen <andi@...stfloor.org>, akpm@...ux-foundation.org,
        linux-kernel@...r.kernel.org, davidlohr.bueso@...com,
        rafael.j.wysocki@...el.com, lenb@...nel.org
Subject: Re: [PATCH] Optimize int_sqrt for small values for faster idle

On Thu, 2017-07-20 at 12:10 +0200, Peter Zijlstra wrote:
> On Mon, Feb 01, 2016 at 04:36:38PM -0800, Eric Dumazet wrote:
> > On Tue, 2016-02-02 at 00:08 +0100, Rasmus Villemoes wrote:
> > 
> > > Thanks. (Is there a good way to tell gcc that avg*avg is actually a
> > > 32x32->64 multiplication?)
> > 
> > If avg is 32bit, compiler does that for you.
> > 
> > u32 avg = ...
> > 
> > u64 result = (u64)avg * avg;
> 
> It does not in fact do that :/ See commit:
> 
>   9e3d6223d209 ("math64, timers: Fix 32bit mul_u64_u32_shr() and friends")

Interesting :/

Thanks for letting me know !


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ