diff --git a/include/enum_quda.h b/include/enum_quda.h index 98d03f4411..9065cb335f 100644 --- a/include/enum_quda.h +++ b/include/enum_quda.h @@ -563,16 +563,16 @@ typedef enum QudaSpinTasteGamma_s { } QudaSpinTasteGamma; typedef enum QudaContractType_s { + QUDA_CONTRACT_TYPE_STAGGERED_FT_T, // Staggered, FT in tdim + QUDA_CONTRACT_TYPE_DR_FT_T, // DegrandRossi insertion, FT in tdim + QUDA_CONTRACT_TYPE_DR_FT_Z, // DegrandRossi insertion, FT in zdim + QUDA_CONTRACT_TYPE_STAGGERED, // Staggered, no summation (TODO: remove line) + QUDA_CONTRACT_TYPE_DR, // DegrandRossi insertion, no summation QUDA_CONTRACT_TYPE_OPEN, // Open spin elementals, no summation QUDA_CONTRACT_TYPE_OPEN_SUM_T, // Open spin elementals, spatially summed over tdim QUDA_CONTRACT_TYPE_OPEN_SUM_Z, // Open spin elementals, spatially summed over zdim QUDA_CONTRACT_TYPE_OPEN_FT_T, // Open spin elementals, FT in tdim QUDA_CONTRACT_TYPE_OPEN_FT_Z, // Open spin elementals, FT in zdim - QUDA_CONTRACT_TYPE_DR, // DegrandRossi insertion, no summation - QUDA_CONTRACT_TYPE_DR_FT_T, // DegrandRossi insertion, FT in tdim - QUDA_CONTRACT_TYPE_DR_FT_Z, // DegrandRossi insertion, FT in zdim - QUDA_CONTRACT_TYPE_STAGGERED, // Staggered, no summation (TODO: remove line) - QUDA_CONTRACT_TYPE_STAGGERED_FT_T, // Staggered, FT in tdim QUDA_CONTRACT_TYPE_INVALID = QUDA_INVALID_ENUM } QudaContractType; diff --git a/include/enum_quda_fortran.h b/include/enum_quda_fortran.h index 7147c49dd0..437de2c96e 100644 --- a/include/enum_quda_fortran.h +++ b/include/enum_quda_fortran.h @@ -497,16 +497,16 @@ #define QUDA_SPIN_TASTE_INVALID QUDA_INVALID_ENUM #define QudaContractType integer(4) +#define QUDA_CONTRACT_TYPE_STAGGERED_FT_T, +#define QUDA_CONTRACT_TYPE_DR_FT_T, +#define QUDA_CONTRACT_TYPE_DR_FT_Z, +#define QUDA_CONTRACT_TYPE_STAGGERED, +#define QUDA_CONTRACT_TYPE_DR, #define QUDA_CONTRACT_TYPE_OPEN , #define QUDA_CONTRACT_TYPE_OPEN_SUM_T, #define QUDA_CONTRACT_TYPE_OPEN_SUM_Z, #define QUDA_CONTRACT_TYPE_OPEN_FT_T, #define QUDA_CONTRACT_TYPE_OPEN_FT_Z, -#define QUDA_CONTRACT_TYPE_DR, -#define QUDA_CONTRACT_TYPE_DR_FT_T, -#define QUDA_CONTRACT_TYPE_DR_FT_Z, -#define QUDA_CONTRACT_TYPE_STAGGERED, -#define QUDA_CONTRACT_TYPE_STAGGERED_FT_T, #define QUDA_CONTRACT_TYPE_INVALID = QUDA_INVALID_ENUM #define QudaContractGamma integer(4) diff --git a/tests/contractFT_test_gtest.hpp b/tests/contractFT_test_gtest.hpp index ad6258d6e9..2422280902 100644 --- a/tests/contractFT_test_gtest.hpp +++ b/tests/contractFT_test_gtest.hpp @@ -39,14 +39,10 @@ TEST_P(ContractFTTest, verify) std::string gettestname(::testing::TestParamInfo param) { - auto contractType = ::testing::get<0>(param.param); - auto prec = ::testing::get<1>(param.param); + std::string str("contract_"); - const char *names[] = {"DegrandRossi_FT_t","DegrandRossi_FT_z", "Staggered_FT_t"}; - - std::string str(names[contractType]); - str += std::string("_"); - str += std::string(get_prec_str(getPrecision(prec))); + str += get_contract_str(::testing::get<0>(param.param)); + str += std::string("_") + get_prec_str(::testing::get<1>(param.param)); return str; } @@ -58,5 +54,5 @@ auto contract_types = Values(QUDA_CONTRACT_TYPE_STAGGERED_FT_T); //FIXME : exten auto precisions = Values(QUDA_DOUBLE_PRECISION, QUDA_SINGLE_PRECISION); -INSTANTIATE_TEST_SUITE_P(QUDA, ContractFTTest, Combine(contract_types, precisions), gettestname); +INSTANTIATE_TEST_SUITE_P(contraction_ft, ContractFTTest, Combine(contract_types, precisions), gettestname); diff --git a/tests/utils/command_line_params.h b/tests/utils/command_line_params.h index b9b7225b56..f288dad55f 100644 --- a/tests/utils/command_line_params.h +++ b/tests/utils/command_line_params.h @@ -541,8 +541,6 @@ extern double eofa_mq1; extern double eofa_mq2; extern double eofa_mq3; -extern QudaContractType contract_type; - // SU(3) smearing options extern double gauge_smear_rho; extern double gauge_smear_epsilon; diff --git a/tests/utils/misc.cpp b/tests/utils/misc.cpp index 6cbce21f4b..dd27dcb616 100644 --- a/tests/utils/misc.cpp +++ b/tests/utils/misc.cpp @@ -125,15 +125,15 @@ const char *get_contract_str(QudaContractType type) switch (type) { case QUDA_CONTRACT_TYPE_OPEN: ret = "open"; break; - case QUDA_CONTRACT_TYPE_OPEN_SUM_T: ret = "open-sum-t"; break; - case QUDA_CONTRACT_TYPE_OPEN_SUM_Z: ret = "open-sum-z"; break; - case QUDA_CONTRACT_TYPE_OPEN_FT_T: ret = "open-ft-t"; break; - case QUDA_CONTRACT_TYPE_OPEN_FT_Z: ret = "open-ft-z"; break; + case QUDA_CONTRACT_TYPE_OPEN_SUM_T: ret = "open_sum_t"; break; + case QUDA_CONTRACT_TYPE_OPEN_SUM_Z: ret = "open_sum_z"; break; + case QUDA_CONTRACT_TYPE_OPEN_FT_T: ret = "open_ft_t"; break; + case QUDA_CONTRACT_TYPE_OPEN_FT_Z: ret = "open_ft_z"; break; case QUDA_CONTRACT_TYPE_DR: ret = "dr"; break; - case QUDA_CONTRACT_TYPE_DR_FT_T: ret = "dr-ft-t"; break; - case QUDA_CONTRACT_TYPE_DR_FT_Z: ret = "dr-ft-z"; break; + case QUDA_CONTRACT_TYPE_DR_FT_T: ret = "dr_ft_t"; break; + case QUDA_CONTRACT_TYPE_DR_FT_Z: ret = "dr_ft_z"; break; case QUDA_CONTRACT_TYPE_STAGGERED: ret = "stag"; break; - case QUDA_CONTRACT_TYPE_STAGGERED_FT_T: ret = "stag-ft-t"; break; + case QUDA_CONTRACT_TYPE_STAGGERED_FT_T: ret = "stag_ft_t"; break; default: ret = "unknown"; break; }