Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner

Code Coverage Features

I am using code coverage on several tests and when I run the tool certain blocks are highlighted as uncovered but those blocks correspond to debugging. Is there a way I can program or manipulate the tool to ignore certain blocks/if statements instead of picking them up?

Thanks in advance

0 Kudos
5 Replies
Highlighted

The techniques for doing this

The techniques for doing this are described in the Code Coverage tool documentation. There are multiple options with granularity as fine as you want.

Retired 12/31/2016
0 Kudos
Highlighted
Beginner

I see, thank you for

I see, thank you for reminding me about the documentation.

Where exactly do I type those options about excluding code in, i.e -beginblkdsbl and -endblkdsbl?. Will it be in the source code? 

Thanks Steve

 

0 Kudos
Highlighted

Tools > Intel Compiler > Code

Tools > Intel Compiler > Code Coverage... > Generate Report > Settings > codecov options > Additional options

Retired 12/31/2016
0 Kudos
Highlighted
Beginner

So does the exclusion of

So does the exclusion of certain functions only occur if they are within a comment?

0 Kudos
Highlighted

I don't quite understand your

I don't quite understand your question. There are multiple ways of excluding portions of code. You can bracket sections with "begin and end" comments, you can add a comment on a particular line, you can exclude whole source files. A function cannot be "within a comment". I don' profess to be an expert in the code coverage tool, but I thought the documentation's examples were clear. Perhaps you could show an example of what you'd like to do if you're still uncertain.

Retired 12/31/2016
0 Kudos