^

Capabilities

Capabilities

Code Quality Review

Manual code inspections for today’s systems are no longer cost-effective due to the increasing size and complexity of modern applications. Instead, developers need to quickly and effectively assess the quality of their code using software metrics for testability, maintainability, and clarity. Each of these characteristics are fundamental in the overall assessment of code quality, and the process for determining them requires software quality metrics tools to efficiently measure code quality.

In combination, these measures provide sound indicators of properties of the code base, including its testability, maintainability, and clarity. These three software quality attributes are fundamental in the overall assessment of code quality.

What is software code quality?

According to the Oxford English Dictionary, in this context the word “quality” might be defined as “the degree of excellence possessed by a thing.” For any measure of software quality to be meaningful, the concept of software quality must be quantified.
Excellence is clearly a desirable characteristic, but a more common aim from a commercial perspective is to achieve adequate software quality. Clearly, the definition of what might be adequate will likely be more demanding for (say) an aircraft flight controller than it would be for a home entertainment system.
Although software quality may be achieved by adherence to something like a functional safety or cybersecurity standard, there is also merit in achieving software quality irrespective of such standards.

What is a software quality model?

A software quality model is a framework that defines the characteristics and attributes of software quality and how they are related. Different models may have different perspectives, goals, and criteria for evaluating software quality. For example, ISO/IEC 25010:2011 “Systems and software engineering — Systems and software Quality Requirements and Evaluation (SQuaRE) — System and software quality models“ defines:

  • a “quality in use” model, subdivided into five characteristics, and
  • a “product quality” model, subdivided into eight characteristics.

Some of those characteristics are further subdivided.

What are software quality measures (aka software quality metrics) ?

There are many software quality measures available. The popularity of each of these varies over time, geographically and according to industry sector. No-one is likely to apply them all concurrently, but each has merit.

They include:

  • Cyclomatic complexity & Essential Cyclomatic Complexity
  • Depth of loop nesting
  • Knots & Essential knots
  • Expansion factor
  • File fan in and fan out
  • LCSAJ density
  • Number and lengths of basic blocks
  • Number of comments, blank lines, and executable lines of code (LoC)
  • Number of LCSAJs
  • Number of loops
  • Number of operands and unique operands
  • Number of procedures
  • Number of unreachable lines, branches, and LCSAJs
  • Procedure exit points
  • Ratios of comments to executable lines
  • Vocabulary

Software code quality review and LDRA tools

Leveraging both static and dynamic analysis, the TBvision component of the LDRA tool suite provides detailed insight into code through graphical visualization tools. Results are presented in various user-friendly formats including call graphs, procedure flow graphs, and data flow analysis reports.

It deploys a software quality model that groups software quality measures into clarity, maintainability, and testability characteristics.

The tool highlights any areas of the code base that would benefit from refactoring to improve these characteristics.

Data Coupling and Control Coupling Analysis is an optional module that examines exactly which variables were used during run-time execution of the application.

Additional information and training materials

FREE 30 Day
TRIAL

Email Us

Email: info@ldra.com

Call Us

EMEA: +44 (0)151 649 9300

USA: +1 (855) 855 5372

INDIA: +91 80 4080 8707

Connect with LDRA