[patch]: Dump of .pdata/.xdata for x64 coff

Dave Korn dave.korn.cygwin@googlemail.com
Mon Apr 20 02:03:00 GMT 2009


Kai Tietz wrote:
> Hello,
> 
> I reworked the patch and add some constants, helper macros, and
> structures for pdata/xdata interpretation to coff/x86_64.h file. So
> the code gets a bit more clear. Additional I could clarify the
> unwind_info flag value 3. 

    Hi Kai,

  This is all excellent now, thanks for doing such a great job!

> Tested for x86_64-pc-mingw32 and regression test on i686-pc-cygwin.
> 
> Ok for apply?

  ... I have a suggestion: since .pdata and .xdata are only features of PE
targets, shouldn't it work just as well to put the data structures and macros
into include/coff/pe.h?

  I've attached a minor respin of your patch, which does this.  I also tweaked
a couple of tiny grammar/spelling nits, and I added a bit of constification;
you have these functions that play a sort of _swap_XXX_in role, so I thought
it would be nice if they consistently took a const pointer to the raw external
format data.  That had a minor knock-on effect via ui->rawUnwindCodes and
ui->rawScopeEntries, so the outcome was that I made everything below the level
of pex64_bfd_print_pdata() treat the external data as const.  Oh, and I found
an unused file scope version of "struct pex64_scope_entry se;" and removed it.

  What do you think?  I tested it on i686-pc-cygwin and cross to
x86_64-pc-mingw32 without any regressions, and I've kicked off an overnight
test run against my standard list of 70-or-so random PE and COFF (and just a
couple of ELF!) targets.  If you like it, I'll leave it to you to adjust the
changelog entry when the formal OK is given.

    cheers,
      DaveK

-------------- next part --------------
A non-text attachment was scrubbed...
Name: xdata_peix64-respun.diff
Type: text/x-c
Size: 23996 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20090420/9e470d7a/attachment.bin>


More information about the Binutils mailing list