[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH for-4.1 v2 31/36] cpu: Introduce CPUNegativeOffs
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH for-4.1 v2 31/36] cpu: Introduce CPUNegativeOffsetState |
Date: |
Mon, 29 Apr 2019 08:23:58 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 |
On 4/29/19 7:43 AM, Peter Maydell wrote:
> It would be nice if we could do a compile-time assert that
> offsetof(CPUArchState, neg) + sizeof(CPUNegativeOffsetState)
> == offsetof(CPUArchState, env)
>
> but I guess the possibility of within-struct padding
> between the two structs makes that dubious. Or does our
> generated code rely on there being no padding between neg
> and env anyway ?
It would be nice, but there *is* padding for some targets.
r~