From patchwork Wed Feb 15 00:18:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans-Peter Nilsson X-Patchwork-Id: 57291 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp3276478wrn; Tue, 14 Feb 2023 16:19:23 -0800 (PST) X-Google-Smtp-Source: AK7set9n204pqKMSvlZQwDR1YU+yv55Ent39OU7rQg42w6bzeYy45tcrB1q7X7orqPFImJPq1tOy X-Received: by 2002:a17:907:10d4:b0:844:79b1:ab36 with SMTP id rv20-20020a17090710d400b0084479b1ab36mr770178ejb.25.1676420363404; Tue, 14 Feb 2023 16:19:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676420363; cv=none; d=google.com; s=arc-20160816; b=lz/14pnVgSF81FXZGn87V7Jmcdbs681jWta9Y2YwPd6ClYm478dtGZEvjVVozwzR1T GOUn59uov8wroPUHJw9vGGiUWpj7fGuZ4rN/0L9cn7zN389EWyu3zYDPlQ3GrCEJ+90I StVxFTP1qUSWuG/A3FnjIHqSdXAh01i/10u/SDd/AsSI64xa9P4MfgXsmV6VXLxFTvmr 4sG1+2qOg0s7rDAOoKp6zpoRoRolpwqgLmyEz+qTYwJLap0iVz4iGYMLNrkm/Dpc3uNV bqca8SLfBgmZpkjO39TkqdOJ+CwzUvAAVDF2fTlmKbRSJW3EBWxqPjQAkfSBZ168PAq5 8Zrg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence:date:message-id :content-transfer-encoding:mime-version:subject:to:dmarc-filter :delivered-to:dkim-signature:dkim-filter; bh=6DXO/etVch7kjDi20pltA73j7qdow8VmB0YI1S6sN0I=; b=z0G6zTKX5ny5XiHns89pwVLCbeMhiDx1rxcb4wfgddn/JVzZ2WxVbofSxC4szZRlrk rRMYjQ5mGahSA0kIqvZ9egr8htxLgpp10AImLq5QFvTDMPOMbXWdYWKKmzRnvO8VOz/u PxlBWenv32AUdFNF+ZB8pIms2Kb1htrtAXiTbuC3NqQKHKAGLtifaw1jiHtCkM/gtcMc gQomrkleboOMUe26KmzPGmKTIq2SxqsbVcaFtYwlAc6mV5Tss6TNYZ9N1EAPOAVJyyzG BtFXy2nxp3DXgNbMWJ6TkZ3bWp1DJUtn3mUi8RdHlCSL94pGdf6kZIZKDjd3+2RsQ5pB 3umQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=b5MmX9EY; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id we6-20020a170907234600b008817e670a18si17107340ejb.900.2023.02.14.16.19.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Feb 2023 16:19:23 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=b5MmX9EY; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 97C8D3858D1E for ; Wed, 15 Feb 2023 00:19:21 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 97C8D3858D1E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1676420361; bh=6DXO/etVch7kjDi20pltA73j7qdow8VmB0YI1S6sN0I=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=b5MmX9EYjp3lM+dbX6d9wscFDqstICPXW5fdLsqA+fHJcu70RnM25VADvf/k4UpuS pL91EUgb5OXrGKjbudyZhB1bgKq1I2QkBe7qONXWD1vkrQi9UykAyCslh5VyTtDh8R tLvtC38JojBW7gw1vFAYE+cQVxc/d19tNn1L/xbM= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp1.axis.com (smtp1.axis.com [195.60.68.17]) by sourceware.org (Postfix) with ESMTPS id AC9D53858D1E for ; Wed, 15 Feb 2023 00:18:16 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org AC9D53858D1E To: Subject: [PATCH] gen_reload: Correct parameter for fatal_insn call MIME-Version: 1.0 Message-ID: <20230215001814.F3BAB2042C@pchp3.se.axis.com> Date: Wed, 15 Feb 2023 01:18:14 +0100 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Hans-Peter Nilsson via Gcc-patches From: Hans-Peter Nilsson Reply-To: Hans-Peter Nilsson Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757854158859952767?= X-GMAIL-MSGID: =?utf-8?q?1757854158859952767?= Committed as obvious. Also, I wrote the neighboring code - apparently including that line... -- >8 -- Observed when disabling LEGITIMIZE_RELOAD_ADDRESS for cris-elf: the current code doesn't handle the post-cc0 parallel-with-clobber-of-cc0 sets, dropping down into the fatal_insn call. Following the code, it's obvious that the variable "set" is always NULL at the call. The intended parameter is "in". * reload1.cc (gen_reload): Correct rtx parameter for fatal_insn "failure trying to reload" call. --- gcc/reload1.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/reload1.cc b/gcc/reload1.cc index 6fe22d8b81f9..7dcef50437b8 100644 --- a/gcc/reload1.cc +++ b/gcc/reload1.cc @@ -8606,7 +8606,7 @@ gen_reload (rtx out, rtx in, int opnum, enum reload_type type) return insn; } - fatal_insn ("failure trying to reload:", set); + fatal_insn ("failure trying to reload:", in); } /* If IN is a simple operand, use gen_move_insn. */ else if (OBJECT_P (in) || GET_CODE (in) == SUBREG)