From patchwork Thu Sep 5 11:01:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Biener X-Patchwork-Id: 1158371 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-508375-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="KzFo4GV1"; 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 46PHnr23l4z9sNf for ; Thu, 5 Sep 2019 21:02:05 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; q=dns; s= default; b=Umq5d/8v452lZOYovGWO/mOiKUdQ2tEzI3rIUQJUXh4kxKqRnBn92 Tjt0PaHxqNttpsNzWuD6AJ7hL876OVTe9+o3QHUFsdkpij2e7OZ3JPeCz1bpCsWC SlObK0ZPgUIET8YgdBSLQmkKSgnLQu0DSF5lETOlhfrHq6VeDTEme8= 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:date :from:to:subject:message-id:mime-version:content-type; s= default; bh=JLj6PwwDDR7J0UZ1FVbe5+GG3lw=; b=KzFo4GV1laDIYay3ZP73 b8vK4BmJVrOOG1VXRtlhet25HhDGgA/oMGj+q/uZvKbf1KhbJHnjDvkdygk4vboK IiwORx7QK7qKrDwccTWbDLOrL2bjebEvxQSj2MCWLQZD8WY6YlLX7QCvScdh9P8E cDX4piZabseootZkot2BE5U= Received: (qmail 102586 invoked by alias); 5 Sep 2019 11:02:00 -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 102577 invoked by uid 89); 5 Sep 2019 11:02:00 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-10.5 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_NUMSUBJECT, SPF_PASS autolearn=ham version=3.3.1 spammy= X-HELO: mx1.suse.de Received: from mx2.suse.de (HELO mx1.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 05 Sep 2019 11:01:59 +0000 Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id B674FAFA4 for ; Thu, 5 Sep 2019 11:01:55 +0000 (UTC) Date: Thu, 5 Sep 2019 13:01:55 +0200 (CEST) From: Richard Biener To: gcc-patches@gcc.gnu.org Subject: [PATCH] Fix PR90501 Message-ID: User-Agent: Alpine 2.21 (LSU 202 2017-01-01) MIME-Version: 1.0 The following fixes D testsuite ICEs by properly marking a return slot addressable after we built an address of it during inlining. Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. Richard. 2019-09-05 Richard Biener PR middle-end/90501 * tree-inline.c (declare_return_variable): Mark the return slot as addressable after building an address of it. Index: gcc/tree-inline.c =================================================================== --- gcc/tree-inline.c (revision 271282) +++ gcc/tree-inline.c (working copy) @@ -3540,6 +3540,7 @@ declare_return_variable (copy_body_data taken by alias analysis. */ gcc_assert (TREE_CODE (return_slot) != SSA_NAME); var = return_slot_addr; + mark_addressable (return_slot); } else {