Index: www/lldb-gdb.html =================================================================== --- www/lldb-gdb.html +++ www/lldb-gdb.html @@ -3,7 +3,7 @@ -LLDB to GDB Command Map +GDB to LLDB Command Map @@ -20,10 +20,10 @@

GDB to LLDB Command Map

-

Below is a table of GDB commands with the LLDB counterparts. +

Below is a table of GDB commands with their LLDB counterparts. The built in GDB-compatibility aliases in LLDB are also listed. The full lldb command names are often long, but any - unique short form can be used. Instead of "breakpoint set", + unique short form can be used. For example, instead of "breakpoint set", "br se" is also acceptable.

@@ -63,7 +63,7 @@ - Launch a process for with arguments a.out 1 2 3 without having to supply the args every time. + Launch process a.out with arguments 1 2 3 without having to supply the args every time. % gdb --args a.out 1 2 3
(gdb) run
@@ -97,7 +97,7 @@ - Launch a process with arguments in new terminal window (Mac OS X only). + Launch a process with arguments in new terminal window (macOS only). @@ -106,7 +106,7 @@ - Launch a process with arguments in existing terminal /dev/ttys006 (Mac OS X only). + Launch a process with arguments <args> in existing terminal /dev/ttys006 (macOS only). @@ -159,7 +159,7 @@ - Attach to a process with process ID 123. + Attach to the process with process ID 123. (gdb) attach 123 @@ -333,7 +333,7 @@ LLDB - Set a breakpoint at all functions named main. + Set a breakpoint at all functions named main. (gdb) break main @@ -345,7 +345,7 @@ - Set a breakpoint in file test.c at line 12. + Set a breakpoint in file test.c at line 12. (gdb) break test.c:12 @@ -357,7 +357,7 @@ - Set a breakpoint at all C++ methods whose basename is main. + Set a breakpoint at all C++ methods whose basename is main. (gdb) break main
@@ -369,7 +369,7 @@ - Set a breakpoint at and object C function: -[NSString stringWithFormat:]. + Set a breakpoint at an Objective C function -[NSString stringWithFormat:]. (gdb) break -[NSString stringWithFormat:]
@@ -380,7 +380,7 @@ - Set a breakpoint at all Objective C methods whose selector is count. + Set a breakpoint at all Objective C methods whose selector is count. (gdb) break count
@@ -403,7 +403,7 @@ - Ensure that breakpoints by file and line work for #included .c/.cpp/.m files. + Ensure that breakpoints by file and line work for #included .c/.cpp/.m files. @@ -428,7 +428,7 @@ - Set a conditional breakpoint + Set a conditional breakpoint. @@ -639,7 +639,7 @@ - Display the variables "argc" and "argv" only when you stop in the function named main. + Display the variables "argc" and "argv" only when you stop in the function named main. @@ -649,7 +649,7 @@ - Display the variable "*this" only when you stop in c class named MyClass. + Display the variable "*this" only when you stop in c class named MyClass. @@ -708,7 +708,7 @@ - Printing the ObjC "description" of an object. + Printing the Objective C "description" of an object. (gdb) po [SomeClass returnAnObject]
@@ -735,7 +735,7 @@ - Calling a function so you can stop at a breakpoint in the function. + Call a function so you can stop at a breakpoint in it. (gdb) set unwindonsignal 0
@@ -746,7 +746,7 @@ - Calling a function that crashes, and stopping when the function crashes. + Call a function that crashes, then stop when it does. (gdb) set unwindonsignal 0
@@ -896,7 +896,7 @@ Show the general purpose registers for the current thread formatted as signed decimal. LLDB tries to use - the same format characters as printf(3) when possible. Type "help format" to see the full list of format specifiers. + the same format characters as printf(3) when possible. Type "help format" to see the full list of format specifiers. @@ -945,7 +945,7 @@ - Read memory from address 0xbffff3c0 and show 4 hex uint32_t values. + Read memory from address 0xbffff3c0 and show 4 hex uint32_t values. (gdb) x/4xw 0xbffff3c0
@@ -974,7 +974,7 @@ - Read 512 bytes of memory from address 0xbffff3c0 and save results to a local file as text. + Read 512 bytes of memory from address 0xbffff3c0 and save the results to a local file as text. (gdb) set logging on
@@ -999,7 +999,7 @@ (lldb) me r -o /tmp/mem.bin -b 0x1000 0x2000
- Get information about a specific heap allocation (available on Mac OS X only). + Get information about a specific heap allocation (available on macOS only). (gdb) info malloc 0x10010d680 @@ -1010,7 +1010,7 @@ (lldb) malloc_info --stack-history 0x10010d680
- Get information about a specific heap allocation and cast the result to any dynamic type that can be deduced (available on Mac OS X only) + Get information about a specific heap allocation and cast the result to any dynamic type that can be deduced (available on macOS only). @@ -1019,7 +1019,7 @@ (lldb) malloc_info --type 0x10010d680
- Find all heap blocks that contain a pointer specified by an expression EXPR (available on Mac OS X only). + Find all heap blocks that contain a pointer specified by expression EXPR (available on macOS only). @@ -1028,7 +1028,7 @@ (lldb) ptr_refs EXPR
- Find all heap blocks that contain a C string anywhere in the block (available on Mac OS X only). + Find all heap blocks that contain a C string anywhere in the block (available on macOS only). @@ -1048,7 +1048,7 @@ - Disassemble any functions named main. + Disassemble any functions named main. (gdb) disassemble main @@ -1179,7 +1179,7 @@ - Look up information for an address in a.out only. + Look up information for an address in a.out only. @@ -1210,7 +1210,7 @@ - Dump all sections in the a.out module. + Dump all sections in the a.out module. @@ -1228,7 +1228,7 @@ - Dump all symbols in a.out and liba.so. + Dump all symbols in a.out and liba.so. @@ -1260,7 +1260,7 @@ - Remap source file pathnames for the debug session. If your source files are no longer located in the same location as when the program was built --- maybe the program was built on a different computer --- you need to tell the debugger how to find the sources at their local file path instead of the build system's file path. + Remap source file pathnames for the debug session. If your source files are no longer located in the same location as when the program was built (for example, if the program was built on a different computer) you need to tell the debugger how to find the sources at their local file path instead of the build system's file path. (gdb) set pathname-substitutions /buildbot/path /my/path