microsoft / ChakraCore-Debugger
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 998 units with 7,303 lines of code in units (54.6% of code).
    • 0 very complex units (0 lines of code)
    • 2 complex units (171 lines of code)
    • 17 medium complex units (855 lines of code)
    • 37 simple units (1,191 lines of code)
    • 942 very simple units (5,086 lines of code)
0% | 2% | 11% | 16% | 69%
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
cpp0% | 2% | 13% | 18% | 65%
h0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lib/Debugger.ProtocolHandler0% | 4% | 2% | 17% | 74%
lib/Debugger.Protocol/Generated/protocol0% | 1% | 17% | 16% | 64%
lib/Debugger.Service0% | 0% | 0% | 9% | 90%
lib/Debugger.Protocol0% | 0% | 0% | 0% | 100%
lib/Debugger.Protocol/Generated/include0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
std::string JsErrorException::TranslateError()
in lib/Debugger.ProtocolHandler/ErrorHelpers.cpp
113 49 1
Token parseToken()
in lib/Debugger.Protocol/Generated/protocol/Protocol.cpp
58 28 4
DispatchResponse::Status DispatcherImpl::evaluate()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
65 21 3
DispatchResponse::Status DispatcherImpl::runScript()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
59 19 3
DispatchResponse::Status DispatcherImpl::evaluateOnCallFrame()
in lib/Debugger.Protocol/Generated/protocol/Debugger.cpp
61 18 3
bool parseStringToken()
in lib/Debugger.Protocol/Generated/protocol/Protocol.cpp
38 18 3
DispatchResponse::Status DispatcherImpl::callFunctionOn()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
56 18 3
JsValueRef RuntimeImpl::GetTypeString()
in lib/Debugger.ProtocolHandler/RuntimeImpl.cpp
58 17 1
bool parseNumberToken()
in lib/Debugger.Protocol/Generated/protocol/Protocol.cpp
44 15 3
bool decodeString()
in lib/Debugger.Protocol/Generated/protocol/Protocol.cpp
52 15 3
DispatchResponse::Status DispatcherImpl::setBreakpointByUrl()
in lib/Debugger.Protocol/Generated/protocol/Debugger.cpp
51 14 3
DispatchResponse::Status UberDispatcher::dispatch()
in lib/Debugger.Protocol/Generated/protocol/Protocol.cpp
49 14 3
DispatchResponse::Status DispatcherImpl::getProperties()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
49 14 3
DispatchResponse::Status DispatcherImpl::setScriptSource()
in lib/Debugger.Protocol/Generated/protocol/Debugger.cpp
44 13 3
bool skipComment()
in lib/Debugger.Protocol/Generated/protocol/Protocol.cpp
33 12 3
std::unique_ptr RemoteObject::fromValue()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
57 12 2
DispatchResponse::Status DispatcherImpl::compileScript()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
41 12 3
DispatchResponse::Status DispatcherImpl::searchInContent()
in lib/Debugger.Protocol/Generated/protocol/Debugger.cpp
40 11 3
std::unique_ptr PropertyDescriptor::fromValue()
in lib/Debugger.Protocol/Generated/protocol/Runtime.cpp
58 11 2
void Debugger::HandleDebugEvent()
in lib/Debugger.ProtocolHandler/Debugger.cpp
28 10 2