[🐛] What's new in zxdb, the Fuchsia debugger

26 views
Skip to first unread message

Dangyi Liu

unread,
Nov 4, 2021, 8:16:02 PM11/4/21
to dis...@fuchsia.dev
Here is the latest news of zxdb. Please check the full documentation for setup and help.

Function return values

Zxdb will now display the return value of functions when you "finish" or step out of a function with "step" or "next". It will print this out right before the code listing at the return location (see the yellow arrow):

returning.png

The main exception is this won't show structures > 16 bytes on ARM due to ABI limitations.

Pretty printers

There is now a std::mutex pretty-printer that indicates whether it's locked and which thread owns the lock (great for diagnosing locking issues). C++ string streams will now display their contents.

Array size syntax

You can now convert pointers to arrays or specify the size of a struct flexible array member using the GDB syntax array_name@array_size.

[zxdb] print argv  # Normal pointer interpretation of char**
(*)0x1e88d07bfc0 ➔ "/pkg/bin/foo"

[zxdb] print argv@3 
# Declare array size 3
{"/pkg/bin/foo", "--bar", "baz"}

Better support for optimized variables

Zxdb can now display values for structures partially or completely held in registers.

Dangyi
Reply all
Reply to author
Forward
0 new messages