Skip to main content



      Home
Home » Eclipse Projects » Linux Tools Project » Reading gcda files
Reading gcda files [message #1734427] Wed, 08 June 2016 06:53 Go to next message
Eclipse UserFriend
Hi!

We get errors when reading gcda files and I tried to compare the parser in the plugin with the one in gcov and I found a possible discrepancy. I hope someone can tell me if it is an error or if I misunderstand.

Can a GCOV_TAG_FUNCTION can be followed by several GCOV_TAG_COUNTERs? It looks like it can from reading the gcov_io.h code and from the data files we get, but the plugin parser resets the currentFunction after the first counter tag (around line 200).

Is it a bug?

best regards,
Vlad
Re: Reading gcda files [message #1737120 is a reply to message #1734427] Tue, 05 July 2016 17:56 Go to previous messageGo to next message
Eclipse UserFriend
My local gcov-io.h has the following for the data file:

function-data: announce_function present counts
counts: header int64:count*

To me, this implies one header for all the counts for the function and thus, one tag.

Are you seeing multiple 0x01a10000 tags?
Re: Reading gcda files [message #1737154 is a reply to message #1737120] Wed, 06 July 2016 03:31 Go to previous messageGo to next message
Eclipse UserFriend
Hi Jeff, good question!

I have found the gcov-dump utility and it displays different values from what I see the plugin parser outputs. As you can see, the end of the file seems garbled. Other files are OK.

gcov-dump:
01000000:   3:FUNCTION ident=991, lineno_checksum=0xa6b28208, cfg_checksum=0xa43083b8
  01a10000:   2:COUNTERS arcs 1 counts
		0 0
01000000:   3:FUNCTION ident=990, lineno_checksum=0xd2457348, cfg_checksum=0xa43083b8
  01a10000:   2:COUNTERS arcs 1 counts
		0 0


plugin parser:
TAG === 1000000
  LENGTH=3 (3
FNCTN=991
TAG === 1a10000
  LENGTH=2 (2
ARCS
TAG === 1000000
  LENGTH=3 (3
FNCTN=990
TAG === 1a10000
  LENGTH=2 (2
ARCS
TAG === 0
TAG === 1000000
  LENGTH=3 (3
FNCTN=990
TAG === 1a10000
  LENGTH=2 (2
ARCS
TAG === 0
TAG === a43083b8
  LENGTH=27328512 (1a10000
BAD gcda tag: a43083b8
TAG === 2
  LENGTH=0 (0
BAD gcda tag: 2
TAG === 0
TAG === 1000000
  LENGTH=3 (3
FNCTN=990
TAG === 1a10000
  LENGTH=2 (2
ARCS
TAG === 0
TAG === 1a10000
  LENGTH=2 (2
ARCS
ERROR
Re: Reading gcda files [message #1737158 is a reply to message #1737154] Wed, 06 July 2016 03:46 Go to previous message
Eclipse UserFriend
The corresponding end of the gcda file looks like this from hexdump: (990 is 0x3de)

00022c0                    0000    0100    0003    0000    03df    0000
00022d0    8208    a6b2    83b8    a430    0000    01a1    0002    0000
00022e0    0000    0000    0000    0000    0000    0100    0003    0000
00022f0    03de    0000    7348    d245    83b8    a430    0000    01a1
0002300    0002    0000    0000    0000    0000    0000    0000    0000
0002310    0000    0100    0003    0000    03de    0000    7348    d245
0002320    83b8    a430    0000    01a1    0002    0000    0000    0000
0002330    0000    0000    0000    0000    83b8    a430    0000    01a1
0002340    0002    0000    0000    0000    0000    0000    0000    0100
0002350    0003    0000    03de    0000    7348    d245    83b8    a430
0002360    0000    01a1    0002    0000    0000    0000    0000    0000
0002370    0000    0000    0000    01a1    0002    0000    0000    0000
0002380    0000    0000    0000    0000    0000    01a1    0002    0000
0002390    0000    0000    0000    0000    0000    0000                
Previous Topic:gprof view show no data on MingW/Windows
Next Topic:Gprof reader fails on Power 8 little endian system
Goto Forum:
  


Current Time: Sat Jul 12 14:42:31 EDT 2025

Powered by FUDForum. Page generated in 0.04354 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top