Code Reuse Quantification via Bill of Materials

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current software development lacks an effective automated method to accurately quantify code reuse, as identifying reused lines of code is complex due to the dynamic nature of software development languages and the introduction of new features and languages.

Innovation Solution

An automated system that generates a bill of materials for source code, queries a knowledge base for known call signatures, and estimates the number of reused lines based on detected signatures, refining estimates for unmatched signatures and storing them for future use.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If automated methods are used to identify reused code, then productivity is improved, but measurement precision deteriorates due to the dynamic nature of software languages and new features

Engineering Contradiction:
Improvecode reuse quantification efficiencyVSAvoidreused code identification accuracy
Core Design Contradiction:
ProductivityVSMeasurement precision

Solution Approach 1:

The system performs preliminary actions by generating a bill of materials for the source code before analysis, and by maintaining a knowledge base of known call signatures in advance. This preparation enables the automated quantification process to efficiently match code patterns against pre-established reference data, improving productivity while maintaining precision through structured preliminary organization of analysis resources

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system implements feedback mechanisms by continuously refining reuse estimates based on detected call signatures and by updating the knowledge base with newly identified signatures. The feedback loop allows the system to adjust its measurement precision dynamically as it encounters new code patterns and language features, thereby maintaining accuracy while processing diverse software languages

Inventive Principle:
Principle #23Feedback

2Measurement precision

If comprehensive code analysis is performed to accurately identify reused lines, then measurement precision is improved, but device complexity increases due to handling dynamic languages and new features

Engineering Contradiction:
Improvereused code identification accuracyVSAvoidanalysis system complexity
Core Design Contradiction:
Measurement precisionVSDevice complexity

Solution Approach 1:

The system segments the code analysis process into distinct components: generating a bill of materials, querying for known call signatures, detecting signatures in source code, and calculating reuse estimates. This segmentation reduces device complexity by breaking down the complex task of identifying reused code in dynamic languages into manageable, modular steps that can be independently optimized and maintained

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system introduces intermediaries in the form of a knowledge base that stores known call signatures and a bill of materials that structures the source code information. These intermediaries simplify the analysis process by providing structured intermediate representations that bridge the complexity of dynamic language features and the requirements for accurate reused code identification

Inventive Principle:
Principle #24Intermediary (Mediator)

Data Source

PatentUS20240394051A1Quantifying software code reuse
Publication Date: 2024.11.28 AT&T GLOBAL NETWORK SERVICES BELGIUM LUXEMBOURG SP
  • US20240394051A1 patent drawing
  • US20240394051A1 patent drawing
  • US20240394051A1 patent drawing

AI summary

A method includes generating a bill of materials for a piece of source code, where the piece of source code comprises a plurality of lines of code, providing the bill of materials to a knowledge base with a request for known call signatures, receiving, from the knowledge base, a list comprising a plurality of known call signatures and a plurality of reuse estimates, wherein each reuse estimate of the plurality of reuse estimates indicates an estimate of a number of lines of reused code associated with one call signature of the plurality of known call signatures, generating an initial calculation of a number of lines of reused code that are present in the piece of source code, using the list comprising the plurality of known call signatures, and generating a report indicating an amount of the source code that comprises reused code, based on at least the initial calculation.