From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from nikam.ms.mff.cuni.cz (nikam.ms.mff.cuni.cz [195.113.20.16]) by sourceware.org (Postfix) with ESMTPS id C8C3E386F81B for ; Sun, 27 Sep 2020 21:46:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org C8C3E386F81B Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=ucw.cz Authentication-Results: sourceware.org; spf=none smtp.mailfrom=hubicka@kam.mff.cuni.cz Received: by nikam.ms.mff.cuni.cz (Postfix, from userid 16202) id A1901282ADB; Sun, 27 Sep 2020 23:46:00 +0200 (CEST) Date: Sun, 27 Sep 2020 23:46:00 +0200 From: Jan Hubicka To: gcc-patches@gcc.gnu.org, d@dcepelik.cz Subject: Fix handling of stores in modref_summary::useful_p Message-ID: <20200927214600.GC52458@kam.mff.cuni.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-Spam-Status: No, score=-14.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) 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-List-Received-Date: Sun, 27 Sep 2020 21:46:04 -0000 Hi, this patch fixes a pasto in modref_summary::useful_p that made ipa-modref to give up on tracking stores when all load info got lost. Bootstrapped/regtested x86_64-linux, comitted. gcc/ChangeLog: 2020-09-27 Jan Hubicka * ipa-modref.c (modref_summary::useful_p): Fix testing of stores. diff --git a/gcc/ipa-modref.c b/gcc/ipa-modref.c index 728c6c1523d..6225552e41a 100644 --- a/gcc/ipa-modref.c +++ b/gcc/ipa-modref.c @@ -135,7 +135,7 @@ modref_summary::useful_p (int ecf_flags) return true; if (ecf_flags & ECF_PURE) return false; - return stores && !loads->every_base; + return stores && !stores->every_base; } /* Dump A to OUT. */