secret
Created

Time between message send and process activation.

  • Download Gist
timing.txt
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
#
# We do have negative numbers here since we're running on multiple threads
# and it's possible, but rare that a message was sent to a process while we
# are scheduling that process for execution, causing small overlaps (up to
# 512ns or so in one case).
#
# With this, we don't know the amount of time it took to *receive* the
# message, but we know that it couldn't've been faster than the time it took
# to get the recipient on the CPU. I'll add a receive probe to get more info.
#
 
% dtrace -qn 'erlang*:::send { sent[copyinstr(arg1)] = timestamp } erlang*:::process_scheduled / sent[copyinstr(arg0)] / { @t = quantize(timestamp - sent[copyinstr(arg0)]); sent[copyinstr(arg0)] = 0;}'
 
 
value ------------- Distribution ------------- count
-1024 | 0
-512 | 1
-256 | 0
-128 | 0
-64 | 1
-32 | 1
-16 | 0
-8 | 0
-4 | 0
-2 | 0
-1 | 0
0 | 0
1 | 0
2 | 0
4 | 0
8 | 0
16 | 0
32 | 0
64 | 0
128 | 2
256 | 6
512 | 8
1024 | 26
2048 | 66
4096 |@@@@@ 17049
8192 |@@@@@@@@@@@@@@@@@@ 58315
16384 |@@@@@@@@@@ 31047
32768 |@@@ 10737
65536 |@ 3424
131072 |@ 1620
262144 | 1469
524288 |@ 1614
1048576 |@ 2016
2097152 | 151
4194304 | 53
8388608 | 47
16777216 | 34
33554432 | 44
67108864 | 26
134217728 | 28
268435456 | 0

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.