Static Testing of Decomposed Software Units via Interface Contracts

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current software testing tools struggle to effectively detect and prevent runtime errors, especially in complex and safety-critical systems, due to scalability issues and high rates of false positive error messages, which can lead to undetected errors and increased development costs.

Innovation Solution

A computer-implemented method for static testing of software systems decomposed into multiple units, where context information and contracts are used to test individual software units independently, reducing false positives and enabling precise analysis by considering the planned behavior and context of each unit, even in heterogeneous systems.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If comprehensive testing of all software configurations is performed, then error detection capability is improved, but testing time and resource consumption increase exponentially

Engineering Contradiction:
Improveerror detection capabilityVSAvoidtesting time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent segments the software system into individual software units and tests them separately using static analysis. Instead of testing the entire system across all possible configurations, each software unit is analyzed independently for runtime errors, dramatically reducing the testing scope from exponential to linear complexity.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent performs static testing during the development phase before the software is deployed or executed. By analyzing the code structure, data flows, and control flows in advance, potential runtime errors are detected early without requiring actual execution of all possible configurations.

Inventive Principle:
Principle #10Preliminary action

2Reliability

If formal verification methods are applied to ensure absence of errors, then software reliability is improved, but complexity of the verification process increases

Engineering Contradiction:
Improvesoftware error-free guaranteeVSAvoidverification process complexity
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent extracts and analyzes specific properties relevant to runtime errors (such as division by zero, array bounds violations, null pointer dereferences) separately from the overall software verification. By focusing only on these specific error types through static analysis of data and control flows, the verification process becomes more manageable while still providing strong reliability guarantees.

Inventive Principle:
Principle #2Taking out (Extraction)

3Productivity

If software units are tested in isolation, then testing efficiency is improved, but accuracy of error detection decreases due to lack of context information

Engineering Contradiction:
Improvetesting efficiencyVSAvoiderror detection accuracy
Core Design Contradiction:
ProductivityVSMeasurement precision

Solution Approach 1:

The patent uses interface contracts as intermediaries between software units. These contracts define preconditions and postconditions that capture the expected behavior and data flow at unit boundaries. During static analysis, these contracts provide the necessary context information to accurately detect errors even when units are tested in isolation, bridging the gap between unit-level analysis and system-level correctness.

Inventive Principle:
Principle #24Intermediary (Mediator)

4Reliability

If conservative analysis is used to ensure soundness, then false negative rate is reduced, but false positive rate increases

Engineering Contradiction:
Improvesoundness of analysisVSAvoidfalse positive error messages
Core Design Contradiction:
ReliabilityVSObject-generated harmful factors

Solution Approach 1:

The patent employs dynamic width analysis that adapts the precision of analysis based on the specific context. The analysis starts with abstract interpretations and progressively refines the analysis depth and precision based on detected patterns and confidence levels. This dynamic approach maintains soundness while reducing false positives by focusing computational resources where they are most needed.

Inventive Principle:
Principle #15Dynamics

Data Source

PatentUS11977478B2Compositional verification of embedded software systems
Publication Date: 2024.05.07 ROBERT BOSCH GMBH
  • US11977478B2 patent drawing
  • US11977478B2 patent drawing
  • US11977478B2 patent drawing

AI summary

A computer-implemented method for static testing a software system that is decomposed into software units connected by interfaces. The method comprises receiving context information for an interface, which includes at least one postcondition for the at least one output variable of a respective first software unit and/or a precondition for the input variable of a respective second software unit; receiving a selection of a third software unit in so that a substitute decomposition appertaining thereto of the software system into the third software unit and a complement of the third software unit is produced, the third software unit and the complement forming the software system and being connected via a substitute interface; selecting, based on the item of context information a postcondition per output variable of the complement; and testing whether the selected postcondition can be forward-propagated by the third software unit with regard to a formal verification.