11
2- from machines_specs import assert_machine_supported , \
3- get_mach_cxx_compiler , get_mach_c_compiler , get_mach_f90_compiler , \
4- get_mach_batch_command , get_mach_env_setup_command , \
5- get_mach_baseline_root_dir , is_cuda_machine , \
6- get_mach_compilation_resources , get_mach_testing_resources
2+ from machines_specs import assert_machine_supported , get_machine , get_mach_env_setup_command
73from utils import expect
84
95CHOICES = (
@@ -24,23 +20,24 @@ def query_scream(machine, param):
2420 assert_machine_supported (machine )
2521 expect (param in CHOICES , f"Unknown param { param } " )
2622
23+ mach = get_machine (machine )
2724 if param == "cxx_compiler" :
28- return get_mach_cxx_compiler ( machine )
25+ return mach . cxx_compiler
2926 elif param == "c_compiler" :
30- return get_mach_c_compiler ( machine )
27+ return mach . c_compiler
3128 elif param == "f90_compiler" :
32- return get_mach_f90_compiler ( machine )
29+ return mach . ftn_compiler
3330 elif param == "batch" :
34- return get_mach_batch_command ( machine )
31+ return mach . batch
3532 elif param == "env" :
3633 return get_mach_env_setup_command (machine )
3734 elif param == "baseline_root" :
38- return get_mach_baseline_root_dir ( machine )
35+ return mach . baselines_dir
3936 elif param == "cuda" :
40- return str (is_cuda_machine ( machine ) )
37+ return str (mach . gpu_arch == "cuda" )
4138 elif param == "comp_j" :
42- return get_mach_compilation_resources ()
39+ return num_bld_res
4340 elif param == "test_j" :
44- return get_mach_testing_resources ( machine )
41+ return gnum_run_res
4542 else :
4643 expect (False , f"Unhandled param { param } " )
0 commit comments