Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] Giving a program priority briefly



On 6/11/07, Darren Cook <darren@example.com> wrote:
> Have you ever heard of lcov or tools like such?
> http://ltp.sourceforge.net/coverage/lcov.php
> When you use that, we know exactly what part of code need to be
> refactored - not by reading the code.

Refactoring is the art of changing the code to make it more
readable/expandable (usually with a future addition in mind, not just
for the sake of itself), without changing functionality. Coverage
doesn't seem to be related (coverage tools are used to see if you have
enough tests).

Darren

I know. You can use lcov to do a coverage test and get a report generated from it. A valuable statistic in lcov report is that you can see what part of the code are executed, and how many times it has been called. For example, you can see a function is called 10000 times and a nested loop is executed 2000 times while another part of code is dead. By rewriting them, we reserve the functionality of the code yet it becomes faster.

--
Best Regards,
Nguyen Hung Vu
vuhung16plus{remove}@example.com
An inquisitive look at Harajuku
http://www.flickr.com/photos/vuhung/sets/72157600109218238/


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links