Skip to content

Commit

Permalink
ocperf: Fix PREC_DIST on SKL
Browse files Browse the repository at this point in the history
  • Loading branch information
Andi Kleen committed Jun 21, 2024
1 parent 9ecd27c commit 4aca2d5
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions ocperf.py
Original file line number Diff line number Diff line change
Expand Up @@ -671,10 +671,14 @@ def getdec(x):
e.msr = msrnum
if u'SampleAfterValue' in row:
e.overflow = get(u'SampleAfterValue')
e.counter = get(u'Counter')
e.precise = getdec(u'Precise') if u'Precise' in row else 0
e.collectpebs = getdec(u'CollectPEBS') if u'CollectPEBS' in row else 0
if e.collectpebs > 1:
e.pebs = getdec(u'PEBS') if u'PEBS' in row else 0
if e.collectpebs > 1 or e.pebs >= 2:
e.extra += "pp"
if len(e.counter.split(",")) == 1:
e.extra += "p"
try:
if get(u'Errata') != "null":
try:
Expand All @@ -686,7 +690,6 @@ def getdec(x):
except KeyError:
pass
e.desc = d
e.counter = get(u'Counter')
for (flag, name) in extra_flags:
if val & flag:
e.newextra += ",%s=%d" % (name, (val & flag) >> ffs(flag), )
Expand Down

0 comments on commit 4aca2d5

Please sign in to comment.