<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p><br>
</p>
<div class="moz-cite-prefix">On 1/24/19 9:33 AM, Jiri Gaisler wrote:<br>
</div>
<blockquote type="cite"
cite="mid:f85198ed-cccb-7675-f33b-119f69b56906@gaisler.se">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<br>
<div class="moz-cite-prefix">On 1/24/19 12:45 AM, Joel Sherrill
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAF9ehCXt3O8pV+u72Qf_DoOVJz9z7rZPmOxFWrehudrNWjdvTQ@mail.gmail.com">
<meta http-equiv="content-type" content="text/html;
charset=UTF-8">
<div dir="ltr">
<div dir="ltr"><br>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Wed, Jan 23, 2019 at
4:45 PM Chris Johns <<a href="mailto:chrisj@rtems.org"
moz-do-not-send="true">chrisj@rtems.org</a>> wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px
0px
 0.8ex;border-left:1px solid

rgb(204,204,204);padding-left:1ex">On 24/1/19 9:12 am,
Jiri Gaisler wrote:<br>
> After some trial and error, I got covoar to run with:<br>
<br>
Great.<br>
<br>
> However, the coverage is always 0% in the summary
report:<br>
<br>
Does adding -v to the command line provide any more
detail? Repeating -v<br>
increases the level but things can become rather verbose
and if you trip full<br>
DWARF tracing there is a lot of output.<br>
</blockquote>
<div><br>
</div>
<div>I would be suspicious of the code that is invoked
around</div>
<div>CoverageReaderTSIM.cc:83 as a starting point. For some
method you</div>
<div>know you should be analyzed, there should be
aCoverageMap. Since you</div>
<div>are looking at only one executable, you could hard-code
a test with</div>
<div>address range of a single method under test to see what
happens.</div>
<br>
</div>
</div>
</blockquote>
<br>
<p>Well, the problem is that covoar in rtems-tools is hard-coded
to use the QEMU format, and the -f switch to change format is
not used. I have attached a patch to fix that. After that,
covoar works fine with the coverage data from sis:</p>
<p>cat coverage/summary.txt <br>
Bytes Analyzed : 20034<br>
Bytes Not Executed : 11734<br>
Percentage Executed : 41.43<br>
Percentage Not Executed : 58.57<br>
Uncovered ranges found : 242<br>
Total branches found : 443<br>
Uncovered branches found : 167<br>
68 branches always taken<br>
99 branches never taken</p>
<p>If you approve to the patch, then I will check it in (now that
I know how ... :-))<br>
</p>
</blockquote>
<p>Here is a better patch that maintains the old behavior of QEMU as
default, while honoring the -f switch if provided.</p>
<p>Jiri.<br>
</p>
</body>
</html>