public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "crazylht at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug rtl-optimization/107057] [10/11/12/13 Regression] ICE in extract_constrain_insn, at recog.cc:2692
Date: Wed, 26 Oct 2022 02:16:43 +0000	[thread overview]
Message-ID: <bug-107057-4-TWXUPuzzbY@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-107057-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107057

--- Comment #6 from Hongtao.liu <crazylht at gmail dot com> ---
(In reply to Hongtao.liu from comment #5)
> I'm testing
> 
> modified   gcc/lra-constraints.cc
> @@ -4382,7 +4382,14 @@ curr_insn_transform (bool check_only_p)
>  		 (op, (enum reg_class) goal_alt[i]) == NO_REGS)
>  		|| no_input_reloads_p))
>  	  {
> -	    rtx tem = force_const_mem (mode, op);
> +	    rtx tem;
> +
> +	    /* PR 107057, for same constant pool, don't bother
> +	       force_const_mem again, just reuse the matched op.  */
> +	    if (goal_alt_matches[i] >= 0)
> +	      tem = *curr_id->operand_loc[goal_alt_matches[i]];
> +	    else
> +	      tem = force_const_mem (mode, op);
>  
>  	    change_p = true;
>  	    if (subreg != NULL_RTX)

It failed bootstrap since there's are matches ops with differnce mode

(define_insn "*fop_xf_4_i387"
  [(set (match_operand:XF 0 "register_operand" "=f,f")
        (match_operator:XF 3 "binary_fp_operator"
           [(float_extend:XF
              (match_operand:MODEF 1 "nonimmediate_operand" "fm,0"))
            (match_operand:XF 2 "register_operand" "0,f")]))]

I don't know if there're other usages, so for safety, i'll just invalid
goal_alt_matches when force_const_mem.

  parent reply	other threads:[~2022-10-26  2:16 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-27 16:25 [Bug c/107057] New: " gscfq@t-online.de
2022-09-27 16:30 ` [Bug target/107057] " pinskia at gcc dot gnu.org
2022-09-29  8:00 ` rguenth at gcc dot gnu.org
2022-09-29 11:41 ` marxin at gcc dot gnu.org
2022-09-29 12:52 ` ubizjak at gmail dot com
2022-09-29 15:01 ` [Bug rtl-optimization/107057] " ubizjak at gmail dot com
2022-10-19  6:28 ` crazylht at gmail dot com
2022-10-25  9:15 ` crazylht at gmail dot com
2022-10-26  2:16 ` crazylht at gmail dot com [this message]
2022-10-26  8:46 ` crazylht at gmail dot com
2022-10-26  8:47 ` crazylht at gmail dot com
2022-10-28  8:38 ` ubizjak at gmail dot com
2022-11-01  5:34 ` cvs-commit at gcc dot gnu.org
2022-11-01  5:38 ` crazylht at gmail dot com
2023-07-07 10:44 ` [Bug rtl-optimization/107057] [11/12 " rguenth at gcc dot gnu.org
2023-11-30 10:43 ` liuhongt at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-107057-4-TWXUPuzzbY@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).