aboutsummaryrefslogtreecommitdiff
path: root/gdb/doc
diff options
context:
space:
mode:
authorLuis Machado <luisgpm@br.ibm.com>2007-11-05 11:32:31 +0000
committerLuis Machado <luisgpm@br.ibm.com>2007-11-05 11:32:31 +0000
commit1a619819d6cb85f66a81d3ca146a960c679edfa4 (patch)
treed79458b9191b3ac748a1108187608fbf3a01262a /gdb/doc
parent9a5e27bd964ba53c203b2c4fe1df4be7f07cb37d (diff)
downloadgdb-1a619819d6cb85f66a81d3ca146a960c679edfa4.zip
gdb-1a619819d6cb85f66a81d3ca146a960c679edfa4.tar.gz
gdb-1a619819d6cb85f66a81d3ca146a960c679edfa4.tar.bz2
* printcmd.c: (printf_command): Add support for new DFP
modifiers %H, %D and %DD. * configure.ac: Add check for DECFLOAT printf support. * configure: Regenerated. * doc/gdb.texinfo: Update printf command's description. * testsuite/gdb.base/printcmds.exp: New function test_printf_with_dfp.
Diffstat (limited to 'gdb/doc')
-rw-r--r--gdb/doc/ChangeLog4
-rw-r--r--gdb/doc/gdb.texinfo28
2 files changed, 32 insertions, 0 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog
index 83d679f..61aad5a 100644
--- a/gdb/doc/ChangeLog
+++ b/gdb/doc/ChangeLog
@@ -1,3 +1,7 @@
+2007-11-05 Luis Machado <luisgpm@br.ibm.com>
+
+ * gdb.texinfo: Update printf command's description.
+
2007-10-30 Daniel Jacobowitz <dan@codesourcery.com>
* gdb.texinfo (PowerPC): Document "set powerpc vector-abi" and "set
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 83c7680..f26393e 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -16557,6 +16557,34 @@ sequences, such as @code{\n}, @samp{\t}, @samp{\\}, @samp{\"},
@samp{\a}, and @samp{\f}, that consist of backslash followed by a
single character. Octal and hexadecimal escape sequences are not
supported.
+
+Additionally, @code{printf} supports conversion specifications for DFP
+(@dfn{Decimal Floating Point}) types using the following conversion
+letters:
+
+@itemize @bullet
+@item
+@samp{H} for printing @code{Decimal32} types.
+
+@item
+@samp{D} for printing @code{Decimal64} types.
+
+@item
+@samp{DD} for printing @code{Decimal128} types.
+@end itemize
+
+If the underlying @code{C} implementation used to build @value{GDBN} has
+support for the three conversion letters for DFP types, other modifiers
+such as width and precision will also be available for @value{GDB} to use.
+
+In case there is no such @code{C} support, no additional modifiers will be
+available and the value will be printed in the standard way.
+
+Here's an example of printing DFP types using the above conversion letters:
+@smallexample
+printf "D32: %H - D64: %D - D128: %DD\n",1.2345df,1.2E10dd,1.2E1dl
+@end smallexample
+
@end table
@node Interpreters