diff --git a/src/cpucounters.cpp b/src/cpucounters.cpp index 097103ad..55953671 100644 --- a/src/cpucounters.cpp +++ b/src/cpucounters.cpp @@ -725,6 +725,8 @@ void PCM::initCStateSupportTables() case MTL: case LNL: case SNOWRIDGE: + case ELKHART_LAKE: + case JASPER_LAKE: PCM_CSTATE_ARRAY(pkgCStateMsr, PCM_PARAM_PROTECT({0, 0, 0x3F8, 0, 0x3F9, 0, 0x3FA, 0, 0, 0, 0 }) ); case NEHALEM_EP: case NEHALEM: @@ -801,6 +803,8 @@ void PCM::initCStateSupportTables() case MTL: case LNL: case SNOWRIDGE: + case ELKHART_LAKE: + case JASPER_LAKE: case ICX: case SPR: case EMR: @@ -1649,6 +1653,8 @@ bool PCM::detectNominalFrequency() || cpu_family_model == DENVERTON || useSKLPath() || cpu_family_model == SNOWRIDGE + || cpu_family_model == ELKHART_LAKE + || cpu_family_model == JASPER_LAKE || cpu_family_model == KNL || cpu_family_model == ADL || cpu_family_model == RPL @@ -3243,6 +3249,8 @@ bool PCM::isCPUModelSupported(const int model_) || model_ == WESTMERE_EX || isAtom(model_) || model_ == SNOWRIDGE + || model_ == ELKHART_LAKE + || model_ == JASPER_LAKE || model_ == CLARKDALE || model_ == SANDY_BRIDGE || model_ == JAKETOWN @@ -3549,6 +3557,8 @@ PCM::ErrorCode PCM::program(const PCM::ProgramMode mode_, const void * parameter core_gen_counter_num_used = 4; break; case SNOWRIDGE: + case ELKHART_LAKE: + case JASPER_LAKE: LLCArchEventInit(coreEventDesc); coreEventDesc[2].event_number = SKL_MEM_LOAD_RETIRED_L2_MISS_EVTNR; coreEventDesc[2].umask_value = SKL_MEM_LOAD_RETIRED_L2_MISS_UMASK; @@ -4824,6 +4834,10 @@ const char * PCM::getUArchCodename(const int32 cpu_family_model_param) const return "Denverton"; case SNOWRIDGE: return "Snowridge"; + case ELKHART_LAKE: + return "Elkhart Lake"; + case JASPER_LAKE: + return "Jasper Lake"; case NEHALEM_EP: case NEHALEM: return "Nehalem/Nehalem-EP"; diff --git a/src/cpucounters.h b/src/cpucounters.h index 46d9fb44..6bb7e6db 100644 --- a/src/cpucounters.h +++ b/src/cpucounters.h @@ -1856,6 +1856,8 @@ class PCM_API PCM GEMINI_LAKE = PCM_CPU_FAMILY_MODEL(6, 122), DENVERTON = PCM_CPU_FAMILY_MODEL(6, 95), SNOWRIDGE = PCM_CPU_FAMILY_MODEL(6, 134), + ELKHART_LAKE = PCM_CPU_FAMILY_MODEL(6, 150), + JASPER_LAKE = PCM_CPU_FAMILY_MODEL(6, 156), CLARKDALE = PCM_CPU_FAMILY_MODEL(6, 37), WESTMERE_EP = PCM_CPU_FAMILY_MODEL(6, 44), NEHALEM_EX = PCM_CPU_FAMILY_MODEL(6, 46), @@ -2122,6 +2124,8 @@ class PCM_API PCM case LNL: return 12; case SNOWRIDGE: + case ELKHART_LAKE: + case JASPER_LAKE: return 4; case DENVERTON: return 3; @@ -2451,6 +2455,8 @@ class PCM_API PCM || cpu_family_model == PCM::GEMINI_LAKE || cpu_family_model == PCM::DENVERTON || cpu_family_model == PCM::SNOWRIDGE + || cpu_family_model == PCM::ELKHART_LAKE + || cpu_family_model == PCM::JASPER_LAKE || cpu_family_model == PCM::HASWELLX || cpu_family_model == PCM::BROADWELL || cpu_family_model == PCM::BDX_DE @@ -4270,6 +4276,8 @@ uint64 getL2CacheMisses(const CounterStateType & before, const CounterStateType const auto cpu_family_model = pcm->getCPUFamilyModel(); if (pcm->useSkylakeEvents() || cpu_family_model == PCM::SNOWRIDGE + || cpu_family_model == PCM::ELKHART_LAKE + || cpu_family_model == PCM::JASPER_LAKE || cpu_family_model == PCM::SRF || cpu_family_model == PCM::ADL || cpu_family_model == PCM::RPL @@ -4382,6 +4390,8 @@ uint64 getL3CacheHitsSnoop(const CounterStateType & before, const CounterStateTy if (!pcm->isL3CacheHitsSnoopAvailable()) return 0; const auto cpu_family_model = pcm->getCPUFamilyModel(); if (cpu_family_model == PCM::SNOWRIDGE + || cpu_family_model == PCM::ELKHART_LAKE + || cpu_family_model == PCM::JASPER_LAKE || cpu_family_model == PCM::SRF || cpu_family_model == PCM::ADL || cpu_family_model == PCM::RPL