Sfoglia il codice sorgente

src/core/workers.c: display message only if environment variable STARPU_SILENT is unset

Nathalie Furmento 13 anni fa
parent
commit
f00330a558
1 ha cambiato i file con 8 aggiunte e 8 eliminazioni
  1. 8 8
      src/core/workers.c

+ 8 - 8
src/core/workers.c

@@ -320,31 +320,31 @@ int starpu_init(struct starpu_conf *user_conf)
 
 #ifdef __GNUC__
 #ifndef __OPTIMIZE__
-	fprintf(stderr,"Warning: StarPU was configured with --enable-debug (-O0)\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --enable-debug (-O0)\n");
 #endif
 #endif
 #if 0
 #ifndef STARPU_NO_ASSERT
-	fprintf(stderr,"Warning: StarPU was configured without --enable-fast\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured without --enable-fast\n");
 #endif
 #endif
 #ifdef STARPU_MEMORY_STATUS
-	fprintf(stderr,"Warning: StarPU was configured with --enable-memory-status\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --enable-memory-status\n");
 #endif
 #ifdef STARPU_VERBOSE
-	fprintf(stderr,"Warning: StarPU was configured with --enable-verbose\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --enable-verbose\n");
 #endif
 #ifdef STARPU_USE_FXT
-	fprintf(stderr,"Warning: StarPU was configured with --with-fxt\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --with-fxt\n");
 #endif
 #ifdef STARPU_PERF_DEBUG
-	fprintf(stderr,"Warning: StarPU was configured with --enable-perf-debug\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --enable-perf-debug\n");
 #endif
 #ifdef STARPU_MODEL_DEBUG
-	fprintf(stderr,"Warning: StarPU was configured with --enable-model-debug\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --enable-model-debug\n");
 #endif
 #ifdef STARPU_DATA_STATS
-	fprintf(stderr,"Warning: StarPU was configured with --enable-stats\n");
+	if (!getenv("STARPU_SILENT")) fprintf(stderr,"Warning: StarPU was configured with --enable-stats\n");
 #endif
 
 	PTHREAD_MUTEX_LOCK(&init_mutex);