-
Notifications
You must be signed in to change notification settings - Fork 2
/
onesec.xd
68 lines (58 loc) · 963 Bytes
/
onesec.xd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#pragma D option quiet
#pragma D option switchrate=10hz
vdev_queue_pending_add:entry
/args[1]->io_spa->spa_name == "test"/
{
start[args[1]] = timestamp;
}
vdev_queue_pending_remove:entry
/start[args[1]]/
{
this->ms = (timestamp - start[args[1]]) / 1000 / 1000
start[args[1]] = 0;
if (this->ms > 500) {
printf("i/o took %ums type=%u\n", this->ms, args[1]->io_type);
}
@ = lquantize(this->ms, 0, 5000, 100);
}
#if 0
zio_ioctl:return
/entry->args[0]->io_spa->spa_name == "test"/
{
printf("flushing...\n");
fio=(zio_t*)arg1;
ftime=timestamp;
}
zio_done:entry
/args[0] == fio/
{
printf("done, took %ums\n", (timestamp-ftime)/1000000);
fio = 0;
}
#endif
spa_sync:entry
/args[0]->spa_name == "test"/
{
printf("beginning sync\n");
}
spa_sync:return
/entry->args[0]->spa_name == "test"/
{
printf("ending sync\n");
}
tick-10hz
{
printf("#");
/*printf("100ms elapsed\n");*/
}
#if 0
tick-1s
{
printa(@_);
trunc(@_);
}
#endif
END
{
printa(@_);
}