Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 1 | Clang's builtin for clear_cache accepts char* and errors out when using void*, |
| 2 | using char* work on both gcc and clang since char* is auto-converted to void* in gcc case |
| 3 | |
| 4 | Source/JavaScriptCore/assembler/ARM64Assembler.h:2857:33: error: cannot initialize a parameter of type 'char *' with an rvalue of type 'void *' |
| 5 | __builtin___clear_cache(reinterpret_cast<void*>(begin), reinterpret_cast<void*>(end)); |
| 6 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 7 | 1 error generated. |
| 8 | |
| 9 | Signed-off-by: Khem Raj <raj.khem@gmail.com> |
| 10 | |
| 11 | Upstream-Status: Accepted |
| 12 | |
| 13 | Index: webkitgtk-2.8.5/Source/JavaScriptCore/assembler/ARM64Assembler.h |
| 14 | =================================================================== |
| 15 | --- webkitgtk-2.8.5.orig/Source/JavaScriptCore/assembler/ARM64Assembler.h |
| 16 | +++ webkitgtk-2.8.5/Source/JavaScriptCore/assembler/ARM64Assembler.h |
| 17 | @@ -2854,7 +2854,7 @@ public: |
| 18 | #if OS(LINUX) && COMPILER(GCC) |
| 19 | static inline void linuxPageFlush(uintptr_t begin, uintptr_t end) |
| 20 | { |
| 21 | - __builtin___clear_cache(reinterpret_cast<void*>(begin), reinterpret_cast<void*>(end)); |
| 22 | + __builtin___clear_cache(reinterpret_cast<char*>(begin), reinterpret_cast<char*>(end)); |
| 23 | } |
| 24 | #endif |
| 25 | |