Linux / Drivers / Tee
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 213 units with 3,936 lines of code in units (68.8% of code).
    • 1 very long units (114 lines of code)
    • 9 long units (569 lines of code)
    • 56 medium size units (1,833 lines of code)
    • 56 small units (826 lines of code)
    • 91 very small units (594 lines of code)
2% | 14% | 46% | 20% | 15%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
c2% | 14% | 47% | 21% | 14%
h0% | 0% | 0% | 0% | 100%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
optee4% | 14% | 45% | 19% | 16%
ROOT0% | 13% | 44% | 23% | 18%
amdtee0% | 15% | 52% | 24% | 7%
Alternative Visuals
Longest Units
Top 50 longest units
Unit# linesMcCabe index# params
114 21 1
77 13 3
77 14 1
74 13 2
62 23 2
62 8 3
59 8 3
56 11 1
51 17 2
51 12 3
50 16 4
50 7 1
50 7 3
48 10 3
44 4 4
44 12 3
42 7 4
41 7 4
41 7 3
41 8 4
40 12 2
40 8 3
40 5 2
40 6 3
39 9 4
39 12 3
39 9 3
39 7 5
39 6 4
38 8 3
38 13 4
38 5 5
37 7 2
36 7 4
35 11 4
33 10 2
33 6 2
32 8 3
31 5 2
31 10 4
30 4 1
30 5 4
30 9 4
30 6 2
29 5 3
28 5 1
27 10 3
26 10 3
26 4 1
26 5 2