Skip to content

Commit

Permalink
Add EMR Intel events and refresh other events (#327)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #327

Add EMR to fetch list.

Run `buck2 run fbcode//hbt/src/perf_event/json_events:refresh`

Differential Revision: D65761976

fbshipit-source-id: 8e942b88640d42d5b5d83f5c148a0a8b1a0a4530
  • Loading branch information
bigzachattack authored and facebook-github-bot committed Nov 11, 2024
1 parent 9874dde commit 7570766
Show file tree
Hide file tree
Showing 34 changed files with 44,568 additions and 14,616 deletions.
5 changes: 5 additions & 0 deletions hbt/src/perf_event/json_events/generated/CpuArch.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ enum class CpuArch {
BDW_DE,
BDX,
CLX,
EMR,
GLM,
HSX,
ICL,
Expand Down Expand Up @@ -69,6 +70,8 @@ inline std::ostream& operator<<(std::ostream& os, CpuArch ev) {
return os << "BDX";
case CpuArch::CLX:
return os << "CLX";
case CpuArch::EMR:
return os << "EMR";
case CpuArch::GLM:
return os << "GLM";
case CpuArch::HSX:
Expand Down Expand Up @@ -210,6 +213,8 @@ inline CpuArch makeCpuArchX86(
return CpuArch::SKL;
case 175:
return CpuArch::SRF;
case 207:
return CpuArch::EMR;
default:
return CpuArch::UNKNOWN;
} // End of model switch case
Expand Down
44 changes: 36 additions & 8 deletions hbt/src/perf_event/json_events/generated/intel/JsonEvents.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,6 @@ namespace icelake_uncore {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace icelake_uncore

namespace icelake_uncore_experimental {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace icelake_uncore_experimental

namespace snowridgex_core {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace snowridgex_core
Expand All @@ -143,6 +139,18 @@ namespace sapphirerapids_uncore_experimental {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace sapphirerapids_uncore_experimental

namespace emeraldrapids_core {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace emeraldrapids_core

namespace emeraldrapids_uncore {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace emeraldrapids_uncore

namespace emeraldrapids_uncore_experimental {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace emeraldrapids_uncore_experimental

namespace icelakex_core {
void addEvents(PmuDeviceManager& pmu_manager);
} // namespace icelakex_core
Expand Down Expand Up @@ -558,8 +566,6 @@ addEvents(uint32_t cpu_model, uint32_t step, PmuDeviceManager& pmu_manager) {
icelake_core::addEvents(pmu_manager);
// from icelake_uncore.json
icelake_uncore::addEvents(pmu_manager);
// from icelake_uncore_experimental.json
icelake_uncore_experimental::addEvents(pmu_manager);
break;

case toCpuKey(126, 0x0): // fall-through
Expand All @@ -582,8 +588,6 @@ addEvents(uint32_t cpu_model, uint32_t step, PmuDeviceManager& pmu_manager) {
icelake_core::addEvents(pmu_manager);
// from icelake_uncore.json
icelake_uncore::addEvents(pmu_manager);
// from icelake_uncore_experimental.json
icelake_uncore_experimental::addEvents(pmu_manager);
break;

case toCpuKey(133, 0x0): // fall-through
Expand Down Expand Up @@ -768,6 +772,30 @@ addEvents(uint32_t cpu_model, uint32_t step, PmuDeviceManager& pmu_manager) {
sierraforest_uncore_experimental::addEvents(pmu_manager);
break;

case toCpuKey(207, 0x0): // fall-through
case toCpuKey(207, 0x1): // fall-through
case toCpuKey(207, 0x2): // fall-through
case toCpuKey(207, 0x3): // fall-through
case toCpuKey(207, 0x4): // fall-through
case toCpuKey(207, 0x5): // fall-through
case toCpuKey(207, 0x6): // fall-through
case toCpuKey(207, 0x7): // fall-through
case toCpuKey(207, 0x8): // fall-through
case toCpuKey(207, 0x9): // fall-through
case toCpuKey(207, 0x10): // fall-through
case toCpuKey(207, 0x11): // fall-through
case toCpuKey(207, 0x12): // fall-through
case toCpuKey(207, 0x13): // fall-through
case toCpuKey(207, 0x14): // fall-through
case toCpuKey(207, 0x15): // fall-through
// from emeraldrapids_core.json
emeraldrapids_core::addEvents(pmu_manager);
// from emeraldrapids_uncore.json
emeraldrapids_uncore::addEvents(pmu_manager);
// from emeraldrapids_uncore_experimental.json
emeraldrapids_uncore_experimental::addEvents(pmu_manager);
break;

default:
HBT_THROW_EINVAL() << "Unknown CPU model ID " + std::to_string(cpu_model);
}
Expand Down
66 changes: 18 additions & 48 deletions hbt/src/perf_event/json_events/generated/intel/broadwell_core.cpp

Large diffs are not rendered by default.

64 changes: 17 additions & 47 deletions hbt/src/perf_event/json_events/generated/intel/broadwellde_core.cpp

Large diffs are not rendered by default.

1,844 changes: 922 additions & 922 deletions hbt/src/perf_event/json_events/generated/intel/broadwellde_uncore.cpp

Large diffs are not rendered by default.

64 changes: 17 additions & 47 deletions hbt/src/perf_event/json_events/generated/intel/broadwellx_core.cpp

Large diffs are not rendered by default.

2,624 changes: 1,305 additions & 1,319 deletions hbt/src/perf_event/json_events/generated/intel/broadwellx_uncore.cpp

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ void addEvents(PmuDeviceManager& pmu_manager) {
));
#endif // HBT_ADD_ALL_GENERATED_EVENTS

#ifdef HBT_ADD_ALL_GENERATED_EVENTS
// Event DTLB_LOAD_MISSES.WALK_COMPLETED is allowlisted
pmu_manager.addEvent(std::make_shared<EventDef>(
PmuType::cpu,
"DTLB_LOAD_MISSES.WALK_COMPLETED",
Expand All @@ -200,7 +200,6 @@ void addEvents(PmuDeviceManager& pmu_manager) {
EventDef::IntelFeatures{},
std::nullopt // Errata
));
#endif // HBT_ADD_ALL_GENERATED_EVENTS

#ifdef HBT_ADD_ALL_GENERATED_EVENTS
pmu_manager.addEvent(std::make_shared<EventDef>(
Expand Down Expand Up @@ -1066,7 +1065,7 @@ void addEvents(PmuDeviceManager& pmu_manager) {
));
#endif // HBT_ADD_ALL_GENERATED_EVENTS

#ifdef HBT_ADD_ALL_GENERATED_EVENTS
// Event DTLB_STORE_MISSES.WALK_COMPLETED is allowlisted
pmu_manager.addEvent(std::make_shared<EventDef>(
PmuType::cpu,
"DTLB_STORE_MISSES.WALK_COMPLETED",
Expand All @@ -1079,7 +1078,6 @@ void addEvents(PmuDeviceManager& pmu_manager) {
EventDef::IntelFeatures{},
std::nullopt // Errata
));
#endif // HBT_ADD_ALL_GENERATED_EVENTS

#ifdef HBT_ADD_ALL_GENERATED_EVENTS
pmu_manager.addEvent(std::make_shared<EventDef>(
Expand Down
Loading

0 comments on commit 7570766

Please sign in to comment.