Linux / Drivers / Pwm
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 557 units with 10,506 lines of code in units (69.8% of code).
    • 0 very complex units (0 lines of code)
    • 2 complex units (169 lines of code)
    • 24 medium complex units (1,591 lines of code)
    • 85 simple units (3,091 lines of code)
    • 446 very simple units (5,655 lines of code)
0% | 1% | 15% | 29% | 53%
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% | 29% | 53%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
ROOT0% | 1% | 15% | 29% | 53%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
73 30 2
96 26 3
92 25 1
98 23 3
105 23 4
95 23 4
59 22 2
57 20 3
67 19 4
53 17 4
86 17 1
71 16 3
56 16 4
56 14 1
44 13 6
76 13 3
68 13 1
51 13 4
70 12 1
60 12 1
46 11 3
38 11 1
45 11 1
76 11 3
55 11 2
67 11 1
53 10 3
49 10 1
48 10 1
32 10 1
40 10 3
59 10 2
42 10 2
29 9 3
40 9 1
56 9 4
52 9 3
36 9 5
40 9 4
54 9 1
48 9 1
42 9 4
31 9 4
83 9 1
33 9 3
40 8 1
51 8 4
34 8 4
40 8 1
51 8 3