brendangregg / BPF-tools

Performance Tools using Linux eBPF
121 stars 32 forks source link

; missing in mallocstacks.py #6

Open rob-scheepens opened 4 years ago

rob-scheepens commented 4 years ago
; was missing from BPF_STACK_TRACE(stack_traces, STACK_STORAGE_SIZE).
diff --git a/old/2017-12-23/mallocstacks.py b/old/2017-12-23/mallocstacks.py
index 8891e82..92271ed 100755
--- a/old/2017-12-23/mallocstacks.py
+++ b/old/2017-12-23/mallocstacks.py
@@ -96,7 +96,7 @@ struct key_t {
     char name[TASK_COMM_LEN];
 };
 BPF_HASH(bytes, struct key_t);
-BPF_STACK_TRACE(stack_traces, STACK_STORAGE_SIZE)
+BPF_STACK_TRACE(stack_traces, STACK_STORAGE_SIZE);

 int trace_malloc(struct pt_regs *ctx, size_t size) {
     u32 pid = bpf_get_current_pid_tgid();