Created
September 23, 2021 07:49
-
-
Save KJTsanaktsidis/a0af8eeb1f2e878d5ca2d7d497eeeb42 to your computer and use it in GitHub Desktop.
bpftrace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
usdt:/usr/local/lib/librdkafka.so.1:librdkafka:rd_malloc { | |
@allocated_addrs[arg0] = ustack(); | |
@allocation_time[arg0] = nsecs; | |
} | |
usdt:/usr/local/lib/librdkafka.so.1:librdkafka:rd_free { | |
delete(@allocated_addrs[arg0]); | |
delete(@allocation_time[arg0]); | |
} | |
// plus similar entries for functions like rd_calloc, rd_strdup, etc. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment