mac/arm64: use sys_icache_invalidate().
Does step 5 of the linked bug. Bug: chromium:1098923 Change-Id: I590cbaddb803f6343a61f7b49f7b8a4cb9773220 Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2270704 Auto-Submit: Nico Weber <thakis@chromium.org> Commit-Queue: Ross McIlroy <rmcilroy@chromium.org> Reviewed-by: Ross McIlroy <rmcilroy@chromium.org> Cr-Commit-Position: refs/heads/master@{#68571}
This commit is contained in:
parent
81d37159e6
commit
238088da68
@ -9,6 +9,10 @@
|
||||
#include "src/codegen/arm64/utils-arm64.h"
|
||||
#include "src/codegen/cpu-features.h"
|
||||
|
||||
#if V8_OS_MACOSX
|
||||
#include <libkern/OSCacheControl.h>
|
||||
#endif
|
||||
|
||||
namespace v8 {
|
||||
namespace internal {
|
||||
|
||||
@ -41,6 +45,8 @@ void CpuFeatures::FlushICache(void* address, size_t length) {
|
||||
#if defined(V8_HOST_ARCH_ARM64)
|
||||
#if defined(V8_OS_WIN)
|
||||
::FlushInstructionCache(GetCurrentProcess(), address, length);
|
||||
#elif defined(V8_OS_MACOSX)
|
||||
sys_icache_invalidate(address, length);
|
||||
#else
|
||||
// The code below assumes user space cache operations are allowed. The goal
|
||||
// of this routine is to make sure the code generated is visible to the I
|
||||
|
Loading…
Reference in New Issue
Block a user