This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: minutes 2009-03-19


On Fri, 2009-03-20 at 12:38 -0400, Frank Ch. Eigler wrote:
> Mark Wielaard <mjw@redhat.com> writes:
> 
> > Frysk contained an fstep program based on ptrace. [...]  And it was
> > indeed horribly slow :) [...]
> 
> If you have or can easily make a copy, could you try benchmarking it
> against...?
> 
> # stap -e 'probe process("foo").insn {}' -w -t -c foo

It is really no contest, even with just counting the number of steps
of /bin/true (yes -t already does that, but I thought it more fair to
write a real "counter", it doesn't really matter much, around 0.01s):

$ LD_LIBRARY_PATH=~/src/frysk/obj/frysk-imports/elfutils/backends time
-p ../install/bin/fstep -s 120000 /bin/true
Total steps [2119]: 117681
[2119] Exited: 0
real 12.96
user 7.55
sys 5.45

$ time -p /usr/local/systemtap/bin/stap -e 'global steps; probe process("/bin/true").insn {steps++} probe end {printf("steps: %d\n", steps);}' -w -t -c /bin/true
steps: 137793
probe process("/bin/true").insn (<input>:1:15), hits: 137793, cycles: 286min/300avg/56518max
probe end (<input>:1:57), hits: 1, cycles: 6193min/6193avg/6193max
real 0.93
user 0.39
sys 0.52



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]