[GRASS-QA] GRASS QA: mmetz |spindex_rw.c spindex.c | 12 clones | 2
monsters |8 warnings
soccerlab.info at gmail.com
soccerlab.info at gmail.com
Tue Jan 4 05:13:11 EST 2011
Hello mmetz,
here's a report on your recent grass-SVN change for the revision : 44857
ANALYSIS
your changes to files/class/methods/functions :
*****************************************************************
File :/lib/vector/diglib/spindex_rw.c
*****************************************************************
Class
spidxstack(Begins at: 593, Ends at:598)
+--------+--------+--------+--------+--------+--------+
| DIT | NOC | WMC | RFC | CBO | LCOM |
+------------+--------+--------+--------+--------+--------+--------|
|NEW Metrics | 1 | 0 | 0 | 0 | 0 | 0 |
+------------+--------+--------+--------+--------+--------+--------|
|OLD Metrics | | | | | | |
+------------+--------+--------+--------+--------+--------+--------+
Function
rtree_write_from_memory(Begins at: 586, Ends at:675)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 11 | * | WARNING | 11 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 6 | | OK | 6 |
LOC: | 90 | * | WARNING | 90 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 3 values are close to an outlier please consider revising code!
rtree_write_to_sidx(Begins at: 786, Ends at:793)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 2 | | OK | 2 |
LOC: | 8 | | OK | 8 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
rtree_load_from_sidx(Begins at: 1047, Ends at:1054)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 2 | | OK | 2 |
LOC: | 8 | | OK | 8 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
rtree_load_to_memory(Begins at: 807, Ends at:918)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 14 | * | WARNING | 14 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 12 | | OK | 12 |
LOC: | 112 | * | WARNING | 112 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 3 values are close to an outlier please consider revising code!
dig_Rd_spidx(Begins at: 1114, Ends at:1148)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 1 | | OK | 1 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 10 | | OK | 10 |
LOC: | 35 | | OK | 35 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
rtree_search(Begins at: 1188, Ends at:1289)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 14 | * | WARNING | 14 |
ParamNBR: | 5 | * | WARNING | 5 |
CalledNBR: | 16 | | OK | 16 |
LOC: | 102 | * | WARNING | 102 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 3 values are close to an outlier please consider revising code!
rtree_write_from_file(Begins at: 691, Ends at:783)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 11 | * | WARNING | 11 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 10 | | OK | 10 |
LOC: | 93 | * | WARNING | 93 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 3 values are close to an outlier please consider revising code!
rtree_load_to_file(Begins at: 932, Ends at:1045)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 14 | * | WARNING | 14 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 13 | | OK | 13 |
LOC: | 114 | * | WARNING | 114 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 3 values are close to an outlier please consider revising code!
dig_Wr_spidx_head(Begins at: 36, Ends at:235)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 40 | *** | MONSTER | 40 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 38 | * | WARNING | 38 |
LOC: | 200 | ** | BABY-MONSTER | 200 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a MONSTER |
-----------------------------------------------------------+
metric are OUT OF RANGE!
dig_Wr_spidx(Begins at: 1064, Ends at:1103)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 1 | | OK | 1 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 15 | | OK | 15 |
LOC: | 40 | | OK | 40 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
dig_Rd_spidx_head(Begins at: 246, Ends at:480)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 35 | *** | MONSTER | 35 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 46 | ** | BABY-MONSTER | 46 |
LOC: | 235 | *** | MONSTER | 235 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a MONSTER |
-----------------------------------------------------------+
metric are OUT OF RANGE!
Clone analysis:
This file does not contain cloned functions
*****************************************************************
File :/lib/vector/diglib/spindex.c
*****************************************************************
Function
dig_spidx_init(Begins at: 36, Ends at:92)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 20 | * | WARNING | 20 |
LOC: | 57 | | OK | 57 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
dig_spidx_free_isles(Begins at: 186, Ends at:208)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 8 | | OK | 8 |
LOC: | 23 | | OK | 23 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
dig_spidx_free_nodes(Begins at: 99, Ends at:121)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 8 | | OK | 8 |
LOC: | 23 | | OK | 23 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
dig_spidx_free_lines(Begins at: 128, Ends at:150)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 8 | | OK | 8 |
LOC: | 23 | | OK | 23 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
dig_spidx_free(Begins at: 215, Ends at:241)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 5 | | OK | 5 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 8 | | OK | 8 |
LOC: | 27 | | OK | 27 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
dig_spidx_free_areas(Begins at: 157, Ends at:179)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 8 | | OK | 8 |
LOC: | 23 | | OK | 23 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
Clone analysis:
This file has 12 potentially cloned functions:
dig_spidx_free_lines dig_spidx_free_areas dig_spidx_free_lines dig_spidx_free_areas dig_spidx_free_isles dig_spidx_free_nodes dig_spidx_free_areas dig_spidx_free_isles dig_spidx_free_nodes dig_spidx_free_lines dig_spidx_free_isles
In /data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c clones of dig_spidx_free_isles are:
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_nodes
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_lines
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_areas
In /data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c clones of dig_spidx_free_nodes are:
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_lines
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_areas
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_isles
In /data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c clones of dig_spidx_free_lines are:
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_nodes
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_areas
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_isles
In /data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c clones of dig_spidx_free_areas are:
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_nodes
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_lines
/data/project-manager/grass/grassSVN/grass/trunk/lib/vector/diglib/spindex.c dig_spidx_free_isles
____________________________________________
Threshold grass key metrics values at Tue Jan 04 05:13:08 EST 2011 are:
----------------------+-----------+-----------+-----------+
| warning | middle | extrem |
| limits | limits | limits |
----------------------+-----------+-----------+-----------+
Complexity (Cyclo): | 9 | 21 | 33 |
ParamNBR: | 3 | 6 | 9 |
CalledNBR: | 17 | 41 | 65 |
LOC: | 65 | 147 | 230 |
----------------------+-----------+-----------+-----------+
Measures (see below Web page for details) :
-Complexity (Cyclo): a complexity index
-ParamNBR: number of passed parameters
-CalledNBR: number of called functions
-LOC: Lines Of Code
-Global analysis: based on 21 metrics(the fourth preceding include)
Message interpretation :
OK : Nothing to say at all
* : this is getting close to be out of range, consider revising the code
** : this is a baby monster, you should revise this function
***: this is a monster, definitely you should revise this function
Conclusion interpretation :
CORRECT : if all metrics are situated before warning limits
WARNING : if 1 to more metrics are between warning and middle limits
BABY_MONSTER: if 1 to more metrics are between middle and extreme limits
MONSTERS : if 1 to more metrics are in the extreme limits
_______________________________________________
Brought to you by :
SOftware Cost-effective Change and Evolution Research (SOCCER) laboratory
Please visite our web site on your project at :
http://web.soccerlab.polymtl.ca/project-manager/grass-website/index.html
More information about the grass-qa
mailing list