Ver código fonte

Make it possible to select the maximum number of buffers per task at configure
time with the --enable-maxbuffers=<nbuffers> option.

Cédric Augonnet 15 anos atrás
pai
commit
9e1bd3857d
3 arquivos alterados com 11 adições e 2 exclusões
  1. 9 0
      configure.ac
  2. 0 2
      include/starpu-data.h
  3. 2 0
      include/starpu_config.h.in

+ 9 - 0
configure.ac

@@ -357,6 +357,15 @@ fi
 #                                                                             #
 #                                                                             #
 ###############################################################################
 ###############################################################################
 
 
+AC_MSG_CHECKING(how many buffers can be manipulated per task)
+AC_ARG_ENABLE(maxbuffers, [AS_HELP_STRING([--enable-maxbuffers=<nbuffers>],
+			[maximum number of buffers per task])],
+			nmaxbuffers=$enableval, nmaxbuffers=8)
+AC_MSG_RESULT($nmaxbuffers)
+AC_DEFINE_UNQUOTED(STARPU_NMAXBUFS, [$nmaxbuffers], 
+		[how many buffers can be manipulated per task])
+
+
 AC_MSG_CHECKING(whether priorities should be enabled)
 AC_MSG_CHECKING(whether priorities should be enabled)
 AC_ARG_ENABLE(priority, [AS_HELP_STRING([--disable-priority],
 AC_ARG_ENABLE(priority, [AS_HELP_STRING([--disable-priority],
 			[do not use priorities])],
 			[do not use priorities])],

+ 0 - 2
include/starpu-data.h

@@ -21,8 +21,6 @@
 #include <starpu-data-interfaces.h>
 #include <starpu-data-interfaces.h>
 #include <starpu-data-filters.h>
 #include <starpu-data-filters.h>
 
 
-#define STARPU_NMAXBUFS        8
-
 #ifdef __cplusplus
 #ifdef __cplusplus
 extern "C" {
 extern "C" {
 #endif
 #endif

+ 2 - 0
include/starpu_config.h.in

@@ -30,4 +30,6 @@
 #undef HAVE_FFTWF
 #undef HAVE_FFTWF
 #undef HAVE_FFTWL
 #undef HAVE_FFTWL
 
 
+#undef STARPU_NMAXBUFS
+
 #endif
 #endif