<div dir="ltr"><div dir="ltr">On Wed, Mar 4, 2020 at 4:37 PM Joerg Sonnenberger <<a href="mailto:joerg@bec.de">joerg@bec.de</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Wed, Mar 04, 2020 at 04:25:36PM -0800, Fāng-ruì Sòng wrote:<br>
> It is already non-trivial to write assembly portable on x86-32 and x86-64<br>
> <br>
> .section .eh_frame,"a",@progbits # 32<br>
> .section .eh_frame,"a",@unwind # 64<br>
> <br>
> Writing .eh_frame manually does not seem very correct.<br>
<br>
So far, @progbits worked everywhere. Can't even find a test case in<br>
binutils for @unwind. As such, this seems to be a move in the wrong<br>
direction.<br>
<br>
Joerg<br>
</blockquote></div><div><br></div>I don't agree. .eh_frame contents for x86-32 and x86-64 are different. There is hardly any scenario where .eh_frame must be written in an assembly file.<div>Writing @unwind is really a very small effort.<br><div><br></div><div>"Can't even find a test case in binutils for @unwind."  That 2004 commit is to be blamed. There are still some tests, e.g.</div><div>gas/testsuite/gas/i386/x86-64-unwind.s and some X86_64_UNWIND readelf -S tests.<br></div><div><br></div><div><br></div><div><br></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr">宋方睿</div></div></div></div>