blob: cc8fd31c789ed76f01a4426679e03a6de0c3447d [file] [log] [blame]
Damjan Marion47d165e2019-01-28 13:27:31 +01001
2#include <perfmon/perfmon_intel.h>
3
4static perfmon_intel_pmc_cpu_model_t cpu_model_table[] = {
5 {0x2E, 0x00, 0},
6
7};
8
9static perfmon_intel_pmc_event_t event_table[] = {
10 {
11 .event_code = {0x14},
12 .umask = 0x1,
13 .event_name = "arith.cycles_div_busy",
14 },
15 {
16 .event_code = {0x14},
17 .umask = 0x1,
18 .event_name = "arith.div",
19 },
20 {
21 .event_code = {0x14},
22 .umask = 0x2,
23 .event_name = "arith.mul",
24 },
25 {
26 .event_code = {0xE6},
27 .umask = 0x2,
28 .event_name = "baclear.bad_target",
29 },
30 {
31 .event_code = {0xE6},
32 .umask = 0x1,
33 .event_name = "baclear.clear",
34 },
35 {
36 .event_code = {0xA7},
37 .umask = 0x1,
38 .event_name = "baclear_force_iq",
39 },
40 {
41 .event_code = {0xE8},
42 .umask = 0x1,
43 .event_name = "bpu_clears.early",
44 },
45 {
46 .event_code = {0xE8},
47 .umask = 0x2,
48 .event_name = "bpu_clears.late",
49 },
50 {
51 .event_code = {0xE5},
52 .umask = 0x1,
53 .event_name = "bpu_missed_call_ret",
54 },
55 {
56 .event_code = {0xE0},
57 .umask = 0x1,
58 .event_name = "br_inst_decoded",
59 },
60 {
61 .event_code = {0x88},
62 .umask = 0x7F,
63 .event_name = "br_inst_exec.any",
64 },
65 {
66 .event_code = {0x88},
67 .umask = 0x1,
68 .event_name = "br_inst_exec.cond",
69 },
70 {
71 .event_code = {0x88},
72 .umask = 0x2,
73 .event_name = "br_inst_exec.direct",
74 },
75 {
76 .event_code = {0x88},
77 .umask = 0x10,
78 .event_name = "br_inst_exec.direct_near_call",
79 },
80 {
81 .event_code = {0x88},
82 .umask = 0x20,
83 .event_name = "br_inst_exec.indirect_near_call",
84 },
85 {
86 .event_code = {0x88},
87 .umask = 0x4,
88 .event_name = "br_inst_exec.indirect_non_call",
89 },
90 {
91 .event_code = {0x88},
92 .umask = 0x30,
93 .event_name = "br_inst_exec.near_calls",
94 },
95 {
96 .event_code = {0x88},
97 .umask = 0x7,
98 .event_name = "br_inst_exec.non_calls",
99 },
100 {
101 .event_code = {0x88},
102 .umask = 0x8,
103 .event_name = "br_inst_exec.return_near",
104 },
105 {
106 .event_code = {0x88},
107 .umask = 0x40,
108 .event_name = "br_inst_exec.taken",
109 },
110 {
111 .event_code = {0xC4},
112 .umask = 0x4,
113 .event_name = "br_inst_retired.all_branches",
114 },
115 {
116 .event_code = {0xC4},
117 .umask = 0x1,
118 .event_name = "br_inst_retired.conditional",
119 },
120 {
121 .event_code = {0xC4},
122 .umask = 0x2,
123 .event_name = "br_inst_retired.near_call",
124 },
125 {
126 .event_code = {0x89},
127 .umask = 0x7F,
128 .event_name = "br_misp_exec.any",
129 },
130 {
131 .event_code = {0x89},
132 .umask = 0x1,
133 .event_name = "br_misp_exec.cond",
134 },
135 {
136 .event_code = {0x89},
137 .umask = 0x2,
138 .event_name = "br_misp_exec.direct",
139 },
140 {
141 .event_code = {0x89},
142 .umask = 0x10,
143 .event_name = "br_misp_exec.direct_near_call",
144 },
145 {
146 .event_code = {0x89},
147 .umask = 0x20,
148 .event_name = "br_misp_exec.indirect_near_call",
149 },
150 {
151 .event_code = {0x89},
152 .umask = 0x4,
153 .event_name = "br_misp_exec.indirect_non_call",
154 },
155 {
156 .event_code = {0x89},
157 .umask = 0x30,
158 .event_name = "br_misp_exec.near_calls",
159 },
160 {
161 .event_code = {0x89},
162 .umask = 0x7,
163 .event_name = "br_misp_exec.non_calls",
164 },
165 {
166 .event_code = {0x89},
167 .umask = 0x8,
168 .event_name = "br_misp_exec.return_near",
169 },
170 {
171 .event_code = {0x89},
172 .umask = 0x40,
173 .event_name = "br_misp_exec.taken",
174 },
175 {
176 .event_code = {0xC5},
177 .umask = 0x2,
178 .event_name = "br_misp_retired.near_call",
179 },
180 {
181 .event_code = {0x63},
182 .umask = 0x2,
183 .event_name = "cache_lock_cycles.l1d",
184 },
185 {
186 .event_code = {0x63},
187 .umask = 0x1,
188 .event_name = "cache_lock_cycles.l1d_l2",
189 },
190 {
191 .event_code = {0x0},
192 .umask = 0x0,
193 .event_name = "cpu_clk_unhalted.ref",
194 },
195 {
196 .event_code = {0x3C},
197 .umask = 0x1,
198 .event_name = "cpu_clk_unhalted.ref_p",
199 },
200 {
201 .event_code = {0x0},
202 .umask = 0x0,
203 .event_name = "cpu_clk_unhalted.thread",
204 },
205 {
206 .event_code = {0x3C},
207 .umask = 0x0,
208 .event_name = "cpu_clk_unhalted.thread_p",
209 },
210 {
211 .event_code = {0x3C},
212 .umask = 0x0,
213 .event_name = "cpu_clk_unhalted.total_cycles",
214 },
215 {
216 .event_code = {0x8},
217 .umask = 0x1,
218 .event_name = "dtlb_load_misses.any",
219 },
220 {
221 .event_code = {0x8},
222 .umask = 0x20,
223 .event_name = "dtlb_load_misses.pde_miss",
224 },
225 {
226 .event_code = {0x8},
227 .umask = 0x10,
228 .event_name = "dtlb_load_misses.stlb_hit",
229 },
230 {
231 .event_code = {0x8},
232 .umask = 0x2,
233 .event_name = "dtlb_load_misses.walk_completed",
234 },
235 {
236 .event_code = {0x49},
237 .umask = 0x1,
238 .event_name = "dtlb_misses.any",
239 },
240 {
241 .event_code = {0x49},
242 .umask = 0x10,
243 .event_name = "dtlb_misses.stlb_hit",
244 },
245 {
246 .event_code = {0x49},
247 .umask = 0x2,
248 .event_name = "dtlb_misses.walk_completed",
249 },
250 {
251 .event_code = {0xD5},
252 .umask = 0x1,
253 .event_name = "es_reg_renames",
254 },
255 {
256 .event_code = {0xF7},
257 .umask = 0x1,
258 .event_name = "fp_assist.all",
259 },
260 {
261 .event_code = {0xF7},
262 .umask = 0x4,
263 .event_name = "fp_assist.input",
264 },
265 {
266 .event_code = {0xF7},
267 .umask = 0x2,
268 .event_name = "fp_assist.output",
269 },
270 {
271 .event_code = {0x10},
272 .umask = 0x2,
273 .event_name = "fp_comp_ops_exe.mmx",
274 },
275 {
276 .event_code = {0x10},
277 .umask = 0x80,
278 .event_name = "fp_comp_ops_exe.sse_double_precision",
279 },
280 {
281 .event_code = {0x10},
282 .umask = 0x4,
283 .event_name = "fp_comp_ops_exe.sse_fp",
284 },
285 {
286 .event_code = {0x10},
287 .umask = 0x10,
288 .event_name = "fp_comp_ops_exe.sse_fp_packed",
289 },
290 {
291 .event_code = {0x10},
292 .umask = 0x20,
293 .event_name = "fp_comp_ops_exe.sse_fp_scalar",
294 },
295 {
296 .event_code = {0x10},
297 .umask = 0x40,
298 .event_name = "fp_comp_ops_exe.sse_single_precision",
299 },
300 {
301 .event_code = {0x10},
302 .umask = 0x8,
303 .event_name = "fp_comp_ops_exe.sse2_integer",
304 },
305 {
306 .event_code = {0x10},
307 .umask = 0x1,
308 .event_name = "fp_comp_ops_exe.x87",
309 },
310 {
311 .event_code = {0xCC},
312 .umask = 0x3,
313 .event_name = "fp_mmx_trans.any",
314 },
315 {
316 .event_code = {0xCC},
317 .umask = 0x1,
318 .event_name = "fp_mmx_trans.to_fp",
319 },
320 {
321 .event_code = {0xCC},
322 .umask = 0x2,
323 .event_name = "fp_mmx_trans.to_mmx",
324 },
325 {
326 .event_code = {0x87},
327 .umask = 0xF,
328 .event_name = "ild_stall.any",
329 },
330 {
331 .event_code = {0x87},
332 .umask = 0x4,
333 .event_name = "ild_stall.iq_full",
334 },
335 {
336 .event_code = {0x87},
337 .umask = 0x1,
338 .event_name = "ild_stall.lcp",
339 },
340 {
341 .event_code = {0x87},
342 .umask = 0x2,
343 .event_name = "ild_stall.mru",
344 },
345 {
346 .event_code = {0x87},
347 .umask = 0x8,
348 .event_name = "ild_stall.regen",
349 },
350 {
351 .event_code = {0x18},
352 .umask = 0x1,
353 .event_name = "inst_decoded.dec0",
354 },
355 {
356 .event_code = {0x1E},
357 .umask = 0x1,
358 .event_name = "inst_queue_write_cycles",
359 },
360 {
361 .event_code = {0x17},
362 .umask = 0x1,
363 .event_name = "inst_queue_writes",
364 },
365 {
366 .event_code = {0x0},
367 .umask = 0x0,
368 .event_name = "inst_retired.any",
369 },
370 {
371 .event_code = {0xC0},
372 .umask = 0x1,
373 .event_name = "inst_retired.any_p",
374 },
375 {
376 .event_code = {0xC0},
377 .umask = 0x4,
378 .event_name = "inst_retired.mmx",
379 },
380 {
381 .event_code = {0xC0},
382 .umask = 0x1,
383 .event_name = "inst_retired.total_cycles",
384 },
385 {
386 .event_code = {0xC0},
387 .umask = 0x2,
388 .event_name = "inst_retired.x87",
389 },
390 {
391 .event_code = {0x6C},
392 .umask = 0x1,
393 .event_name = "io_transactions",
394 },
395 {
396 .event_code = {0xAE},
397 .umask = 0x1,
398 .event_name = "itlb_flush",
399 },
400 {
401 .event_code = {0xC8},
402 .umask = 0x20,
403 .event_name = "itlb_miss_retired",
404 },
405 {
406 .event_code = {0x85},
407 .umask = 0x1,
408 .event_name = "itlb_misses.any",
409 },
410 {
411 .event_code = {0x85},
412 .umask = 0x2,
413 .event_name = "itlb_misses.walk_completed",
414 },
415 {
416 .event_code = {0x51},
417 .umask = 0x4,
418 .event_name = "l1d.m_evict",
419 },
420 {
421 .event_code = {0x51},
422 .umask = 0x2,
423 .event_name = "l1d.m_repl",
424 },
425 {
426 .event_code = {0x51},
427 .umask = 0x8,
428 .event_name = "l1d.m_snoop_evict",
429 },
430 {
431 .event_code = {0x51},
432 .umask = 0x1,
433 .event_name = "l1d.repl",
434 },
435 {
436 .event_code = {0x43},
437 .umask = 0x1,
438 .event_name = "l1d_all_ref.any",
439 },
440 {
441 .event_code = {0x43},
442 .umask = 0x2,
443 .event_name = "l1d_all_ref.cacheable",
444 },
445 {
446 .event_code = {0x40},
447 .umask = 0x4,
448 .event_name = "l1d_cache_ld.e_state",
449 },
450 {
451 .event_code = {0x40},
452 .umask = 0x1,
453 .event_name = "l1d_cache_ld.i_state",
454 },
455 {
456 .event_code = {0x40},
457 .umask = 0x8,
458 .event_name = "l1d_cache_ld.m_state",
459 },
460 {
461 .event_code = {0x40},
462 .umask = 0xF,
463 .event_name = "l1d_cache_ld.mesi",
464 },
465 {
466 .event_code = {0x40},
467 .umask = 0x2,
468 .event_name = "l1d_cache_ld.s_state",
469 },
470 {
471 .event_code = {0x42},
472 .umask = 0x4,
473 .event_name = "l1d_cache_lock.e_state",
474 },
475 {
476 .event_code = {0x42},
477 .umask = 0x1,
478 .event_name = "l1d_cache_lock.hit",
479 },
480 {
481 .event_code = {0x42},
482 .umask = 0x8,
483 .event_name = "l1d_cache_lock.m_state",
484 },
485 {
486 .event_code = {0x42},
487 .umask = 0x2,
488 .event_name = "l1d_cache_lock.s_state",
489 },
490 {
491 .event_code = {0x53},
492 .umask = 0x1,
493 .event_name = "l1d_cache_lock_fb_hit",
494 },
495 {
496 .event_code = {0x52},
497 .umask = 0x1,
498 .event_name = "l1d_cache_prefetch_lock_fb_hit",
499 },
500 {
501 .event_code = {0x41},
502 .umask = 0x4,
503 .event_name = "l1d_cache_st.e_state",
504 },
505 {
506 .event_code = {0x41},
507 .umask = 0x8,
508 .event_name = "l1d_cache_st.m_state",
509 },
510 {
511 .event_code = {0x41},
512 .umask = 0x2,
513 .event_name = "l1d_cache_st.s_state",
514 },
515 {
516 .event_code = {0x4E},
517 .umask = 0x2,
518 .event_name = "l1d_prefetch.miss",
519 },
520 {
521 .event_code = {0x4E},
522 .umask = 0x1,
523 .event_name = "l1d_prefetch.requests",
524 },
525 {
526 .event_code = {0x4E},
527 .umask = 0x4,
528 .event_name = "l1d_prefetch.triggers",
529 },
530 {
531 .event_code = {0x28},
532 .umask = 0x4,
533 .event_name = "l1d_wb_l2.e_state",
534 },
535 {
536 .event_code = {0x28},
537 .umask = 0x1,
538 .event_name = "l1d_wb_l2.i_state",
539 },
540 {
541 .event_code = {0x28},
542 .umask = 0x8,
543 .event_name = "l1d_wb_l2.m_state",
544 },
545 {
546 .event_code = {0x28},
547 .umask = 0xF,
548 .event_name = "l1d_wb_l2.mesi",
549 },
550 {
551 .event_code = {0x28},
552 .umask = 0x2,
553 .event_name = "l1d_wb_l2.s_state",
554 },
555 {
556 .event_code = {0x80},
557 .umask = 0x4,
558 .event_name = "l1i.cycles_stalled",
559 },
560 {
561 .event_code = {0x80},
562 .umask = 0x1,
563 .event_name = "l1i.hits",
564 },
565 {
566 .event_code = {0x80},
567 .umask = 0x2,
568 .event_name = "l1i.misses",
569 },
570 {
571 .event_code = {0x80},
572 .umask = 0x3,
573 .event_name = "l1i.reads",
574 },
575 {
576 .event_code = {0x26},
577 .umask = 0xFF,
578 .event_name = "l2_data_rqsts.any",
579 },
580 {
581 .event_code = {0x26},
582 .umask = 0x4,
583 .event_name = "l2_data_rqsts.demand.e_state",
584 },
585 {
586 .event_code = {0x26},
587 .umask = 0x1,
588 .event_name = "l2_data_rqsts.demand.i_state",
589 },
590 {
591 .event_code = {0x26},
592 .umask = 0x8,
593 .event_name = "l2_data_rqsts.demand.m_state",
594 },
595 {
596 .event_code = {0x26},
597 .umask = 0xF,
598 .event_name = "l2_data_rqsts.demand.mesi",
599 },
600 {
601 .event_code = {0x26},
602 .umask = 0x2,
603 .event_name = "l2_data_rqsts.demand.s_state",
604 },
605 {
606 .event_code = {0x26},
607 .umask = 0x40,
608 .event_name = "l2_data_rqsts.prefetch.e_state",
609 },
610 {
611 .event_code = {0x26},
612 .umask = 0x10,
613 .event_name = "l2_data_rqsts.prefetch.i_state",
614 },
615 {
616 .event_code = {0x26},
617 .umask = 0x80,
618 .event_name = "l2_data_rqsts.prefetch.m_state",
619 },
620 {
621 .event_code = {0x26},
622 .umask = 0xF0,
623 .event_name = "l2_data_rqsts.prefetch.mesi",
624 },
625 {
626 .event_code = {0x26},
627 .umask = 0x20,
628 .event_name = "l2_data_rqsts.prefetch.s_state",
629 },
630 {
631 .event_code = {0xF1},
632 .umask = 0x7,
633 .event_name = "l2_lines_in.any",
634 },
635 {
636 .event_code = {0xF1},
637 .umask = 0x4,
638 .event_name = "l2_lines_in.e_state",
639 },
640 {
641 .event_code = {0xF1},
642 .umask = 0x2,
643 .event_name = "l2_lines_in.s_state",
644 },
645 {
646 .event_code = {0xF2},
647 .umask = 0xF,
648 .event_name = "l2_lines_out.any",
649 },
650 {
651 .event_code = {0xF2},
652 .umask = 0x1,
653 .event_name = "l2_lines_out.demand_clean",
654 },
655 {
656 .event_code = {0xF2},
657 .umask = 0x2,
658 .event_name = "l2_lines_out.demand_dirty",
659 },
660 {
661 .event_code = {0xF2},
662 .umask = 0x4,
663 .event_name = "l2_lines_out.prefetch_clean",
664 },
665 {
666 .event_code = {0xF2},
667 .umask = 0x8,
668 .event_name = "l2_lines_out.prefetch_dirty",
669 },
670 {
671 .event_code = {0x24},
672 .umask = 0x10,
673 .event_name = "l2_rqsts.ifetch_hit",
674 },
675 {
676 .event_code = {0x24},
677 .umask = 0x20,
678 .event_name = "l2_rqsts.ifetch_miss",
679 },
680 {
681 .event_code = {0x24},
682 .umask = 0x30,
683 .event_name = "l2_rqsts.ifetches",
684 },
685 {
686 .event_code = {0x24},
687 .umask = 0x1,
688 .event_name = "l2_rqsts.ld_hit",
689 },
690 {
691 .event_code = {0x24},
692 .umask = 0x2,
693 .event_name = "l2_rqsts.ld_miss",
694 },
695 {
696 .event_code = {0x24},
697 .umask = 0x3,
698 .event_name = "l2_rqsts.loads",
699 },
700 {
701 .event_code = {0x24},
702 .umask = 0xAA,
703 .event_name = "l2_rqsts.miss",
704 },
705 {
706 .event_code = {0x24},
707 .umask = 0x40,
708 .event_name = "l2_rqsts.prefetch_hit",
709 },
710 {
711 .event_code = {0x24},
712 .umask = 0x80,
713 .event_name = "l2_rqsts.prefetch_miss",
714 },
715 {
716 .event_code = {0x24},
717 .umask = 0xC0,
718 .event_name = "l2_rqsts.prefetches",
719 },
720 {
721 .event_code = {0x24},
722 .umask = 0xFF,
723 .event_name = "l2_rqsts.references",
724 },
725 {
726 .event_code = {0x24},
727 .umask = 0x4,
728 .event_name = "l2_rqsts.rfo_hit",
729 },
730 {
731 .event_code = {0x24},
732 .umask = 0x8,
733 .event_name = "l2_rqsts.rfo_miss",
734 },
735 {
736 .event_code = {0x24},
737 .umask = 0xC,
738 .event_name = "l2_rqsts.rfos",
739 },
740 {
741 .event_code = {0xF0},
742 .umask = 0x80,
743 .event_name = "l2_transactions.any",
744 },
745 {
746 .event_code = {0xF0},
747 .umask = 0x20,
748 .event_name = "l2_transactions.fill",
749 },
750 {
751 .event_code = {0xF0},
752 .umask = 0x4,
753 .event_name = "l2_transactions.ifetch",
754 },
755 {
756 .event_code = {0xF0},
757 .umask = 0x10,
758 .event_name = "l2_transactions.l1d_wb",
759 },
760 {
761 .event_code = {0xF0},
762 .umask = 0x1,
763 .event_name = "l2_transactions.load",
764 },
765 {
766 .event_code = {0xF0},
767 .umask = 0x8,
768 .event_name = "l2_transactions.prefetch",
769 },
770 {
771 .event_code = {0xF0},
772 .umask = 0x2,
773 .event_name = "l2_transactions.rfo",
774 },
775 {
776 .event_code = {0xF0},
777 .umask = 0x40,
778 .event_name = "l2_transactions.wb",
779 },
780 {
781 .event_code = {0x27},
782 .umask = 0x40,
783 .event_name = "l2_write.lock.e_state",
784 },
785 {
786 .event_code = {0x27},
787 .umask = 0xE0,
788 .event_name = "l2_write.lock.hit",
789 },
790 {
791 .event_code = {0x27},
792 .umask = 0x10,
793 .event_name = "l2_write.lock.i_state",
794 },
795 {
796 .event_code = {0x27},
797 .umask = 0x80,
798 .event_name = "l2_write.lock.m_state",
799 },
800 {
801 .event_code = {0x27},
802 .umask = 0xF0,
803 .event_name = "l2_write.lock.mesi",
804 },
805 {
806 .event_code = {0x27},
807 .umask = 0x20,
808 .event_name = "l2_write.lock.s_state",
809 },
810 {
811 .event_code = {0x27},
812 .umask = 0xE,
813 .event_name = "l2_write.rfo.hit",
814 },
815 {
816 .event_code = {0x27},
817 .umask = 0x1,
818 .event_name = "l2_write.rfo.i_state",
819 },
820 {
821 .event_code = {0x27},
822 .umask = 0x8,
823 .event_name = "l2_write.rfo.m_state",
824 },
825 {
826 .event_code = {0x27},
827 .umask = 0xF,
828 .event_name = "l2_write.rfo.mesi",
829 },
830 {
831 .event_code = {0x27},
832 .umask = 0x2,
833 .event_name = "l2_write.rfo.s_state",
834 },
835 {
836 .event_code = {0x82},
837 .umask = 0x1,
838 .event_name = "large_itlb.hit",
839 },
840 {
841 .event_code = {0x13},
842 .umask = 0x7,
843 .event_name = "load_dispatch.any",
844 },
845 {
846 .event_code = {0x13},
847 .umask = 0x4,
848 .event_name = "load_dispatch.mob",
849 },
850 {
851 .event_code = {0x13},
852 .umask = 0x1,
853 .event_name = "load_dispatch.rs",
854 },
855 {
856 .event_code = {0x13},
857 .umask = 0x2,
858 .event_name = "load_dispatch.rs_delayed",
859 },
860 {
861 .event_code = {0x4C},
862 .umask = 0x1,
863 .event_name = "load_hit_pre",
864 },
865 {
866 .event_code = {0x2E},
867 .umask = 0x41,
868 .event_name = "longest_lat_cache.miss",
869 },
870 {
871 .event_code = {0x2E},
872 .umask = 0x4F,
873 .event_name = "longest_lat_cache.reference",
874 },
875 {
876 .event_code = {0xA8},
877 .umask = 0x1,
878 .event_name = "lsd.active",
879 },
880 {
881 .event_code = {0xA8},
882 .umask = 0x1,
883 .event_name = "lsd.inactive",
884 },
885 {
886 .event_code = {0x20},
887 .umask = 0x1,
888 .event_name = "lsd_overflow",
889 },
890 {
891 .event_code = {0xC3},
892 .umask = 0x1,
893 .event_name = "machine_clears.cycles",
894 },
895 {
896 .event_code = {0xC3},
897 .umask = 0x2,
898 .event_name = "machine_clears.mem_order",
899 },
900 {
901 .event_code = {0xC3},
902 .umask = 0x4,
903 .event_name = "machine_clears.smc",
904 },
905 {
906 .event_code = {0xD0},
907 .umask = 0x1,
908 .event_name = "macro_insts.decoded",
909 },
910 {
911 .event_code = {0xA6},
912 .umask = 0x1,
913 .event_name = "macro_insts.fusions_decoded",
914 },
915 {
916 .event_code = {0xB},
917 .umask = 0x1,
918 .event_name = "mem_inst_retired.loads",
919 },
920 {
921 .event_code = {0xB},
922 .umask = 0x2,
923 .event_name = "mem_inst_retired.stores",
924 },
925 {
926 .event_code = {0xCB},
927 .umask = 0x80,
928 .event_name = "mem_load_retired.dtlb_miss",
929 },
930 {
931 .event_code = {0xCB},
932 .umask = 0x40,
933 .event_name = "mem_load_retired.hit_lfb",
934 },
935 {
936 .event_code = {0xCB},
937 .umask = 0x1,
938 .event_name = "mem_load_retired.l1d_hit",
939 },
940 {
941 .event_code = {0xCB},
942 .umask = 0x2,
943 .event_name = "mem_load_retired.l2_hit",
944 },
945 {
946 .event_code = {0xCB},
947 .umask = 0x10,
948 .event_name = "mem_load_retired.llc_miss",
949 },
950 {
951 .event_code = {0xCB},
952 .umask = 0x4,
953 .event_name = "mem_load_retired.llc_unshared_hit",
954 },
955 {
956 .event_code = {0xCB},
957 .umask = 0x8,
958 .event_name = "mem_load_retired.other_core_l2_hit_hitm",
959 },
960 {
961 .event_code = {0xC},
962 .umask = 0x1,
963 .event_name = "mem_store_retired.dtlb_miss",
964 },
965 {
966 .event_code = {0xB0},
967 .umask = 0x40,
968 .event_name = "offcore_requests.l1d_writeback",
969 },
970 {
971 .event_code = {0xB2},
972 .umask = 0x1,
973 .event_name = "offcore_requests_sq_full",
974 },
975 {
976 .event_code = {0x7},
977 .umask = 0x1,
978 .event_name = "partial_address_alias",
979 },
980 {
981 .event_code = {0xD2},
982 .umask = 0xF,
983 .event_name = "rat_stalls.any",
984 },
985 {
986 .event_code = {0xD2},
987 .umask = 0x1,
988 .event_name = "rat_stalls.flags",
989 },
990 {
991 .event_code = {0xD2},
992 .umask = 0x2,
993 .event_name = "rat_stalls.registers",
994 },
995 {
996 .event_code = {0xD2},
997 .umask = 0x4,
998 .event_name = "rat_stalls.rob_read_port",
999 },
1000 {
1001 .event_code = {0xD2},
1002 .umask = 0x8,
1003 .event_name = "rat_stalls.scoreboard",
1004 },
1005 {
1006 .event_code = {0xA2},
1007 .umask = 0x1,
1008 .event_name = "resource_stalls.any",
1009 },
1010 {
1011 .event_code = {0xA2},
1012 .umask = 0x20,
1013 .event_name = "resource_stalls.fpcw",
1014 },
1015 {
1016 .event_code = {0xA2},
1017 .umask = 0x2,
1018 .event_name = "resource_stalls.load",
1019 },
1020 {
1021 .event_code = {0xA2},
1022 .umask = 0x40,
1023 .event_name = "resource_stalls.mxcsr",
1024 },
1025 {
1026 .event_code = {0xA2},
1027 .umask = 0x80,
1028 .event_name = "resource_stalls.other",
1029 },
1030 {
1031 .event_code = {0xA2},
1032 .umask = 0x10,
1033 .event_name = "resource_stalls.rob_full",
1034 },
1035 {
1036 .event_code = {0xA2},
1037 .umask = 0x4,
1038 .event_name = "resource_stalls.rs_full",
1039 },
1040 {
1041 .event_code = {0xA2},
1042 .umask = 0x8,
1043 .event_name = "resource_stalls.store",
1044 },
1045 {
1046 .event_code = {0x4},
1047 .umask = 0x7,
1048 .event_name = "sb_drain.any",
1049 },
1050 {
1051 .event_code = {0xD4},
1052 .umask = 0x1,
1053 .event_name = "seg_rename_stalls",
1054 },
1055 {
1056 .event_code = {0x12},
1057 .umask = 0x4,
1058 .event_name = "simd_int_128.pack",
1059 },
1060 {
1061 .event_code = {0x12},
1062 .umask = 0x20,
1063 .event_name = "simd_int_128.packed_arith",
1064 },
1065 {
1066 .event_code = {0x12},
1067 .umask = 0x10,
1068 .event_name = "simd_int_128.packed_logical",
1069 },
1070 {
1071 .event_code = {0x12},
1072 .umask = 0x1,
1073 .event_name = "simd_int_128.packed_mpy",
1074 },
1075 {
1076 .event_code = {0x12},
1077 .umask = 0x2,
1078 .event_name = "simd_int_128.packed_shift",
1079 },
1080 {
1081 .event_code = {0x12},
1082 .umask = 0x40,
1083 .event_name = "simd_int_128.shuffle_move",
1084 },
1085 {
1086 .event_code = {0x12},
1087 .umask = 0x8,
1088 .event_name = "simd_int_128.unpack",
1089 },
1090 {
1091 .event_code = {0xFD},
1092 .umask = 0x4,
1093 .event_name = "simd_int_64.pack",
1094 },
1095 {
1096 .event_code = {0xFD},
1097 .umask = 0x20,
1098 .event_name = "simd_int_64.packed_arith",
1099 },
1100 {
1101 .event_code = {0xFD},
1102 .umask = 0x10,
1103 .event_name = "simd_int_64.packed_logical",
1104 },
1105 {
1106 .event_code = {0xFD},
1107 .umask = 0x1,
1108 .event_name = "simd_int_64.packed_mpy",
1109 },
1110 {
1111 .event_code = {0xFD},
1112 .umask = 0x2,
1113 .event_name = "simd_int_64.packed_shift",
1114 },
1115 {
1116 .event_code = {0xFD},
1117 .umask = 0x40,
1118 .event_name = "simd_int_64.shuffle_move",
1119 },
1120 {
1121 .event_code = {0xFD},
1122 .umask = 0x8,
1123 .event_name = "simd_int_64.unpack",
1124 },
1125 {
1126 .event_code = {0xB8},
1127 .umask = 0x1,
1128 .event_name = "snoop_response.hit",
1129 },
1130 {
1131 .event_code = {0xB8},
1132 .umask = 0x2,
1133 .event_name = "snoop_response.hite",
1134 },
1135 {
1136 .event_code = {0xB8},
1137 .umask = 0x4,
1138 .event_name = "snoop_response.hitm",
1139 },
1140 {
1141 .event_code = {0xF6},
1142 .umask = 0x1,
1143 .event_name = "sq_full_stall_cycles",
1144 },
1145 {
1146 .event_code = {0xF4},
1147 .umask = 0x10,
1148 .event_name = "sq_misc.split_lock",
1149 },
1150 {
1151 .event_code = {0xC7},
1152 .umask = 0x4,
1153 .event_name = "ssex_uops_retired.packed_double",
1154 },
1155 {
1156 .event_code = {0xC7},
1157 .umask = 0x1,
1158 .event_name = "ssex_uops_retired.packed_single",
1159 },
1160 {
1161 .event_code = {0xC7},
1162 .umask = 0x8,
1163 .event_name = "ssex_uops_retired.scalar_double",
1164 },
1165 {
1166 .event_code = {0xC7},
1167 .umask = 0x2,
1168 .event_name = "ssex_uops_retired.scalar_single",
1169 },
1170 {
1171 .event_code = {0xC7},
1172 .umask = 0x10,
1173 .event_name = "ssex_uops_retired.vector_integer",
1174 },
1175 {
1176 .event_code = {0x6},
1177 .umask = 0x4,
1178 .event_name = "store_blocks.at_ret",
1179 },
1180 {
1181 .event_code = {0x6},
1182 .umask = 0x8,
1183 .event_name = "store_blocks.l1d_block",
1184 },
1185 {
1186 .event_code = {0x19},
1187 .umask = 0x1,
1188 .event_name = "two_uop_insts_decoded",
1189 },
1190 {
1191 .event_code = {0xDB},
1192 .umask = 0x1,
1193 .event_name = "uop_unfusion",
1194 },
1195 {
1196 .event_code = {0xD1},
1197 .umask = 0x4,
1198 .event_name = "uops_decoded.esp_folding",
1199 },
1200 {
1201 .event_code = {0xD1},
1202 .umask = 0x8,
1203 .event_name = "uops_decoded.esp_sync",
1204 },
1205 {
1206 .event_code = {0xD1},
1207 .umask = 0x2,
1208 .event_name = "uops_decoded.ms_cycles_active",
1209 },
1210 {
1211 .event_code = {0xD1},
1212 .umask = 0x1,
1213 .event_name = "uops_decoded.stall_cycles",
1214 },
1215 {
1216 .event_code = {0xB1},
1217 .umask = 0x3F,
1218 .event_name = "uops_executed.core_active_cycles",
1219 },
1220 {
1221 .event_code = {0xB1},
1222 .umask = 0x1F,
1223 .event_name = "uops_executed.core_active_cycles_no_port5",
1224 },
1225 {
1226 .event_code = {0xB1},
1227 .umask = 0x3F,
1228 .event_name = "uops_executed.core_stall_count",
1229 },
1230 {
1231 .event_code = {0xB1},
1232 .umask = 0x1F,
1233 .event_name = "uops_executed.core_stall_count_no_port5",
1234 },
1235 {
1236 .event_code = {0xB1},
1237 .umask = 0x3F,
1238 .event_name = "uops_executed.core_stall_cycles",
1239 },
1240 {
1241 .event_code = {0xB1},
1242 .umask = 0x1F,
1243 .event_name = "uops_executed.core_stall_cycles_no_port5",
1244 },
1245 {
1246 .event_code = {0xB1},
1247 .umask = 0x1,
1248 .event_name = "uops_executed.port0",
1249 },
1250 {
1251 .event_code = {0xB1},
1252 .umask = 0x40,
1253 .event_name = "uops_executed.port015",
1254 },
1255 {
1256 .event_code = {0xB1},
1257 .umask = 0x40,
1258 .event_name = "uops_executed.port015_stall_cycles",
1259 },
1260 {
1261 .event_code = {0xB1},
1262 .umask = 0x2,
1263 .event_name = "uops_executed.port1",
1264 },
1265 {
1266 .event_code = {0xB1},
1267 .umask = 0x4,
1268 .event_name = "uops_executed.port2_core",
1269 },
1270 {
1271 .event_code = {0xB1},
1272 .umask = 0x80,
1273 .event_name = "uops_executed.port234_core",
1274 },
1275 {
1276 .event_code = {0xB1},
1277 .umask = 0x8,
1278 .event_name = "uops_executed.port3_core",
1279 },
1280 {
1281 .event_code = {0xB1},
1282 .umask = 0x10,
1283 .event_name = "uops_executed.port4_core",
1284 },
1285 {
1286 .event_code = {0xB1},
1287 .umask = 0x20,
1288 .event_name = "uops_executed.port5",
1289 },
1290 {
1291 .event_code = {0xE},
1292 .umask = 0x1,
1293 .event_name = "uops_issued.any",
1294 },
1295 {
1296 .event_code = {0xE},
1297 .umask = 0x1,
1298 .event_name = "uops_issued.core_stall_cycles",
1299 },
1300 {
1301 .event_code = {0xE},
1302 .umask = 0x1,
1303 .event_name = "uops_issued.cycles_all_threads",
1304 },
1305 {
1306 .event_code = {0xE},
1307 .umask = 0x2,
1308 .event_name = "uops_issued.fused",
1309 },
1310 {
1311 .event_code = {0xE},
1312 .umask = 0x1,
1313 .event_name = "uops_issued.stall_cycles",
1314 },
1315 {
1316 .event_code = {0xC2},
1317 .umask = 0x1,
1318 .event_name = "uops_retired.active_cycles",
1319 },
1320 {
1321 .event_code = {0xC2},
1322 .umask = 0x1,
1323 .event_name = "uops_retired.any",
1324 },
1325 {
1326 .event_code = {0xC2},
1327 .umask = 0x4,
1328 .event_name = "uops_retired.macro_fused",
1329 },
1330 {
1331 .event_code = {0xC2},
1332 .umask = 0x2,
1333 .event_name = "uops_retired.retire_slots",
1334 },
1335 {
1336 .event_code = {0xC2},
1337 .umask = 0x1,
1338 .event_name = "uops_retired.stall_cycles",
1339 },
1340 {
1341 .event_code = {0xC2},
1342 .umask = 0x1,
1343 .event_name = "uops_retired.total_cycles",
1344 },
1345 {
1346 .event_code = {0xC0},
1347 .umask = 0x1,
1348 .event_name = "inst_retired.total_cycles_ps",
1349 },
1350 {
1351 .event_name = 0,
1352 },
1353};
1354
1355PERFMON_REGISTER_INTEL_PMC (cpu_model_table, event_table);
1356