Name
print [/format
] [expression
]
Print the value of expression. If the first argument is "/
" and format, use the format to print the expression. Omitting expression prints the previous expression, allowing you to use a different format to see the same value. The allowed format values are a subset of the format items for the x
command; see also x, later in this section.
Print Formats
| Print the value as an address. The address is printed as both an absolute (hexadecimal) address and as an offset from the nearest symbol. |
| Print the value as a character constant. |
| Print the value as a signed decimal integer. |
| Print the value as a floating-point number. |
| Print the value as an octal integer. |
| Print the value as a binary integer ( |
| Print the value as an unsigned decimal integer. |
| Print the value as a hexadecimal integer. |
Get GDB Pocket Reference now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.