Generating compilable machine code programs from dynamic language code
AssigneeManycore Corporation
InventorNicolas Toper
Life of this patent
Estimating the term…
Loading patent…
AssigneeManycore Corporation
InventorNicolas Toper
Estimating the term…
Methods and systems describe providing a compilable machine code program from dynamic language code. First, the system receives a computer program consisting of code in a dynamic language. For each dynamic instruction within the code, the system: identifies all function calls within the code which may call the dynamic instruction; generates a super slice callgraph for all identified function calls for the dynamic instruction, including dependency relationships for instance variables and static variables within time constraints; and generates a set of slices for the dynamic instruction. The system then compiles and executes each slice to identify one or more values for each dynamic instruction. Next, the system updates the computer program such that each of at least a subset of the dynamic instructions is replaced with machine code instructions based on the corresponding values.
A method for generating compilable code for a computer program from dynamic language code, comprising:
A non-transitory computer-readable medium containing instructions for generating compilable code for a computer program from dynamic language code, comprising:
Dependencies are inferred from the claim text.
Drawings are temporarily unavailable. Open the PDF at USPTO
The present invention relates generally to computer science, and more particularly, to methods and apparatuses for generating a compiled program from a dynamic language program.
Within the field of computer science, a major topic of discussion and debate revolves around the merits of dynamic languages and static languages. Many programmers and developers prefer to write computer programs in dynamic languages, such as Python, Ruby, and PHP. Dynamic languages can be altered at runtime, and have flexibility in how a program should be executed at runtime. In contrast to a static or non-dynamic language, these dynamic runtime instructions can be defined by the program itself. While this is powerful and flexible, a major downside is that the usage of dynamic instructions is often very slow.
One example is the use of reflection instructions in Java. Reflection instructions are dynamic instructions defined in an API which is used to examine or modify the behavior of methods, classes, and interfaces at runtime. Reflection gives information about the class to which an object belongs, as well as the methods of that class which can be executed by using the object. Through reflection, methods can be invoked at runtime as long as the name and parameter types of the method are known. This allows the program to be built at runtime.
The present disclosure will become better understood from the detailed description and the drawings, wherein:
FIG. 1A is a diagram illustrating an exemplary environment in which some embodiments may operate.
FIG. 1B is a diagram illustrating an exemplary computer system that may execute instructions to perform some of the methods herein.
In this specification, reference is made in detail to specific embodiments of the invention. Some of the embodiments or their aspects are illustrated in the drawings.
For clarity in explanation, the invention has been described with reference to specific embodiments, however it should be understood that the invention is not limited to the described embodiments. On the contrary, the invention covers alternatives, modifications, and equivalents as may be included within its scope as defined by any patent claims. The following embodiments of the invention are set forth without any loss of generality to, and without imposing limitations on, the claimed invention. In the following description, specific details are set forth in order to provide a thorough understanding of the present invention. The present invention may be practiced without some or all of these specific details. In addition, well known features may not have been described in detail to avoid unnecessarily obscuring the invention.
In addition, it should be understood that steps of the exemplary methods set forth in this exemplary patent can be performed in different orders than the order presented in this specification. Furthermore, some steps of the exemplary methods may be performed in parallel rather than being performed sequentially. Also, the steps of the exemplary methods may be performed in a network environment in which some steps are performed by different computers in the networked environment.
From the US filing history. Foreign family members aren’t listed.
Encoding: optimisation
Optimisation: reducing the execution time required by the program code
Checking; Contextual analysis: dependency analysis; Data or control flow analysis
Compilation: partial evaluation
About 14 years 5 months of term left · ends 24 Mar 2041 (estimated)