somewhat working ebpf bpftrace

This commit is contained in:
Harshavardhan Musanalli
2025-11-08 20:42:07 +01:00
parent 190e54dd38
commit 794111cb44
16 changed files with 2834 additions and 216 deletions

19
scripts/debug_trace_script.sh Executable file
View File

@@ -0,0 +1,19 @@
#!/bin/bash
# Test the current script generation
echo "Testing tracepoint script generation..."
# Simulate what the failing test does
echo "Target: syscalls:sys_enter_openat"
echo "ProbeType: t"
echo ""
echo "Generated bpftrace script would be:"
echo "tracepoint:syscalls:sys_enter_openat {"
echo " printf(\"TRACE|%d|%d|%d|%s|syscalls:sys_enter_openat|file access\\n\", nsecs, pid, tid, comm, arg2@user);"
echo "}"
echo ""
echo "This is INVALID - should be:"
echo "tracepoint:syscalls:sys_enter_openat {"
echo " printf(\"TRACE|%d|%d|%d|%s|openat|file access\\n\", nsecs, pid, tid, comm);"
echo "}"