IP Library Granted Patent US 8,527,965
Granted Patent B2
US 8,527,965 · App. 12/102,796 · Granted Sep 3, 2013

Layered static program analysis framework for software testing

Inventors: Cristina N. Cifuentes (Forest Lake, AU); Bernhard F. Scholz (Sydney, AU)
Assignee: Oracle America, Inc.
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 8,527,965
App. No.
12/102,796
Granted
Sep 3, 2013
Kind
B2
Abstract

A method for analyzing a set of potential bug statements in source code. The method including obtaining a set of static program analyses; recursively reducing the set of potential bug statements in the source code by: selecting a static program analysis for each recursion from the set of static program analyses in order from least time consuming to most time consuming; evaluating the set of potential bug statements using the static program analysis of the set of static program analyses to determine a subgroup of bug free statements of the set of potential bug statements in each recursion; and removing the subgroup of the bug free statements from the set of potential bug statements to reduce the set of potential bug statements in each recursion; thereby filtering at least one subgroup of bug free statements out of the set of potential bug statements in the source code.

Claims (66)

1. A method for analyzing a plurality of potential bug statements in source code, comprising:

obtaining a plurality of static program analyses;

recursively reducing the plurality of potential bug statements in the source code by:

selecting a static program analysis for each recursion from the plurality of static program analyses in order from least time consuming to most time consuming;

evaluating the plurality of potential bug statements using the static program analysis of the plurality of static program analyses to determine a subgroup of bug free statements of the plurality of potential bug statements in each recursion, wherein evaluating the plurality of potential bug statements comprises:

evaluating a first potential bug statement using a first static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement, wherein if it cannot be determined whether the first potential bug statement is a bug free statement and subsequent to evaluating the first potential bug statement using the first static program analysis, concurrently:

evaluating the first potential bug statement using a second static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement; and

evaluating a second potential bug statement using the first static program analysis to determine whether the second potential bug statement is a bug free statement,

wherein the first static program analysis is less time consuming than the second static program analysis; and

removing the subgroup of the bug free statements from the plurality of potential bug statements to reduce the plurality of potential bug statements in each recursion;

thereby filtering at least one subgroup of bug free statements out of the plurality of potential bug statements in the source code.

2. The method of claim 1 , further comprising modifying at least one potential bug statement of a remaining plurality of potential bug statements.

3. The method of claim 1 , wherein the plurality of static program analyses comprises at least two static program analyses.

4. The method of claim 1 , further comprising:

evaluating the plurality of potential bug statements using the static program analysis of the plurality of static program analyses to determine a subgroup of real bug statements of the plurality of potential bug statements in each recursion;

removing the subgroup of the real bug statements from the plurality of potential bug statements to reduce the plurality of potential bug statements in each recursion; and

subsequent to recursively reducing the plurality of potential bug statements, modifying at least one real bug statement of the subgroup of real bug statements.

5. The method of claim 1 , wherein a time consumption of the static program analysis is determined based on a runtime complexity estimate.

6. The method of claim 5 , wherein the runtime complexity estimate is one from a group consisting of linear, exponential, and logarithmic.

7. A system for analyzing a plurality of potential bug statements, comprising:

a computer processor;

a results repository comprising:

a plurality of potential bug statements;

a static analysis engine executing on the computer processor and comprising functionality to recursively:

select a static program analysis for each recursion from a plurality of static program analyses in order from least time consuming to most time consuming;

evaluate the plurality of potential bug statements using the static program analysis of the plurality of static program analyses to determine a subgroup of bug free statements of the plurality of potential bug statements in each recursion, wherein evaluating the plurality of potential bug statements comprises:

evaluating a first potential bug statement using a first static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement, wherein if it cannot be determined whether the first potential bug statement is a bug free statement and subsequent to evaluating the first potential bug statement using the first static program analysis, concurrently:

evaluating the first potential bug statement using a second static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement; and

evaluating a second potential bug statement using the first static program analysis to determine whether the second potential bug statement is a bug free statement,

wherein the first static program analysis is less time consuming than the second static program analysis; and

remove the subgroup of the bug free statements from the plurality of potential bug statements to reduce the plurality of potential bug statements in each recursion; and

a statement modifier executing on the computer processor and comprising functionality to:

