[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/7] QEMU does not currently support host pages
Re: [Qemu-devel] [PATCH 2/7] QEMU does not currently support host pages that are larger than guest pages, likely due to glibc using fixed mmap requests.
Sun, 19 Jun 2016 11:24:44 -0700
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1
On 06/19/2016 02:46 AM, Peter Maydell wrote:
On 19 June 2016 at 01:11, Timothy Pearson
Attempting to use host pages larger than the guest leads to
alignment errors during ELF load in the best case, and an
initialization failure inside NPTL in the worst case, causing
all fork() requests inside the guest to fail.
Warn when thread space cannot be set up, and suggest reducing
host page size if applicable.
This is supposed to work -- for instance the linux-user/mmap.c
code has support for host pages and target pages not being the same.
In particular for ARM guests TARGET_PAGE_SIZE is 1K but the
host page size is 4K, so the config of "host page larger than
guest" isn't untested.
You're right, it isn't untested, it's completely broken.
The arm 1k example isn't really realistic, because the actual arm kernel doles
out 4k units, and that's what userspace was built to expect. Try running i386
on aarch64 (or ppc64) with a 64k page kernel. Maps fail very very quickly.
This is one of the reasons why I think there's no way to do such emulation
without softmmu for linux-user.