[compiler-rt] r309848 - This ppc64 implementation of clear_cache works for both big and little endian.

Sterling Augustine via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 2 11:13:59 PDT 2017


Author: saugustine
Date: Wed Aug  2 11:13:59 2017
New Revision: 309848

URL: http://llvm.org/viewvc/llvm-project?rev=309848&view=rev
Log:
This ppc64 implementation of clear_cache works for both big and little endian.

Modified:
    compiler-rt/trunk/lib/builtins/clear_cache.c

Modified: compiler-rt/trunk/lib/builtins/clear_cache.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/builtins/clear_cache.c?rev=309848&r1=309847&r2=309848&view=diff
==============================================================================
--- compiler-rt/trunk/lib/builtins/clear_cache.c (original)
+++ compiler-rt/trunk/lib/builtins/clear_cache.c Wed Aug  2 11:13:59 2017
@@ -165,7 +165,7 @@ void __clear_cache(void *start, void *en
   for (addr = xstart; addr < xend; addr += icache_line_size)
     __asm __volatile("ic ivau, %0" :: "r"(addr));
   __asm __volatile("isb sy");
-#elif defined (__powerpc64__) && defined(__LITTLE_ENDIAN__)
+#elif defined (__powerpc64__)
   const size_t line_size = 32;
   const size_t len = (uintptr_t)end - (uintptr_t)start;
 




More information about the llvm-commits mailing list