Automated Performance Bug Detection via ML Code Recommendation
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Performance bugs in software systems are difficult to detect due to the absence of fail-stop symptoms, leading to significant performance degradation, increased latency, and reduced throughput, which complicates resource management in complex software systems.
Innovation Solution
An automated system that uses a machine learning classifier to identify performance-related pull requests from source code repositories, constructing a code recommendation table with structural and performance features before and after code changes, and provides code recommendations by matching target method features with similar performance-improved methods.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If performance bugs are not detected, then software systems can operate without intervention, but performance degradation, increased latency, and reduced throughput occur
Solution Approach 1:
The patent replaces manual performance analysis methods with an automated machine learning-based detection system. The system uses ML classifiers to automatically identify performance-related pull requests and construct code recommendation tables, substituting the mechanical/manual process of code review with an automated intelligent system that continuously monitors and detects performance issues.
Solution Approach 2:
The system enables self-service by automatically detecting performance bugs and generating code recommendations without requiring manual intervention. The machine learning model continuously learns from pull requests and automatically constructs code recommendation tables, allowing the system to monitor and improve its own performance detection capabilities over time.
2Measurement precision
If code recommendations are provided based on machine learning classification, then performance bug detection accuracy improves, but system complexity increases
Solution Approach 1:
The patent segments the complex performance detection system into distinct functional modules: a machine learning classifier module for identifying performance-related pull requests, a code recommendation table construction module for organizing and indexing code examples, and a feature extraction module for analyzing code structures. This segmentation allows each component to be developed, maintained, and optimized independently while working together to achieve high detection accuracy.
Data Source
Figure 1
Figure 2
Figure 3
AI summary
An automated system for detecting performance bugs in a program and for providing code recommendations to improve the performance of the program generates a code recommendation table from performance-related pull requests. The performance-related pull requests are identified in part from a classifier trained on semi-supervised data. A code recommendation table is generated from performance-related pull requests and is searched for similarly-improved code based on a set of difference features that includes structural and performance features of the before-code of a pull request that is not in the after-code.