lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <4B389391.8050303@klingt.org>
Date:	Mon, 28 Dec 2009 12:16:33 +0100
From:	Tim Blechmann <tim@...ngt.org>
To:	linux-kernel@...r.kernel.org
Subject: perf: counter and event question

hi all,

trying to use the perf subsystem, i am a bit confused by the terms
`performance counter' and `performance event'.

i am trying to compare `counting' counters with `sampling' counters. as
a test case, i am counting PERF_COUNT_HW_INSTRUCTIONS of the same code
piece with both approaches. the sampling counters are sampled with a
period of 1. the code is really trivial [1].

the `counting' counters report numbers of about 9000 instructions, but
the mmap buffer only seems to contain about 100 to 200 event samples.
from my (limited) understanding, these number should at least be
similar, so i am a bit confused to see such a big difference. am i
missing something, like it is impossible to sample instructions with a
period of 1? or could there be an issue with my code?

thanks, tim

[1] http://tim.klingt.org/git?p=perf-cpp.git

-- 
tim@...ngt.org
http://tim.klingt.org

I don't write music for sissy ears.
  Charles Ives


Download attachment "signature.asc" of type "application/pgp-signature" (198 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