simple (dumb) script to track sizes of IOs
Badari Pulavarty
pbadari@us.ibm.com
Thu Oct 6 17:37:00 GMT 2005
Frank Ch. Eigler wrote:
> pbadari wrote:
>
>
>>Here is a simple systemtap script to track the sizes of IOs
>>that are getting generated (to the driver).
>
>
> That's block i/o only right?
Yes.
>
>
>>[...]
>>Is there a way, I can print in the order of IO sizes easily ?
>
>
> There will be a way of iterating in a sorted order, probably
> expressed syntactically like this:
>
> # function report () {
> # foreach (ascending(io) in iosizes) {
> # if (iosizes[io]) # ...
> # }
>
Does this functionality exists today ?
>
>>[...]# stap -g iosizes.stp [...]
>
>
> Your script does not need guru mode. Merely reading $rq->nr_sectors
> is fine without that. You also don't need to check "if (iosizes[io])"
> since zero-valued array elements do not appear in foreach()
> iterations.
Thanks. Is there some documentation on the allowed syntax and
library functions ?
Thanks,
Badari
More information about the Systemtap
mailing list