On 08/25/2011 09:03 AM, Stefan Weil wrote:
As I wrote in my last mail, I compared all structs without and with
-mms-bitfields
using pahole and codiff. The result is in the appended codiff.log.

About 17 structs changed because of -mms-bitfield. This attribute
modifies not only
structs with bitfield but also packed structs or structs with other
attributes
like TCGPool.

Jan's patch fixed slirp bitfields. For the remaining cases, I also
thought about
removing -mms-bitfield or setting a pragma in qemu-common.h, but now I
prefer a different solution: replace all __attribute__(packed),
__attribute(__packed__)
by QEMU_PACKED.

QEMU_PACKED will be a macro defined in compiler.h which sets the attributes
needed (also for w32 with -mms-bitfields).

That sounds like a good idea.

Regards,

Anthony Liguori


Maybe I can send patches with the changes needed next weekend if
everybody agrees
to this solution.

Cheers,
Stefan



Reply via email to