lkml.org 
[lkml]   [2022]   [Feb]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 4/4] x86/mce: Avoid unnecessary padding in struct mce_bank
On Fri, Feb 11, 2022 at 04:34:42PM -0600, Smita Koralahalli wrote:
> Include struct mce_bank member "init" in the bitfield by changing its type
> from bool to get rid of unnecessary padding and to reduce the overall
> struct size.
>
> Outputs collected before and after the change.
>
> $ pahole -C mce_bank arch/x86/kernel/cpu/mce/core.o
>
> before:
>
> /* size: 24, cachelines: 1, members: 5 */
> /* bit holes: 1, sum bit holes: 62 bits */
> /* bit_padding: 2 bits */
> /* last cacheline: 24 bytes */
>
> after:
>
> /* size: 16, cachelines: 1, members: 5 */
> /* last cacheline: 16 bytes */

I don't mind cleanups like that but when you send them as part of a set
adding new functionality, the usual rule is to put bug fixes, cleanups,
improvements, etc to the existing code *first*, and then, ontop you add
your new code.

IOW, this patch should be first in your set.

Thx.

--
Regards/Gruss,
Boris.

https://people.kernel.org/tglx/notes-about-netiquette

\
 
 \ /
  Last update: 2022-02-22 16:38    [W:0.185 / U:0.876 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site