Linux / Drivers / Bluetooth
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 782 units with 18,251 lines of code in units (76.0% of code).
    • 1 very complex units (270 lines of code)
    • 2 complex units (314 lines of code)
    • 83 medium complex units (5,422 lines of code)
    • 126 simple units (4,785 lines of code)
    • 570 very simple units (7,460 lines of code)
1% | 1% | 29% | 26% | 40%
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
c1% | 1% | 30% | 26% | 40%
h0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
ROOT1% | 1% | 29% | 26% | 40%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
270 77 2
198 42 1
116 33 1
79 25 2
99 24 1
139 23 1
91 22 5
64 21 1
85 21 2
84 21 1
77 21 3
132 20 1
119 20 3
51 19 2
60 18 1
88 18 2
115 18 1
95 18 1
85 17 2
84 17 1
92 17 2
71 17 1
127 17 1
61 17 6
79 17 4
49 16 1
58 16 1
54 15 2
43 15 1
63 15 1
73 15 4
24 15 2
90 15 3
35 15 1
78 15 1
68 15 4
93 14 1
76 14 1
63 14 1
84 14 1
99 14 1
62 14 1
46 14 2
83 14 1
58 14 1
34 13 1
31 13 1
85 13 1
98 13 3
44 13 1