[RFC] Rewrite obj-coff-seh.c

Kai Tietz ktietz70@googlemail.com
Wed Aug 25 11:54:00 GMT 2010


2010/8/25 Kai Tietz <ktietz70@googlemail.com>:
> 2010/8/25 Richard Henderson <rth@redhat.com>:
>> I'm a bit disappointed there wasn't better code review done when
>> this file was first created.  It does nothing the standard way
>> compared to the rest of the gas source base.
>>
>> This is a total rewrite.  Improvements:
>>
>>  (1) Hopefully better parsing diagnostics.
>>  (2) Use of expression instead of raw strings.
>>  (3) Use of symbol_temp_new_now instead of made up global symbols.
>>  (4) Use of emit_expr instead of frobbing bfd_set_section_contents.
>>
>> This is good enough to not crash cross-compiling to x86_64-mingw32,
>> with additional patches to have gcc emit SEH directives.  I have not
>> yet combed through the xdata info to make sure it's all correct.  I
>> have not yet cross-compiled to ARM, MIPS, or SH to make sure that
>> still works.  I have not tried to actually perform a real unwinding
>> on a win64 system.
>>
>> Comments greatly appreciated.
>>
>>
>> r~
>>
>
> Hello Richard,
>
> first thanks for your rework of it. One point to mention here is, that
> by this patch chained blocks of unwind-information aren't supported
> anymore, but well, by this we can live IMHO. Secondly on first glance
> I had to notice that the unwind-codes aren't aligned any more. So the
> generated blocks are not usable. See the logic in old variant about
> stored number of uw-codes and the actual (aligned) size written to
> xdata.
>
> Further tests will come then.

So, I adjusted patch to emit also alignment of the uwcode section for
xdata. Tests are working for my limited tests, but I was a bit curious
to see in final object relocations in .xdata. AFAIU there shouldn't be
any in final object anymore.

Regards,
Kai


-- 
|  (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rh_seh.diff
Type: application/octet-stream
Size: 67190 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20100825/0073dec3/attachment.obj>


More information about the Binutils mailing list