xref: /freebsd/lib/libpmc/pmu-events/arch/x86/amdzen4/pipeline.json (revision 278d6950943a9fec2bddb037b547c04a847c54ba)
1*278d6950SAlexander Motin[
2*278d6950SAlexander Motin  {
3*278d6950SAlexander Motin    "MetricName": "total_dispatch_slots",
4*278d6950SAlexander Motin    "BriefDescription": "Total dispatch slots (upto 6 instructions can be dispatched in each cycle).",
5*278d6950SAlexander Motin    "MetricExpr": "6 * ls_not_halted_cyc"
6*278d6950SAlexander Motin  },
7*278d6950SAlexander Motin  {
8*278d6950SAlexander Motin    "MetricName": "frontend_bound",
9*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because the frontend did not supply enough instructions/ops.",
10*278d6950SAlexander Motin    "MetricExpr": "d_ratio(de_no_dispatch_per_slot.no_ops_from_frontend, total_dispatch_slots)",
11*278d6950SAlexander Motin    "MetricGroup": "PipelineL1",
12*278d6950SAlexander Motin    "ScaleUnit": "100%"
13*278d6950SAlexander Motin  },
14*278d6950SAlexander Motin  {
15*278d6950SAlexander Motin    "MetricName": "bad_speculation",
16*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatched ops that did not retire.",
17*278d6950SAlexander Motin    "MetricExpr": "d_ratio(de_src_op_disp.all - ex_ret_ops, total_dispatch_slots)",
18*278d6950SAlexander Motin    "MetricGroup": "PipelineL1",
19*278d6950SAlexander Motin    "ScaleUnit": "100%"
20*278d6950SAlexander Motin  },
21*278d6950SAlexander Motin  {
22*278d6950SAlexander Motin    "MetricName": "backend_bound",
23*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because of backend stalls.",
24*278d6950SAlexander Motin    "MetricExpr": "d_ratio(de_no_dispatch_per_slot.backend_stalls, total_dispatch_slots)",
25*278d6950SAlexander Motin    "MetricGroup": "PipelineL1",
26*278d6950SAlexander Motin    "ScaleUnit": "100%"
27*278d6950SAlexander Motin  },
28*278d6950SAlexander Motin  {
29*278d6950SAlexander Motin    "MetricName": "smt_contention",
30*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because the other thread was selected.",
31*278d6950SAlexander Motin    "MetricExpr": "d_ratio(de_no_dispatch_per_slot.smt_contention, total_dispatch_slots)",
32*278d6950SAlexander Motin    "MetricGroup": "PipelineL1",
33*278d6950SAlexander Motin    "ScaleUnit": "100%"
34*278d6950SAlexander Motin  },
35*278d6950SAlexander Motin  {
36*278d6950SAlexander Motin    "MetricName": "retiring",
37*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots used by ops that retired.",
38*278d6950SAlexander Motin    "MetricExpr": "d_ratio(ex_ret_ops, total_dispatch_slots)",
39*278d6950SAlexander Motin    "MetricGroup": "PipelineL1",
40*278d6950SAlexander Motin    "ScaleUnit": "100%"
41*278d6950SAlexander Motin  },
42*278d6950SAlexander Motin  {
43*278d6950SAlexander Motin    "MetricName": "frontend_bound_latency",
44*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because of a latency bottleneck in the frontend (such as instruction cache or TLB misses).",
45*278d6950SAlexander Motin    "MetricExpr": "d_ratio((6 * cpu@de_no_dispatch_per_slot.no_ops_from_frontend\\,cmask\\=0x6@), total_dispatch_slots)",
46*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;frontend_bound_group",
47*278d6950SAlexander Motin    "ScaleUnit": "100%"
48*278d6950SAlexander Motin  },
49*278d6950SAlexander Motin  {
50*278d6950SAlexander Motin    "MetricName": "frontend_bound_bandwidth",
51*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because of a bandwidth bottleneck in the frontend (such as decode or op cache fetch bandwidth).",
52*278d6950SAlexander Motin    "MetricExpr": "d_ratio(de_no_dispatch_per_slot.no_ops_from_frontend - (6 * cpu@de_no_dispatch_per_slot.no_ops_from_frontend\\,cmask\\=0x6@), total_dispatch_slots)",
53*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;frontend_bound_group",
54*278d6950SAlexander Motin    "ScaleUnit": "100%"
55*278d6950SAlexander Motin  },
56*278d6950SAlexander Motin  {
57*278d6950SAlexander Motin    "MetricName": "bad_speculation_mispredicts",
58*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatched ops that were flushed due to branch mispredicts.",
59*278d6950SAlexander Motin    "MetricExpr": "d_ratio(bad_speculation * ex_ret_brn_misp, ex_ret_brn_misp + resyncs_or_nc_redirects)",
60*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;bad_speculation_group",
61*278d6950SAlexander Motin    "ScaleUnit": "100%"
62*278d6950SAlexander Motin  },
63*278d6950SAlexander Motin  {
64*278d6950SAlexander Motin    "MetricName": "bad_speculation_pipeline_restarts",
65*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatched ops that were flushed due to pipeline restarts (resyncs).",
66*278d6950SAlexander Motin    "MetricExpr": "d_ratio(bad_speculation * resyncs_or_nc_redirects, ex_ret_brn_misp + resyncs_or_nc_redirects)",
67*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;bad_speculation_group",
68*278d6950SAlexander Motin    "ScaleUnit": "100%"
69*278d6950SAlexander Motin  },
70*278d6950SAlexander Motin  {
71*278d6950SAlexander Motin    "MetricName": "backend_bound_memory",
72*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because of stalls due to the memory subsystem.",
73*278d6950SAlexander Motin    "MetricExpr": "backend_bound * d_ratio(ex_no_retire.load_not_complete, ex_no_retire.not_complete)",
74*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;backend_bound_group",
75*278d6950SAlexander Motin    "ScaleUnit": "100%"
76*278d6950SAlexander Motin  },
77*278d6950SAlexander Motin  {
78*278d6950SAlexander Motin    "MetricName": "backend_bound_cpu",
79*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots that remained unused because of stalls not related to the memory subsystem.",
80*278d6950SAlexander Motin    "MetricExpr": "backend_bound * (1 - d_ratio(ex_no_retire.load_not_complete, ex_no_retire.not_complete))",
81*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;backend_bound_group",
82*278d6950SAlexander Motin    "ScaleUnit": "100%"
83*278d6950SAlexander Motin  },
84*278d6950SAlexander Motin  {
85*278d6950SAlexander Motin    "MetricName": "retiring_fastpath",
86*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots used by fastpath ops that retired.",
87*278d6950SAlexander Motin    "MetricExpr": "retiring * (1 - d_ratio(ex_ret_ucode_ops, ex_ret_ops))",
88*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;retiring_group",
89*278d6950SAlexander Motin    "ScaleUnit": "100%"
90*278d6950SAlexander Motin  },
91*278d6950SAlexander Motin  {
92*278d6950SAlexander Motin    "MetricName": "retiring_microcode",
93*278d6950SAlexander Motin    "BriefDescription": "Fraction of dispatch slots used by microcode ops that retired.",
94*278d6950SAlexander Motin    "MetricExpr": "retiring * d_ratio(ex_ret_ucode_ops, ex_ret_ops)",
95*278d6950SAlexander Motin    "MetricGroup": "PipelineL2;retiring_group",
96*278d6950SAlexander Motin    "ScaleUnit": "100%"
97*278d6950SAlexander Motin  }
98*278d6950SAlexander Motin]
99