From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from delivery.mailspamprotection.com (delivery.mailspamprotection.com [185.56.84.18]) by sourceware.org (Postfix) with ESMTPS id E3E383858C3A for ; Tue, 11 Jan 2022 04:15:37 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org E3E383858C3A Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tantosonline.com Authentication-Results: sourceware.org; spf=none smtp.mailfrom=tantosonline.com Received: from 107.112.208.35.bc.googleusercontent.com ([35.208.112.107] helo=siteground277.com) by se23.mailspamprotection.com with esmtps (TLSv1.2:AES128-GCM-SHA256:128) (Exim 4.92) (envelope-from ) id 1n78ZL-000DBL-7j for gcc@gcc.gnu.org; Mon, 10 Jan 2022 22:15:37 -0600 Received: from [73.169.135.95] (port=45662 helo=kakukkfu.lan) by siteground277.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.90-.1) (envelope-from ) id 1n78ZK-0008J1-Pf; Tue, 11 Jan 2022 04:15:34 +0000 Received: from dell-laptop.lan (router.lan [192.168.139.254]) by kakukkfu.lan (Postfix) with ESMTPSA id 0115E241; Mon, 10 Jan 2022 20:15:33 -0800 (PST) Message-ID: Subject: Re: What's wrong with this RTL? From: Andras Tantos To: Andrew Pinski Cc: gcc@gcc.gnu.org Date: Mon, 10 Jan 2022 20:15:33 -0800 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.36.5-0ubuntu1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - siteground277.com X-AntiAbuse: Original Domain - gcc.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tantosonline.com X-Source: X-Source-Args: X-Source-Dir: X-Originating-IP: 35.208.112.107 X-SpamExperts-Domain: siteground277.com X-SpamExperts-Username: 35.208.112.107 Authentication-Results: mailspamprotection.com; auth=pass smtp.auth=35.208.112.107@siteground277.com X-SpamExperts-Outgoing-Class: ham X-SpamExperts-Outgoing-Evidence: Combined (0.14) X-Recommended-Action: accept X-Filter-ID: Pt3MvcO5N4iKaDQ5O6lkdGlMVN6RH8bjRMzItlySaT+ICaQaxn1Uqym6Ha6EbcEgPUtbdvnXkggZ 3YnVId/Y5jcf0yeVQAvfjHznO7+bT5xBytxzJBgOlCIhBVn7zf5DAxQ+GhOWeJSm0X/4oD2rzQIN 2QbY73X6YGS+xzd6mAch55uqY3MhMgFAHq5BxPxPnSWXEV458bUmxaOKcxICtcN9X9K1DzVKciEj mqsTuLPQAKujagVaTNLZ5X+kLHvN+ufcSwqqOlrljbZrM+IOzcdMIqsIyb3aJqs33ZX4HJh0xl54 MAEbe1oNTNeaZ2bNJnWeeuYTXKpbWwq0Jmmi2mrgACkj+K/uKiOZLpbQmXWPi0A2vLwcNEjxGjiC Erd+5eRAFGRXX9l6BElkZQeY94zIacMilJyGVyjpEgOg2D9z7iXziAEKWBLXmO85pBwPaF+P3CGL wqkaQ0xpotL0Mhypt3L7tZhLu6Os9ceqGjHQelPdLZIWapW8lSgOkuDXqHh92LXjpWxyqA19gVEn 1I8jz3K25BQZYLiRBulvflK9x7G+8oFGjk5+Tb1j8PJET4ztkOffVWdpRr+g5kzHCGrLhMVo7s5r C/i1xA6nwvG8Ksk+aedMfNWSnJswrtlNQ8clfdequDnRZkTy+cnx+wzevvA7ArqeQFEd2navgAmn OvL8Z8nObfEzCxRgiDMmm7RVhDC6rGajPOQMsilQygZImPb9UZXs+o5qEZeRpTi3BT/xcase7lCw 0EQdzS0Qs10w7kA+lqPr+8hLk2VakRU9Dp2IDhxbd6uHRDYwg9yrPO+g7eVo14kJgz9q4Ywi4G/y b0lqja52Mvsrgj8rEk7tj7p+dyFIQ47gnxHR/cQeFcyQ7VJExC7Q4eRzWD0n0z6bhalFEM/pjPCQ A+BAlkOpG56vNwNAHsDD96cr7LsGGzgmrxJJssXyURBEIIDYJMPEAAC5mJVNKOXqIK/gaLBrG8Ze xQEYzgQ+UAszvYbTH+zEfYdvQVRntCQXFl8UPAlbDjazCbhs7qBpykynMvte84F69yef3rjIE9aq rvwwVFFEq45gMHpOzZY5w3lZONZwysYcuEaP1yUDhIrf6APNx91A6n31AAHEln911CjeNHk15Vol AGHS5rCXQKDywZSW8C3uaBiKZzYl7/DyqzzEOtOWX+ZTSN4+SxiH2XbbksYLroyN1JYjH3L7qaaK PM3kr7e7CDjX3ZthNfMWi+djXZBNOJeqVzGgrKtR6HA= X-Report-Abuse-To: spam@quarantine1.mailspamprotection.com X-Spam-Status: No, score=-0.7 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, KAM_SHORT, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2022 04:15:41 -0000 On Sun, 2022-01-09 at 22:19 -0800, Andrew Pinski wrote: > On Sun, Jan 9, 2022 at 8:49 PM Andras Tantos > wrote: > > All! > > > > I'm trying to port GCC to a new target, I call 'brew'. I've based > > it on > > the Moxie target mostly because of it's simplicity. > > > > I must be doing something horribly wrong as the following C code > > crokes > > in the LRA path: > > > > long long foo (long long a, long long *w) > > { > > return __builtin_add_overflow (a, a, w); > > } > > > > The error message I get is the following: > > > > during RTL pass: reload > > ../brew-gcc-build/second.c: In function ‘foo’: > > ../brew-gcc-build/second.c:5:1: internal compiler error: maximum > > number of generated reload insns per insn achieved (90) > > 5 | } > > | ^ > > 0xd23854 lra_constraints(bool) > > ../../brew-gcc/gcc/lra-constraints.c:5095 > > 0xd10322 lra(_IO_FILE*) > > ../../brew-gcc/gcc/lra.c:2336 > > 0xcc86d9 do_reload > > ../../brew-gcc/gcc/ira.c:5932 > > 0xcc86d9 execute > > ../../brew-gcc/gcc/ira.c:6118 > > Please submit a full bug report, > > with preprocessed source if appropriate. > > Please include the complete backtrace with any bug report. > > See for instructions. > > This usually means the move instruction is being reloaded over and > over again as you describe below. > I think you should have one merged movsi instruction which handles > all > of the constraints together. mov is "special" in that it needs to be > done that way otherwise this happens. > But really there seems to be another issue where (subreg:SI (reg:DI)) > is not being accepted for the xor set too. > What regclasses are being chosen for the reg DI mode? Etc. > > Thanks, > Andrew Pinski > That's what it was: after merging all my movsi variants, the problem went away. Thanks for the help! Andras