[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
new GNU project released: complexity 0.4 (GNU Complexity) - Measure comp
From: |
Bruce Korb |
Subject: |
new GNU project released: complexity 0.4 (GNU Complexity) - Measure complexity of C source |
Date: |
Sun, 15 May 2011 12:44:57 -0700 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.17) Gecko/20110414 SUSE/3.1.10 Thunderbird/3.1.10 |
This program does something very similar to pmccabe, but has a slightly
different purpose. pmccabe is appropriate for estimating the effort
required for testing a code base. As a developer, I am a little more
interested in how difficult it might be to comprehend a code base and
figuring out what parts of my code might be harder for others to
understand. Please see the introduction:
http://www.gnu.org/software/complexity/manual/html_node/Introduction.html
The scoring of a procedure is increased linearly by code length and
exponentially by logic nesting depth, and then scaled to approximate
the scores one typically sees from pmccabe output. Pending a lot more
experience, these values are tunable:
http://www.gnu.org/software/complexity/manual/html_node/tuning.html
So I am interested in feedback in order to adjust their defaults
(--nesting-penalty=2.0 --scale=20). The "penalty" value, for example,
may be on the high-ish end, but I doubt it should be below about 1.7
or 1.8. A penalty of 1.0 would turn the program into an approximate
non-comment line/statement counter.
Improvements to the code recognizer (accepting C++ and K&R procedure
headers, for example) would also be nice.
Here is some sample output:
http://www.gnu.org/software/complexity/manual/html_node/Example-Output.html
complexity home: http://www.gnu.org/software/complexity
primary ftp: ftp://ftp.gnu.org/gnu/complexity
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- new GNU project released: complexity 0.4 (GNU Complexity) - Measure complexity of C source,
Bruce Korb <=