lkml.org 
[lkml]   [2023]   [Jun]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [Bug report] __arch_hweight32/64 x86
Date
From: Borislav Petkov
> Sent: 27 June 2023 05:26
>
> On Mon, Jun 26, 2023 at 03:41:27PM -0700, Dave Hansen wrote:
> > I'm not even sure that UML needs GENERIC_HWEIGHT. From a quick glance,
> > it looks like x86 used to use GENERIC_HWEIGHT, but got arch-specific
> > versions later. UML just never moved over to the arch-specific versions.
>
> Thanks - that could very well be the explanation.
>
> That bug report made me blink a couple of times since I did take extra
> precaution to not clobber regs in arch/x86/lib/hweight.S as this was
> part of the whole pain back then with calling a function from asm where
> gcc doesn't even know we're calling a function, see:

Perhaps the asm called function should use a different global
label than the one in the C file.

Then it wouldn't be as fragile.

David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)
\
 
 \ /
  Last update: 2023-06-29 11:14    [W:0.045 / U:0.256 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site