summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/pcre/patches/r1340_fix_jit_on_android.patch
blob: 41699d48823681bfef7fc17516a75f230dd2f41c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Index: sljit/sljitConfigInternal.h
===================================================================
--- sljit/sljitConfigInternal.h	(revision 1339)
+++ sljit/sljitConfigInternal.h	(working copy)
@@ -221,6 +221,13 @@
 #define SLJIT_CACHE_FLUSH(from, to) \
 	sys_icache_invalidate((char*)(from), (char*)(to) - (char*)(from))
 
+#elif defined __ANDROID__
+
+/* Android lacks __clear_cache; instead, cacheflush should be used. */
+
+#define SLJIT_CACHE_FLUSH(from, to) \
+    cacheflush((long)(from), (long)(to), 0)
+
 #elif (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
 
 /* The __clear_cache() implementation of GCC is a dummy function on PowerPC. */