microsoft / MSIX-PackageSupportFramework
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 2,369 units with 27,289 lines of code in units (51.3% of code).
    • 6 very complex units (1,661 lines of code)
    • 11 complex units (1,806 lines of code)
    • 88 medium complex units (5,577 lines of code)
    • 148 simple units (4,961 lines of code)
    • 2,116 very simple units (13,284 lines of code)
6% | 6% | 20% | 18% | 48%
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
cs40% | 0% | 28% | 11% | 18%
cpp3% | 12% | 27% | 25% | 31%
h1% | 2% | 12% | 13% | 69%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
PsfShimMonitor40% | 0% | 28% | 11% | 18%
Detours6% | 12% | 28% | 20% | 32%
include/rapidjson4% | 7% | 20% | 14% | 52%
fixups/FileRedirectionFixup0% | 13% | 24% | 38% | 22%
fixups/RegLegacyFixups0% | 15% | 19% | 28% | 35%
include/wil0% | 0% | 7% | 9% | 82%
PsfRuntime0% | 0% | 45% | 4% | 49%
PsfLauncher0% | 0% | 15% | 18% | 66%
fixups/ElectronFixup0% | 0% | 8% | 13% | 77%
fixups/DynamicLibraryFixup0% | 0% | 0% | 53% | 46%
include0% | 0% | 0% | 16% | 83%
PsfRunDll0% | 0% | 0% | 100% | 0%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
void EnableKernelTrace()
in PsfShimMonitor/KernelTrace.cs
743 113 1
private bool ApplyFilterCategoryEventToEventItem()
in PsfShimMonitor/MainWindow.xaml.cs
239 113 1
void ParseNumber()
in include/rapidjson/reader.h
232 93 2
55 68 1
55 68 1
BOOL CImage::Write()
in Detours/image.cpp
337 64 1
BOOL CImage::Read()
in Detours/image.cpp
250 45 1
void Parse()
in include/rapidjson/internal/regex.h
107 37 1
LONG WINAPI DetourAttachEx()
in Detours/detours.cpp
288 36 5
static path_redirect_info ShouldRedirectImpl()
in fixups/FileRedirectionFixup/PathRedirection.cpp
206 34 3
REGSAM RegFixupSam()
in fixups/RegLegacyFixups/RegistryFixups.cpp
167 34 3
BOOL CImage::EditImports()
in Detours/image.cpp
138 32 5
static BOOL UPDATE_IMPORTS_XX()
in Detours/uimports.cpp
202 32 3
105 31 5
void Parse()
in include/rapidjson/pointer.h
106 29 2
BOOL __stdcall FindNextFileFixup()
in fixups/FileRedirectionFixup/FindFirstFileFixup.cpp
164 28 2
RAPIDJSON_FORCEINLINE bool EndValue()
in include/rapidjson/schema.h
73 28 1
68 25 1
HANDLE __stdcall FindFirstFileExFixup()
in fixups/FileRedirectionFixup/FindFirstFileFixup.cpp
166 25 3
105 24 4