|
From: | Richard Henderson |
Subject: | Re: [RFC v2 3/6] target/i386: Add native library calls |
Date: | Wed, 7 Jun 2023 12:19:37 -0700 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 |
On 6/7/23 09:47, Yeqi Fu wrote:
+ /* One unknown opcode for native call */ +#if defined(CONFIG_USER_ONLY) && defined(CONFIG_USER_NATIVE_CALL) + case 0x1ff: + uint16_t sig = x86_lduw_code(env, s); + switch (sig) { + case NATIVE_MEMCPY: + gen_helper_native_memcpy(cpu_env); + break; + case NATIVE_MEMSET: + gen_helper_native_memset(cpu_env); + break; + case NATIVE_MEMCMP: + gen_helper_native_memcmp(cpu_env); + break; + default: + goto unknown_op; + } + break; +#endif
This bit of code must be protected by native_calls_enabled() or some such, as we do with semihosting_enabled().
Which means that patch 6 should come before this, so that native_calls_enabled() can be true if and only if "-native-bypass" is given.
r~
[Prev in Thread] | Current Thread | [Next in Thread] |