microsoft / MIEngine
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 1,975 units with 27,710 lines of code in units (65.4% of code).
    • 2 very complex units (581 lines of code)
    • 10 complex units (1,517 lines of code)
    • 64 medium complex units (4,325 lines of code)
    • 164 simple units (5,946 lines of code)
    • 1,735 very simple units (15,341 lines of code)
2% | 5% | 15% | 21% | 55%
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
cs2% | 5% | 15% | 21% | 55%
csx0% | 0% | 71% | 0% | 28%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/MIDebugEngine6% | 3% | 18% | 19% | 51%
src/OpenDebugAD70% | 13% | 26% | 21% | 38%
src/AndroidDebugLauncher0% | 18% | 6% | 34% | 40%
src/MICore0% | 2% | 10% | 23% | 63%
src/tools0% | 45% | 0% | 20% | 34%
src/MIDebugPackage0% | 0% | 63% | 0% | 36%
src/WindowsDebugLauncher0% | 0% | 44% | 8% | 46%
tools0% | 0% | 71% | 0% | 28%
src/SSHDebugPS0% | 0% | 4% | 29% | 66%
src/IOSDebugLauncher0% | 0% | 24% | 40% | 35%
src/DebugEngineHost0% | 0% | 0% | 19% | 80%
tools/iOS0% | 0% | 0% | 49% | 50%
src/JDbg0% | 0% | 0% | 7% | 92%
src/DebugEngineHost.VSCode0% | 0% | 0% | 0% | 100%
src/SSHDebugTests0% | 0% | 0% | 0% | 100%
src/DebugEngineHost.Stub0% | 0% | 0% | 0% | 100%
src/MakePIAPortable0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public DebuggedProcess()
in src/MIDebugEngine/Engine.Impl/DebuggedProcess.cs
314 56 8
private async Task HandleBreakModeEvent()
in src/MIDebugEngine/Engine.Impl/DebuggedProcess.cs
267 53 2
private LaunchOptions SetupForDebuggingWorker()
in src/AndroidDebugLauncher/Launcher.cs
244 36 1
private string StripFormatSpecifier()
in src/MIDebugEngine/Engine.Impl/Variables.cs
64 36 2
public void SetFrameInfo()
in src/MIDebugEngine/AD7.Impl/AD7StackFrame.cs
135 35 3
internal async Task Eval()
in src/MIDebugEngine/Engine.Impl/Variables.cs
120 32 3
public static LaunchOptions GetInstance()
in src/MICore/LaunchOptions.cs
157 30 9
194 30 1
176 29 1
protected override void HandleAttachRequestAsync()
in src/OpenDebugAD7/AD7DebugSession.cs
154 27 1
private string InterpolateToken()
in src/OpenDebugAD7/Tracepoint.cs
130 27 6
private static int TransformIL()
in src/tools/MakePIAPortableTool/MakePIAPortableTool.cs
143 26 2
protected void InitializeCommonOptions()
in src/MICore/LaunchOptions.cs
69 23 1
private static int Main()
in src/OpenDebugAD7/OpenDebug/Program.cs
112 23 1
private async Task UpdateCategory()
in src/MIDebugEngine/Engine.Impl/ExceptionManager.cs
114 22 3
protected override void HandleLaunchRequestAsync()
in src/OpenDebugAD7/AD7DebugSession.cs
147 22 1
protected override void HandleEvaluateRequestAsync()
in src/OpenDebugAD7/AD7DebugSession.cs
123 22 1
public DEBUG_PROPERTY_INFO ConstructDebugPropertyInfo()
in src/MIDebugEngine/AD7.Impl/AD7Property.cs
82 21 1
private static int Main()
in src/WindowsDebugLauncher/Program.cs
96 21 1
public int Compare()
in src/MIDebugEngine/AD7.Impl/AD7MemoryAddress.cs
86 20 4