This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] gdb: Add support for dumping to verilog hex format.
- From: Pedro Alves <palves at redhat dot com>
- To: Andrew Burgess <andrew dot burgess at embecosm dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Thu, 23 Apr 2015 11:41:27 +0100
- Subject: Re: [PATCH] gdb: Add support for dumping to verilog hex format.
- Authentication-results: sourceware.org; auth=none
- References: <ac8db75957e27b34d78e2f0b692b5072a9809a37 dot 1429740646 dot git dot andrew dot burgess at embecosm dot com> <553821B2 dot 1080704 at redhat dot com> <20150422230431 dot GF2422 at embecosm dot com>
On 04/23/2015 12:04 AM, Andrew Burgess wrote:
> * Pedro Alves <palves@redhat.com> [2015-04-22 23:33:22 +0100]:
>
>> On 04/22/2015 11:24 PM, Andrew Burgess wrote:
>>> This patch extends the 'dump' command to generate output in the
>>> verilog hex format supported by bfd.
>>>
>>> OK to apply?
>>
>> Sounds like gdb.base/dump.exp should be extended to cover this?
>
> Of course, sorry.
>
> New version, including tests. Given that bfd (currently) only
> supports writing to verilog format, and not reading, then the tests
> (obviously) only cover 'dump' and not 'restore'.
>
> Within dump.exp I reordered the 'all_files' list a little in order to
> make it easier to insert new files. Everything else should be
> straight forward.
(Looks like the test could be simplified with something like
foreach format $dump_formats {} { ... }. Something for another
day.)
Thanks, this looks good to me with the missing _() Eli noticed, and ...
> index 0410702..4b78fb4 100644
> --- a/gdb/doc/gdb.texinfo
> +++ b/gdb/doc/gdb.texinfo
> @@ -10890,6 +10890,8 @@ Intel hex format.
> Motorola S-record format.
> @item tekhex
> Tektronix Hex format.
> +@item verilog
> +Verilog Hex format.
> @end table
>
> @value{GDBN} uses the same definitions of these formats as the
... at least this bit needs updating too:
You can use the commands @code{dump}, @code{append}, and
@code{restore} to copy data between target memory and a file. The
@code{dump} and @code{append} commands write data to a file, and the
@code{restore} command reads data from a file back into the inferior's
memory. Files may be in binary, Motorola S-record, Intel hex, or
Tektronix Hex format; however, @value{GDBN} can only append to binary
files.
Thanks,
Pedro Alves