From patchwork Wed May 15 15:17:46 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Jambor X-Patchwork-Id: 244110 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 8372A2C01BE for ; Thu, 16 May 2013 01:17:57 +1000 (EST) 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=aq1aArUJkPlvEVLw5cRg9ihPy6NP4RDOL930xJTKbiYb1KnUUbFhJ Z7MsAKBJiUQkR/cT567gSsKcEnSZkv1YGKT96tD9cHv0QaXnX53WQcmSiIv6z3fQ Ow1JOLF1Ckq+JKxC92V90yyBdvHeeLAyGsb5bv0PNM6NqlqUGgdpQA= 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=2W45y6L98Dp1YLfd6s7ewKX7Wqo=; b=aiGW7YqBzVn3BnkR7x6m zSdFHIwn6aNLohoWPvgi6Al2rX3PjCtvEV2TsgrtbXzokJUAeeCBPk8vhImdmPCJ gHz8+IB2yOamS2fJN3XJYcU3UT+cE79zFpzLaJFjPfgL6a+Fk4b/JxWWiAW4LEmA 7laDLhbGEXJBEMCMbzh8VdM= Received: (qmail 20509 invoked by alias); 15 May 2013 15:17:50 -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 20500 invoked by uid 89); 15 May 2013 15:17:50 -0000 X-Spam-SWARE-Status: No, score=-3.4 required=5.0 tests=AWL, BAYES_00, TW_GG autolearn=ham version=3.3.1 Received: from cantor2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 15 May 2013 15:17:49 +0000 Received: from relay2.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 741B5A5596 for ; Wed, 15 May 2013 17:17:47 +0200 (CEST) Date: Wed, 15 May 2013 17:17:46 +0200 From: Martin Jambor To: GCC Patches Subject: [PATCH, PR 57276] Add a missing break in cgraph_edge_brings_all_agg_vals_for_node Message-ID: <20130515151746.GK3568@virgil.suse> Mail-Followup-To: GCC Patches MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Hi, in PR 57276, Po-Chun Chang noticed there is a missing break in a loop in cgraph_edge_brings_all_agg_vals_for_node. This patch adds it. Bootstrapped and tested on x86_64-linux. I consider it trivial and will commit t some time tomorrow if there are no objections. Thanks, Martin 2013-05-15 Po-Chun Chang Martin Jambor PR middle-end/57276 * ipa-cp.c (cgraph_edge_brings_all_agg_vals_for_node): Break when a value that corresponds to the given aggval is found in values vector. Index: src/gcc/ipa-cp.c =================================================================== --- src.orig/gcc/ipa-cp.c +++ src/gcc/ipa-cp.c @@ -3213,7 +3213,10 @@ cgraph_edge_brings_all_agg_vals_for_node if (item->value && item->offset == av->offset && values_equal_for_ipcp_p (item->value, av->value)) - found = true; + { + found = true; + break; + } if (!found) { values.release();