On Sat, Jan 11, 2025 at 1:11 PM Jeff Law <jeffreya...@gmail.com> wrote:
>
>
>
> On 1/11/25 2:08 PM, Andrew Pinski (QUIC) wrote:
> >> -----Original Message-----
> >> From: Jeff Law <jeffreya...@gmail.com>
> >> Sent: Saturday, January 11, 2025 8:12 AM
> >> To: Andrew Pinski (QUIC) <quic_apin...@quicinc.com>; gcc-
> >> patc...@gcc.gnu.org
> >> Subject: Re: [PATCH] final: Fix get_attr_length for asm goto
> >> [PR118411]
> >>
> >>
> >>
> >> On 1/11/25 2:52 AM, Andrew Pinski wrote:
> >>> The problem is for inline-asm goto, the outer rtl insn type is
> >> a
> >>> jump_insn and get_attr_length does not handle ASM
> >> specially unlike if
> >>> the outer rtl insn type was just insn.
> >>>
> >>> This fixes the issue by adding support for both CALL_INSN
> >> and
> >>> JUMP_INSN with asm.
> >>>
> >>> OK? Bootstrapped and tested on x86_64-linux-gnu.
> >>>
> >>>     PR middle-end/118411
> >>>
> >>> gcc/ChangeLog:
> >>>
> >>>     * final.cc (get_attr_length_1): Handle asm for CALL_INSN
> >>>     and JUMP_INSNs.
> >> OK
> >
> > Can I apply this to both the GCC 14, 13 and 12 branches too? Even though 
> > this is not a regression; it seems like an important bug fix for asm goto. 
> > Especially since the Linux kernel uses it and might run into this issue.
> Seems pretty safe to me and while not a regression, it's a case where we
> generate incorrect output.  So yea, fine by me.  Consider giving it a
> week or so on the trunk just in case...

Applied finally to the open branches.

>
> jeff
>

Reply via email to