performance - Linux Perf Counting Instructions, Cycles, Cache misses more lightweight over a long time -
i want profile programs under different restrictions research. use perf tool measure counters. profiling go long time (hours), , perf tool generates data don't need. instance:
$ perf record -e cycles,instructions,cache-misses,cpu-clock,context-switches,cpu-migrations ./stress-ng --cpu 4 --cpu-ops 10000 stress-ng: info: [6642] defaulting 86400 second run per stressor stress-ng: info: [6642] dispatching hogs: 4 cpu stress-ng: info: [6642] successful run completed in 15.57s [ perf record: woken 117 times write data ] [ perf record: captured , wrote 29.971 mb perf.data (~1309444 samples) ]
it approrixmately 1.92 mbs per second. in 24 hours, 165 gbs. when used perf report tool, saw kept function calls not need. how can make perf-record work more lightweight , record data need? need analyze following data on time see how change changes make system. considering records lot of data, , use in 24 core machines makes data large. best option far record periodically , analyze perf.data integers want , delete it, believe there should better option since can miss profiling data in window.
performance counter stats './stress-ng --cpu 4 --cpu-ops 10000': 128.290.294.651 cycles 201.217.788.817 instructions # 1,57 insns per cycle 3.048.096 cache-misses 40340,258757 cpu-clock (msec) 123 context-switches 25 cpu-migrations 10,205760993 seconds time elapsed
does simple perf stat
output you? example
$ perf stat -e cycles,instructions,cache-misses,cpu-clock,context-switches,cpu-migrations date sun jan 24 18:46:10 est 2016 performance counter stats 'date': 1,269,265 cycles 660,875 instructions # 0.52 insns per cycle 2,265 cache-misses 0.644391 cpu-clock (msec) 2 context-switches 1 cpu-migrations 0.001031207 seconds time elapsed
Comments
Post a Comment