Ubuntu Linux를 실행하는 AMD 시스템에서 PAPI를 통해 마지막 수준 캐시 누락 측정

Ubuntu Linux를 실행하는 AMD 시스템에서 PAPI를 통해 마지막 수준 캐시 누락 측정

기본적으로 PAPI(성능 응용 프로그래밍 인터페이스)는 Ubuntu Linux를 실행하는 AMD 시스템에서 마지막 수준 캐시 누락(L3) 측정을 지원하지 않는 것으로 보입니다. 그러나 L1/L2 캐시 미스를 측정할 수 있습니다. 아래에서 프로세서 세부 정보를 확인할 수 있습니다. 적절한 드라이버를 설치하면 마지막 수준의 캐시 미스를 측정할 수 있다고 들었습니다. 누군가 나에게 이에 대한 추가 정보를 제공할 수 있습니까?

$ uname -a
Linux 2.6.32-21-server #32-Ubuntu SMP Fri Apr 16 09:17:34 UTC 2010 x86_64 GNU/Linux

$cat /proc/cpuinfo
processor   : 0
vendor_id   : AuthenticAMD
cpu family  : 16
model       : 8
model name  : Six-Core AMD Opteron(tm) Processor 8431
fpu     : yes
fpu_exception   : yes
cpuid level : 5
wp      : yes
flags       : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt
bogomips    : 4788.66
TLB size    : 1024 4K pages
clflush size    : 64
cache_alignment : 64
address sizes   : 48 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate

ベストアンサー1

Valgrind의 캐시된 그라인드 분석기나 perf 또는 perf Expert를 사용해 보세요.

이들 모두는 대부분의 경우 L3와 마찬가지로 LastLevel 캐시 세부 정보를 제공합니다.

이 모듈을 모두 로드해야 합니다.

주문 실행:

월그라인드:

valgrind --tool=cachegrind ./exe

완벽한 전문가:

perfexpert_run_exp ./exe

성능:

perf stat -e <hardware counter> ... -e <hardwarecounter> ./exe

おすすめ記事