Sfoglia il codice sorgente

port r17876 from 1.2: fix warning

Samuel Thibault 9 anni fa
parent
commit
1328f05aa9
1 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. 3 3
      src/core/perfmodel/perfmodel_bus.c

+ 3 - 3
src/core/perfmodel/perfmodel_bus.c

@@ -45,7 +45,7 @@
 #include <windows.h>
 #endif
 
-#if HAVE_DECL_HWLOC_CUDA_GET_DEVICE_OSDEV_BY_INDEX
+#ifdef HAVE_DECL_HWLOC_CUDA_GET_DEVICE_OSDEV_BY_INDEX
 #include <hwloc/cuda.h>
 #endif
 
@@ -1694,7 +1694,7 @@ void _starpu_simgrid_get_platform_path(char *path, size_t maxlen)
  * - then through all CUDA-CUDA possible transfers again to emit routes.
  */
 
-#if defined(STARPU_USE_CUDA) && HAVE_DECL_HWLOC_CUDA_GET_DEVICE_OSDEV_BY_INDEX && defined(HAVE_CUDA_MEMCPY_PEER)
+#if defined(STARPU_USE_CUDA) && defined(HAVE_DECL_HWLOC_CUDA_GET_DEVICE_OSDEV_BY_INDEX) && defined(HAVE_CUDA_MEMCPY_PEER)
 
 /* Records, for each PCI link and hub, the maximum bandwidth seen through it */
 struct pci_userdata
@@ -2247,7 +2247,7 @@ static void write_bus_platform_file_content(void)
 	}
 #endif
 
-#if HAVE_DECL_HWLOC_CUDA_GET_DEVICE_OSDEV_BY_INDEX && defined(HAVE_CUDA_MEMCPY_PEER)
+#if defined(HAVE_DECL_HWLOC_CUDA_GET_DEVICE_OSDEV_BY_INDEX) && defined(HAVE_CUDA_MEMCPY_PEER)
 	/* If we have enough hwloc information, write PCI bandwidths and routes */
 	if (!starpu_get_env_number_default("STARPU_PCI_FLAT", 0))
 	{