Linux / Drivers / Remoteproc
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 567 units with 12,071 lines of code in units (70.1% of code).
    • 7 very long units (908 lines of code)
    • 44 long units (3,021 lines of code)
    • 141 medium size units (4,409 lines of code)
    • 156 small units (2,320 lines of code)
    • 219 very small units (1,413 lines of code)
7% | 25% | 36% | 19% | 11%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
c7% | 25% | 37% | 19% | 10%
h0% | 0% | 0% | 25% | 75%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
ROOT7% | 25% | 36% | 19% | 11%
Alternative Visuals
Longest Units
Top 50 longest units
Unit# linesMcCabe index# params
154 31 1
152 16 1
138 21 1
137 24 1
115 29 2
109 19 1
103 22 1
98 12 1
96 16 1
96 16 1
91 13 1
90 8 1
90 21 1
90 19 1
89 14 1
87 17 6
80 16 2
78 14 1
78 21 1
77 8 2
74 14 4
74 14 1
72 10 1
70 10 1
70 11 1
70 8 1
70 10 1
67 12 1
65 10 1
65 8 1
64 11 2
64 9 2
63 12 3
61 10 1
59 12 1
58 12 1
57 10 1
57 9 1
57 13 2
56 10 2
56 8 1
56 11 1
55 12 1
54 11 2
54 7 1
54 10 1
53 3 1
53 8 1
51 7 1
51 8 2