From patchwork Mon Oct 22 14:00:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Segher Boessenkool X-Patchwork-Id: 987741 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-488024-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=kernel.crashing.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="DjKHFuww"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42dyqL38FTz9sDX for ; Tue, 23 Oct 2018 01:01:18 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id; q=dns; s=default; b=Xsga/ZxjS99d rrdzmVDa4njaWoNUm33fu1CqB6TFpmTFHtLfl12e0d2+f1SZqIocGPzjsU6B/rBa LkGRU2WrIGRP22IOUTQ18aNYdhm3r7UOmw96yPPRNyyBM1CRYzxrjxl8mz5UkoT2 Kyy0yvuizrd5BVg0eeRb9EiTWZtcFUk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id; s=default; bh=v+ZN6ahFB/ycvo3J9H Q7NbOpd+0=; b=DjKHFuwwG/EecCuVaUVpOvTX6JQdbEa/RZeb6iwAkY6STaAUhj KiHI33Up/X1uCPkyZNKZv1dIUIEn0cfJKx01c4Eu2huNrRwm5kiseAZwwgvcKSvI /JdCIYRxyr+AJJxKw+59vt+eCn4SG62dSoUjyQMQwZFu2VADHIjT+sBk4= Received: (qmail 18374 invoked by alias); 22 Oct 2018 14:01:05 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 14130 invoked by uid 89); 22 Oct 2018 14:00:35 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, TIME_LIMIT_EXCEEDED autolearn=unavailable version=3.3.2 spammy= X-HELO: gcc1-power7.osuosl.org Received: from gcc1-power7.osuosl.org (HELO gcc1-power7.osuosl.org) (140.211.15.137) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 22 Oct 2018 14:00:04 +0000 Received: by gcc1-power7.osuosl.org (Postfix, from userid 10019) id 06B71124087D; Mon, 22 Oct 2018 14:00:01 +0000 (UTC) From: Segher Boessenkool To: gcc-patches@gcc.gnu.org Cc: dje.gcc@gmail.com, Segher Boessenkool Subject: [PATCH] rs6000: Handle print_operand_address for unexpected RTL (PR87598) Date: Mon, 22 Oct 2018 14:00:00 +0000 Message-Id: <38749009464c9deb459562622650086789f2898d.1540216416.git.segher@kernel.crashing.org> X-IsSubscribed: yes As the PR shows, the user can force this to be called on at least some RTL that is not a valid address. Most targets treat this as if the user knows best; let's do the same. Committing to trunk. Segher 2018-10-22 Segher Boessenkool PR target/87598 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL call output_addr_const and hope for the best. --- gcc/config/rs6000/rs6000.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index b7da571..db82c67 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -21255,7 +21255,7 @@ print_operand_address (FILE *file, rtx x) fprintf (file, "(%s)", reg_names[REGNO (XVECEXP (tocrel_base_oac, 0, 1))]); } else - gcc_unreachable (); + output_addr_const (file, x); } /* Implement TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA. */