Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(653)

Unified Diff: runtime/vm/cpu_arm64.cc

Issue 2226843002: Fuchsia: Fix arm64 build (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/assembler_arm64_test.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/cpu_arm64.cc
diff --git a/runtime/vm/cpu_arm64.cc b/runtime/vm/cpu_arm64.cc
index 881aebc42fb166c6de00eb567bb6828115c50568..e612cceb6990c71c3cb30ffc07f0f175def64549 100644
--- a/runtime/vm/cpu_arm64.cc
+++ b/runtime/vm/cpu_arm64.cc
@@ -3,10 +3,11 @@
// BSD-style license that can be found in the LICENSE file.
#include "vm/globals.h"
-
#if defined(TARGET_ARCH_ARM64)
#include "vm/cpu.h"
+#include "vm/cpu_arm64.h"
+
#include "vm/cpuinfo.h"
#include "vm/simulator.h"
@@ -31,13 +32,15 @@ void CPU::FlushICache(uword start, uword size) {
// ARM recommends using the gcc intrinsic __clear_cache on Linux and Android.
// blogs.arm.com/software-enablement/141-caches-and-self-modifying-code/
- #if defined(__linux__) || defined(ANDROID)
+ #if defined(TARGET_OS_ANDROID) || \
+ defined(TARGET_OS_FUCHSIA) || \
+ defined(TARGET_OS_LINUX)
extern void __clear_cache(char*, char*);
char* beg = reinterpret_cast<char*>(start);
char* end = reinterpret_cast<char*>(start + size);
::__clear_cache(beg, end);
#else
- #error FlushICache only tested/supported on Linux and Android
+ #error FlushICache only tested/supported on Android, Fuchsia, and Linux
#endif
#endif
« no previous file with comments | « runtime/vm/assembler_arm64_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698