[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ltp-coverage
Subject:    Re: [Ltp-coverage] Inferring HTML Report
From:       Peter Oberparleiter <oberpar () linux ! vnet ! ibm ! com>
Date:       2012-01-08 20:39:57
Message-ID: 4F09FF1D.2010308 () linux ! vnet ! ibm ! com
[Download RAW message or body]

Hi,

On 23.12.2011 11:28, Dhruva Bharadwaj wrote:
> Im having trouble inferring the HTML report generated using lcov for several  .C / \
> .h files which are compiled using the make utility. 
> 
> 1.       What does a + or - in branch data represent?

See
http://sourceforge.net/mailarchive/message.php?msg_id=25752946
and
http://sourceforge.net/mailarchive/message.php?msg_id=26711956

> 
> I have been working under the assumption:
> 
> [- +] : means yes condition not evaluated and no condition evaluated.
> 
> The branch coverage formula im assuming = no. of '+' present in file / no. of '+', \
> '-' or '#' present. 
> However, I have several [- +],[# #] , etc for each decision point and the branch \
> coverage calculation for [+ -] and [- +] would come to 50% even though both the \
> conditions have been covered (100%).

Note that each [] represents a basic block and each -/+/# is a branch. 
To reach 100% branch coverage, all basic blocks must be +.

> 2.       Also, some functions are showing 0 hits, even while the line data for it \
> shows hits. 
> Please clarify the above.

I'm assuming that this is due to gcov input data. You can see what gcov 
reports regarding function coverage by using gcov -b <filename.c>. 
Sometimes it helps to turn of gcc optimization. Also have a look at 
lcov's --derive-func-data option to see if it helps.


Regards,
   Peter Oberparleiter


------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
Ltp-coverage mailing list
Ltp-coverage@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-coverage


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic