[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3] tcg: Fix execution on Apple Silicon
From: |
Roman Bolshakov |
Subject: |
Re: [PATCH v3] tcg: Fix execution on Apple Silicon |
Date: |
Tue, 2 Feb 2021 11:54:43 +0300 |
On Fri, Jan 29, 2021 at 07:27:57PM -1000, Richard Henderson wrote:
> On 1/29/21 10:50 AM, Roman Bolshakov wrote:
> >
> > I thought you already added MAP_JIT in 6f70ddee19e. It's getting enabled
> > on my M1 laptop. Was it intended or not?
> >
> > /* Applicable to both iOS and macOS (Apple Silicon). */
> > if (!splitwx) {
> > flags |= MAP_JIT;
> > }
> >
> > TCG from master branch of QEMU works fine on M1. I'm not sure why do we
> > need to duplicate it.
>
> I thought there was something about abi/api build issues. If there's nothing
> that needs doing, great!
>
Hi Richard,
You're correct that older versions of OS X/macOS might not have MAP_JIT
definition, so a simple wrapping of the hunk with ifdef MAP_JIT might be
sufficient (or guard it for Big Sur and above):
#if defined(MAC_OS_VERSION_11_0) && \
MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_VERSION_11_0
if (!splitwx && __builtin_available(macOS 11.0, *)) {
flags |= MAP_JIT;
}
#endif
But I'm not sure if we want to support hosts older than 10.14.
Regards,
Roman
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH v3] tcg: Fix execution on Apple Silicon,
Roman Bolshakov <=