Skip to content

Commit

Permalink
Add stalls per dispatch slot metrics in GENOA (#331)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #331

``dyno.stalls_no_execute_mhz`` no longer applicable in AMD Genoa, because stalls are caulculated on a basis of the number of dispatch slots not cycles.

Add new ODS keys to represent these metrics.

Reviewed By: bigzachattack

Differential Revision: D67264483

fbshipit-source-id: b269d19d38a4261680fbf446b0f4a1e5d927be95
  • Loading branch information
williamsumendap authored and facebook-github-bot committed Dec 19, 2024
1 parent 4b89752 commit 215028b
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions hbt/src/perf_event/AmdEvents.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,21 @@ constexpr PmuMsr kStalledCyclesIdqEmpty{
.amdCore = {.event = 0x87, .unitMask = 0x2}};
constexpr PmuMsr kStalledCyclesAny{.amdCore = {.event = 0x87, .unitMask = 0x4}};

// Zen4 Stalls per dispatch slots
constexpr PmuMsr kFrontendBoundStalls{
.amdCore = {.event = 0xa0, .unitMask = 0x1, .event_11_8 = 0x1}};
constexpr PmuMsr kBackendBoundStalls{
.amdCore = {.event = 0xa0, .unitMask = 0x1e, .event_11_8 = 0x1}};
constexpr PmuMsr kSMTContentionStalls{
.amdCore = {.event = 0xa0, .unitMask = 0x60, .event_11_8 = 0x1}};
// Bad speculation stalls events
constexpr PmuMsr kMacroOpsDispatched{
.amdCore = {.event = 0xaa, .unitMask = 0x7}};
// constexpr PmuMsr kRetiredUOps{.amdCore = {.event = 0xc1}};
constexpr PmuMsr kDispatchSlots{
.amdCore = {
.event = 0x76}}; // this is unhalted cycles, which is already defined

// Retired uops
constexpr PmuMsr kRetiredUOps{.amdCore = {.event = 0xc1}};
constexpr PmuMsr kDeUopsDispatchedOpCache{
Expand Down

0 comments on commit 215028b

Please sign in to comment.