From patchwork Fri Sep 2 17:06:46 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Prathamesh Kulkarni X-Patchwork-Id: 75322 Delivered-To: patch@linaro.org Received: by 10.140.29.8 with SMTP id a8csp979096qga; Fri, 2 Sep 2016 10:07:45 -0700 (PDT) X-Received: by 10.98.93.25 with SMTP id r25mr38202597pfb.122.1472836065155; Fri, 02 Sep 2016 10:07:45 -0700 (PDT) Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id az10si12321529pab.236.2016.09.02.10.07.44 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Sep 2016 10:07:45 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-return-435145-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) client-ip=209.132.180.131; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org; spf=pass (google.com: domain of gcc-patches-return-435145-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-435145-patch=linaro.org@gcc.gnu.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; q=dns; s=default; b=olvj4joCJ/of/BE 1j6lxDpx9Z6E9iVcq6O4bqTa63DicL+e/Q65kGD86pn80wxCJb3cRkpyW4BXs4b5 5A1KsMq5q0DLQFpktMzFvnaDywT8mj+dCtOog/aBUEfNLj7AQriKNs4t/eH+FZMd wmLGgpmnZJh++QBhk0sR5hPqKvOU= 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 :mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; s=default; bh=VAxozVc1slmQMWi65Rxly 8vxLU8=; b=bkmFRcy8uhMidMKOLyt1YmEhtlWtV042R0MrUqRW1E0Ar83i7Bk9D 4rrD78JB+OiSSNH7pSx/7rYNEns+2T7rT3I+AQjT9/ahFYGMvnG7nchnPWH7EeGA L0Pathn4vXEpuoJXwSeOdM08H1dLmCRYB5CAZsM5JiBC3ahrd49OSM= Received: (qmail 40529 invoked by alias); 2 Sep 2016 17:07: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 40477 invoked by uid 89); 2 Sep 2016 17:06:58 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.5 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_SORBS_SPAM, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-it0-f44.google.com Received: from mail-it0-f44.google.com (HELO mail-it0-f44.google.com) (209.85.214.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 02 Sep 2016 17:06:48 +0000 Received: by mail-it0-f44.google.com with SMTP id c198so49928874ith.1 for ; Fri, 02 Sep 2016 10:06:48 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=sBjrvS4HIVeaTHXYhhIBblHPrF8/80S19+C1i69mkwU=; b=Rfpuwv1WygU/+RO3yPQMX+vFBL4mAYfBkCHU6UGXnBPseel2vQLvlMo0TwQemRyAty cYPalexcAolntLMevpwtYIE8f5kcnOCiw+CSgyhivn5BQH5gmrrB4E8LyS9l7DjGfbQv NVC1i1otubGo7fm8yrYnvQRKs3AHY6UZItABlIPwZpcl9fM7TBueffkBl5nA4t4IuTWV B6Pg8arnnrdF980qZBoFCpNhFagcaXg9A4kZ/D0uSfM4U1b75xuEpnlf6vnaG5oaJob9 HjAc+KMocBJRKO16P/S6KPJ1lxIag4hFk9JMOtzu1SwMJkCNBWN4AyBHnZ7T83TAlJkY NGDA== X-Gm-Message-State: AE9vXwMLbXmpi5csnPlm0PpWW5vckOMdrgEXCu2zDM7m57hoA0c9e6FaSXRxototduKtXaq7k8JuCPal27CmfHeN X-Received: by 10.107.137.105 with SMTP id l102mr379986iod.137.1472836006709; Fri, 02 Sep 2016 10:06:46 -0700 (PDT) MIME-Version: 1.0 Received: by 10.36.81.85 with HTTP; Fri, 2 Sep 2016 10:06:46 -0700 (PDT) In-Reply-To: References: From: Prathamesh Kulkarni Date: Fri, 2 Sep 2016 22:36:46 +0530 Message-ID: Subject: Re: cfg.c: redundant second assignment of bb_copy = NULL in free_original_copy_tables() To: Richard Biener Cc: "gcc@gcc.gnu.org" , gcc Patches X-IsSubscribed: yes On 2 September 2016 at 15:49, Richard Biener wrote: > On Fri, 2 Sep 2016, Prathamesh Kulkarni wrote: > >> Hi, >> There appears to be a redundant second assignmeent bb_copy = NULL in >> free_copy_original_tables(). I suppose it should be >> bb_original = NULL instead ? >> I found this mentioned on a blog "Bugs found in gcc with help of PVS studio": >> http://www.viva64.com/en/b/0425/#ID0EHCCK > > Ok. Thanks, committed as r239960 after bootstrap+test on x86_64-unknown-linux-gnu. Regards, Prathamesh > > Thanks, > Richard. 2016-09-02 Prathamesh Kulkarni * cfg.c (free_original_copy_tables): Replace second assignment of bb_copy = NULL by bb_original = NULL. diff --git a/gcc/cfg.c b/gcc/cfg.c index 0e31780..cab66c6 100644 --- a/gcc/cfg.c +++ b/gcc/cfg.c @@ -1075,7 +1075,7 @@ free_original_copy_tables (void) delete bb_copy; bb_copy = NULL; delete bb_original; - bb_copy = NULL; + bb_original = NULL; delete loop_copy; loop_copy = NULL; delete original_copy_bb_pool;