public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Sebastian Huber <sebastian.huber@embedded-brains.de>
To: "Martin Liška" <mliska@suse.cz>, gcc-patches@gcc.gnu.org
Subject: Re: [PATCH] gcov-tool: Allow merging of empty profile lists
Date: Thu, 24 Mar 2022 11:51:59 +0100	[thread overview]
Message-ID: <262bfcbc-dfd7-722f-e06a-b7fb7dbbe977@embedded-brains.de> (raw)
In-Reply-To: <930c7bec-aea5-9491-94cd-a4e8c86f9bfe@suse.cz>

On 24/03/2022 11:29, Martin Liška wrote:
> On 3/23/22 15:50, Sebastian Huber wrote:
>> The attached script reads the log file and creates the *.gcda files 
>> using gcov-tool. Initially, the target files do not exist.
> 
> Now I've got your use-case and I like it. It's cool one can utilize GCOV 
> even without a filesystem.

Yes, it basically works quite well. I try to make it a bit easier to 
use. What seems to be quite common is that tests for embedded systems 
report their test data through an in order character stream, for example 
through an UART device. I used this primitive encoding of the gcov 
information:

*** BEGIN OF GCOV INFO ***

/home/EB/sebastian_h/src/lwip/b-xilinx_zynq_a9_qemu/init.gcda
YWRjZ1IzMEKtLjW3AAAAAQMAAADcaps855EX05p4KUUAAKEBOgAAAAEAAAAAAAAAAQAAAAAAAAAB
AAAAAAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEA
AAAAAAAAAQAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAQAA
AAAAAAABAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAABAwAAACXn3k16
TDqmuIMwpAAAoQECAAAAAgAAAAAAAAAAAAABAwAAADzkvDcfSnvcuIMwpAAAoQH+////AAAAAQMA
AACnWNZaIM7GWZ9hiOIAAKEBBAAAAAEAAAAAAAAAAAAAAAAAAAAAAAABAwAAAPkGW3YHFUOO6Old
2wAAoQECAAAAAQAAAAAAAAAAAAABAwAAAIvy4CE9FxuM6Old2wAAoQECAAAAAQAAAAAAAAAAAAAB
AwAAANyvBDZiERlQ6Old2wAAoQECAAAAAQAAAAAAAAAAAAABAwAAACKQjCp2pYlIuIMwpAAAoQEC
AAAAAQAAAAAAAAAAAAABAwAAAKSSXEjQFDluuIMwpAAAoQH+////AAAAAA==

/home/EB/sebastian_h/src/lwip/b-xilinx_zynq_a9_qemu/src/netif/ethernet.gcda
YWRjZ1IzMEIwMjW3AAAAAQMAAAC+EBQuXa7stuNAYTkAAKEBCgAAAAEAAAAAAAAAAQAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAABAwAAAAQbGWmmhbpBJ5lR8AAAoQEmAAAAAQAAAAAA
AAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

...

*** END OF GCOV INFO ***

Maybe we could add the file path into the gcov information stream using 
a new tag:

#define GCOV_TAG_GCDA_FILE_NAME  ((gcov_unsigned_t)0xa5000000)

Then the complete gcov information can be dumped using a single base64 
encoded stream. We could add some support to the gcov-tool to read this 
stream and merge it into gcda files.

-- 
embedded brains GmbH
Herr Sebastian HUBER
Dornierstr. 4
82178 Puchheim
Germany
email: sebastian.huber@embedded-brains.de
phone: +49-89-18 94 741 - 16
fax:   +49-89-18 94 741 - 08

Registergericht: Amtsgericht München
Registernummer: HRB 157899
Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
Unsere Datenschutzerklärung finden Sie hier:
https://embedded-brains.de/datenschutzerklaerung/

  reply	other threads:[~2022-03-24 10:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-23  9:34 Sebastian Huber
2022-03-23 12:19 ` Martin Liška
2022-03-23 14:50   ` Sebastian Huber
2022-03-24 10:29     ` Martin Liška
2022-03-24 10:51       ` Sebastian Huber [this message]
2022-03-24 12:03         ` Martin Liška
2022-03-28 16:23           ` Sebastian Huber
2022-03-30 11:56             ` Martin Liška
2022-03-30 13:30               ` Sebastian Huber
2022-03-30 14:48                 ` Sebastian Huber
2022-03-31  6:58                   ` Martin Liška

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=262bfcbc-dfd7-722f-e06a-b7fb7dbbe977@embedded-brains.de \
    --to=sebastian.huber@embedded-brains.de \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=mliska@suse.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).