xref: /original-bsd/sys/scripts/stats (revision 3705696b)
1#	@(#)stats	8.1 (Berkeley) 06/10/93
2#
3# disk statistics
4
5define dstat
6	set $op=(struct sdop *)&($arg0[$arg2])
7	set $i=$arg1
8	while ($i)
9		printf "$arg3 "
10		printf "%d %d 0x%x 0x%x %d", $op->bp, $op->bufsize, $op->blkno, $op->when.tv_sec, $op->when.tv_usec
11		if ($op->op & 1)
12			printf " READ\n"
13		else
14			printf " WRITE\n"
15		end
16		set $op = $op + 1
17		set $i = $i - 1
18	end
19end
20