Re: [Qemu-devel] [PATCH 01/26] tcg: Assert h2g_valid for 32-bit guest on 64-bit host

2019-04-03 Thread Richard Henderson
On 4/3/19 11:59 AM, Peter Maydell wrote: >> +#if TARGET_LONG_BITS == 32 && HOST_LONG_BITS == 64 >> +g_assert(h2g_valid(address)); >> +#endif > > I'm not sure this is right. h2g_valid() will check whether the guest address > is > below GUEST_ADDR_MAX. For architectures which set > TARGET_VIRT_

Re: [Qemu-devel] [PATCH 01/26] tcg: Assert h2g_valid for 32-bit guest on 64-bit host

2019-04-02 Thread Peter Maydell
On Wed, 3 Apr 2019 at 10:46, Richard Henderson wrote: > > For this combination, we can tell whether or not the address > being accessed is within the 4GB range that is accessible by > the guest. Otherwise the fault must be elsewhere in qemu, > accessing qemu data structures. > > Signed-off-by: Ri

[Qemu-devel] [PATCH 01/26] tcg: Assert h2g_valid for 32-bit guest on 64-bit host

2019-04-02 Thread Richard Henderson
For this combination, we can tell whether or not the address being accessed is within the 4GB range that is accessible by the guest. Otherwise the fault must be elsewhere in qemu, accessing qemu data structures. Signed-off-by: Richard Henderson --- accel/tcg/user-exec.c | 9 + 1 file ch