473,587 Members | 2,527 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Code coverage tool for C

Can anybody show me a list of such tools so that I can pick up the tools
match my requirement.
Mar 5 '07 #1
7 2808
On Mon, 5 Mar 2007 10:30:03 +0800, "Kai Zhu" <cs***@hotmail. comwrote
in comp.lang.c:
Can anybody show me a list of such tools so that I can pick up the tools
match my requirement.
There are no such tools defined by the C language, which means that
the question is not really topical here.

I would suggest you try news:comp.softw are-eng, or a Google search.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://c-faq.com/
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.l earn.c-c++
http://www.contrib.andrew.cmu.edu/~a...FAQ-acllc.html
Mar 5 '07 #2
Kai Zhu <cs***@hotmail. comwrote:
Can anybody show me a list of such tools so that I can pick up the tools
match my requirement.
gcc has options to instrument the code and generate
line-by-line execution counts.

If anyone knows the Windows equivalent, I'd like
to hear it.

--
pa at panix dot com
Mar 5 '07 #3
Pierre Asselin wrote, On 05/03/07 15:05:
Kai Zhu <cs***@hotmail. comwrote:
>Can anybody show me a list of such tools so that I can pick up the tools
match my requirement.

gcc has options to instrument the code and generate
line-by-line execution counts.

If anyone knows the Windows equivalent, I'd like
to hear it.
Well, you could try gcc...

Specific tools are off topic here, but the gcc suggestion was not a joke.
--
Flash Gordon
Mar 5 '07 #4
On Mar 5, 7:05 am, p...@see.signat ure.invalid (Pierre Asselin) wrote:
Kai Zhu <c...@hotmail.c omwrote:
Can anybody show me a list of such tools so that I can pick up the tools
match my requirement.

gcc has options to instrument the code and generate
line-by-line execution counts.

If anyone knows the Windows equivalent, I'd like
to hear it.
I get 426000 hits for this query:
http://www.google.com/search?client=...=Google+Search

Mar 5 '07 #5
Pierre Asselin wrote:
Kai Zhu <cs***@hotmail. comwrote:
>Can anybody show me a list of such tools so that I can pick up
the tools match my requirement.

gcc has options to instrument the code and generate
line-by-line execution counts.

If anyone knows the Windows equivalent, I'd like to hear it.
Just use gcc with the -pg operion and gprof for analysis. DJGPP,
MingW, and Cygwin will run gcc on winblows.

--
<http://www.cs.auckland .ac.nz/~pgut001/pubs/vista_cost.txt>
<http://www.securityfoc us.com/columnists/423>

"A man who is right every time is not likely to do very much."
-- Francis Crick, co-discover of DNA
"There is nothing more amazing than stupidity in action."
-- Thomas Matthews

Mar 6 '07 #6
CBFalconer <cb********@yah oo.comwrote:
Just use gcc with the -pg operion and gprof for analysis. DJGPP,
MingW, and Cygwin will run gcc on winblows.
That's for profiling, not code coverage. The gcc options
for code coverage are -fprofile-arcs -ftest-coverage .
Then you use the gcov utility to analyze the results.
--
pa at panix dot com
Mar 6 '07 #7
Pierre Asselin wrote:
CBFalconer <cb********@yah oo.comwrote:
>Just use gcc with the -pg operion and gprof for analysis. DJGPP,
MingW, and Cygwin will run gcc on winblows.

That's for profiling, not code coverage. The gcc options
for code coverage are -fprofile-arcs -ftest-coverage .
Then you use the gcov utility to analyze the results.
You're right. Thanks for the correction.

--
<http://www.cs.auckland .ac.nz/~pgut001/pubs/vista_cost.txt>
<http://www.securityfoc us.com/columnists/423>

"A man who is right every time is not likely to do very much."
-- Francis Crick, co-discover of DNA
"There is nothing more amazing than stupidity in action."
-- Thomas Matthews
Mar 6 '07 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
2775
by: John J. Lee | last post by:
Anybody know of one? Actually, I have a feeling that emacs understands a standard format for errors, which would make it really easy to implement this by having the coverage tool print results in that format -- anybody know where to find the details? I also wonder if some kind of graphical display might be useful somehow, having been...
6
2363
by: tjm | last post by:
Pure coverage from Rational is the only coverage tool I've been able to find for C#, and I don't really want to pay what Rational charges for something as simple as a coverage tool. So, I'd like to try to write my own, but I'm having trouble getting started. The way I see it, I need to do the following… 1) Create a debugger object or...
4
2323
by: O. Zimmermann | last post by:
Hello, I am looking for a tool to process torough UNIT and COVERAGE testing over 60 and more functions of a "critical" embedded application written in C. I found IPL's Cantata++ but we don't seem to really need all the power of this software. I think some other tool out there could provide me with the basic testing I want with less...
5
4865
by: Nikhil | last post by:
Hi, I have a set of C source files and I need a tool which can add probes and then dynamically trace the execution and print the results (The C source code does not have any printf statements). The purpose of the tool is to add test cases for unit testing and then see the statement/branch coverage for them. Thanks,
0
1006
by: alan.lemon | last post by:
I currently use CxxTest as my unit testing framework for C++. It has really worked well to meet my needs. Does anyone know of a good _free_ coverage analysis tool? If this is the wrong place to post this question my apologies in advance.
1
2026
by: =?UTF-8?B?TWFydGluIFDDtnBwaW5n?= | last post by:
Hello, I am searching for a good profiling tool for C# which can be easily embedded into Visual Studio. My objective is to measure the times and counts of every method in my program. If used the Coverage Tool of TestDriven.Net (http://www.testdriven.net/) which worked fine if I have defined any Unit test-cases.
1
1216
by: Steven W. Orr | last post by:
Lots of code, calls to, calls by, inheritance, multiple tasks, etc. What do people use to figure out what's happening? TIA -- Time flies like the wind. Fruit flies like a banana. Stranger things have .0. happened but none stranger than this. Does your driver's license say Organ ..0 Donor?Black holes are where God divided by zero....
5
4274
by: ev | last post by:
Hello, We are looking for any testing tool that is capable of checking code coverage for C,C ++ and Java code. Or at least for C and C++. We want to know how much (percentage) of our code written on C/C++ is covered in terms of function calls and line calls. We tried Rational PureCoverage. It's excellent but has some limitations in our case....
24
2506
by: David | last post by:
Hi list. What strategies do you use to ensure correctness of new code? Specifically, if you've just written 100 new lines of Python code, then: 1) How do you test the new code? 2) How do you ensure that the code will work correctly in the future? Short version:
0
8215
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8347
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7973
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
8220
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6626
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
3844
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
2358
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1454
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1189
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.