Language interoperability to automate code analysis
AssigneeMicrosoft Technology Licensing, LLC
InventorsShao Kun Deng, Matthew Glenn Jin, Shuvendu Lahiri, Xiaoyu Liu, Xin Shi, Neelakantan Sundaresan
Life of this patent
Estimating the term…
Loading patent…
AssigneeMicrosoft Technology Licensing, LLC
InventorsShao Kun Deng, Matthew Glenn Jin, Shuvendu Lahiri, Xiaoyu Liu, Xin Shi, Neelakantan Sundaresan
Estimating the term…
Language interoperability between source code programs not compatible with an interprocedural static code analyzer is achieved through language-independent representations of the programs. The source code programs are transformed into respective intermediate language instructions from which a language-independent control flow graph and a language-independent type environment is created. A program compatible with the interprocedural static code analyzer is generated from the language-independent control flow graph and the language-independent type environment in order to utilize the interprocedural static code analyzer to detect memory safety faults.
A system comprising:
A computer-implemented method comprising:
A computer-implemented method comprising:
Dependencies are inferred from the claim text.
Drawings are temporarily unavailable. Open the PDF at USPTO
From the US filing history. Foreign family members aren’t listed.
Encoding: target code generation
Checking; Contextual analysis: dependency analysis; Data or control flow analysis
Semantic checking: type checking
Transformation of program code: source to source
About 13 years 7 months of term left · ends 13 May 2040 (estimated)
During the development of a program or software, a range of measures is taken to ensure that the program is tested prior to the release and distribution of the program. These measures are aimed at reducing the number of bugs in the program in order to improve the quality of the program. A bug in a source code program is an unintended state in the executing program that results in undesired behavior. Tests are used to identify program errors for a limited number of cases since it is impossible to test all possible user scenarios. Tests are ineffective at discovering unknown bugs or defects, such as resource leaks, memory leaks, null pointer dereferences, and concurrency errors, which are difficult to detect deterministically. Regardless of the amount of testing that is performed on a program, the program may still contain bugs.
Software maintenance makes the corrective measures needed to fix software bugs after the bugs are reported by end users. Fixing the software bugs after deployment of the program hampers the usability of the deployed program and increases the cost of the software maintenance services. Detecting the software bugs prior to the release of the program is a preferred solution. However, when a program includes tens of millions of lines of code, bug detection becomes a complicated task. that the task needs to be performed within the constraints of resource and developer availability which may be limited.
This Summary is provided to introduce a selection of concepts in a simplified form that are further described below in the Detailed Description. This Summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
FIG. 1 illustrates an exemplary language interoperability system for statically analyzing a program.
FIG. 2 is a flow diagram illustrating an exemplary method of a language interoperatibility system for statically analyzing a program.
FIG. 3 is an exemplary illustration of a C# method that is converted into corresponding Common Intermediate Language (CIL) instructions.
Overview
Aspects of the present invention pertains to the interoperability of programs supported by the .NET framework with an analysis language used for an interprocedural static code analysis. The .NET framework is collection of programming languages and development tools (e.g., compilers, libraries, runtime, specifications, intermediate language) used to develop and execute software (e.g., applications, programs, code) to runs on Microsoft® operating systems. Interprocedural static code analysis is a technique that analyzes programs for memory safety issues such as null pointer dereferences, memory leaks, and resource leaks. One particular interprocedural static code analyzer uses Separation Logic in its memory safety analysis of a programs. The analysis language is not compatible with a number of commonly-used programming languages and development frameworks.
The mechanisms and techniques described herein provide a language interoperability system that allows programs supported by the .NET framework and other programming languages (e.g., Python, JavaScript), to utilize code analysis tools having limited cross-language tools. Language interoperability issues arise due to analyzer's reliance on a relatively uncommon analysis language that has limited cross-language libraries and other tools to facilitate language interoperability. The language interoperability system disclosed herein is a bridge that accounts for the limitation of cross-language tools.