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

List:       ltp-coverage
Subject:    Re: [Ltp-coverage] Facing difficulties for code coverage related project
From:       Peter Oberparleiter <oberpar () linux ! vnet ! ibm ! com>
Date:       2017-02-06 7:55:29
Message-ID: 35e2e939-9a6a-8415-326e-f6d4bd1b58f4 () linux ! vnet ! ibm ! com
[Download RAW message or body]

On 04.02.2017 10:47, Apoorva Ambesange wrote:
> Now i have another folder(pqr , located elsewhere in other folder ) that
> contains a list of test suite for the particular XXX driver. When i build
> the test suite and run the binary ,the .gcda files are not getting created
> ,neither in the the source folder(where the .gcno & obj files are created )
> nor in the test suite folder !

If you see the .gcno files for the test suite programs, then your
compilation step seems correct. My guess would be that either your test
program doesn't exit normally (if interrupted by a signal, no coverage
data files will be created), or that they are created, but in a
different location.

> I have included CFLAGS += --coverage and LDFLAGS += --coverage  flages in
> both the make files of the driver and the test suite.
> I request you to please guide me !

Some thoughts:
1. Ensure that your test program terminates normally (i.e. using exit())
2. Check for the target location of the .gcda files (use a command like
"strings <progname> | grep gcda")

If that doesn't help, try starting with a simple hello-world type
program and try to get coverage data for that. If that works, build from
there to see where your test suite setup differs.


Regards,
  Peter Oberparleiter

-- 
Peter Oberparleiter
Linux on z Systems Development - IBM Germany


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
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