[Devel] Re: [PATCH 1/7] cgroups: Shrink struct cgroup_subsys

Paul Menage menage at google.com
Tue Nov 9 13:05:31 PST 2010


On Sun, Nov 7, 2010 at 9:23 PM, Li Zefan <lizf at cn.fujitsu.com> wrote:
>
> bool active;
> bool disabled;
> ...
>
> ?
>
> With alignment 5-8 bool values == 8 bytes in 64-bit machine, compared to
> 4 bytes with the approach this patch takes.

I meant specifying it as:

bool active:1;
bool disabled:1;

i.e. keeping the bit-sized flags but also keeping the bool semantics.
Having said that, I'm not really sure why saving 12 bytes per
subsystem is worth a patch.

Paul
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list