modify at least one potential bug statement of the plurality of potential bug statements.

8. The system of claim 7 , wherein the plurality of static program analyses comprises at least two static program analyses.

9. The system of claim 7 , wherein the static analysis engine further comprises functionality to recursively:

evaluate the plurality of potential bug statements using the static program analysis of the plurality of static program analyses to determine a subgroup of real bug statements of the plurality of potential bug statements in each recursion; and

remove the subgroup of the real bug statements from the plurality of potential bug statements to reduce the plurality of potential bug statements in each recursion;

wherein the statement modifier further comprises functionality to:

modify at least one real bug statement of the subgroup of real bug statements.

10. The system of claim 7 , wherein the static analysis engine further comprises functionality to:

determine a time consumption of the static program analysis based on a runtime complexity estimate of the static program analysis.

11. The system of claim 10 , wherein the runtime complexity estimate is one from a group consisting of: linear; exponential; and logarithmic.

12. A non-transitory computer readable medium comprising instructions for analyzing a plurality of potential bug statements, the instructions comprising functionality for:

obtaining a plurality of static program analyses;

recursively reducing the plurality of potential bug statements in the source code by:

selecting a static program analysis for each recursion from the plurality of static program analyses in order from least time consuming to most time consuming;

evaluating the plurality of potential bug statements using the static program analysis of the plurality of static program analyses to determine a subgroup of bug free statements of the plurality of potential bug statements in each recursion, wherein evaluating the plurality of potential bug statements comprises:

evaluating a first potential bug statement using a first static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement, wherein if it cannot be determined whether the first potential bug statement is a bug free statement and subsequent to evaluating the first potential bug statement using the first static program analysis, concurrently:

evaluating the first potential bug statement using a second static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement; and

evaluating a second potential bug statement using the first static program analysis to determine whether the second potential bug statement is a bug free statement,

wherein the first static program analysis is less time consuming than the second static program analysis; and

removing the subgroup of the bug free statements from the plurality of potential bug statements to reduce the plurality of potential bug statements in each recursion;

thereby filtering at least one subgroup of bug free statements out of the plurality of potential bug statements in the source code.

13. The non-transitory computer readable medium of claim 12 , wherein the plurality of static program analyses comprises at least two static program analyses.

14. The non-transitory computer readable medium of claim 12 , wherein the instructions further comprising functionality for:

evaluating the plurality of potential bug statements using the static program analysis of the plurality of static program analyses to determine a subgroup of real bug statements of the plurality of potential bug statements in each recursion;

removing the subgroup of the real bug statements from the plurality of potential bug statements to reduce the plurality of potential bug statements in each recursion; and

subsequent to recursively reducing the plurality of potential bug statements, modifying at least one real bug statement of the subgroup of real bug statements.

15. The non-transitory computer readable medium of claim 12 , wherein the instructions further comprising functionality for:

evaluating a first potential bug statement using a first static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement, wherein it cannot be determined whether the first potential bug statement is a bug free statement; and

subsequent to evaluating the first potential bug statement using the first static program analysis, concurrently:

evaluating the first potential bug statement using a second static program analysis of the plurality of static program analyses to determine whether the first potential bug statement is a bug free statement; and

evaluating a second potential bug statement using the first static program analysis to determine whether the second potential bug statement is a big free statement,

wherein the first static program analysis is less time consuming than the second static program analysis.

16. The non-transitory computer readable medium of claim 12 , wherein a time consumption of the static program analysis is determined based on a runtime complexity estimate.

17. The non-transitory computer readable medium of claim 16 , wherein the runtime complexity estimate is one from a group consisting of linear, exponential, and logarithmic.

Assignments (2)
MERGER AND CHANGE OF NAME Recorded Dec 16, 2015
From: ORACLE USA, INC.; SUN MICROSYSTEMS, INC.; ORACLE AMERICA, INC.
To: ORACLE AMERICA, INC.
Reel/Frame 037311/0206 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 30, 2008
From: CIFUENTES, CRISTINA N.; SCHOLZ, BERNHARD F.
To: SUN MICROSYSTEMS, INC.
Reel/Frame 021042/0061 →
Continuity (1)
Related Publication 20090259989A1 · Oct 15, 2009