Bug 1359051 - Define cacheFlush for non-Simulator ARM64 builds. r=tcampbell, a=gchang
authorSean Stangl <sstangl@mozilla.com>
Mon, 24 Apr 2017 07:10:58 -0700
changeset 396190 d22924480749a538be73441d00c3ee50c65263a2
parent 396189 b13c3ced8ccf79c0df78183fd57f4a22272022bf
child 396191 ffe5677aac10c9d45c22fa3e1005737005a3e4c4
push id1468
push userasasaki@mozilla.com
push dateMon, 05 Jun 2017 19:31:07 +0000
treeherdermozilla-release@0641fc6ee9d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstcampbell, gchang
bugs1359051
milestone54.0
Bug 1359051 - Define cacheFlush for non-Simulator ARM64 builds. r=tcampbell, a=gchang
js/src/jit/ExecutableAllocator.h
--- a/js/src/jit/ExecutableAllocator.h
+++ b/js/src/jit/ExecutableAllocator.h
@@ -254,17 +254,17 @@ class ExecutableAllocator
         _flush_cache(reinterpret_cast<char*>(code), size, BCACHE);
 #endif
     }
 #elif defined(JS_CODEGEN_ARM) && (defined(__FreeBSD__) || defined(__NetBSD__))
     static void cacheFlush(void* code, size_t size)
     {
         __clear_cache(code, reinterpret_cast<char*>(code) + size);
     }
-#elif defined(JS_CODEGEN_ARM) && defined(XP_IOS)
+#elif (defined(JS_CODEGEN_ARM) || defined(JS_CODEGEN_ARM64)) && defined(XP_IOS)
     static void cacheFlush(void* code, size_t size)
     {
         sys_icache_invalidate(code, size);
     }
 #elif defined(JS_CODEGEN_ARM) && (defined(__linux__) || defined(ANDROID)) && defined(__GNUC__)
     static void cacheFlush(void* code, size_t size)
     {
         void* end = (void*)(reinterpret_cast<char*>(code) + size);
@@ -292,17 +292,17 @@ class ExecutableAllocator
                 "mov     r2, #0x0\n"
                 "svc     0x0\n"
                 "pop     {r7}\n"
                 :
                 : "r" (start), "r" (end)
                 : "r0", "r1", "r2");
         }
     }
-#elif defined(JS_CODEGEN_ARM64) && (defined(__linux__) || defined(ANDROID)) && defined(__GNUC__)
+#elif defined(JS_CODEGEN_ARM64)
     static void cacheFlush(void* code, size_t size)
     {
         vixl::CPU::EnsureIAndDCacheCoherency(code, size);
     }
 #elif defined(__sparc__)
     static void cacheFlush(void* code, size_t size)
     {
         sync_instruction_memory((caddr_t)code, size);