The author mentions that with perf you can get the functions but not the stacktrace of stuff in C running, in dtrace you can accomplish getting the stack traces (to some degree of success depending on how the binaries are compiled) with this:
This will store the stacktrace of whatever is running in underland 1001 times per second and store the count, then every second it will print the top 5 results then clear (so it will not be accumulative).
The author mentions that with perf you can get the functions but not the stacktrace of stuff in C running, in dtrace you can accomplish getting the stack traces (to some degree of success depending on how the binaries are compiled) with this:
This will store the stacktrace of whatever is running in underland 1001 times per second and store the count, then every second it will print the top 5 results then clear (so it will not be accumulative).