aws / aws-nitro-enclaves-sdk-c
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 47 units with 1,174 lines of code in units (33.6% of code).
    • 1 very long units (122 lines of code)
    • 3 long units (171 lines of code)
    • 18 medium size units (576 lines of code)
    • 17 small units (238 lines of code)
    • 8 very small units (67 lines of code)
10% | 14% | 49% | 20% | 5%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
c10% | 14% | 49% | 20% | 5%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
source10% | 14% | 49% | 20% | 5%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
122 43 4
61 7 5
55 7 3
55 7 3
48 5 4
45 7 3
38 8 3
36 9 1
34 7 4
int aws_attestation_request()
in source/attestation.c
34 8 3
int aws_attestation_rsa_decrypt()
in source/attestation.c
34 10 4
33 6 4
33 7 3
32 4 4
29 5 3
28 8 1
28 2 4
26 5 5
25 5 3
25 7 1