From patchwork Tue May 30 09:41:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Martin_Li=C5=A1ka?= X-Patchwork-Id: 768520 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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3wcTCm1RZBz9ryv for ; Tue, 30 May 2017 19:42:10 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="gJNAXSd7"; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to:cc :from:subject:message-id:date:mime-version:content-type; q=dns; s=default; b=efHFMUNxbndR6ZSuHP2WEa5N+4TBsp2useK6wa2XBbqt3Mn5rz fGJpti2GXwwd9MAOalaCKvsGWWE1m6jlIRK6M1eOmUg+6HXmzcZ375zWU7GoTfsp WN97fyAAlFozcZcnQyddA8cbBL9dXMbIueCN2j1mqEYGlgHJSbWJgNgcg= 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:to:cc :from:subject:message-id:date:mime-version:content-type; s= default; bh=1vS+EXee2I4B8L6jIb0A7iBIJKo=; b=gJNAXSd7rhXbUbHsxgR+ YdLVH49HppF76aArS705vinKyBaV0s3dZ20I50NU1QSLvQDkm5Cvtjq3N5W0WYXr 5aXNJTYF/dzJUVmI42Z9S0WSGw2+wCY8YP2iPsECNcHIPKqJidlqTJhssRdu2Nci 2Os87BKj6oeQkO3xCJO4f3A= Received: (qmail 100673 invoked by alias); 30 May 2017 09:41:47 -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 100658 invoked by uid 89); 30 May 2017 09:41:46 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_PASS autolearn=ham version=3.3.2 spammy=pred 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; Tue, 30 May 2017 09:41:45 +0000 Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id F012AABF0; Tue, 30 May 2017 09:41:46 +0000 (UTC) To: GCC Patches Cc: Nathan Sidwell , Tom de Vries From: =?UTF-8?Q?Martin_Li=c5=a1ka?= Subject: [PATCH] gcov: Add block_info::block_info (PR gcov-profile/80911). Message-ID: <277f98a1-9b9a-00e4-071d-83815dda5058@suse.cz> Date: Tue, 30 May 2017 11:41:45 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 X-IsSubscribed: yes Hello. Following patch adds default constructor that initializes all fields in block_info. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin From b4f7a624b25c7cf3ed3ccc6d59fb68d1dabb2873 Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 29 May 2017 14:00:09 +0200 Subject: [PATCH] gcov: Add block_info::block_info (PR gcov-profile/80911). gcc/ChangeLog: 2017-05-29 Martin Liska PR gcov-profile/80911 * gcov.c (block_info::block_info): New constructor. --- gcc/gcov.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/gcc/gcov.c b/gcc/gcov.c index a5aa4aadcac..e324cadad82 100644 --- a/gcc/gcov.c +++ b/gcc/gcov.c @@ -132,6 +132,9 @@ struct block_location_info typedef struct block_info { + /* Constructor. */ + block_info (); + /* Chain of exit and entry arcs. */ arc_t *succ; arc_t *pred; @@ -173,6 +176,14 @@ typedef struct block_info } block_t; +block_info::block_info (): succ (NULL), pred (NULL), num_succ (0), num_pred (0), + id (0), count (0), count_valid (0), valid_chain (0), invalid_chain (0), + exceptional (0), is_call_site (0), is_call_return (0), is_nonlocal_return (0), + locations (), chain (NULL) +{ + cycle.arc = NULL; +} + /* Describes a single function. Contains an array of basic blocks. */ typedef struct function_info -- 2.12.2