Linux / Drivers / Cxl
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 114 units with 1,832 lines of code in units (62.4% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 2 medium complex units (88 lines of code)
    • 19 simple units (653 lines of code)
    • 93 very simple units (1,091 lines of code)
0% | 0% | 4% | 35% | 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% | 0% | 4% | 35% | 59%
h0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
core0% | 0% | 4% | 29% | 65%
ROOT0% | 0% | 4% | 42% | 52%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
49 18 3
39 12 2
34 10 2
59 10 2
49 8 3
52 8 6
28 8 3
49 8 2
34 7 1
37 7 3
16 7 1
38 7 1
35 7 1
33 7 2
23 6 6
24 6 2
21 6 2
15 6 1
47 6 3
28 6 2
31 6 1
38 5 1
20 5 4
21 5 2
28 5 4
23 5 3
37 5 2
25 4 3
22 4 1
22 4 2
42 4 3
21 4 3
17 4 1
23 4 3
20 4 2
19 3 3
17 3 1
12 3 3
8 3 1
22 3 4
17 3 3
31 3 1
18 3 1
15 3 2
8 3 1
16 3 1
21 3 2
18 3 2
14 3 3
13 3 3