Method and system for program transformation using flow-sensitive type constraint analysis
First Claim
1. A method for building an application, comprising:
- providing an application builder that receives source code instruction of a program;
determining the minimum amount of optimum code requirement for the source code instruction;
wherein the determining comprises;
determining variable size of program functions in the program based on a set of constraints;
wherein the determining variable size comprises;
If a variable is discrete, hard-coding a single value; and
if a first variable is assigned to a second variable, then merging a size constraint of the first variable into a size constraint of the second variable;
reducing the variable size of the program functions for program execution based on the determination of the variable size; and
compiling the program functions into native processor functions comprising native functions that return a declared type, native functions that return a fixed set of types, and native functions that return types that vary according to input parameters of the native functions;
wherein the compiling comprises performing specialized type constraint analysis for the native functions to determine return type constraints associated with the returns based on input type constraints according to the specification of the native functions.
3 Assignments
0 Petitions
Accused Products
Abstract
A method for analyzing a program is provided. The method includes, determining an object type that may exist at an execution point of the program, wherein this enables determination of possible virtual functions that may be called; creating a call graph at a main entry point of the program; and recording an outgoing function call within a main function. The method also includes analyzing possible object types that may occur at any given instruction from any call path for virtual calls, wherein possible object types are determined by tracking object types as they pass through plural constructs; and calling into functions generically for handling specialized native runtime type information.
-
Citations
8 Claims
-
1. A method for building an application, comprising:
-
providing an application builder that receives source code instruction of a program;
determining the minimum amount of optimum code requirement for the source code instruction;
wherein the determining comprises;
determining variable size of program functions in the program based on a set of constraints;
wherein the determining variable size comprises;
If a variable is discrete, hard-coding a single value; and
if a first variable is assigned to a second variable, then merging a size constraint of the first variable into a size constraint of the second variable;reducing the variable size of the program functions for program execution based on the determination of the variable size; and compiling the program functions into native processor functions comprising native functions that return a declared type, native functions that return a fixed set of types, and native functions that return types that vary according to input parameters of the native functions;
wherein the compiling comprises performing specialized type constraint analysis for the native functions to determine return type constraints associated with the returns based on input type constraints according to the specification of the native functions. - View Dependent Claims (2, 3, 4)
-
-
5. A computer readable storage medium storing computer-executable process steps of a process for building an application, comprising:
-
providing an application builder that receives source code instruction of a program; determining the minimum amount of optimum code requirement for the source code instruction;
wherein the determining comprises;
determining variable size of program functions in the program based on a set of constraints;
wherein the determining variable size comprises;
If a variable is discrete, hard-coding a single value; and
if a first variable is assigned to a second variable, then merging a size constraint of the first variable into a size constraint of the second variable;reducing the variable size of the program functions for program execution based on the determination of the variable size; and compiling the program functions into native processor functions comprising native functions that return a declared type native functions that return a fixed set of types, and native functions that return types that vary according to input parameters of the native functions;
wherein the compiling comprises performing specialized type constraint analysis for the native functions to determine return type constraints associated with the returns based on input type constraints according to the specification of the native functions. - View Dependent Claims (6, 7, 8)
-
Specification