@@ -1142,17 +1142,25 @@ def pre_configure_hook_BLIS(self, *args, **kwargs):
11421142def pre_configure_hook_CUDA_Samples_test_remove (self , * args , ** kwargs ):
11431143 """skip immaTensorCoreGemm in CUDA-Samples for compute capability 7.0."""
11441144 if self .name == 'CUDA-Samples' :
1145- if self .version in ['12.1' ]:
1145+ if self .version in ['12.1' , '12.9' ]:
11461146 # Get compute capability from build option
11471147 cuda_caps = build_option ('cuda_compute_capabilities' )
11481148 # Check if compute capability 7.0 is in the list
11491149 if cuda_caps and '7.0' in cuda_caps :
11501150 print_msg ("Applying hook for CUDA-Samples %s with compute capability 7.0" , self .version )
11511151 # local_filters is set by the easyblock, remove path to the Makefile instead
11521152 makefile_path = os .path .join (self .start_dir , 'Samples/3_CUDA_Features/immaTensorCoreGemm/Makefile' )
1153+ # later versions use CMake rather than Makefiles
1154+ cmakefile_path = os .path .join (self .start_dir , 'Samples/3_CUDA_Features/CMakeLists.txt' )
11531155 if os .path .exists (makefile_path ):
11541156 remove_file (makefile_path )
11551157 print_msg ("Removed Makefile at %s to skip immaTensorCoreGemm build" , makefile_path )
1158+ elif os .path .exists (cmakefile_path ):
1159+ self .cfg .update (
1160+ 'preconfigopts' ,
1161+ # Comment out the line that contains immaTensorCoreGemm
1162+ "sed -i '17{/immaTensorCoreGemm/s/^/#/}' %s && " % cmakefile_path ,
1163+ )
11561164 else :
11571165 print_msg ("Makefile not found at %s" , makefile_path )
11581166 else :
0 commit comments