作者:摄影师张恒 | 来源:互联网 | 2022-12-20 09:01
我有一个测试用例来观察iTLB负载,iTLB负载未命中
perf stat -e dTLB-loads,dTLB-load-misses,iTLB-loads,iTLB-load-misses -p 22479
并得到输出:
进程ID"22479"的性能计数器统计信息:
1,262,817 dTLB-loads
13,950 dTLB-load-misses # 1.10% of all dTLB cache hits
75 iTLB-loads
6,882 iTLB-load-misses # 9176.00% of all iTLB cache hits
3.999720948 seconds time elapsed
我不知道如何解释iTLB负载仅75但iTLB负载未命中6,882?
lscpu showes:Intel(R)Xeon(R)CPU E5-2620 v4 @ 2.10GHz
编辑:
我可以解释如下:
做(75 + 6882)次iTLB负载,有75次点击但6882次未命中?
编辑:
ocperf.py list | wc -l
Downloading https://download.01.org/perfmon/mapfile.csv to mapfile.csv
Traceback (most recent call last):
File "/home/marschen/tools/pmu-tools-master/ocperf.py", line 1012, in
emap = find_emap()
File "/home/marschen/tools/pmu-tools-master/ocperf.py", line 831, in find_emap
event_download.download(el, toget)
File "/home/marschen/tools/pmu-tools-master/event_download.py", line 105, in download
getfile(modelpath, dir, "mapfile.csv")
File "/home/marschen/tools/pmu-tools-master/event_download.py", line 86, in getfile
f = urlopen(url)
File "/usr/lib64/python2.7/urllib2.py", line 154, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib64/python2.7/urllib2.py", line 431, in open
respOnse= self._open(req, data)
File "/usr/lib64/python2.7/urllib2.py", line 449, in _open
'_open', req)
File "/usr/lib64/python2.7/urllib2.py", line 409, in _call_chain
result = func(*args)
File "/usr/lib64/python2.7/urllib2.py", line 1258, in https_open
cOntext=self._context, check_hostname=self._check_hostname)
File "/usr/lib64/python2.7/urllib2.py", line 1211, in do_open
h.request(req.get_method(), req.get_selector(), req.data, headers)
File "/usr/lib64/python2.7/httplib.py", line 1017, in request
self._send_request(method, url, body, headers)
File "/usr/lib64/python2.7/httplib.py", line 1051, in _send_request
self.endheaders(body)
File "/usr/lib64/python2.7/httplib.py", line 1013, in endheaders
self._send_output(message_body)
File "/usr/lib64/python2.7/httplib.py", line 864, in _send_output
self.send(msg)
File "/usr/lib64/python2.7/httplib.py", line 826, in send
self.connect()
File "/usr/lib64/python2.7/httplib.py", line 1227, in connect
HTTPConnection.connect(self)
File "/usr/lib64/python2.7/httplib.py", line 807, in connect
self.timeout, self.source_address)
File "/usr/lib64/python2.7/socket.py", line 562, in create_connection
sock.connect(sa)
File "/usr/lib64/python2.7/socket.py", line 224, in meth
return getattr(self._sock,name)(*args)
Hadi Brais..
6
在您的Broadwell微架构处理器,香水,映射iTLB-loads
到ITLB_MISSES.STLB_HIT
,它代表了TLB查找的是错过了L1 ITLB但命中统一TLB所有页面大小,和事件iTLB-load-misses
来ITLB_MISSES.MISS_CAUSES_A_WALK
,这代表了TLB查找未命中两个L1 ITLB和事件所有页面大小的统一TLB(导致页面遍历).因此,iTLB-load-misses
可以大于或小于等于iTLB-loads
.他们是独立的事件.
1> Hadi Brais..:
在您的Broadwell微架构处理器,香水,映射iTLB-loads
到ITLB_MISSES.STLB_HIT
,它代表了TLB查找的是错过了L1 ITLB但命中统一TLB所有页面大小,和事件iTLB-load-misses
来ITLB_MISSES.MISS_CAUSES_A_WALK
,这代表了TLB查找未命中两个L1 ITLB和事件所有页面大小的统一TLB(导致页面遍历).因此,iTLB-load-misses
可以大于或小于等于iTLB-loads
.他们是独立的事件.
看起来像一个非常奇怪的设计选择.对于'perf`只是说'iTLB-loads`事件在那些CPU上不可用,而不是在iTLB未命中之后混淆地将它用于二级统一TLB中的命中,这会更有意义.
@HadiBrais很好`ITLB_MISSES.MISS_CAUSES_A_WALK / ITLB_MISSES.STLB_HIT`是一个毫无意义的数字,对吗?显然,“ iTLB-loads”已映射到错误的基础事件。我认为没有修复它的计划或票务afaik。我认为`perf`是狗屎秀,但我喜欢像您这样的人,他们会深入研究细节并记录这些奇怪的怪癖