lkml.org 
[lkml]   [2018]   [Oct]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v9 04/10] x86: refcount: prevent gcc distortions
From
Date
On 10/04/18 02:16, Ingo Molnar wrote:
>
> * hpa@zytor.com <hpa@zytor.com> wrote:
>
>> Ingo: I wasn't talking necessarily about the specifics of each bit, but rather the general
>> concept about being able to use macros in inlines...
>
> Ok, agreed about that part - and some of the patches did improve readability.
>
> Also, the 275 lines macros.s is a lot nicer than the 4,200 lines macros.S.
>
> Also, I'm not against using workarounds when the benefits are larger than the costs, but I am
> against *hiding* the fact that these are workarounds and that for some of them there are costs.
>

Agreed, of course.

>> I can send you something I have been working on in the background, but have been holding off
>> on because of this, in the morning my time.
>
> BTW., I have applied most of the series to tip:x86/kbuild already, and will push them out later
> today after some testing. I didn't apply the final 3 patches as they have dependencies, but
> applied the basics and fixed up the changelogs.
>
> So you can rely on this.
>

Wonderful.

Here is the horrible code I mentioned yesterday. This is about
implementing the immediate-patching framework that Linus and others have
discussed (it helps both performance and kernel hardening):

Warning: this stuff can cause serious damage to your eyes, and this is a
just a small chunk of the whole mess; and relying on gas macros, as
brain damaged as they are, really is much, much cleaner than not:

http://www.zytor.com/~hpa/foo.S

-hpa



\
 
 \ /
  Last update: 2018-10-04 21:34    [W:0.141 / U:3.344 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site