StringIO#each_byte now checks the current position against the length of the containe...
[rbx.git] / tools / dtrace / custom.d
blobb8150f29f818aa6705ad7f1eb3f692721d5b0066
1 /*
2 * custom rubinius probe.
4 * This script prints the parameters passed to an arbitrary custom probe
5 * within rubinius. arg0 and arg1 are the parameters passed to Dtrace.fire().
6 * custom probes are useful to enable/disable other probes within scripts
7 * or just to pass arbitrary data through to dtrace.
9 * Example invocation:
11 * $> sudo dtrace -s entry-counts.d -c 'rbx custom.rb'
13 * Example script:
15 * $> cat custom.rb
16 * Dtrace.fire 'hello', 'world'
19 #pragma D option quiet
21 rubinius$target:::ruby-probe
23 printf("%s:%s\n", copyinstr(arg0), copyinstr(arg1));