From patchwork Tue May 23 13:50:24 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Prathamesh Kulkarni X-Patchwork-Id: 100365 Delivered-To: patch@linaro.org Received: by 10.140.96.100 with SMTP id j91csp328884qge; Tue, 23 May 2017 06:50:46 -0700 (PDT) X-Received: by 10.98.17.86 with SMTP id z83mr24296672pfi.212.1495547446221; Tue, 23 May 2017 06:50:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1495547446; cv=none; d=google.com; s=arc-20160816; b=ZOQkJWqT5S+StaExnVHpG0824EYzG0WiXnzhc24QcRdk1nrkEx+8nQvewXIlnhdeMP gCA+hya9PFcZ2Og4iUXwrDi5v2fyBnhnslV/4XpMOj1Y3fB8fIqlzai3CnsWWnqdIo8z 8Qsu5L62IenuWdOuDqqAt4tb8sJPZ6ZHeTXWHjWrDaM2DOQKcl+DC+l3vkme+5FeBuyX XqrlzJmj+Xh+LD1Q3byv80sgeBFSBSf7nSHveIceY71ycmI40Ou9UdaJOvpD5bhD6PHw nZHxHkHzIqfmMMlmH7Ihq1yMwgv4F4ZvqwqBgTpwYIt8npgXSwY9JyQGLyMGrWHGDbQ5 yh4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:subject:message-id:date:from:mime-version:delivered-to:sender :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mailing-list:dkim-signature:domainkey-signature :arc-authentication-results; bh=8pw3h1fnrzp7pmKxb1sOnNqvks6WYaLuW2WVPWqoC+w=; b=r+WzvkZprD89TuTTt6lxiKYyvvKrfVZ6b75nT/BpjKSNmiqvYz0A14n49+J67RpYdw 0OlTtmngNfwqha0vaaEJT5RSSGo5yD4T5p+nXGVYRsb3ZClm4HjCtSFJt+EYVHmMa/oD ETALm2xe75uUWXM+s4lX9xVRW//rwimjIRY9NzESarX2EYPCJhkT9UduuBRSPMvuX3HR l9T/XH2x/4A4QnhOSc/Ot/jh93Qt+G8awJxzp8fkBsKL/rDd8anBf/i/0ktbFdcioNlA rbmGheRVYbHIATnuv28aXWCMly2OutPr+hklnPwqXG7CLGbPXvBKTMMRhYDHgepB7GlP fMYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org; spf=pass (google.com: domain of gcc-patches-return-454242-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-454242-patch=linaro.org@gcc.gnu.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id l70si14626149pfb.415.2017.05.23.06.50.45 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 23 May 2017 06:50:46 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-return-454242-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-454242-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-454242-patch=linaro.org@gcc.gnu.org; dmarc=fail (p=NONE sp=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:from:date:message-id:subject:to:content-type; q= dns; s=default; b=wJDEs9HXTunAeuTPWAaz/p42JSADXKCSvlCxYCpKG5iFKD VXxB8u9o97PNO/xKJxh2JFH8aFmSIc91MppNeVgHhOM6Fq/FhwFqQcK/qhg0fvwJ SaDkRCyuHzVLsBvZhxY2ZuNZDyRUs6ARgf59p+DcsQUKfGXBrN0I+2bHakXEE= 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:from:date:message-id:subject:to:content-type; s= default; bh=iyTQofliQ7ueMV8SGAm/qOzSpfc=; b=SPhm/tmJx8Y65L5E0WND Ok1sW5IiUtArVQOHKI7svp+0Hr+9nw6diipPhBRkN8EkSo8uN/kjprfgHhufsz6w 3uR6lnm95yF0m4A1UONE4tHSp3Dfw1Oz+9N9a7YaIeLpzvnfpM6F/UeXtnIrVkmC sws1d/cBSsB5GsY2zhY5wLA= Received: (qmail 124019 invoked by alias); 23 May 2017 13:50:24 -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 123999 invoked by uid 89); 23 May 2017 13:50:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.0 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, RCVD_IN_SORBS_SPAM, SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:793 X-HELO: mail-io0-f179.google.com Received: from mail-io0-f179.google.com (HELO mail-io0-f179.google.com) (209.85.223.179) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 23 May 2017 13:50:23 +0000 Received: by mail-io0-f179.google.com with SMTP id f102so96949223ioi.2 for ; Tue, 23 May 2017 06:50:26 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=o1+URacSRi+oAOd4+qafzLhLE0X9WrSNOUopxoD/Ib8=; b=nsPzTPthRKueDc1/RTHfLR03sZP3rFeJgly0rcHKm68iZLJzs+bzSMJRlidfPUZBir rR0CVz5k2bpHbGaW3M/JBzfW0HCTens/R2X7oXSSKzcmXyO5SfchNT7eVzrdif4eaxF2 DhcAYtlbAnbYAPP59ugZfP1Yc7A+f5ABcyHKnY7H0CriZXW3n2HzGTHEUmHCVvaO7998 OOxHAbm6ioos4Vkx1cmWFLcV54VVQNAWnQhV8oQzvhi+UuvR5RcaECWb+y0/ND+K81eb ycIcYUcdrVaHVA8ORIN1mdcRQkGCnnOaLs/2b5RWbYJUU2v6cIOoEZDNi4sfz1lPAaJt CWmw== X-Gm-Message-State: AODbwcDWaVPfBinFAH957/OiGcYjvMu5CwBqCb6+kpj2ZgFPZGCMTBHR HJjvxSu4g6QfleMZQipCJtpIZYLqKUy4Aa0= X-Received: by 10.107.161.19 with SMTP id k19mr28148240ioe.204.1495547425037; Tue, 23 May 2017 06:50:25 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.25.5 with HTTP; Tue, 23 May 2017 06:50:24 -0700 (PDT) From: Prathamesh Kulkarni Date: Tue, 23 May 2017 19:20:24 +0530 Message-ID: Subject: remove call to memset in value-prof.c:free_hist() To: Jeff Law , gcc Patches X-IsSubscribed: yes Hi Jeff, As discussed in the other thread, this patch removes dead call to memset in free_hist(). Bootstrap+tested on x86_64-unknown-linux-gnu. Cross-tested on arm*-*-*, aarch64*-*-*. OK for trunk ? Thanks, Prathamesh 2017-05-23 Prathamesh Kulkarni * value-prof.c (free_hist): Remove call to memset and the enclosing if condition. diff --git a/gcc/value-prof.c b/gcc/value-prof.c index 1ce0fda0ed2..7366070d97a 100644 --- a/gcc/value-prof.c +++ b/gcc/value-prof.c @@ -564,8 +564,6 @@ free_hist (void **slot, void *data ATTRIBUTE_UNUSED) { histogram_value hist = *(histogram_value *) slot; free (hist->hvalue.counters); - if (flag_checking) - memset (hist, 0xab, sizeof (*hist)); free (hist); return 1; }