

rbtrace: like strace, but for ruby code - tmm1
https://github.com/tmm1/rbtrace

======
jhund
Wow, this looks super useful. Thanks a lot!

------
rdtsc
Anything similar for Python?

I am aware of this: <http://docs.python.org/devguide/gdb.html> only.

~~~
tmm1
rbtrace is built on ruby's event hook api, which provides events when ruby and
C extension methods are called, and when they return.

python offers a very similar event hook api:
<http://www.doughellmann.com/PyMOTW/sys/tracing.html>

~~~
rdtsc
Thank you.

I used Python for 6 years and had no idea about sys.settrace()

------
rhizome
Why use --firehose instead of the more-standard -v/vv/vvv way?

~~~
jrockway
Because "firehose" is what Twitter calls it?

~~~
tmm1
If you tried it, you would understand. Ruby programs make a _LOT_ of method
calls.

Unfortunately the firehose doesn't work too well on OSX, because the unix
message queue API I'm using (msgget(2)) is capped in the kernel to 2048 bytes
and 40 messages per queue.

~~~
riffraff
it could be made to work through a FIFO though, I guess? if so I could take a
shot at it :)

~~~
tmm1
A FIFO might work. Do you know how big the buffers associated with FIFOs on
OSX are?

~~~
riffraff
sadly, I do not, I was sure I had a reference somewhere but I am completely
unable to find it again :(

