]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Fix the bigcode test failure for TILEGX
authorZhi-Gang Liu <zliu@tilera.com>
Wed, 15 Apr 2015 02:56:20 +0000 (02:56 +0000)
committerZhi-Gang Liu <zliu@tilera.com>
Wed, 15 Apr 2015 02:56:20 +0000 (02:56 +0000)
By: Zhi-Gang Liu

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15095

perf/bigcode.c

index 6e8940140bfed38b4de75e624a9f06104b2d3fbe..8cb1cd223c819865c949526e1ee2c61f6cfdcc22 100644 (file)
 #if defined(__mips__)
 #include <asm/cachectl.h>
 #include <sys/syscall.h>
+#elif defined(__tilegx__)
+#include <asm/cachectl.h>
 #endif
 #include "tests/sys_mman.h"
 
-#define FN_SIZE   996      // Must be big enough to hold the compiled f()
+#define FN_SIZE   1024     // Must be big enough to hold the compiled f()
 #define N_LOOPS   20000    // Should be divisible by four
 #define RATIO     4        // Ratio of code sizes between the two modes
 
@@ -71,6 +73,8 @@ int main(int argc, char* argv[])
 
 #if defined(__mips__)
    syscall(__NR_cacheflush, a, FN_SIZE * n_fns, ICACHE);
+#elif defined(__tilegx__)
+   cacheflush(a, FN_SIZE * n_fns, ICACHE);
 #endif
 
    for (h = 0; h < n_reps; h += 1) {