Patent classifications
G06F8/437
Handling value types
In one approach, a method comprises receiving one or more higher-level instructions specifying to assign a value of a particular value type to a particular container of a plurality of containers, wherein the plurality of containers represent a data structure for maintaining one or more variables during execution of a block of code, wherein at least two containers of the plurality of containers are different sizes; generating one or more lower-level instructions that assign the value to the particular container based on applying one or more assignment rules to the one or more higher-level instructions based on the particular value type and executing the one or more lower-level instructions.
PROGRAM REWRITE DEVICE, STORAGE MEDIUM, AND PROGRAM REWRITE METHOD
A program rewrite method executed by a computer, the method includes rewriting a program to output a first output group by performing operations for a first variable among a plurality of variables with a plurality of data types; rewriting the program to output a second output group by performing operations for a second variable among the plurality of variables with a plurality of data types; identifying, from the first output group and the second output group, a third output group that satisfied a predetermined criterion as a result of executing the rewritten programs; determining a data type that corresponds to the third output group as a use data type; and outputting a program in which the use data type is set for each of the plurality of variables.
Language interoperability to automate code analysis
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.
Implementing optional specialization when compiling code
A compiler is capable of compiling instructions that do or do not supply specialization information for a generic type. The generic type is compiled into an unspecialized type. If specialization information was supplied, the unspecialized type is adorned with information indicating type restrictions for application programming interface (API) points associated with the unspecialized type, which becomes a specialized type. A runtime environment is capable of executing calls to a same API point that do or do not indicate a specialized type, and is capable of executing calls to a same API point of objects of an unspecialized type or of objects of a specialized type. When the call to an API point indicates a specialized type, and the specialized type matches that of the object (if the API point belongs to an object), then a runtime environment may perform optimized accesses based on type restrictions derived from the specialized type.
Instantiating a parametric class within a specialized context
A parametric constant resolves to different values in different contexts, but a single value within a particular context. An anchor constant is a parametric constant that allows for a degree of parametricity for an API point. The context for the anchor constant is provided by a caller to the API point. The anchor constant resolves to an anchor value that records specialization decisions for the API point within the provided context. Specialization decisions may include type restrictions, memory layout, and/or memory size. The anchor value together with an unspecialized type of the API point result in a specialized type of the API point. A class object representing the specialized type is created. The class object may be accessible to the caller, but the full value of the anchor value is not accessible to the caller. The API point is executed based on the specialization decisions embodied in the anchor value.
Type inference optimization
Operations include (a) identifying bounds corresponding to two or more inference variables corresponding to a nested method invocation context, (b) determining that resolution of a first inference variable can be determined as a function of a resolution of a second inference variable, (c) propagating bounds corresponding to the second inference variable from the nested method invocation context to an outer method invocation context without propagating bounds corresponding to the first inference variable, (d) resolving a constraint set to resolve the second inference variable, and (e) resolving the first inference variable based on the resolution of the second inference variable.
Artificial intelligence engine for mixing and enhancing features from one or more trained pre-existing machine-learning models
An AI engine having an architect module to create a number of nodes and how the nodes are connected in a graph of concept nodes that make up a resulting AI model. The architect module also creates a first concept node by wrapping an external entity of code into a software container with an interface configured to exchange information in a protocol of a software language used by the external entity of code. The architect module also creates a second concept node derived from its description in a scripted file coded in a pedagogical programming language, and connects the second concept node into the graph of nodes in the resulting AI model.
Data flow retyping for functional programming languages
The type system of a functional programming language, such as DataWeave and/or the like, may be extended to add valuable semantic information to data types (e.g., attributes of data that inform a compiler/interpreter how the data should be used, etc.) that is automatically generated and/or hidden from a developer/programmer. For example, the type system may be configured for flow typing, based on a graph of type dependencies between expressions, without modifying an existing implementation, except at places where extra information can be obtained. Different parts of the type system implementation may be modified, for example, based on one or more injected retyper nodes, to provide more and better type inference.
Systems and methods for handling macro compatibility for documents at a storage system
A document to be stored on a network-based storage system is identified. The document includes one or more macros in a first programming language. An object referenced by a function defined by a macro of the one or more macros is identified. The function is converted into one or more sets of operations represented in a second programming language. Each set of operations corresponds to one of one or more candidate object types associated with the object. At least one of the one or more sets of operations is to be performed with respect to the object responsive to indication of a corresponding candidate object type for the object during execution of the macro. The document including the one or more sets of operations represented in the second programming language is stored on the network-based storage system.
Systems and methods for handling macro compatibility for documents at a storage system
Systems and methods for handling macro compatibility for documents at a storage system are provided. A document to be stored on a network-based storage system is identified. The document is created using a first document processing application that uses a first programming language that is incompatible with the network-based storage system. The document includes macros in the first programming language. A semantic context for an object included in a macro is determined. The macro defines a function to be performed with respect to the object. In response to a determination, based on the semantic context of the object, that the object corresponds to multiple object types, a set of candidate object types for the object is identified. The function is converted into multiple sets of operations represented in a second programming language. Each set of operations is associated with a candidate object type and one set of operations is to be performed with respect to the object responsive to receiving an indication of a candidate object type for the object during execution of the macro. The document including the multiple sets of operations represented in the second programming language is stored on the network-based storage system. The second programming language is compatible with the network-based storage system.