From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by sourceware.org (Postfix) with ESMTPS id DBF65385BF99 for ; Thu, 17 Jun 2021 09:39:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org DBF65385BF99 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.cz Received: from imap.suse.de (imap-alt.suse-dmz.suse.de [192.168.254.47]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id DEA691FDC9 for ; Thu, 17 Jun 2021 09:39:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1623922787; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O4Q/Prb3b84VVgNbr/7ejpyRP4bbY39PqGOzEYDVrmM=; b=EZCcDJIF2vytHpSUf/DhTMI99h+8P8uRFS/1zUbukNUA0IVPUHMeD9K+JwI/psgwBrzq65 9jMydAM9ds5VpWQHkG0oYq5fVcXOR+/5XfFF6/g/Ab6I18t4UjwrmHUOWMXilF4/MhFOPX 1zRQErC//oTJ4cUly2bRpS3aGcFzQ8s= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1623922787; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O4Q/Prb3b84VVgNbr/7ejpyRP4bbY39PqGOzEYDVrmM=; b=0DY1oy7ofRNk/4SEparH7SkX4sIUJaM/51pYxMh+JGldpc9Kf9GPynAYGcA5jRimuezNFE LJ+tumONvx75fIAw== Received: from imap3-int (imap-alt.suse-dmz.suse.de [192.168.254.47]) by imap.suse.de (Postfix) with ESMTP id C606F118DD for ; Thu, 17 Jun 2021 09:39:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1623922787; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O4Q/Prb3b84VVgNbr/7ejpyRP4bbY39PqGOzEYDVrmM=; b=EZCcDJIF2vytHpSUf/DhTMI99h+8P8uRFS/1zUbukNUA0IVPUHMeD9K+JwI/psgwBrzq65 9jMydAM9ds5VpWQHkG0oYq5fVcXOR+/5XfFF6/g/Ab6I18t4UjwrmHUOWMXilF4/MhFOPX 1zRQErC//oTJ4cUly2bRpS3aGcFzQ8s= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1623922787; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O4Q/Prb3b84VVgNbr/7ejpyRP4bbY39PqGOzEYDVrmM=; b=0DY1oy7ofRNk/4SEparH7SkX4sIUJaM/51pYxMh+JGldpc9Kf9GPynAYGcA5jRimuezNFE LJ+tumONvx75fIAw== Received: from director2.suse.de ([192.168.254.72]) by imap3-int with ESMTPSA id R6uFL2MYy2AKTAAALh3uQQ (envelope-from ) for ; Thu, 17 Jun 2021 09:39:47 +0000 From: =?UTF-8?Q?Martin_Li=c5=a1ka?= Subject: [PATCH][pushed] gcov: update documentation entry about string format To: gcc-patches@gcc.gnu.org Message-ID: <3e4f2d65-b240-a6ea-0d0f-54551a075225@suse.cz> Date: Thu, 17 Jun 2021 11:39:47 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_NONE, SPF_PASS, 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: Thu, 17 Jun 2021 09:39:50 -0000 gcc/ChangeLog: * gcov-io.h: Update documentation entry about string format. --- gcc/gcov-io.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gcc/gcov-io.h b/gcc/gcov-io.h index f7584eb9679..ff92afe63df 100644 --- a/gcc/gcov-io.h +++ b/gcc/gcov-io.h @@ -42,15 +42,14 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see Numbers are recorded in the 32 bit unsigned binary form of the endianness of the machine generating the file. 64 bit numbers are - stored as two 32 bit numbers, the low part first. Strings are - padded with 1 to 4 NUL bytes, to bring the length up to a multiple - of 4. The number of 4 bytes is stored, followed by the padded + stored as two 32 bit numbers, the low part first. + The number of bytes is stored, followed by the string. Zero length and NULL strings are simply stored as a length of zero (they have no trailing NUL or padding). int32: byte3 byte2 byte1 byte0 | byte0 byte1 byte2 byte3 int64: int32:low int32:high - string: int32:0 | int32:length char* char:0 padding + string: int32:0 | int32:length char* char:0 padding: | char:0 | char:0 char:0 | char:0 char:0 char:0 item: int32 | int64 | string -- 2.32.0