Commit 238088da authored by Nico Weber's avatar Nico Weber Committed by Commit Bot

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: 's avatarRoss McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#68571}
parent 81d37159
......@@ -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
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment