Forráskód Böngészése

More prefixing ...

find . -type f -not -name "*svn*"|xargs sed -i s/"\bCONFIG_FUT\b"/STARPU_CONFIG_FUT/g
find . -type f -not -name "*svn*"|xargs sed -i s/"\bDATA_STATS\b"/STARPU_DATA_STATS/g
find . -type f -not -name "*svn*"|xargs sed -i s/"\bHAVE_CLOCK_GETTIME\b"/STARPU_HAVE_CLOCK_GETTIME/g
find . -type f -not -name "*svn*"|xargs sed -i s/"\bHAVE_DLFCN_H\b"/STARPU_HAVE_DLFCN_H/g
find . -type f -not -name "*svn*"|xargs sed -i s/"\bHAVE_DRAND48\b"/STARPU_HAVE_DRAND48/g
Nathalie Furmento 15 éve
szülő
commit
bcbf72dd24

+ 3 - 3
configure.ac

@@ -361,7 +361,7 @@ AM_CONDITIONAL(USE_FXT, test x$use_fxt = xyes)
 
 if test x$use_fxt = xyes; then
 	AC_DEFINE(USE_FXT, [1], [enable FxT traces])
-	AC_DEFINE(CONFIG_FUT, [1], [enable FUT traces])
+	AC_DEFINE(STARPU_CONFIG_FUT, [1], [enable FUT traces])
 
 	AC_SUBST(USE_FXTDIR_FROM_USER,$use_fxt_from_system)
 	if test x$use_fxt_from_system = xno; then
@@ -404,10 +404,10 @@ AC_ARG_ENABLE(stats, [AS_HELP_STRING([--enable-stats],
 			enable_stats=$enableval, enable_stats=no)
 AC_MSG_RESULT($enable_stats)
 AC_SUBST(STATS, $enable_stats)
-AC_SUBST(DATA_STATS, $enable_stats)
+AC_SUBST(STARPU_DATA_STATS, $enable_stats)
 
 if test x$enable_stats = xyes; then
-        AC_DEFINE(DATA_STATS, [1], [enable statistics])
+        AC_DEFINE(STARPU_DATA_STATS, [1], [enable statistics])
 fi
 
 

+ 3 - 3
src/common/timing.c

@@ -16,7 +16,7 @@
 
 #include "timing.h"
 
-#ifdef HAVE_CLOCK_GETTIME
+#ifdef STARPU_HAVE_CLOCK_GETTIME
 
 #define TICK_DIFF(t1, t2) ((long long)((t2).ts.tv_sec*1e9 + (t2).ts.tv_nsec) + \
 				- (long long)((t1).ts.tv_sec*1e9) + (long long)(t1).ts.tv_nsec)
@@ -52,7 +52,7 @@ inline double timing_now(void)
 
 
 
-#else // HAVE_CLOCK_GETTIME
+#else // STARPU_HAVE_CLOCK_GETTIME
 
 #define TICK_RAW_DIFF(t1, t2) ((t2).tick - (t1).tick)
 #define TICK_DIFF(t1, t2) (TICK_RAW_DIFF(t1, t2) - residual)
@@ -113,4 +113,4 @@ inline double timing_now(void)
 	return _starpu_tick2usec(tick_now.tick);
 }
 
-#endif // HAVE_CLOCK_GETTIME
+#endif // STARPU_HAVE_CLOCK_GETTIME

+ 3 - 3
src/common/timing.h

@@ -32,7 +32,7 @@
 #include <common/config.h>
 #include <starpu.h>
 
-#ifdef HAVE_CLOCK_GETTIME
+#ifdef STARPU_HAVE_CLOCK_GETTIME
 #include <time.h>
 #ifndef _POSIX_C_SOURCE
 /* for clock_gettime */
@@ -46,7 +46,7 @@ typedef struct tick_s
 } tick_t;
 #define GET_TICK(t) clock_gettime(CLOCK_MONOTONIC, &((t).ts))
 
-#else // !HAVE_CLOCK_GETTIME
+#else // !STARPU_HAVE_CLOCK_GETTIME
 
 typedef union u_tick
 {
@@ -69,7 +69,7 @@ typedef union u_tick
 #  define GET_TICK(t) do {} while(0);
 #endif
 
-#endif // HAVE_CLOCK_GETTIME
+#endif // STARPU_HAVE_CLOCK_GETTIME
 
 void __attribute__ ((unused)) timing_init(void);
 inline double __attribute__ ((unused)) _starpu_tick2usec(long long t);

+ 1 - 1
src/core/workers.c

@@ -435,7 +435,7 @@ void starpu_shutdown(void)
 	/* tell all workers to shutdown */
 	_starpu_kill_all_workers(&config);
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	display_comm_ammounts();
 #endif
 

+ 1 - 1
src/core/workers.h

@@ -54,7 +54,7 @@
 #define STARPU_CUDA_ALPHA	13.33f
 #define STARPU_GORDON_ALPHA	6.0f /* XXX this is a random value ... */
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 #define BENCHMARK_COMM	1
 #else
 #define BENCHMARK_COMM	0

+ 1 - 1
src/datawizard/copy-driver.c

@@ -217,7 +217,7 @@ int __attribute__((warn_unused_result)) driver_copy_data_1_to_1(starpu_data_hand
 		STARPU_ASSERT(handle->ops);
 		//STARPU_ASSERT(handle->ops->copy_data_1_to_1);
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 		size_t size = handle->ops->get_size(handle);
 		update_comm_ammount(src_node, dst_node, size);
 #endif

+ 9 - 9
src/datawizard/datastats.c

@@ -21,28 +21,28 @@
 
 /* measure the cache hit ratio for each node */
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 static unsigned hit_cnt[STARPU_MAXNODES];
 static unsigned miss_cnt[STARPU_MAXNODES];
 #endif
 
 inline void msi_cache_hit(unsigned node __attribute__ ((unused)))
 {
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	hit_cnt[node]++;
 #endif
 }
 
 inline void msi_cache_miss(unsigned node __attribute__ ((unused)))
 {
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	miss_cnt[node]++;
 #endif
 }
 
 void display_msi_stats(void)
 {
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	unsigned node;
 	unsigned total_hit_cnt = 0;
 	unsigned total_miss_cnt = 0;
@@ -71,28 +71,28 @@ void display_msi_stats(void)
 
 /* measure the efficiency of our allocation cache */
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 static unsigned alloc_cnt[STARPU_MAXNODES];
 static unsigned alloc_cache_hit_cnt[STARPU_MAXNODES];
 #endif
 
 inline void allocation_cache_hit(unsigned node __attribute__ ((unused)))
 {
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	alloc_cache_hit_cnt[node]++;
 #endif
 }
 
 inline void data_allocation_inc_stats(unsigned node __attribute__ ((unused)))
 {
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	alloc_cnt[node]++;
 #endif
 }
 
 void display_alloc_cache_stats(void)
 {
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	fprintf(stderr, "Allocation cache stats:\n");
 	unsigned node;
 	for (node = 0; node < STARPU_MAXNODES; node++) 
@@ -109,7 +109,7 @@ void display_alloc_cache_stats(void)
 }
 
 /* measure the amount of data transfers between each pair of nodes */
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 
 static size_t comm_ammount[STARPU_MAXNODES][STARPU_MAXNODES];
 

+ 1 - 1
src/datawizard/datastats.h

@@ -33,7 +33,7 @@ inline void data_allocation_inc_stats(unsigned node __attribute__ ((unused)));
 void display_comm_ammounts(void);
 void display_alloc_cache_stats(void);
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 inline void update_comm_ammount(uint32_t src_node, uint32_t dst_node, size_t size);
 #endif
 

+ 1 - 1
src/drivers/cpu/driver_cpu.c

@@ -193,7 +193,7 @@ void *_starpu_cpu_worker(void *arg)
 
 	TRACE_WORKER_DEINIT_START
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	fprintf(stderr, "CPU #%d computation %le comm %le (%lf \%%)\n", cpu_arg->id, cpu_arg->jobq->total_computation_time, cpu_arg->jobq->total_communication_time,  cpu_arg->jobq->total_communication_time*100.0/cpu_arg->jobq->total_computation_time);
 #endif
 

+ 1 - 1
src/drivers/cuda/driver_cuda.c

@@ -280,7 +280,7 @@ void *_starpu_cuda_worker(void *arg)
 
 	deinit_context(args->workerid);
 
-#ifdef DATA_STATS
+#ifdef STARPU_DATA_STATS
 	fprintf(stderr, "CUDA #%d computation %le comm %le (%lf \%%)\n", args->id, args->jobq->total_computation_time, args->jobq->total_communication_time, args->jobq->total_communication_time*100.0/args->jobq->total_computation_time);
 #endif