Linux / Mm
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 4,618 units with 76,675 lines of code in units (74.6% of code).
    • 1 very complex units (233 lines of code)
    • 37 complex units (4,431 lines of code)
    • 275 medium complex units (15,832 lines of code)
    • 558 simple units (16,842 lines of code)
    • 3,747 very simple units (39,337 lines of code)
<1% | 5% | 20% | 21% | 51%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
c<1% | 5% | 20% | 22% | 50%
h0% | 0% | 0% | 11% | 88%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
ROOT<1% | 6% | 21% | 21% | 50%
damon0% | 0% | 13% | 21% | 64%
kfence0% | 0% | 42% | 11% | 46%
kasan0% | 0% | 1% | 34% | 63%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
233 90 5
162 50 6
246 48 5
113 46 8
167 45 8
103 45 7
160 44 4
167 41 1
187 41 2
99 36 6
101 35 9
112 35 1
100 35 9
124 34 4
135 33 4
103 33 4
138 32 4
103 32 2
156 32 8
91 31 2
137 30 4
75 30 5
99 30 7
102 30 3
111 29 4
111 29 6
121 29 2
81 29 2
113 29 4
113 29 7
127 28 7
104 28 3
122 28 2
94 28 6
98 27 4
93 27 4
75 26 3
88 26 4
124 25 7
80 25 6
67 24 4
84 24 8
114 24 4
114 24 7
72 24 5
96 24 6
85 24 2
94 24 2
84 24 7
67 23 5