This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
RE: [RFC] Add support for printing pdata for x86_64 pe coff objects
- From: "Pierre Muller" <pierre dot muller at ics-cnrs dot unistra dot fr>
- To: "'Nicholas Clifton'" <nickc at redhat dot com>, <binutils at sourceware dot org>
- Date: Wed, 24 Dec 2014 11:47:27 +0100
- Subject: RE: [RFC] Add support for printing pdata for x86_64 pe coff objects
- Authentication-results: sourceware.org; auth=none
- References: <004201cfdd49$be9683c0$3bc38b40$ at muller@ics-cnrs.unistra.fr> <5499A8D3 dot 4090900 at redhat dot com> <000a01d01f05$65bdf5f0$3139e1d0$ at muller@ics-cnrs.unistra.fr> <549A910B dot 9000806 at redhat dot com>
Hi Nick,
The new version seems to work as expected.
The content of .xdata is displayed both for executable and for objects.
Comparison of
$ x86_64-w64-mingw32-objdump.exe --version
GNU objdump (GNU Binutils) 2.24.51.20140411
Copyright (C) 2014 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later
version.
This program has absolutely no warranty.
and current objdump compiled for x86_64-w64-mingw32
reveals only one change, but I don't know if this is really related to
your recent patch:
$ ./objdump.exe -p ./objdump.exe > objdump.test-git
$ x86_64-w64-mingw32-objdump.exe -p ./objdump.exe > objdump.test64
$ diff objdump.test64 objdump.test-git
10,11c10
< Time/Date Sat Mar 8 10:44:01 1902
< Magic 020b (PE32+)
---
> Time/Date (null)Magic 020b (PE32+)
The missing newline, is explained by the comment below:
2719 /* ctime implies '\n'. */
2720 {
2721 time_t t = pe->coff.timestamp;
2722 fprintf (file, "\nTime/Date\t\t%s", ctime (&t));
2723 }
2724
but I don't know why t returns "(null)"
(gdb) ptyp t
type = long long
(gdb) p /x t
$4 = 0xffffffff806f8040
Is this some magical number?
Anyway, thanks for committing my patch!
Pierre Muller
> -----Message d'origine-----
> De : Nicholas Clifton [mailto:nickc@redhat.com]
> Envoyé : mercredi 24 décembre 2014 11:10
> À : Pierre Muller; binutils@sourceware.org
> Objet : Re: [RFC] Add support for printing pdata for x86_64 pe coff
> objects
>
> Hi Pierre,
>
> > But even after moving the check, I still get only part
> > of unwind code, while most is simply replaced by
> > "Too many unwind codes ("...
> > messages.
>
> This was due to the check for corrupt unwind information being
> incorrect. It was including the "addr" value twice, when it should
> have
> been only once. I have now corrected this and checked in your patch.
> Please could you have a look just to make sure that I did not miss
> anything.
>
> Cheers
> Nick