Linux / Drivers / Thunderbolt
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 844 units with 14,084 lines of code in units (71.5% of code).
    • 0 very complex units (0 lines of code)
    • 2 complex units (157 lines of code)
    • 41 medium complex units (2,208 lines of code)
    • 118 simple units (3,393 lines of code)
    • 683 very simple units (8,326 lines of code)
0% | 1% | 15% | 24% | 59%
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
c0% | 1% | 15% | 24% | 58%
h0% | 0% | 0% | 9% | 90%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
ROOT0% | 1% | 15% | 24% | 59%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
104 32 1
53 30 3
69 23 1
35 23 1
38 21 5
51 20 2
56 19 1
70 18 1
58 18 3
80 17 1
42 16 1
62 16 3
83 16 1
58 16 1
74 15 2
56 15 4
61 14 1
62 14 5
58 14 2
43 14 1
46 14 8
43 14 1
43 14 2
57 14 4
49 13 3
76 12 1
42 12 1
46 12 1
43 12 1
50 12 2
44 12 4
44 12 2
62 12 1
71 12 1
44 11 1
29 11 2
72 11 1
43 11 8
29 11 1
42 11 3
63 11 3
66 11 7
48 11 2
31 10 1
38 10 2
16 10 1
38 10 6
54 10 1
46 10 2
48 10 2