TrueCoverage Driver Edition and non-paged code

Hi,

While analyzing a session recorded by Compuware’s TrueCoverage for drivers I
noticed that invoke counter for all of the functions I marked as non-paged
(with #pragma code_seg()) was 0. Now, I am sure that some of these functions
were invoked. I couldn’t find any non-paged function with a non-zero counter
or paged functions that had zero in the counter although I am sure they were
invoked.

Is it possible that TrueCoverage has a problem with intercepting calls to
non-paged functions?

Thanks,

Shahar

I would say down-right ABSURD !.

you have to figureout, why it is happening. THIS WAS MY ATOMIC-BOMB to trap
fats and facies in kernel modules provided by others …

Get the help from Compuware.

-pro
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of Shahar Talmi
Sent: Wednesday, September 22, 2004 9:59 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] TrueCoverage Driver Edition and non-paged code

Hi,

While analyzing a session recorded by Compuware’s TrueCoverage for drivers
I noticed that invoke counter for all of the functions I marked as non-paged
(with #pragma code_seg()) was 0. Now, I am sure that some of these functions
were invoked. I couldn’t find any non-paged function with a non-zero counter
or paged functions that had zero in the counter although I am sure they were
invoked.

Is it possible that TrueCoverage has a problem with intercepting calls to
non-paged functions?

Thanks,

Shahar


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com

To be truthful I didn’t really understand what you were saying, but I guess
it’s just my flawed English to blame.

Anyway, after a bit of Google-ing I finally gave up and moved to using
BullseyeCoverage which is the only alternative I could find that will work
with kernel-mode drivers.

It took me some time to get BullseyeCoverage working since, unlike
TrueCoverage, I needed to compile my driver with the Bullseye compiler,
which is sadly a little buggy and didn’t work well with the WPP macros in my
code (the bug report is attached, for those of you who are interested).

BullseyeCoverage has no problem with non-paged code but it has some other
minor problems (the code viewer sometimes mismatches with the coverage
indications, there is no counter for function entries - just an indication
whether it was invoked and the coverage details, but no invocation counter),
but in the overall these are much less disturbing from the TrueCoverage
problem.

If someone know a way to fix this TrueCoverage problem please contact me, I
like its interface much more and the special compiling for BullseyeCoverage
is very limiting.

Thanks,

Shahar


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Prokash Sinha
Sent: Wednesday, September 22, 2004 7:17 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] TrueCoverage Driver Edition and non-paged code

I would say down-right ABSURD !.

you have to figureout, why it is happening. THIS WAS MY ATOMIC-BOMB to trap
fats and facies in kernel modules provided by others …

Get the help from Compuware.

-pro

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of Shahar Talmi
Sent: Wednesday, September 22, 2004 9:59 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] TrueCoverage Driver Edition and non-paged code

Hi,

While analyzing a session recorded by Compuware’s TrueCoverage for drivers I
noticed that invoke counter for all of the functions I marked as non-paged
(with #pragma code_seg()) was 0. Now, I am sure that some of these functions
were invoked. I couldn’t find any non-paged function with a non-zero counter
or paged functions that had zero in the counter although I am sure they were
invoked.

Is it possible that TrueCoverage has a problem with intercepting calls to
non-paged functions?

Thanks,

Shahar


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com

The BullseyeCoverage bug report, if it is of any interest.

-----Original Message-----
From: Shahar Talmi [mailto:xxxxx@safend.com]
Sent: Thursday, September 23, 2004 12:33 PM
To: ‘Steve Cornett’
Subject: RE: BullseyeCoverage Evaluation Request

Hi Steve,
I tried using your product to test the software I’m working on but I
couldn’t get the Bulls-eye Compiler to compile my code. After some further
investigation I’ve found the piece of code that your compiler cannot compile
although it is completely legal. Here it is:

#define BC
#define E(val) val
#define A E(B) ## C

void main()
{
A;
}

In this simple code segment “A” translates into “E(B) ## C” which translates
to “B ## C” which translates to “BC” which translates to “”, which is
completely legal but your compiler gives me the following errors:

bull.cpp(7) : error C2065: ‘B’ : undeclared identifier
bull.cpp(7) : error C2146: syntax error : missing ‘;’ before identifier ‘C’
bull.cpp(7) : error C2065: ‘C’ : undeclared identifier

Apparently something in the preprocessor went wrong and the code translated
this way: “A” -> “E(B) ## C” -> “B C” -> compilation error, B and C are
separated by a space.

The weirdest thing is that when I tried to run “cl bull.cpp /EP” in order to
see the code that your preprocessor produced I got:

void main()
{
;
}

Which is correct(!) Is it possible that your compiler uses the preprocessor
in a different way that makes it produce the erroneous code?

The following piece of code compiles correctly (that might help you to find
the problem, notice that I wrote B instead of E(B)):

#define BC
#define E(val) val
#define A B ## C

void main()
{
A;
}

The code in my program that causes this problem is auto-generated by a
Microsoft pre-processor named WPP. This code is a must-have in my software
and I cannot change it - so this means I cannot use your software to test my
code until this problem is fixed.

For the meantime I have solved this problem by first running the
preprocessor on the files and then compiling the produced files (and then
overwriting the files I compiled with the originals so I will be able to
browse the sources in the Coverage Browser), but this is highly inefficient
and consumes too much time for me each time I need to re-compile the
program.

Thanks for your help,
Shahar

-----Original Message-----
From: Steve Cornett [mailto:xxxxx@bullseye.com]
Sent: Wednesday, September 22, 2004 9:30 PM
To: xxxxx@safend.com
Subject: RE: BullseyeCoverage Evaluation Request

Here is your 30-day evaluation license of BullseyeCoverage. You can
download the software from http://www.bullseye.com/download/. Your license
key is ########################. This license key works for all the
platforms you requested.

BullseyeCoverage is sold on a floating license basis - any number of users
may use a single license, but only one at a time. Pricing and purchasing
information is at http://www.bullseye.com/cgi-bin/store. All prices include
technical support. Prices are discounted for more than 5 users and volume
licensing is available for 20+ users.

Let me know of any questions or comments.

Sincerely,
Steve Cornett

Sorry for not being able to attach your response !

I did not try the other product you mentioned Blue*…

TrueCoverage from compuware is a good code coverage product. I used it in the past for 3 different driver(s), and soon I would have to use for may be another two drivers…

What I meant by ABSURD is that lot of driver(s) even dont care to have pageable code(routine) even if they perfectly belong to that category, so statistically most of 3rd party ( non-ms ) driver I have seen are mostly non-paged cost mostly, and Turecoverage being a code coverage software could not just afford to make that silly mistake … SO YOU WILL HAVE TO FIGUREOUT WHY IT IS HAPPENING OR GET THE HELP FROM COMPUWARE OR WHEREVER DEEM FIT FOR YOU …

I personally liked it a lot, and sure I would not do a favor to Alberto :). He does not need one !

-pro