surftrace
surftrace copied to clipboard
support navigate complex data object in user-space trace script
just like the bpftrace, its better to enable trace an running program in user-space and navigate/ traverse its argument and member field of the argument when it is a complex data object:
surftrace -e 'uprobe:/home/test/observer:oceanbase_transaction { printf("%d", arg0->mvcc_ctx_->tx_id_); }'
Here, the arg0 is the argument of function 'oceanbase_transaction' with type 'ObTxDesc', and we want to print the transaction id
info, which nested in 'ObTxDesc.mvcc_ctx_.tx_id_'
Thanks:)